--- libxrandr-1.2.99.2.orig/ChangeLog +++ libxrandr-1.2.99.2/ChangeLog @@ -0,0 +1,536 @@ +commit bf476779616b24c6456339bc77896460f1a2545a +Author: Adam Jackson +Date: Wed Jul 2 15:28:08 2008 -0400 + + libXrandr 1.2.3 + +commit 203fc002b6948c3942f0461a0346dd07b633222d +Author: thb +Date: Mon Jun 23 13:25:12 2008 -0400 + + Bug #16430: Ignore ConfigureNotify on non-root windows in UpdateConfiguration + +commit 332eee90c4d00be3b11049e0261323abe89a96dc +Author: Peter Hutterer +Date: Mon May 19 17:34:36 2008 +0930 + + Rename parameters to clarify QueryVersion/QueryExtension. + + These parameters are not treated as input. Rename them to make the inner + workings slightly more obvious. + + X.Org Bug 14511 + +commit 824f3d4a3a4669526a5c391c6668df0384b49cdb +Author: Julien Cristau +Date: Tue Feb 5 15:37:32 2008 +0100 + + Bug #14388: Remove XRRScreenConfig() and XRRConfig() from Xrandr.h. + + It seems that they were never actually implemented. + Also remove the corresponding manpage symlinks. + +commit dc0ce2e363dbdac560fc2a8c1296c5468d75f644 +Author: Matthieu Herrb +Date: Sun Mar 9 08:37:17 2008 +0100 + + nuke RCS Ids + +commit 23a47035818390ca197179a9a69a54badb370990 +Author: Julien Cristau +Date: Tue Feb 5 15:35:30 2008 +0100 + + Hide some private symbols. + + XExtensionInfo, XRRExtensionName, XRRFindDisplay, _XRRHasRates and + _XRRVersionHandler are internal to libXrandr. Don't export them. + +commit 732ae92882383b33384791c2e9136a54e0fd06f3 +Author: James Cloos +Date: Thu Dec 6 16:38:42 2007 -0500 + + Replace static ChangeLog with dist-hook to generate from git log + +commit e56fa06624dc240dbe8d3e127cc3b65da580fe6e +Merge: 27b91d1... 0294912... +Author: James Cloos +Date: Sun Nov 11 10:27:35 2007 -0500 + + Merge branch 'master' of git://git.freedesktop.org/git/xorg/lib/libXrandr + +commit 029491243b43c2e03a62c143ac21941449f335aa +Author: Eric Anholt +Date: Wed Sep 5 10:01:06 2007 -0700 + + Bump version to 1.2.2. + +commit 27b91d1d62acb70da7d131ee4b6da265d64cb835 +Author: James Cloos +Date: Mon Sep 3 05:53:48 2007 -0400 + + Add *~ to .gitignore to skip patch/emacs droppings + +commit 126143add5349fc34488b23d54d1bdcc7e8847b9 +Author: Keith Packard +Date: Tue Jul 3 09:58:09 2007 -0700 + + CrtcChange event format conversion was using 'height' for 'width'. + + CrtcChange events were getting the source 'height' value stored in the + 'width' target in both conversion directions. + +commit 3e753542bcf0fd49fe977e56b7ab7e540bbd4282 +Author: Keith Packard +Date: Sun Mar 4 20:03:59 2007 -0800 + + Set version to 1.2.1 for release. + +commit c279b64ccca18b14974e413b0b1d55ac81abceda +Author: Fredrik Höglund +Date: Tue Feb 20 22:30:00 2007 +0100 + + Fix the use of a C++ keyword as a parameter name in Xrandr.h + +commit 75d9944484651d4180e3079a739be4edb36545fe +Author: Keith Packard +Date: Sun Feb 18 20:57:31 2007 -0800 + + Reset version from 1.2.0.0 to 1.2.0 + +commit ac82ee50f3938b7b4d6dbcec850d38500258bfe0 +Author: Keith Packard +Date: Thu Feb 15 16:56:11 2007 -0800 + + Must pass size information in SetCrtcGamma request. + +commit 9c4fea702a0382689898fc14cbdab456fb18c403 +Merge: c85237a... 382b7a3... +Author: Keith Packard +Date: Wed Jan 31 14:24:57 2007 -0800 + + Merge 64-bit fixes in + +commit c85237a1651ae8e1abe9ae442ffa04dcb20c1d3e +Author: Keith Packard +Date: Wed Jan 31 14:20:33 2007 -0800 + + Fix read sizes for 64-bit machines. + + Be consistent in variable usage: + nbytes = network byte length. + rbytes = memory byte length. + nbytesRead = actual network bytes read. + Malloc rbytes data to pass to _XRead*, but use nbytes as the + amount of data to read (yes, this is insane, welcome to Xlib). + Some of this patch is semi-gratuitous, but the goal is to be consistent + everywhere. + +commit 382b7a3cfabdd37a6231e18a2ac92bc8a3722b79 +Author: Eric Anholt +Date: Tue Jan 16 13:10:49 2007 -0800 + + Return a valid property info even if we lack valid value sets. + + Previously, XRRQueryOutputProperty90 would return an uninitialized pointer if + num_values was 0. + +commit 36a4a633a93a89bd854f49e670777925c9751de3 +Author: Keith Packard +Date: Sat Jan 6 12:42:47 2007 -0800 + + Avoid nested LockDisplay calls. + + XRRFindDisplay must make extension requests that use LockDisplay, so don't + call it with the display locked, instead pass the info around to the + internal functions that were calling it themselves, having acquired the info + before the outer LockDisplay is called. + +commit d70a3e7f111cb65c37edfa78ca66449338d3bb8f +Author: Keith Packard +Date: Sat Dec 30 13:11:10 2006 -0800 + + Failed to copy rotations from reply to XRRCrtcInfo. + + XRRGetCrtcInfo was not moving the rotations value from the wire reply + structure to the XRRCrtcInfo being returned, leaving the value uninitialized. + +commit bc75a92cac23dad4a661a13e6af121f6072cecc8 +Merge: 7fcdcbb... 370fa28... +Author: Dave Airlie +Date: Sat Dec 2 11:27:36 2006 +1100 + + Merge branch 'randr-1.2' + +commit 370fa28a6afd70ec91411edf1413c0e448ae45b6 +Author: Keith Packard +Date: Thu Nov 30 21:56:59 2006 -0800 + + Add initial implementation of crtc gamma and mode adding requests. + + They build. More testing seems indicated. + +commit 7fcdcbb0f9c4736bd678be7f9bf76d472293233f +Merge: 875867f... 0dba1be... +Author: Eric Anholt +Date: Mon Nov 27 15:41:03 2006 -0800 + + Merge branch 'randr-1.2' + + Conflicts: + + configure.ac + +commit 0dba1be7969aa56f934d93889cbd589b3dafd3d4 +Author: Keith Packard +Date: Mon Nov 20 20:59:18 2006 -0800 + + Change properties to have a pending value and report valid values. + + Pending values are transferred to current values at mode set, allowing a + queue of values to accrue in preparation for the modeset operation while + still reporting valid 'current' values for applications. + + The set of valid values is also available so applications can present + a reasonable list to the user during configuration. + +commit 8edabfeba65562f026111b35ec14a9801b4b6a5c +Author: Keith Packard +Date: Thu Nov 16 13:35:46 2006 -0800 + + Remove RandR output options. + + Options are to be implemented as properties instead. + +commit 7ac8dba76fe33b13620e023699bf971fe8c99fb2 +Author: Eric Anholt +Date: Thu Nov 9 20:26:33 2006 -0800 + + Return the right actual property type for XRRGetOutputProperty. + +commit b49342b58d17267fae81205f1a89263ec4d3d114 +Author: Eric Anholt +Date: Thu Nov 9 17:07:55 2006 -0800 + + Add support for various output property requests. + + These should be reviewed by someone with proto clue, which I'm generally + lacking. + +commit 6676505b6012c97d2f711a84237fa14a62d1d33d +Author: Keith Packard +Date: Wed Nov 1 00:25:45 2006 -0800 + + Moving physical size from mode to output. + + Follows protocol change which places physical size + information in the output rather than (inappropriately) + in each mode line. + +commit 875867f275803682e58f0649f054a83293c6e02c +Author: Adam Jackson +Date: Fri Oct 13 17:09:57 2006 -0400 + + Bump to 1.1.2 + +commit 6eacf491a094add48363d530357dce0d25b8f244 +Author: Adam Jackson +Date: Fri Oct 13 16:25:00 2006 -0400 + + Bump to 1.1.1 + +commit d914d05d34991b4cfa3af411fd2a3e281ea0e73b +Author: Jamey Sharp +Date: Thu Oct 12 17:42:48 2006 -0700 + + Do not call UnlockDisplay without calling LockDisplay. + + Thanks to Magnus Kessler for reporting this + bug and a correct fix. + +commit ab4207db14d70384f017cc2a22379d7c358b60e0 +Author: Keith Packard +Date: Wed Oct 4 20:04:09 2006 -0700 + + Remove mode origins. Add preferred mode count. + +commit dd0fb435a0168d4041ecd81024d6493295651c61 +Author: Keith Packard +Date: Tue Oct 3 21:03:10 2006 -0700 + + Add mode origins and output options. + +commit cb1dbb7c2446ddf514ee709fba940cc4e75438a0 +Author: Keith Packard +Date: Wed Sep 20 20:00:57 2006 -0700 + + XRRGetScreenSizeRange returns Status. Lots more requests added. + + XRRGetCrtcInfo + XRRSetCrtcConfig + XRRGetScreenSizeRange + XRRSetScreenSize + + properties still to do. + +commit c712df73eeb0cb84aad6a0bec2be0f480418c217 +Author: Keith Packard +Date: Tue Sep 19 00:42:49 2006 -0700 + + Start update to 1.2, splitting code across multiple files. + +commit a8abbe92f0486f174fb89ca2c81eabede646bf32 +Author: Alan Coopersmith +Date: Thu Jul 13 14:59:05 2006 -0700 + + renamed: .cvsignore -> .gitignore + +commit 88f4e37d937f171352dc0089a0903c0a3d9487d8 +Author: Alan Coopersmith +Date: Sun Feb 12 18:19:22 2006 +0000 + + Bug #5628 Shadow pages + not created correctly when MANDIR & MANSUFFIX don't match. + +commit c6541af3ef1cfaba57a73369090b6ac1a38b9b1e +Author: Kevin E Martin +Date: Thu Dec 15 00:24:33 2005 +0000 + + Update package version number for final X11R7 release candidate. + +commit be2b102d0ce89f4ac2eb2c2aad5b2e3af947abba +Author: Kevin E Martin +Date: Tue Dec 6 22:48:44 2005 +0000 + + Change *man_SOURCES ==> *man_PRE to fix autotools warnings. + +commit 8f9937022d259917ea7f1a3fefab58607300756a +Author: Kevin E Martin +Date: Sat Dec 3 05:49:45 2005 +0000 + + Update package version number for X11R7 RC3 release. + +commit 127ec4993118efe56caef761febef86eae2b7300 +Author: Kevin E Martin +Date: Sat Dec 3 04:41:50 2005 +0000 + + Add check and cflags for malloc(0) returning NULL. + +commit 89f4aca8d76806edf51d4999223011cbff1c3f55 +Author: Alan Coopersmith +Date: Mon Nov 28 22:03:06 2005 +0000 + + Change *mandir targets to use new *_MAN_DIR variables set by xorg-macros.m4 + update to fix bug #5167 (Linux prefers *.1x man pages in man1 subdir) + +commit bf2fcad15b7bf2c505f5478648bf6ecbc0be701a +Author: Kevin E Martin +Date: Sat Nov 19 07:15:43 2005 +0000 + + Update pkgconfig files to separate library build-time dependencies from + application build-time dependencies, and update package deps to work + with separate build roots. + +commit a27c3d61d107fe4af33181a63f8ea951367ff418 +Author: Kevin E Martin +Date: Mon Nov 14 22:02:13 2005 +0000 + + Fix pkgconfig deps for separate build roots. + +commit 1d690983d20e3d874b7f0e7f430e3d0cf2710c53 +Author: Kevin E Martin +Date: Wed Nov 9 21:19:13 2005 +0000 + + Update package version number for X11R7 RC2 release. + +commit 090314b101b9d3626dc0dc970be68aec7e382d0f +Author: Kevin E Martin +Date: Tue Nov 1 15:11:51 2005 +0000 + + Update pkgcheck dependencies to work with separate build roots. + +commit 2deac5f213ee0a1cedccc721cd015691661b8002 +Author: Kevin E Martin +Date: Wed Oct 19 02:48:11 2005 +0000 + + Update package version number for RC1 release. + +commit 33d17445401ec09bb0c2305d477b00c3abc2182a +Author: Alan Coopersmith +Date: Tue Oct 18 00:00:09 2005 +0000 + + Use @LIB_MAN_SUFFIX@ instead of $(LIB_MAN_SUFFIX) in macro substitutions to + work better with BSD make + +commit a42c72fe8924e98f0794e37dec8e5ef49fd7423c +Author: Alan Coopersmith +Date: Mon Oct 17 21:13:22 2005 +0000 + + Rename .shadows.DONE to shadows.DONE to avoid some make's thinking it's a + suffix rule (reported by Matthieu Herrb) + +commit 13ec5d5d689bb03e01d8f269d2c7a72e4cf0b5f1 +Author: Alan Coopersmith +Date: Thu Oct 13 05:06:10 2005 +0000 + + [lib/Xrandr] + Use sed to fill in variables in man page Add shadow man pages for man pages + that document multiple functions. + +commit 544ec9ae021fecc6001df97a6000095f294b7422 +Author: Alan Coopersmith +Date: Thu Oct 13 02:56:42 2005 +0000 + + Fix troff macros from last commit to not generate cpp warnings + +commit f678f6cc9b73960c3ad61cc93fc61acefbe40ef5 +Author: Alan Coopersmith +Date: Wed Oct 12 23:45:05 2005 +0000 + + Use troff macros to prevent cpp eating C comments & #defines that are + supposed to appear in man page output. + +commit a42516d3a5aa532ed7c19fa128afd63d159676f8 +Author: Aaron Plattner +Date: Fri Sep 30 04:25:14 2005 +0000 + + Bug #2965 Patch #2994 + Swap the screen + dimensions when handling XRRScreenChangeNotify events for 90- and + 270-degree rotations. This fixes KDE's panel placement for rotated + screens. + +commit f9c9043f2a6787cdb6ab130f66fd39b29e7f2506 +Author: Kevin E Martin +Date: Fri Jul 29 21:22:52 2005 +0000 + + Various changes preparing packages for RC0: + - Verify and update package version numbers as needed + - Implement versioning scheme + - Change bug address to point to bugzilla bug entry form + - Disable loadable i18n in libX11 by default (use --enable-loadable-i18n to + reenable it) + - Fix makedepend to use pkgconfig and pass distcheck + - Update build script to build macros first + - Update modular Xorg version + +commit 6fd64a5c552ce5f0559838b2b4ae5a27b40e52f1 +Author: Kevin E Martin +Date: Sat Jul 23 05:27:00 2005 +0000 + + Fix distchecks + +commit bceba127b9b671e378030b348f36602eb44278af +Author: Daniel Stone +Date: Sat Jul 16 07:34:59 2005 +0000 + + Set soversion to 2.0.0 with -version-number. + +commit 63538e6c68e1697e027e55a5015791de3af7bc8c +Author: Keith Packard +Date: Sat Jul 9 06:48:05 2005 +0000 + + Add .cvsignore files Switch _la_CFLAGS for AM_CFLAGS to clean up directory + +commit 3f5e389cb5bd5305cc45aca522086d3b92506265 +Author: Kevin E Martin +Date: Sat Jul 2 06:35:03 2005 +0000 + + Add appropriate lib*_CFLAGS to Makefile.am's -- fixes build problems + +commit 48a3a08206e827a5af88d6a2d8ac62aa3bbbe122 +Author: Daniel Stone +Date: Fri Jun 10 14:10:29 2005 +0000 + + Bug #1976: Fix deadlock when attempting to initialise with threads. + +commit 1279a7f95e654bb33c9057e25a291e2a093f2dee +Author: Alexander Gottwald +Date: Thu Jun 9 12:52:44 2005 +0000 + + Require renderproto instead of render for pkgconfig + +commit 9c36643810a7e837f325970ddd5964bbff4971b6 +Author: Søren Sandmann Pedersen +Date: Wed Jun 8 20:22:47 2005 +0000 + + - Don't search for non-autoconf'ed X libs in Xrandr + - Rename man page Xrandr.3 + +commit 73b3dff9d12d417716c19a33a95eac5f73e5da13 +Author: Søren Sandmann Pedersen +Date: Wed Jun 8 19:19:31 2005 +0000 + + Add Xcursor + conditionally include config.h + +commit 32107cdd57b4796c3f41ac56c9ba683be3d894af +Author: Søren Sandmann Pedersen +Date: Wed Jun 8 17:48:03 2005 +0000 + + Check in build system for Xrandr + +commit 84264cf7a9ce88850f3bc18428e2c046ff0251ed +Author: Markus Kuhn +Date: Sat Dec 4 00:42:48 2004 +0000 + + Encoding of numerous files changed to UTF-8 + +commit a9b18ca5a13816d4ffbbd00d3fc80a048e84e94f +Author: Egbert Eich +Date: Mon May 24 19:06:58 2004 +0000 + + Fix build glitches when building modules independently using Imake. + +commit 76f134caf8da6a08f0fb3587868efaec401c7e74 +Author: Egbert Eich +Date: Fri Apr 23 18:43:47 2004 +0000 + + Merging XORG-CURRENT into trunk + +commit 634976e69c2d0cd014ac537acb1e52884c1d89b2 +Author: Egbert Eich +Date: Sun Mar 14 08:32:25 2004 +0000 + + Importing vendor version xf86-4_4_99_1 on Sun Mar 14 00:26:39 PST 2004 + +commit f07005c663731709ec6c5d7f36492ff3ac253845 +Author: Egbert Eich +Date: Wed Mar 3 12:11:30 2004 +0000 + + Importing vendor version xf86-4_4_0 on Wed Mar 3 04:09:24 PST 2004 + +commit e61377128a66342b8e39a4c5b7e2acd34f38799f +Author: Egbert Eich +Date: Thu Feb 26 13:35:33 2004 +0000 + + readding XFree86's cvs IDs + +commit 696a58bfcb75b56cad6e5994f8c974ac4bb884da +Author: Egbert Eich +Date: Thu Feb 26 09:22:44 2004 +0000 + + Importing vendor version xf86-4_3_99_903 on Wed Feb 26 01:21:00 PST 2004 + +commit 731775dea70f37fd41e4a384d484236e9d0ce4ef +Author: Kaleb Keithley +Date: Thu Dec 4 22:02:57 2003 +0000 + + XFree86 4.3.99.901 (RC 1) + +commit 35eca17cac066690575683bc1367b1fdaba1f4cc +Author: Kaleb Keithley +Date: Tue Nov 25 19:28:15 2003 +0000 + + XFree86 4.3.99.16 Bring the tree up to date for the Cygwin folks + +commit 8a8b419755dd3c815cc70265ed0d44e5f31028cc +Author: Kaleb Keithley +Date: Fri Nov 14 16:48:49 2003 +0000 + + XFree86 4.3.0.1 + +commit 52d0891b9e3c51d43fd13d0b2680b7e24b2f2e2d +Author: Kaleb Keithley +Date: Fri Nov 14 16:48:49 2003 +0000 + + Initial revision --- libxrandr-1.2.99.2.orig/debian/compat +++ libxrandr-1.2.99.2/debian/compat @@ -0,0 +1 @@ +5 --- libxrandr-1.2.99.2.orig/debian/rules +++ libxrandr-1.2.99.2/debian/rules @@ -0,0 +1,102 @@ +#!/usr/bin/make -f +# debian/rules for the Debian libxrandr package. +# Copyright © 2004 Scott James Remnant +# Copyright © 2005 Daniel Stone +# Copyright © 2005 David Nusinow + +# Uncomment this to turn on verbose mode. +#export DH_VERBOSE=1 + +# set this to the name of the main shlib's binary package +PACKAGE = libxrandr2 + +include debian/xsfbs/xsfbs.mk + +CFLAGS = -Wall -g +ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS))) + CFLAGS += -O0 +else + CFLAGS += -O2 +endif +ifeq (,$(findstring nostrip,$(DEB_BUILD_OPTIONS))) + INSTALL_PROGRAM += -s +endif + +DEB_HOST_ARCH ?= $(shell dpkg-architecture -qDEB_HOST_ARCH) +DEB_HOST_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE) +DEB_BUILD_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE) +ifeq ($(DEB_BUILD_GNU_TYPE), $(DEB_HOST_GNU_TYPE)) + confflags += --build=$(DEB_HOST_GNU_TYPE) +else + confflags += --build=$(DEB_BUILD_GNU_TYPE) --host=$(DEB_HOST_GNU_TYPE) +endif + +configure: $(STAMP_DIR)/patch + dh_testdir + autoreconf -vfi + +obj-$(DEB_BUILD_GNU_TYPE)/config.status: configure + dh_testdir + test -d obj-$(DEB_BUILD_GNU_TYPE) || mkdir obj-$(DEB_BUILD_GNU_TYPE) + cd obj-$(DEB_BUILD_GNU_TYPE) && \ + ../configure --prefix=/usr --mandir=\$${prefix}/share/man \ + --infodir=\$${prefix}/share/info $(confflags) \ + CFLAGS="$(CFLAGS)" + + +build: build-stamp +build-stamp: obj-$(DEB_BUILD_GNU_TYPE)/config.status + dh_testdir + cd obj-$(DEB_BUILD_GNU_TYPE) && $(MAKE) + >$@ + +clean: xsfclean + dh_testdir + dh_testroot + rm -f build-stamp + + rm -f config.cache config.log config.status + rm -f */config.cache */config.log */config.status + rm -f conftest* */conftest* + rm -rf autom4te.cache */autom4te.cache + rm -rf obj-* + rm -f $$(find -name Makefile.in) + rm -f compile config.guess config.sub configure depcomp install-sh + rm -f ltmain.sh missing INSTALL aclocal.m4 config.h.in mkinstalldirs + + dh_clean + +install: build + dh_testdir + dh_testroot + dh_clean -k + dh_installdirs + + cd obj-$(DEB_BUILD_GNU_TYPE) && $(MAKE) DESTDIR=$(CURDIR)/debian/tmp install + +# Build architecture-dependent files here. +binary-arch: build install + dh_testdir + dh_testroot + + dh_installdocs + dh_install --sourcedir=debian/tmp --list-missing + dh_installchangelogs ChangeLog + dh_installman + dh_link + dh_strip --dbg-package=$(PACKAGE)-dbg + dh_compress + dh_fixperms + dh_makeshlibs + dh_shlibdeps + dh_installdeb + dh_gencontrol + dh_md5sums + dh_builddeb + +# Build architecture-independent files here. +binary-indep: build install +# Nothing to do + +binary: binary-indep binary-arch +.PHONY: build clean binary-indep binary-arch binary install --- libxrandr-1.2.99.2.orig/debian/libxrandr-dev.install +++ libxrandr-1.2.99.2/debian/libxrandr-dev.install @@ -0,0 +1,5 @@ +usr/include/X11/* +usr/lib/libXrandr.a +usr/lib/libXrandr.so +usr/lib/pkgconfig/xrandr.pc +usr/share/man/man3/* --- libxrandr-1.2.99.2.orig/debian/libxrandr2.shlibs +++ libxrandr-1.2.99.2/debian/libxrandr2.shlibs @@ -0,0 +1 @@ +libXrandr 2 libxrandr2 (>= 2:1.2.0) --- libxrandr-1.2.99.2.orig/debian/watch +++ libxrandr-1.2.99.2/debian/watch @@ -0,0 +1,2 @@ +version=3 +http://xorg.freedesktop.org/releases/individual/lib/ libXrandr-(.*)\.tar\.gz --- libxrandr-1.2.99.2.orig/debian/control +++ libxrandr-1.2.99.2/debian/control @@ -0,0 +1,86 @@ +Source: libxrandr +Section: x11 +Priority: optional +Maintainer: Ubuntu X-SWAT +XSBC-Original-Maintainer: Debian X Strike Force +Uploaders: David Nusinow , Jamey Sharp , Josh Triplett , Julien Cristau +Build-Depends: + debhelper (>= 5.0.0), + libx11-dev (>= 1:0.99.2), + libxext-dev (>= 1:0.99.1), + x11proto-randr-dev (>= 1.2.99.2), + x11proto-render-dev, + libxrender-dev (>= 1:0.9.0-2), + pkg-config, + quilt, + automake, + libtool, + xutils-dev +Standards-Version: 3.7.3 +Vcs-Git: git://git.debian.org/git/pkg-xorg/lib/libxrandr +Vcs-Browser: http://git.debian.org/?p=pkg-xorg/lib/libxrandr.git + +Package: libxrandr2 +Section: libs +Architecture: any +Depends: ${shlibs:Depends}, ${misc:Depends} +Description: X11 RandR extension library + libXrandr provides an X Window System client interface to the RandR + extension to the X protocol. + . + The RandR extension allows for run-time configuration of display attributes + such as resolution, rotation, and reflection. + . + More information about X.Org can be found at: + + + + . + This module can be found at + git://anongit.freedesktop.org/git/xorg/lib/libXrandr + +Package: libxrandr2-dbg +Section: libdevel +Priority: extra +Architecture: any +Depends: ${shlibs:Depends}, ${misc:Depends}, libxrandr2 (= ${binary:Version}) +Description: X11 RandR extension library (debug package) + libXrandr provides an X Window System client interface to the RandR + extension to the X protocol. + . + The RandR extension allows for run-time configuration of display attributes + such as resolution, rotation, and reflection. + . + This package contains the debug versions of the library found in libxrandr2. + Non-developers likely have little use for this package. + . + More information about X.Org can be found at: + + + + . + This module can be found at + git://anongit.freedesktop.org/git/xorg/lib/libXrandr + +Package: libxrandr-dev +Section: libdevel +Architecture: any +Depends: ${shlibs:Depends}, ${misc:Depends}, libxrandr2 (= ${binary:Version}), libx11-dev, libxext-dev, x11proto-randr-dev (>= 1.2), libxrender-dev +Pre-Depends: x11-common (>= 1:7.0.0) +Description: X11 RandR extension library (development headers) + libXrandr provides an X Window System client interface to the RandR + extension to the X protocol. + . + The RandR extension allows for run-time configuration of display attributes + such as resolution, rotation, and reflection. + . + This package contains the development headers for the library found in + libxrandr2. Non-developers likely have little use for this package. + . + More information about X.Org can be found at: + + + + . + This module can be found at + git://anongit.freedesktop.org/git/xorg/lib/libXrandr --- libxrandr-1.2.99.2.orig/debian/changelog +++ libxrandr-1.2.99.2/debian/changelog @@ -0,0 +1,167 @@ +libxrandr (2:1.2.99.2-0ubuntu1) jaunty; urgency=low + + * Merge from debian experimental git branch. + + -- Timo Aaltonen Tue, 09 Dec 2008 20:30:52 +0200 + +libxrandr (2:1.2.99.2-1) UNRELEASED; urgency=low + + * New upstrem prerelease. + * debian/control: + - Build-depend on automake, libtool, xutils-dev. + - Split the build-depends to span multiple lines. + - Bump the build-dep on x11proto-randr-dev to (>= 1.2.99.2). + * debian/rules: + - Run autoreconf -vfi on configure. + * debian/libxrandr2.symbols: Add the new symbols. + + -- Timo Aaltonen Mon, 08 Dec 2008 22:25:39 +0200 + +libxrandr (2:1.2.3-1) unstable; urgency=low + + [ Brice Goglin ] + * Add a link to www.X.org in the long description. + * Add upstream URL to debian/copyright. + + [ Julien Cristau ] + * New upstream release. + + -- Julien Cristau Tue, 08 Jul 2008 23:26:14 +0200 + +libxrandr (2:1.2.2-2) unstable; urgency=low + + * Add debian/libxrandr2.symbols. + Symbols added in the first version (RandR protocol 1.0) carry no version, + symbols added for RandR 1.1 need >= 4.3, and RandR 1.2 symbols need + libxrandr2 >= 2:1.2.0. + * Drop -1 debian revisions from build-deps. + * Bump Standards-Version to 3.7.3. + * Drop the XS- prefix from Vcs-* control fields. + * libxrandr2{,-dbg} don't need to depend on x11-common. + * Merge changes from the 7.1 branch (libxrandr 1.1.1) which had never been + merged to the trunk (yes, that was two years ago). + + -- Julien Cristau Mon, 19 May 2008 00:32:55 +0200 + +libxrandr (2:1.1.1-1) experimental; urgency=low + + * New upstream release. + * Drop patches/01_manpage_location.diff; merged upstream. + * Autoreconf w/ an updated xutils-dev so that manpages have the 'x' + extension dropped. + * Test for obj-$(DEB_BUILD_GNU_TYPE) before creating it during build; + idempotency fix. + * Run dh_install w/ --list-missing. + * Drop duplicate x11-common dep in -dev package. + * Bump standards version to 3.7.2.0. + * Version x11-common pre-dep in -dev package to 1:7.0.0 to match + the rest of Debian. + * Bump debhelper compat to 5. + * Fix dh_strip call to skip the -dbg package. + * Include manpages in -dev package. + + -- Andres Salomon Sat, 29 Jul 2006 16:56:00 -0400 + +libxrandr (2:1.2.2-1) unstable; urgency=low + + * New upstream release. + * Add myself to Uploaders, and remove Branden and Fabio with their + permission. + * Use ${binary:Version} instead of ${Source-Version}. + + -- Julien Cristau Thu, 06 Sep 2007 16:34:32 +0200 + +libxrandr (2:1.2.1-1) unstable; urgency=low + + * New upstream release. + * Upload to unstable. + * Add XS-Vcs-Browser. + + -- Julien Cristau Fri, 20 Apr 2007 08:15:14 +0200 + +libxrandr (2:1.2.0-4) experimental; urgency=low + + * New patch from upstream git to fix use of a C++ keyword as a parameter + name in Xrandr.h. + + -- Julien Cristau Fri, 23 Feb 2007 02:17:40 +0100 + +libxrandr (2:1.2.0-3) experimental; urgency=low + + * Add debian/libxrandr2.shlibs, thanks to Michel Dänzer for noticing my + mistake. + + -- Julien Cristau Tue, 20 Feb 2007 10:39:03 +0100 + +libxrandr (2:1.2.0-2) experimental; urgency=low + + * Oops, libxrandr-dev needs to depend on x11proto-randr-dev >= 1.2. + + -- Julien Cristau Mon, 19 Feb 2007 10:27:32 +0100 + +libxrandr (2:1.2.0-1) experimental; urgency=low + + * Adjust Section and Priority values to what the override says. + * Update location of upstream repository from CVS to git in the long + descriptions. + * Install Xrandr(3) in libxrandr-dev, and use dh_installman. + * Run dh_install with --list-missing. + * New upstream release. + * Install the upstream ChangeLog. + * Add XS-Vcs-Git header. + * Update Standards-Version to 3.7.2. + * Bump Pre-Depends on x11-common to >= 1:7.0.0 and remove the regular + dependency on x11-common in libxrandr-dev to shut lintian up. + * Bump build-dependency on x11proto-randr-dev to >= 1.2. + + -- Julien Cristau Mon, 19 Feb 2007 09:07:09 +0100 + +libxrandr (2:1.1.0.2-5) unstable; urgency=low + + [ Thierry Reding ] + * Add libxrender-dev dependency to libxrandr-dev. + + [ Jamey Sharp ] + * libXrandr: Calls UnlockDisplay without calling LockDisplay. (Closes: + #400441) + * Add Josh and myself to Uploaders. + + -- Jamey Sharp Mon, 27 Nov 2006 14:31:54 -0800 + +libxrandr (2:1.1.0.2-4) unstable; urgency=low + + * Reorder makeshlib command in rules file so that ldconfig is run + properly. Thanks Drew Parsons and Steve Langasek. + * Add quilt to build-depends + + -- David Nusinow Wed, 19 Apr 2006 01:19:50 -0400 + +libxrandr (2:1.1.0.2-3) unstable; urgency=low + + * Upload to unstable + + -- David Nusinow Thu, 23 Mar 2006 22:45:15 -0500 + +libxrandr (2:1.1.0.2-2) experimental; urgency=low + + * Backport manpage location fix + + -- David Nusinow Thu, 9 Mar 2006 23:25:40 -0500 + +libxrandr (2:1.1.0.2-1) UNRLEASED; urgency=low + + * First modular upload to Debian + + -- David Nusinow Thu, 29 Dec 2005 20:54:23 -0500 + +libxrandr (1:1.0.2-2) breezy; urgency=low + + * Update Build-Depends on libx11-dev and libxext-dev to avoid _XOPEN_SOURCE. + + -- Daniel Stone Sat, 23 Jul 2005 00:00:57 +1000 + +libxrandr (1:1.0.2-1) breezy; urgency=low + + * First libxrandr release. + + -- Daniel Stone Mon, 16 May 2005 22:10:17 +1000 --- libxrandr-1.2.99.2.orig/debian/libxrandr2.symbols +++ libxrandr-1.2.99.2/debian/libxrandr2.symbols @@ -0,0 +1,52 @@ +libXrandr.so.2 libxrandr2 #MINVER# + XRRAddOutputMode@Base 2:1.2.0 + XRRAllocGamma@Base 2:1.2.0 + XRRAllocModeInfo@Base 2:1.2.0 + XRRChangeOutputProperty@Base 2:1.2.0 + XRRConfigCurrentConfiguration@Base 0 + XRRConfigCurrentRate@Base 4.3 + XRRConfigRates@Base 4.3 + XRRConfigRotations@Base 0 + XRRConfigSizes@Base 0 + XRRConfigTimes@Base 0 + XRRConfigureOutputProperty@Base 2:1.2.0 + XRRCreateMode@Base 2:1.2.0 + XRRDeleteOutputMode@Base 2:1.2.0 + XRRDeleteOutputProperty@Base 2:1.2.0 + XRRDestroyMode@Base 2:1.2.0 + XRRFreeCrtcInfo@Base 2:1.2.0 + XRRFreeGamma@Base 2:1.2.0 + XRRFreeModeInfo@Base 2:1.2.0 + XRRFreeOutputInfo@Base 2:1.2.0 + XRRFreePanning@Base 2:1.2.99.2 + XRRFreeScreenConfigInfo@Base 0 + XRRFreeScreenResources@Base 2:1.2.0 + XRRGetCrtcGamma@Base 2:1.2.0 + XRRGetCrtcGammaSize@Base 2:1.2.0 + XRRGetCrtcInfo@Base 2:1.2.0 + XRRGetCrtcTransform@Base 2:1.2.99.2 + XRRGetOutputInfo@Base 2:1.2.0 + XRRGetOutputProperty@Base 2:1.2.0 + XRRGetPanning@Base 2:1.2.99.2 + XRRGetScreenInfo@Base 0 + XRRGetScreenResources@Base 2:1.2.0 + XRRGetScreenResourcesCurrent@Base 2:1.2.99.2 + XRRGetScreenSizeRange@Base 2:1.2.0 + XRRListOutputProperties@Base 2:1.2.0 + XRRQueryExtension@Base 0 + XRRQueryOutputProperty@Base 2:1.2.0 + XRRQueryVersion@Base 0 + XRRRates@Base 4.3 + XRRRootToScreen@Base 0 + XRRRotations@Base 0 + XRRSelectInput@Base 0 + XRRSetCrtcConfig@Base 2:1.2.0 + XRRSetCrtcGamma@Base 2:1.2.0 + XRRSetCrtcTransform@Base 2:1.2.99.2 + XRRSetPanning@Base 2:1.2.99.2 + XRRSetScreenConfig@Base 0 + XRRSetScreenConfigAndRate@Base 4.3 + XRRSetScreenSize@Base 2:1.2.0 + XRRSizes@Base 0 + XRRTimes@Base 0 + XRRUpdateConfiguration@Base 0 --- libxrandr-1.2.99.2.orig/debian/copyright +++ libxrandr-1.2.99.2/debian/copyright @@ -0,0 +1,22 @@ +This package was downloaded from +http://xorg.freedesktop.org/releases/individual/lib/ + +Copyright © 2000, Compaq Computer Corporation, +Copyright © 2002, Hewlett Packard, Inc. + +Permission to use, copy, modify, distribute, and sell this software and its +documentation for any purpose is hereby granted without fee, provided that +the above copyright notice appear in all copies and that both that +copyright notice and this permission notice appear in supporting +documentation, and that the name of Compaq or HP not be used in advertising +or publicity pertaining to distribution of the software without specific, +written prior permission. HP makes no representations about the +suitability of this software for any purpose. It is provided "as is" +without express or implied warranty. + +HP DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ALL +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL HP +BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION +OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN +CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. --- libxrandr-1.2.99.2.orig/debian/libxrandr2.install +++ libxrandr-1.2.99.2/debian/libxrandr2.install @@ -0,0 +1 @@ +usr/lib/libXrandr.so.2* --- libxrandr-1.2.99.2.orig/debian/xsfbs/xsfbs.sh +++ libxrandr-1.2.99.2/debian/xsfbs/xsfbs.sh @@ -0,0 +1,931 @@ +# $Id$ + +# This is the X Strike Force shell library for X Window System package +# maintainer scripts. It serves to define shell functions commonly used by +# such packages, and performs some error checking necessary for proper operation +# of those functions. By itself, it does not "do" much; the maintainer scripts +# invoke the functions defined here to accomplish package installation and +# removal tasks. + +# If you are reading this within a Debian package maintainer script (e.g., +# /var/lib/dpkg)info/PACKAGE.{config,preinst,postinst,prerm,postrm}), you can +# skip past this library by scanning forward in this file to the string +# "GOBSTOPPER". + +SOURCE_VERSION=@SOURCE_VERSION@ +OFFICIAL_BUILD=@OFFICIAL_BUILD@ + +# Use special abnormal exit codes so that problems with this library are more +# easily tracked down. +SHELL_LIB_INTERNAL_ERROR=86 +SHELL_LIB_THROWN_ERROR=74 +SHELL_LIB_USAGE_ERROR=99 + +# old -> new variable names +if [ -z "$DEBUG_XORG_PACKAGE" ] && [ -n "$DEBUG_XFREE86_PACKAGE" ]; then + DEBUG_XORG_PACKAGE="$DEBUG_XFREE86_PACKAGE" +fi +if [ -z "$DEBUG_XORG_DEBCONF" ] && [ -n "$DEBUG_XFREE86_DEBCONF" ]; then + DEBUG_XORG_DEBCONF="$DEBUG_XFREE86_DEBCONF" +fi + +# initial sanity checks +if [ -z "$THIS_PACKAGE" ]; then + cat >&2 < on the World Wide Web for +instructions, read the file /usr/share/doc/debian/bug-reporting.txt from the +"doc-debian" package, or install the "reportbug" package and use the command of +the same name to file a report against version $SOURCE_VERSION of this package. +EOF + exit $SHELL_LIB_USAGE_ERROR +fi + +if [ -z "$THIS_SCRIPT" ]; then + cat >&2 < on the World Wide Web for +instructions, read the file /usr/share/doc/debian/bug-reporting.txt from the +"doc-debian" package, or install the "reportbug" package and use the command of +the same name to file a report against version $SOURCE_VERSION of the +"$THIS_PACKAGE" package. +EOF + exit $SHELL_LIB_USAGE_ERROR +fi + +ARCHITECTURE="$(dpkg --print-installation-architecture)" + +if [ "$1" = "reconfigure" ] || [ -n "$DEBCONF_RECONFIGURE" ]; then + RECONFIGURE="true" +else + RECONFIGURE= +fi + +if ([ "$1" = "install" ] || [ "$1" = "configure" ]) && [ -z "$2" ]; then + FIRSTINST="yes" +fi + +if [ -z "$RECONFIGURE" ] && [ -z "$FIRSTINST" ]; then + UPGRADE="yes" +fi + +trap "message;\ + message \"Received signal. Aborting $THIS_PACKAGE package $THIS_SCRIPT script.\";\ + message;\ + exit 1" HUP INT QUIT TERM + +reject_nondigits () { + # syntax: reject_nondigits [ operand ... ] + # + # scan operands (typically shell variables whose values cannot be trusted) for + # characters other than decimal digits and barf if any are found + while [ -n "$1" ]; do + # does the operand contain anything but digits? + if ! expr "$1" : "[[:digit:]]\+$" > /dev/null 2>&1; then + # can't use die(), because it wraps message() which wraps this function + echo "$THIS_PACKAGE $THIS_SCRIPT error: reject_nondigits() encountered" \ + "possibly malicious garbage \"$1\"" >&2 + exit $SHELL_LIB_THROWN_ERROR + fi + shift + done +} + +reject_whitespace () { + # syntax: reject_whitespace [ operand ] + # + # scan operand (typically a shell variable whose value cannot be trusted) for + # whitespace characters and barf if any are found + if [ -n "$1" ]; then + # does the operand contain any whitespace? + if expr "$1" : "[[:space:]]" > /dev/null 2>&1; then + # can't use die(), because I want to avoid forward references + echo "$THIS_PACKAGE $THIS_SCRIPT error: reject_whitespace() encountered" \ + "possibly malicious garbage \"$1\"" >&2 + exit $SHELL_LIB_THROWN_ERROR + fi + fi +} + +reject_unlikely_path_chars () { + # syntax: reject_unlikely_path_chars [ operand ... ] + # + # scan operands (typically shell variables whose values cannot be trusted) for + # characters unlikely to be seen in a path and which the shell might + # interpret and barf if any are found + while [ -n "$1" ]; do + # does the operand contain any funny characters? + if expr "$1" : '.*[!$&()*;<>?|].*' > /dev/null 2>&1; then + # can't use die(), because I want to avoid forward references + echo "$THIS_PACKAGE $THIS_SCRIPT error: reject_unlikely_path_chars()" \ + "encountered possibly malicious garbage \"$1\"" >&2 + exit $SHELL_LIB_THROWN_ERROR + fi + shift + done +} + +# Query the terminal to establish a default number of columns to use for +# displaying messages to the user. This is used only as a fallback in the +# event the COLUMNS variable is not set. ($COLUMNS can react to SIGWINCH while +# the script is running, and this cannot, only being calculated once.) +DEFCOLUMNS=$(stty size 2> /dev/null | awk '{print $2}') || true +if ! expr "$DEFCOLUMNS" : "[[:digit:]]\+$" > /dev/null 2>&1; then + DEFCOLUMNS=80 +fi + +message () { + # pretty-print messages of arbitrary length + reject_nondigits "$COLUMNS" + echo "$*" | fmt -t -w ${COLUMNS:-$DEFCOLUMNS} >&2 +} + +observe () { + # syntax: observe message ... + # + # issue observational message suitable for logging someday when support for + # it exists in dpkg + if [ -n "$DEBUG_XORG_PACKAGE" ]; then + message "$THIS_PACKAGE $THIS_SCRIPT note: $*" + fi +} + +warn () { + # syntax: warn message ... + # + # issue warning message suitable for logging someday when support for + # it exists in dpkg; also send to standard error + message "$THIS_PACKAGE $THIS_SCRIPT warning: $*" +} + +die () { + # syntax: die message ... + # + # exit script with error message + message "$THIS_PACKAGE $THIS_SCRIPT error: $*" + exit $SHELL_LIB_THROWN_ERROR +} + +internal_error () { + # exit script with error; essentially a "THIS SHOULD NEVER HAPPEN" message + message "internal error: $*" + if [ -n "$OFFICIAL_BUILD" ]; then + message "Please report a bug in the $THIS_SCRIPT script of the" \ + "$THIS_PACKAGE package, version $SOURCE_VERSION to the Debian Bug" \ + "Tracking System. Include all messages above that mention the" \ + "$THIS_PACKAGE package. Visit " \ + " on the World Wide Web for" \ + "instructions, read the file" \ + "/usr/share/doc/debian/bug-reporting.txt from the doc-debian" \ + "package, or install the reportbug package and use the command of" \ + "the same name to file a report." + fi + exit $SHELL_LIB_INTERNAL_ERROR +} + +usage_error () { + message "usage error: $*" + message "Please report a bug in the $THIS_SCRIPT script of the" \ + "$THIS_PACKAGE package, version $SOURCE_VERSION to the Debian Bug" \ + "Tracking System. Include all messages above that mention the" \ + "$THIS_PACKAGE package. Visit " \ + " on the World Wide Web for" \ + "instructions, read the file" \ + "/usr/share/doc/debian/bug-reporting.txt from the doc-debian" \ + "package, or install the reportbug package and use the command of" \ + "the same name to file a report." + exit $SHELL_LIB_USAGE_ERROR +} + + +maplink () { + # returns what symlink should point to; i.e., what the "sane" answer is + # Keep this in sync with the debian/*.links files. + # This is only needed for symlinks to directories. + # + # XXX: Most of these look wrong in the X11R7 world and need to be fixed. + # If we've stopped using this function, fixing it might enable us to re-enable + # it again and catch more errors. + case "$1" in + /etc/X11/xkb/compiled) echo /var/lib/xkb ;; + /etc/X11/xkb/xkbcomp) echo /usr/X11R6/bin/xkbcomp ;; + /usr/X11R6/lib/X11/app-defaults) echo /etc/X11/app-defaults ;; + /usr/X11R6/lib/X11/fs) echo /etc/X11/fs ;; + /usr/X11R6/lib/X11/lbxproxy) echo /etc/X11/lbxproxy ;; + /usr/X11R6/lib/X11/proxymngr) echo /etc/X11/proxymngr ;; + /usr/X11R6/lib/X11/rstart) echo /etc/X11/rstart ;; + /usr/X11R6/lib/X11/twm) echo /etc/X11/twm ;; + /usr/X11R6/lib/X11/xdm) echo /etc/X11/xdm ;; + /usr/X11R6/lib/X11/xinit) echo /etc/X11/xinit ;; + /usr/X11R6/lib/X11/xkb) echo /etc/X11/xkb ;; + /usr/X11R6/lib/X11/xserver) echo /etc/X11/xserver ;; + /usr/X11R6/lib/X11/xsm) echo /etc/X11/xsm ;; + /usr/bin/X11) echo ../X11R6/bin ;; + /usr/bin/rstartd) echo ../X11R6/bin/rstartd ;; + /usr/include/X11) echo ../X11R6/include/X11 ;; + /usr/lib/X11) echo ../X11R6/lib/X11 ;; + *) internal_error "maplink() called with unknown path \"$1\"" ;; + esac +} + +analyze_path () { + # given a supplied set of pathnames, break each one up by directory and do an + # ls -dl on each component, cumulatively; i.e. + # analyze_path /usr/X11R6/bin -> ls -dl /usr /usr/X11R6 /usr/X11R6/bin + # Thanks to Randolph Chung for this clever hack. + + local f g + + while [ -n "$1" ]; do + reject_whitespace "$1" + g= + message "Analyzing $1:" + for f in $(echo "$1" | tr / \ ); do + if [ -e /$g$f ]; then + ls -dl /$g$f /$g$f.dpkg-* 2> /dev/null || true + g=$g$f/ + else + message "/$g$f: nonexistent; directory contents of /$g:" + ls -l /$g + break + fi + done + shift + done +} + +find_culprits () { + local f p dpkg_info_dir possible_culprits smoking_guns bad_packages package \ + msg + + reject_whitespace "$1" + message "Searching for overlapping packages..." + dpkg_info_dir=/var/lib/dpkg/info + if [ -d $dpkg_info_dir ]; then + if [ "$(echo $dpkg_info_dir/*.list)" != "$dpkg_info_dir/*.list" ]; then + possible_culprits=$(ls -1 $dpkg_info_dir/*.list | egrep -v \ + "(xbase-clients|x11-common|xfs|xlibs)") + if [ -n "$possible_culprits" ]; then + smoking_guns=$(grep -l "$1" $possible_culprits || true) + if [ -n "$smoking_guns" ]; then + bad_packages=$(printf "\\n") + for f in $smoking_guns; do + # too bad you can't nest parameter expansion voodoo + p=${f%*.list} # strip off the trailing ".list" + package=${p##*/} # strip off the directories + bad_packages=$(printf "%s\n%s" "$bad_packages" "$package") + done + msg=$(cat < /dev/null 2>&1; then + message "The readlink command was not found. Please install version" \ + "1.13.1 or later of the debianutils package." + readlink () { + # returns what symlink in $1 actually points to + perl -e '$l = shift; exit 1 unless -l $l; $r = readlink $l; exit 1 unless $r; print "$r\n"' "$1" + } +fi + +check_symlink () { + # syntax: check_symlink symlink + # + # See if specified symlink points where it is supposed to. Return 0 if it + # does, and 1 if it does not. + # + # Primarily used by check_symlinks_and_warn() and check_symlinks_and_bomb(). + + local symlink + + # validate arguments + if [ $# -ne 1 ]; then + usage_error "check_symlink() called with wrong number of arguments;" \ + "expected 1, got $#" + exit $SHELL_LIB_USAGE_ERROR + fi + + symlink="$1" + + if [ "$(maplink "$symlink")" = "$(readlink "$symlink")" ]; then + return 0 + else + return 1 + fi +} + +check_symlinks_and_warn () { + # syntax: check_symlinks_and_warn symlink ... + # + # For each argument, check for symlink sanity, and warn if it isn't sane. + # + # Call this function from a preinst script in the event $1 is "upgrade" or + # "install". + + local errmsg symlink + + # validate arguments + if [ $# -lt 1 ]; then + usage_error "check_symlinks_and_warn() called with wrong number of" \ + "arguments; expected at least 1, got $#" + exit $SHELL_LIB_USAGE_ERROR + fi + + while [ -n "$1" ]; do + symlink="$1" + if [ -L "$symlink" ]; then + if ! check_symlink "$symlink"; then + observe "$symlink symbolic link points to wrong location" \ + "$(readlink "$symlink"); removing" + rm "$symlink" + fi + elif [ -e "$symlink" ]; then + errmsg="$symlink exists and is not a symbolic link; this package cannot" + errmsg="$errmsg be installed until this" + if [ -f "$symlink" ]; then + errmsg="$errmsg file" + elif [ -d "$symlink" ]; then + errmsg="$errmsg directory" + else + errmsg="$errmsg thing" + fi + errmsg="$errmsg is removed" + die "$errmsg" + fi + shift + done +} + +check_symlinks_and_bomb () { + # syntax: check_symlinks_and_bomb symlink ... + # + # For each argument, check for symlink sanity, and bomb if it isn't sane. + # + # Call this function from a postinst script. + + local problem symlink + + # validate arguments + if [ $# -lt 1 ]; then + usage_error "check_symlinks_and_bomb() called with wrong number of" + "arguments; expected at least 1, got $#" + exit $SHELL_LIB_USAGE_ERROR + fi + + while [ -n "$1" ]; do + problem= + symlink="$1" + if [ -L "$symlink" ]; then + if ! check_symlink "$symlink"; then + problem=yes + warn "$symlink symbolic link points to wrong location" \ + "$(readlink "$symlink")" + fi + elif [ -e "$symlink" ]; then + problem=yes + warn "$symlink is not a symbolic link" + else + problem=yes + warn "$symlink symbolic link does not exist" + fi + if [ -n "$problem" ]; then + analyze_path "$symlink" "$(readlink "$symlink")" + find_culprits "$symlink" + die "bad symbolic links on system" + fi + shift + done +} + +font_update () { + # run $UPDATECMDS in $FONTDIRS + + local dir cmd shortcmd x_font_dir_prefix + + x_font_dir_prefix="/usr/share/fonts/X11" + + if [ -z "$UPDATECMDS" ]; then + usage_error "font_update() called but \$UPDATECMDS not set" + fi + if [ -z "$FONTDIRS" ]; then + usage_error "font_update() called but \$FONTDIRS not set" + fi + + reject_unlikely_path_chars "$UPDATECMDS" + reject_unlikely_path_chars "$FONTDIRS" + + for dir in $FONTDIRS; do + if [ -d "$x_font_dir_prefix/$dir" ]; then + for cmd in $UPDATECMDS; do + if which "$cmd" > /dev/null 2>&1; then + shortcmd=${cmd##*/} + observe "running $shortcmd in $dir font directory" + cmd_opts= + if [ "$shortcmd" = "update-fonts-alias" ]; then + cmd_opts=--x11r7-layout + fi + if [ "$shortcmd" = "update-fonts-dir" ]; then + cmd_opts=--x11r7-layout + fi + if [ "$shortcmd" = "update-fonts-scale" ]; then + cmd_opts=--x11r7-layout + fi + $cmd $cmd_opts $dir || warn "$cmd $cmd_opts $dir" \ + "failed; font directory data may not" \ + "be up to date" + else + warn "$cmd not found; not updating corresponding $dir font" \ + "directory data" + fi + done + else + warn "$dir is not a directory; not updating font directory data" + fi + done +} + +remove_conffile_prepare () { + # syntax: remove_conffile_prepare filename official_md5sum ... + # + # Check a conffile "filename" against a list of canonical MD5 checksums. + # If the file's current MD5 checksum matches one of the "official_md5sum" + # operands provided, then prepare the conffile for removal from the system. + # We defer actual deletion until the package is configured so that we can + # roll this operation back if package installation fails. + # + # Call this function from a preinst script in the event $1 is "upgrade" or + # "install" and verify $2 to ensure the package is being upgraded from a + # version (or installed over a version removed-but-not-purged) prior to the + # one in which the conffile was obsoleted. + + local conffile current_checksum + + # validate arguments + if [ $# -lt 2 ]; then + usage_error "remove_conffile_prepare() called with wrong number of" \ + "arguments; expected at least 2, got $#" + exit $SHELL_LIB_USAGE_ERROR + fi + + conffile="$1" + shift + + # does the conffile even exist? + if [ -e "$conffile" ]; then + # calculate its checksum + current_checksum=$(md5sum < "$conffile" | sed 's/[[:space:]].*//') + # compare it to each supplied checksum + while [ -n "$1" ]; do + if [ "$current_checksum" = "$1" ]; then + # we found a match; move the confffile and stop looking + observe "preparing obsolete conffile $conffile for removal" + mv "$conffile" "$conffile.$THIS_PACKAGE-tmp" + break + fi + shift + done + fi +} + +remove_conffile_lookup () { + # syntax: remove_conffile_lookup package filename + # + # Lookup the md5sum of a conffile in dpkg's database, and prepare for removal + # if it matches the actual file's md5sum. + # + # Call this function when you would call remove_conffile_prepare but only + # want to check against dpkg's status database instead of known checksums. + + local package conffile old_md5sum + + # validate arguments + if [ $# -ne 2 ]; then + usage_error "remove_conffile_lookup() called with wrong number of" \ + "arguments; expected 1, got $#" + exit $SHELL_LIB_USAGE_ERROR + fi + + package="$1" + conffile="$2" + + if ! [ -e "$conffile" ]; then + return + fi + old_md5sum="$(dpkg-query -W -f='${Conffiles}' "$package" | \ + awk '{ if (match($0, "^ '"$conffile"' ")) print $2}')" + if [ -n "$old_md5sum" ]; then + remove_conffile_prepare "$conffile" "$old_md5sum" + fi +} + +remove_conffile_commit () { + # syntax: remove_conffile_commit filename + # + # Complete the removal of a conffile "filename" that has become obsolete. + # + # Call this function from a postinst script after having used + # remove_conffile_prepare() in the preinst. + + local conffile + + # validate arguments + if [ $# -ne 1 ]; then + usage_error "remove_conffile_commit() called with wrong number of" \ + "arguments; expected 1, got $#" + exit $SHELL_LIB_USAGE_ERROR + fi + + conffile="$1" + + # if the temporary file created by remove_conffile_prepare() exists, remove it + if [ -e "$conffile.$THIS_PACKAGE-tmp" ]; then + observe "committing removal of obsolete conffile $conffile" + rm "$conffile.$THIS_PACKAGE-tmp" + fi +} + +remove_conffile_rollback () { + # syntax: remove_conffile_rollback filename + # + # Roll back the removal of a conffile "filename". + # + # Call this function from a postrm script in the event $1 is "abort-upgrade" + # or "abort-install" is after having used remove_conffile_prepare() in the + # preinst. + + local conffile + + # validate arguments + if [ $# -ne 1 ]; then + usage_error "remove_conffile_rollback() called with wrong number of" \ + "arguments; expected 1, got $#" + exit $SHELL_LIB_USAGE_ERROR + fi + + conffile="$1" + + # if the temporary file created by remove_conffile_prepare() exists, move it + # back + if [ -e "$conffile.$THIS_PACKAGE-tmp" ]; then + observe "rolling back removal of obsolete conffile $conffile" + mv "$conffile.$THIS_PACKAGE-tmp" "$conffile" + fi +} + +replace_conffile_with_symlink_prepare () { + # syntax: replace_conffile_with_symlink_prepare oldfilename newfilename \ + # official_md5sum ... + # + # Check a conffile "oldfilename" against a list of canonical MD5 checksums. + # If the file's current MD5 checksum matches one of the "official_md5sum" + # operands provided, then prepare the conffile for removal from the system. + # We defer actual deletion until the package is configured so that we can + # roll this operation back if package installation fails. Otherwise copy it + # to newfilename and let dpkg handle it through conffiles mechanism. + # + # Call this function from a preinst script in the event $1 is "upgrade" or + # "install" and verify $2 to ensure the package is being upgraded from a + # version (or installed over a version removed-but-not-purged) prior to the + # one in which the conffile was obsoleted. + + local conffile current_checksum + + # validate arguments + if [ $# -lt 3 ]; then + usage_error "replace_conffile_with_symlink_prepare() called with wrong" \ + " number of arguments; expected at least 3, got $#" + exit $SHELL_LIB_USAGE_ERROR + fi + + oldconffile="$1" + shift + newconffile="$1" + shift + + remove_conffile_prepare "$_oldconffile" "$@" + # If $oldconffile still exists, then md5sums didn't match. + # Copy it to new one. + if [ -f "$oldconffile" ]; then + cp "$oldconffile" "$newconffile" + fi + +} + +replace_conffile_with_symlink_commit () { + # syntax: replace_conffile_with_symlink_commit oldfilename + # + # Complete the removal of a conffile "oldfilename" that has been + # replaced by a symlink. + # + # Call this function from a postinst script after having used + # replace_conffile_with_symlink_prepare() in the preinst. + + local conffile + + # validate arguments + if [ $# -ne 1 ]; then + usage_error "replace_conffile_with_symlink_commit() called with wrong" \ + "number of arguments; expected 1, got $#" + exit $SHELL_LIB_USAGE_ERROR + fi + + conffile="$1" + + remove_conffile_commit "$conffile" +} + +replace_conffile_with_symlink_rollback () { + # syntax: replace_conffile_with_symlink_rollback oldfilename newfilename + # + # Roll back the replacing of a conffile "oldfilename" with symlink to + # "newfilename". + # + # Call this function from a postrm script in the event $1 is "abort-upgrade" + # or "abort-install" and verify $2 to ensure the package failed to upgrade + # from a version (or install over a version removed-but-not-purged) prior + # to the one in which the conffile was obsoleted. + # You should have used replace_conffile_with_symlink_prepare() in the + # preinst. + + local conffile + + # validate arguments + if [ $# -ne 2 ]; then + usage_error "replace_conffile_with_symlink_rollback() called with wrong" \ + "number of arguments; expected 2, got $#" + exit $SHELL_LIB_USAGE_ERROR + fi + + oldconffile="$1" + newconffile="$2" + + remove_conffile_rollback "$_oldconffile" + if [ -f "$newconffile" ]; then + rm "$newconffile" + fi +} + +run () { + # syntax: run command [ argument ... ] + # + # Run specified command with optional arguments and report its exit status. + # Useful for commands whose exit status may be nonzero, but still acceptable, + # or commands whose failure is not fatal to us. + # + # NOTE: Do *not* use this function with db_get or db_metaget commands; in + # those cases the return value of the debconf command *must* be checked + # before the string returned by debconf is used for anything. + + local retval + + # validate arguments + if [ $# -lt 1 ]; then + usage_error "run() called with wrong number of arguments; expected at" \ + "least 1, got $#" + exit $SHELL_LIB_USAGE_ERROR + fi + + "$@" || retval=$? + + if [ ${retval:-0} -ne 0 ]; then + observe "command \"$*\" exited with status $retval" + fi +} + +register_x_lib_dir_with_ld_so () { + # syntax: register_x_lib_dir_with_ld_so + # + # Configure the dynamic loader ld.so to search /usr/X11R6/lib for shared + # libraries. + # + # Call this function from the postinst script of a package that places a + # shared library in /usr/X11R6/lib, before invoking ldconfig. + + local dir ldsoconf + + dir="/usr/X11R6/lib" + ldsoconf="/etc/ld.so.conf" + + # is the line not already present? + if ! fgrep -qsx "$dir" "$ldsoconf"; then + observe "adding $dir directory to $ldsoconf" + echo "$dir" >> "$ldsoconf" + fi +} + +deregister_x_lib_dir_with_ld_so () { + # syntax: deregister_x_lib_dir_with_ld_so + # + # Configure dynamic loader ld.so to not search /usr/X11R6/lib for shared + # libraries, if and only if no shared libaries remain there. + # + # Call this function from the postrm script of a package that places a shared + # library in /usr/X11R6/lib, in the event "$1" is "remove", and before + # invoking ldconfig. + + local dir ldsoconf fgrep_status cmp_status + + dir="/usr/X11R6/lib" + ldsoconf="/etc/ld.so.conf" + + # is the line present? + if fgrep -qsx "$dir" "$ldsoconf"; then + # are there any shared objects in the directory? + if [ "$(echo "$dir"/lib*.so.*.*)" = "$dir/lib*.so.*.*" ]; then + # glob expansion produced nothing, so no shared libraries are present + observe "removing $dir directory from $ldsoconf" + # rewrite the file (very carefully) + set +e + fgrep -svx "$dir" "$ldsoconf" > "$ldsoconf.dpkg-tmp" + fgrep_status=$? + set -e + case $fgrep_status in + 0|1) ;; # we don't actually care if any lines matched or not + *) die "error reading \"$ldsoconf\"; fgrep exited with status" \ + "$fgrep_status" ;; + esac + set +e + cmp -s "$ldsoconf.dpkg-tmp" "$ldsoconf" + cmp_status=$? + set -e + case $cmp_status in + 0) rm "$ldsoconf.dpkg-tmp" ;; # files are identical + 1) mv "$ldsoconf.dpkg-tmp" "$ldsoconf" ;; # files differ + *) die "error comparing \"$ldsoconf.dpkg-tmp\" to \"$ldsoconf\";" \ + "cmp exited with status $cmp_status" ;; + esac + fi + fi +} + +make_symlink_sane () { + # syntax: make_symlink_sane symlink target + # + # Ensure that the symbolic link symlink exists, and points to target. + # + # If symlink does not exist, create it and point it at target. + # + # If symlink exists but is not a symbolic link, back it up. + # + # If symlink exists, is a symbolic link, but points to the wrong location, fix + # it. + # + # If symlink exists, is a symbolic link, and already points to target, do + # nothing. + # + # This function wouldn't be needed if ln had an -I, --idempotent option. + + # Validate arguments. + if [ $# -ne 2 ]; then + usage_error "make_symlink_sane() called with wrong number of arguments;" \ + "expected 2, got $#" + exit $SHELL_LIB_USAGE_ERROR + fi + + # We could just use the positional parameters as-is, but that makes things + # harder to follow. + local symlink target + + symlink="$1" + target="$2" + + if [ -L "$symlink" ] && [ "$(readlink "$symlink")" = "$target" ]; then + observe "link from $symlink to $target already exists" + else + observe "creating symbolic link from $symlink to $target" + mkdir -p "${target%/*}" "${symlink%/*}" + ln -s -b -S ".dpkg-old" "$target" "$symlink" + fi +} + +migrate_dir_to_symlink () { + # syntax: migrate_dir_to_symlink old_location new_location + # + # Per Debian Policy section 6.5.4, "A directory will never be replaced by a + # symbolic link to a directory or vice versa; instead, the existing state + # (symlink or not) will be left alone and dpkg will follow the symlink if + # there is one." + # + # We have to do it ourselves. + # + # This function moves the contents of old_location, a directory, into + # new_location, a directory, then makes old_location a symbolic link to + # new_location. + # + # old_location need not exist, but if it does, it must be a directory (or a + # symlink to a directory). If it is not, it is backed up. If new_location + # exists already and is not a directory, it is backed up. + # + # This function should be called from a package's preinst so that other + # packages unpacked after this one --- but before this package's postinst runs + # --- are unpacked into new_location even if their payloads contain + # old_location filespecs. + + # Validate arguments. + if [ $# -ne 2 ]; then + usage_error "migrate_dir_to_symlink() called with wrong number of" + "arguments; expected 2, got $#" + exit $SHELL_LIB_USAGE_ERROR + fi + + # We could just use the positional parameters as-is, but that makes things + # harder to follow. + local new old + + old="$1" + new="$2" + + # Is old location a symlink? + if [ -L "$old" ]; then + # Does it already point to new location? + if [ "$(readlink "$old")" = "$new" ]; then + # Nothing to do; migration has already been done. + observe "migration of $old to $new already done" + return 0 + else + # Back it up. + warn "backing up symbolic link $old as $old.dpkg-old" + mv -b "$old" "$old.dpkg-old" + fi + fi + + # Does old location exist, but is not a directory? + if [ -e "$old" ] && ! [ -d "$old" ]; then + # Back it up. + warn "backing up non-directory $old as $old.dpkg-old" + mv -b "$old" "$old.dpkg-old" + fi + + observe "migrating $old to $new" + + # Is new location a symlink? + if [ -L "$new" ]; then + # Does it point the wrong way, i.e., back to where we're migrating from? + if [ "$(readlink "$new")" = "$old" ]; then + # Get rid of it. + observe "removing symbolic link $new which points to $old" + rm "$new" + else + # Back it up. + warn "backing up symbolic link $new as $new.dpkg-old" + mv -b "$new" "$new.dpkg-old" + fi + fi + + # Does new location exist, but is not a directory? + if [ -e "$new" ] && ! [ -d "$new" ]; then + warn "backing up non-directory $new as $new.dpkg-old" + mv -b "$new" "$new.dpkg-old" + fi + + # Create new directory if it does not yet exist. + if ! [ -e "$new" ]; then + observe "creating $new" + mkdir -p "$new" + fi + + # Copy files in old location to new location. Back up any filenames that + # already exist in the new location with the extension ".dpkg-old". + observe "copying files from $old to $new" + if ! (cd "$old" && cp -a -b -S ".dpkg-old" . "$new"); then + die "error(s) encountered while copying files from $old to $new" + fi + + # Remove files at old location. + observe "removing $old" + rm -r "$old" + + # Create symlink from old location to new location. + make_symlink_sane "$old" "$new" +} + +# vim:set ai et sw=2 ts=2 tw=80: + +# GOBSTOPPER: The X Strike Force shell library ends here. --- libxrandr-1.2.99.2.orig/debian/xsfbs/xsfbs.mk +++ libxrandr-1.2.99.2/debian/xsfbs/xsfbs.mk @@ -0,0 +1,300 @@ +#!/usr/bin/make -f + +# Debian X Strike Force Build System (XSFBS): Make portion + +# Copyright 1996 Stephen Early +# Copyright 1997 Mark Eichin +# Copyright 1998-2005, 2007 Branden Robinson +# Copyright 2005 David Nusinow +# +# Licensed under the GNU General Public License, version 2. See the file +# /usr/share/common-licenses/GPL or . + +# Originally by Stephen Early +# Modified by Mark W. Eichin +# Modified by Adam Heath +# Modified by Branden Robinson +# Modified by Fabio Massimo Di Nitto +# Modified by David Nusinow +# Acknowledgements to Manoj Srivastava. + +# Pass $(DH_OPTIONS) into the environment for debhelper's benefit. +export DH_OPTIONS + +# force quilt to not use ~/.quiltrc and to use debian/patches +QUILT = QUILT_PATCHES=debian/patches quilt --quiltrc /dev/null + +# Set up parameters for the upstream build environment. + +# Determine (source) package name from Debian changelog. +SOURCE_NAME:=$(shell dpkg-parsechangelog -ldebian/changelog \ + | grep '^Source:' | awk '{print $$2}') + +# Determine package version from Debian changelog. +SOURCE_VERSION:=$(shell dpkg-parsechangelog -ldebian/changelog \ + | grep '^Version:' | awk '{print $$2}') + +# Determine upstream version number. +UPSTREAM_VERSION:=$(shell echo $(SOURCE_VERSION) | sed 's/-.*//') + +# Determine the source version without the epoch for make-orig-tar-gz +NO_EPOCH_VER:=$(shell echo $(UPSTREAM_VERSION) | sed 's/^.://') + +# Figure out who's building this package. +BUILDER:=$(shell echo $${DEBEMAIL:-$${EMAIL:-$$(echo $$LOGNAME@$$(cat /etc/mailname 2>/dev/null))}}) + +# Find out if this is an official build; an official build has nothing but +# digits, dots, and/or the strings "woody" or "sarge" in the Debian part of the +# version number. Anything else indicates an unofficial build. +OFFICIAL_BUILD:=$(shell VERSION=$(SOURCE_VERSION); if ! expr "$$(echo $${VERSION\#\#*-} | sed 's/\(woody\|sarge\)//g')" : ".*[^0-9.].*" >/dev/null 2>&1; then echo yes; fi) + +# Set up parameters for the Debian build environment. + +# Determine our architecture. +BUILD_ARCH:=$(shell dpkg-architecture -qDEB_BUILD_ARCH) +# Work around some old-time dpkg braindamage. +BUILD_ARCH:=$(subst i486,i386,$(BUILD_ARCH)) +# The DEB_HOST_ARCH variable may be set per the Debian cross-compilation policy. +ifdef DEB_HOST_ARCH + ARCH:=$(DEB_HOST_ARCH) +else + # dpkg-cross sets the ARCH environment variable; if set, use it. + ifdef ARCH + ARCH:=$(ARCH) + else + ARCH:=$(BUILD_ARCH) + endif +endif + +# $(STAMP_DIR) houses stamp files for complex targets. +STAMP_DIR:=stampdir + +# $(SOURCE_DIR) houses one or more source trees. +SOURCE_DIR:=build-tree + +# $(SOURCE_TREE) is the location of the source tree to be compiled. If there +# is more than one, others are found using this name plus a suffix to indicate +# the purpose of the additional tree (e.g., $(SOURCE_TREE)-custom). The +# "setup" target is responsible for creating such trees. +#SOURCE_TREE:=$(SOURCE_DIR)/xc +#FIXME We need to define this in our debian/rules file + +# $(DEBTREEDIR) is where all install rules are told (via $(DESTDIR)) to place +# their files. +DEBTREEDIR:=$(CURDIR)/debian/tmp + +# All "important" targets have four lines: +# 1) A target name that is invoked by a package-building tool or the user. +# This consists of a dependency on a "$(STAMP_DIR)/"-prefixed counterpart. +# 2) A line delcaring 1) as a phony target (".PHONY:"). +# 3) A "$(STAMP_DIR)/"-prefixed target which does the actual work, and may +# depend on other targets. +# 4) A line declaring 3) as a member of the $(stampdir_targets) variable; the +# "$(STAMP_DIR)/" prefix is omitted. +# +# This indirection is needed so that the "stamp" files that signify when a rule +# is done can be located in a separate "stampdir". Recall that make has no way +# to know when a goal has been met for a phony target (like "build" or +# "install"). +# +# At the end of each "$(STAMP_DIR)/" target, be sure to run the command ">$@" +# so that the target will not be run again. Removing the file will make Make +# run the target over. + +# All phony targets should be declared as dependencies of .PHONY, even if they +# do not have "($STAMP_DIR)/"-prefixed counterparts. + +# Define a harmless default rule to keep things from going nuts by accident. +.PHONY: default +default: + +# Set up the $(STAMP_DIR) directory. +.PHONY: stampdir +stampdir_targets+=stampdir +stampdir: $(STAMP_DIR)/stampdir +$(STAMP_DIR)/stampdir: + mkdir $(STAMP_DIR) + >$@ + +# Set up the package build directory as quilt expects to find it. +.PHONY: prepare +stampdir_targets+=prepare +prepare: $(STAMP_DIR)/genscripts $(STAMP_DIR)/prepare $(STAMP_DIR)/log +$(STAMP_DIR)/prepare: $(STAMP_DIR)/stampdir + if [ ! -e $(STAMP_DIR)/log ]; then \ + mkdir $(STAMP_DIR)/log; \ + fi; \ + >$@ + +# Apply all patches to the upstream source. +.PHONY: patch +stampdir_targets+=patch +patch: $(STAMP_DIR)/patch +$(STAMP_DIR)/patch: $(STAMP_DIR)/prepare + if ! [ `which quilt` ]; then \ + echo "Couldn't find quilt. Please install it or add it to the build-depends for this package."; \ + exit 1; \ + fi; \ + if $(QUILT) next >/dev/null 2>&1; then \ + echo -n "Applying patches..."; \ + if $(QUILT) push -a -v >$(STAMP_DIR)/log/patch 2>&1; then \ + cat $(STAMP_DIR)/log/patch; \ + echo "successful."; \ + else \ + cat $(STAMP_DIR)/log/patch; \ + echo "failed! (check $(STAMP_DIR)/log/patch for details)"; \ + exit 1; \ + fi; \ + else \ + echo "No patches to apply"; \ + fi; \ + >$@ + +# Revert all patches to the upstream source. +.PHONY: unpatch +unpatch: $(STAMP_DIR)/prepare + rm -f $(STAMP_DIR)/patch + @echo -n "Unapplying patches..."; \ + if $(QUILT) applied >/dev/null 2>/dev/null; then \ + if $(QUILT) pop -a -v >$(STAMP_DIR)/log/unpatch 2>&1; then \ + cat $(STAMP_DIR)/log/unpatch; \ + echo "successful."; \ + else \ + cat $(STAMP_DIR)/log/unpatch; \ + echo "failed! (check $(STAMP_DIR)/log/unpatch for details)"; \ + exit 1; \ + fi; \ + else \ + echo "nothing to do."; \ + fi + +# Clean the generated maintainer scripts. +.PHONY: cleanscripts +cleanscripts: + rm -f $(STAMP_DIR)/genscripts + rm -f debian/*.config \ + debian/*.postinst \ + debian/*.postrm \ + debian/*.preinst \ + debian/*.prerm + +# Clean the package build tree. +.PHONY: xsfclean +xsfclean: cleanscripts unpatch + dh_testdir + rm -rf .pc + rm -rf $(STAMP_DIR) $(SOURCE_DIR) + rm -rf imports + dh_clean debian/shlibs.local \ + debian/po/pothead + +# Generate the debconf templates POT file header. +debian/po/pothead: debian/po/pothead.in + sed -e 's/SOURCE_VERSION/$(SOURCE_VERSION)/' \ + -e 's/DATE/$(shell date "+%F %X%z"/)' <$< >$@ + +# Update POT and PO files. +.PHONY: updatepo +updatepo: debian/po/pothead + debian/scripts/debconf-updatepo --pot-header=pothead --verbose + +# Remove files from the upstream source tree that we don't need, or which have +# licensing problems. It must be run before creating the .orig.tar.gz. +# +# Note: This rule is for Debian package maintainers' convenience, and is not +# needed for conventional build scenarios. +.PHONY: prune-upstream-tree +prune-upstream-tree: + # Ensure we're in the correct directory. + dh_testdir + grep -rvh '^#' debian/prune/ | xargs --no-run-if-empty rm -rf + +# Verify that there are no offsets or fuzz in the patches we apply. +# +# Note: This rule is for Debian package maintainers' convenience, and is not +# needed for conventional build scenarios. +.PHONY: patch-audit +patch-audit: prepare unpatch + @echo -n "Auditing patches..."; \ + >$(STAMP_DIR)/log/patch; \ + FUZZY=; \ + while [ -n "$$($(QUILT) next)" ]; do \ + RESULT=$$($(QUILT) push -v | tee -a $(STAMP_DIR)/log/patch | grep ^Hunk | sed 's/^Hunk.*\(succeeded\|FAILED\).*/\1/');\ + case "$$RESULT" in \ + succeeded) \ + echo "fuzzy patch: $$($(QUILT) top)" \ + | tee -a $(STAMP_DIR)/log/$$($(QUILT) top); \ + FUZZY=yes; \ + ;; \ + FAILED) \ + echo "broken patch: $$($(QUILT) next)" \ + | tee -a $(STAMP_DIR)/log/$$($(QUILT) next); \ + exit 1; \ + ;; \ + esac; \ + done; \ + if [ -n "$$FUZZY" ]; then \ + echo "there were fuzzy patches; please fix."; \ + exit 1; \ + else \ + echo "done."; \ + fi + +# Generate the maintainer scripts. +.PHONY: genscripts +stampdir_targets+=genscripts +genscripts: $(STAMP_DIR)/genscripts +$(STAMP_DIR)/genscripts: $(STAMP_DIR)/stampdir + for FILE in debian/*.config.in \ + debian/*.postinst.in \ + debian/*.postrm.in \ + debian/*.preinst.in \ + debian/*.prerm.in; do \ + if [ -e "$$FILE" ]; then \ + MAINTSCRIPT=$$(echo $$FILE | sed 's/.in$$//'); \ + sed -n '1,/^#INCLUDE_SHELL_LIB#$$/p' <$$FILE \ + | sed -e '/^#INCLUDE_SHELL_LIB#$$/d' >$$MAINTSCRIPT.tmp; \ + cat debian/xsfbs/xsfbs.sh >>$$MAINTSCRIPT.tmp; \ + sed -n '/^#INCLUDE_SHELL_LIB#$$/,$$p' <$$FILE \ + | sed -e '/^#INCLUDE_SHELL_LIB#$$/d' >>$$MAINTSCRIPT.tmp; \ + sed -e 's/@SOURCE_VERSION@/$(SOURCE_VERSION)/' \ + -e 's/@OFFICIAL_BUILD@/$(OFFICIAL_BUILD)/' \ + -e 's/@DEFAULT_DCRESOLUTIONS@/$(DEFAULT_DCRESOLUTIONS)/' \ + <$$MAINTSCRIPT.tmp >$$MAINTSCRIPT; \ + rm $$MAINTSCRIPT.tmp; \ + fi; \ + done + # Validate syntax of generated shell scripts. + #sh debian/scripts/validate-posix-sh debian/*.config \ + # debian/*.postinst \ + # debian/*.postrm \ + # debian/*.preinst \ + # debian/*.prerm + >$@ + +# Generate the shlibs.local file. +debian/shlibs.local: + cat debian/*.shlibs >$@ + +SERVERMINVERS = $(shell cat /usr/share/xserver-xorg/serverminver 2>/dev/null) +VIDEOABI = $(shell cat /usr/share/xserver-xorg/videoabiver 2>/dev/null) +INPUTABI = $(shell cat /usr/share/xserver-xorg/inputabiver 2>/dev/null) +SERVER_DEPENDS = xserver-xorg-core (>= $(SERVERMINVERS)) +VIDDRIVER_PROVIDES = xserver-xorg-video-$(VIDEOABI) +INPDRIVER_PROVIDES = xserver-xorg-input-$(INPUTABI) +ifeq ($(PACKAGE),) +PACKAGE=$(shell awk '/^Package:/ { print $$2; exit }' < debian/control) +endif + +.PHONY: serverabi +serverabi: install +ifeq ($(SERVERMINVERS),) + @echo error: xserver-xorg-dev needs to be installed + @exit 1 +else + echo "xserver:Depends=$(SERVER_DEPENDS)" >> debian/$(PACKAGE).substvars + echo "xviddriver:Provides=$(VIDDRIVER_PROVIDES)" >> debian/$(PACKAGE).substvars + echo "xinpdriver:Provides=$(INPDRIVER_PROVIDES)" >> debian/$(PACKAGE).substvars +endif + +# vim:set noet ai sts=8 sw=8 tw=0: