summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorroot <root@rshg054.dnsready.net>2012-05-28 00:02:35 +0000
committerroot <root@rshg054.dnsready.net>2012-05-28 00:02:35 +0000
commit89dd7b5f30d48c708092a71b1c8285090fe91505 (patch)
treefb3a22f789121b955ff0fce7ec8d2f8c8886579b
parent1f45ad8e3f17397e2f44e68ef9a0d860091eea9e (diff)
Mon May 28 00:02:35 UTC 2012
-rw-r--r--community-staging/ekg2/PKGBUILD6
-rw-r--r--community-staging/libcec/PKGBUILD30
-rw-r--r--community-staging/pcsc-perl/PKGBUILD30
-rw-r--r--community-staging/pcsclite/PKGBUILD41
-rw-r--r--community-staging/pcsclite/pcscd53
-rw-r--r--community-staging/perl-gstreamer-interfaces/PKGBUILD32
-rw-r--r--community-staging/perl-gstreamer/PKGBUILD28
-rw-r--r--community-staging/perl-linux-pid/PKGBUILD44
-rw-r--r--community-staging/perl-package-stash-xs/PKGBUILD50
-rw-r--r--community-staging/perl-params-util/PKGBUILD51
-rw-r--r--community-staging/perl-tk-tablematrix/PKGBUILD33
-rw-r--r--community-staging/spacefm/PKGBUILD44
-rw-r--r--community-staging/spacefm/spacefm.install12
-rw-r--r--community-testing/conntrack-tools/01-config-file-path.patch11
-rw-r--r--community-testing/conntrack-tools/02-fix-compilation-of-timeout-extension.patch33
-rw-r--r--community-testing/conntrack-tools/PKGBUILD53
-rw-r--r--community-testing/conntrack-tools/conntrack-tools.install9
-rw-r--r--community-testing/conntrack-tools/conntrackd.conf3
-rw-r--r--community-testing/conntrack-tools/conntrackd.rc34
-rw-r--r--community-testing/conntrack-tools/conntrackd.service8
-rw-r--r--community-testing/libnetfilter_cttimeout/PKGBUILD26
-rw-r--r--community-testing/multipath-tools/PKGBUILD41
-rw-r--r--community-testing/multipath-tools/all-in-one.patch209
-rw-r--r--community-testing/multipath-tools/fix-build.patch140
-rw-r--r--community-testing/multipath-tools/multipath-tools.install4
-rw-r--r--community-testing/multipath-tools/multipath.conf8
-rw-r--r--community-testing/multipath-tools/multipath.conf.annotated362
-rw-r--r--community-testing/multipath-tools/multipathd.rc35
-rw-r--r--community/arptables/PKGBUILD36
-rw-r--r--community/arptables/arptables.conf7
-rw-r--r--community/arptables/arptables.install10
-rw-r--r--community/arptables/arptables.rc62
-rw-r--r--community/arptables/arptables.service11
-rw-r--r--community/arptables/arptables.systemd22
-rw-r--r--community/cgit/PKGBUILD8
-rw-r--r--community/ebtables/PKGBUILD52
-rw-r--r--community/ebtables/ebtables.conf40
-rw-r--r--community/ebtables/ebtables.install9
-rw-r--r--community/ebtables/ebtables.rc135
-rw-r--r--community/ebtables/ebtables.service11
-rw-r--r--community/ebtables/ebtables.systemd22
-rw-r--r--community/gambas2/PKGBUILD33
-rw-r--r--community/gambas2/poppler-0.20.patch100
-rw-r--r--community/gambas3/PKGBUILD15
-rw-r--r--community/gambas3/poppler-0-20.patch106
-rw-r--r--community/ipset/PKGBUILD18
-rw-r--r--community/ipset/ipset.conf8
-rw-r--r--community/ipset/ipset.rc32
-rw-r--r--community/ipset/ipset.service6
-rw-r--r--community/ipset/ipset.systemd18
-rw-r--r--community/ipvsadm/PKGBUILD43
-rw-r--r--community/ipvsadm/ipvsadm.conf8
-rw-r--r--community/ipvsadm/ipvsadm.install10
-rw-r--r--community/ipvsadm/ipvsadm.rc50
-rw-r--r--community/ipvsadm/ipvsadm.service11
-rw-r--r--community/ipvsadm/ipvsadm.systemd22
-rw-r--r--community/ktikz/PKGBUILD3
-rw-r--r--community/libextractor/PKGBUILD4
-rw-r--r--community/libmnl/PKGBUILD10
-rw-r--r--community/milkytracker/PKGBUILD4
-rw-r--r--community/mplayer2/PKGBUILD9
-rw-r--r--community/ngircd/PKGBUILD6
-rw-r--r--community/pdf2djvu/PKGBUILD14
-rw-r--r--community/pdf2djvu/poppler-0.20.patch69
-rw-r--r--community/qmmp/PKGBUILD6
-rw-r--r--community/qmmp/qmmp.changelog3
-rw-r--r--community/springlobby/PKGBUILD8
-rw-r--r--community/tellico/PKGBUILD27
-rw-r--r--community/tellico/tellico.install9
-rw-r--r--core/libssh2/PKGBUILD8
-rw-r--r--extra/audacious/PKGBUILD6
-rw-r--r--extra/bzflag/PKGBUILD4
-rw-r--r--extra/calligra/PKGBUILD4
-rw-r--r--extra/cups-filters/PKGBUILD6
-rw-r--r--extra/gimp/PKGBUILD6
-rw-r--r--extra/inkscape/PKGBUILD7
-rw-r--r--extra/inkscape/poppler20.patch642
-rw-r--r--extra/kdegraphics-okular/PKGBUILD4
-rw-r--r--extra/libreoffice/PKGBUILD59
-rw-r--r--extra/libreoffice/fix_broken_hebrew_wordwrapping.diff360
-rw-r--r--extra/libreoffice/libreoffice-base.install11
-rw-r--r--extra/libreoffice/libreoffice-calc.install11
-rw-r--r--extra/libreoffice/libreoffice-common.install47
-rw-r--r--extra/libreoffice/libreoffice-draw.install11
-rw-r--r--extra/libreoffice/libreoffice-impress.install11
-rw-r--r--extra/libreoffice/libreoffice-writer.install11
-rw-r--r--extra/poppler/PKGBUILD8
-rw-r--r--extra/thunar/PKGBUILD15
-rw-r--r--extra/thunar/thunar-1.4.0-show-loop-devices-hack.patch15
-rw-r--r--extra/windowmaker/PKGBUILD6
-rw-r--r--extra/xpdf/PKGBUILD12
-rw-r--r--multilib/wine/PKGBUILD6
-rw-r--r--staging/bluez/PKGBUILD87
-rw-r--r--staging/bluez/bluetooth.conf.d30
-rw-r--r--staging/bluez/rc.bluetooth100
-rw-r--r--staging/cairo-perl/PKGBUILD34
-rw-r--r--staging/cairo-perl/testsuite.patch135
-rw-r--r--staging/easytag/PKGBUILD28
-rw-r--r--staging/easytag/easytag.install11
-rw-r--r--staging/frozen-bubble/PKGBUILD41
-rw-r--r--staging/frozen-bubble/frozen-bubble.desktop9
-rw-r--r--staging/gconf-perl/PKGBUILD34
-rw-r--r--staging/gconf-perl/disable-orbit.patch30
-rw-r--r--staging/glib-perl/PKGBUILD32
-rw-r--r--staging/graphicsmagick/PKGBUILD60
-rw-r--r--staging/gvfs/PKGBUILD112
-rw-r--r--staging/gvfs/gvfs-module.install7
-rw-r--r--staging/gvfs/gvfs-smb.install12
-rw-r--r--staging/gvfs/gvfs.install14
-rw-r--r--staging/libatasmart/PKGBUILD28
-rw-r--r--staging/mesa/LICENSE82
-rw-r--r--staging/mesa/PKGBUILD268
-rw-r--r--staging/mesa/mesa-8.0.3-llvm-3.1-fixes.patch46
-rw-r--r--staging/mod_perl/PKGBUILD45
-rw-r--r--staging/mod_perl/mod_perl-2.0.6-nolfs.patch13
-rw-r--r--staging/mod_perl/mod_perl-2.0.6-perl-5.16-fixes.patch17
-rw-r--r--staging/net-snmp/PKGBUILD58
-rw-r--r--staging/net-snmp/libnl32.patch80
-rw-r--r--staging/net-snmp/snmpd.confd5
-rw-r--r--staging/net-snmp/snmpd.rc39
-rw-r--r--staging/pango-perl/PKGBUILD31
-rw-r--r--staging/perl-async-interrupt/PKGBUILD47
-rw-r--r--staging/perl-ev/PKGBUILD46
-rw-r--r--staging/perl-guard/PKGBUILD48
-rw-r--r--staging/perl-list-moreutils/PKGBUILD49
-rw-r--r--staging/perl-socket6/PKGBUILD49
-rw-r--r--staging/perl-template-toolkit/PKGBUILD32
-rw-r--r--staging/razor/PKGBUILD41
-rw-r--r--staging/rrdtool/PKGBUILD38
-rw-r--r--staging/subversion/PKGBUILD79
-rw-r--r--staging/subversion/subversion.rpath.fix.patch10
-rw-r--r--staging/subversion/svn11
-rwxr-xr-xstaging/subversion/svnserve42
-rw-r--r--staging/subversion/svnserve.conf7
-rw-r--r--staging/udisks/PKGBUILD31
-rw-r--r--staging/util-linux/PKGBUILD55
-rw-r--r--staging/vlc/PKGBUILD88
-rw-r--r--staging/vlc/vlc.install18
-rw-r--r--staging/xf86-video-ati/0000-poor-man-s-solid-picture-support-for-r300-r600.patch571
-rw-r--r--staging/xf86-video-ati/0001-poor-man-s-solid-picture-support-for-evergreen.patch290
-rw-r--r--staging/xf86-video-ati/0002-poor-man-s-solid-picture-support-for-r100.patch182
-rw-r--r--staging/xf86-video-ati/0003-poor-man-s-solid-picture-support-for-r200.patch179
-rw-r--r--staging/xf86-video-ati/PKGBUILD61
-rw-r--r--staging/xf86-video-ati/git_fixes.diff33
-rw-r--r--staging/xf86-video-intel/PKGBUILD30
-rw-r--r--staging/xf86-video-nouveau/PKGBUILD41
-rw-r--r--staging/xf86-video-nouveau/xf86-video-nouveau.install16
-rw-r--r--staging/xfconf/PKGBUILD49
-rw-r--r--staging/xorg-server/10-quirks.conf10
-rw-r--r--staging/xorg-server/EXA_Fall_back_earlier_and_more_thoroughly_from_exaGlyphsV2.diff116
-rw-r--r--staging/xorg-server/PKGBUILD200
-rw-r--r--staging/xorg-server/autoconfig-nvidia.patch28
-rw-r--r--staging/xorg-server/autoconfig-sis.patch21
-rw-r--r--staging/xorg-server/git-fixes.patch1717
-rw-r--r--staging/xorg-server/xvfb-run180
-rw-r--r--staging/xorg-server/xvfb-run.1282
156 files changed, 9533 insertions, 429 deletions
diff --git a/community-staging/ekg2/PKGBUILD b/community-staging/ekg2/PKGBUILD
index 72f248855..a73592ddc 100644
--- a/community-staging/ekg2/PKGBUILD
+++ b/community-staging/ekg2/PKGBUILD
@@ -1,10 +1,10 @@
-# $Id: PKGBUILD 71220 2012-05-25 05:24:20Z tdziedzic $
-# Maintainer: Bartłomiej Piotrowski
+# $Id: PKGBUILD 71286 2012-05-26 08:42:25Z bpiotrowski $
+# Maintainer: Bartłomiej Piotrowski <nospam@bpiotrowski.pl>
# Contributor: Mateusz Herych <heniekk@gmail.com>
pkgname=ekg2
pkgver=0.3.1
-pkgrel=3
+pkgrel=4
pkgdesc="ncurses based Jabber, Gadu-Gadu, Tlen and IRC client"
arch=('i686' 'x86_64')
url="http://ekg2.org/"
diff --git a/community-staging/libcec/PKGBUILD b/community-staging/libcec/PKGBUILD
new file mode 100644
index 000000000..4c501c681
--- /dev/null
+++ b/community-staging/libcec/PKGBUILD
@@ -0,0 +1,30 @@
+# $Id: PKGBUILD 71308 2012-05-26 14:17:38Z idevolder $
+# Maintainer: BlackIkeEagle <ike DOT devolder AT gmail DOT com>
+# Contributor: Philippe Cherel <philippe.cherel@mayenne.org>
+
+pkgname=libcec
+pkgver=1.6.3
+pkgrel=1
+pkgdesc="Pulse-Eight's libcec for the Pulse-Eight USB-CEC adapter"
+arch=('i686' 'x86_64')
+url="https://github.com/Pulse-Eight/libcec"
+license=('GPL')
+depends=('udev' 'lockdev')
+source=("$pkgname-$pkgver.tar.gz::https://github.com/Pulse-Eight/libcec/tarball/$pkgname-$pkgver")
+_srcfolder=Pulse-Eight-libcec-ab37938
+sha256sums=('964fb7ad2281b44dacddd57e5cfc16750271492cbbf48291ee487644d69bcb61')
+options=(!libtool)
+
+build() {
+ mv "$_srcfolder" "$pkgname-$pkgver"
+
+ cd "$pkgname-$pkgver"
+ autoreconf -vif
+ ./configure --prefix=/usr
+ make
+}
+
+package() {
+ cd "$pkgname-$pkgver"
+ make DESTDIR="$pkgdir" install
+}
diff --git a/community-staging/pcsc-perl/PKGBUILD b/community-staging/pcsc-perl/PKGBUILD
new file mode 100644
index 000000000..7131cdf61
--- /dev/null
+++ b/community-staging/pcsc-perl/PKGBUILD
@@ -0,0 +1,30 @@
+# $Id: PKGBUILD 71294 2012-05-26 12:15:03Z giovanni $
+# Maintainer: Giovanni Scafora <giovanni@archlinux.org>
+# Contributor: neuromante <lorenzo.nizzi.grifi@gmail.com>
+# Contributor: marc0s <marc0s@fsfe.org>
+
+pkgname=pcsc-perl
+pkgver=1.4.12
+pkgrel=3
+pkgdesc="A Perl Module for PC/SC SmartCard access"
+arch=('i686' 'x86_64')
+url="http://ludovic.rousseau.free.fr/softwares/pcsc-perl/"
+license=('GPL' 'PerlArtistic')
+depends=('pcsclite' 'perl')
+makedepends=('pkgconfig')
+options=('!emptydirs')
+source=("http://ludovic.rousseau.free.fr/softwares/${pkgname}/${pkgname}-${pkgver}.tar.bz2")
+md5sums=('f34c5ab748815bf0b2e571362b4f8121')
+
+build() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
+
+ # install module in vendor directories.
+ PERL_MM_USE_DEFAULT=1 perl Makefile.PL INSTALLDIRS=vendor
+}
+
+package() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
+
+ make DESTDIR="${pkgdir}" install
+}
diff --git a/community-staging/pcsclite/PKGBUILD b/community-staging/pcsclite/PKGBUILD
new file mode 100644
index 000000000..e32997c8c
--- /dev/null
+++ b/community-staging/pcsclite/PKGBUILD
@@ -0,0 +1,41 @@
+# $Id: PKGBUILD 71253 2012-05-26 06:27:20Z giovanni $
+# Maintainer: Giovanni Scafora <giovanni@archlinux.org>
+# Contributor: Daniel Plaza <daniel.plaza.espi@gmail.com>
+
+pkgname=pcsclite
+pkgver=1.8.3
+pkgrel=3
+pkgdesc="PC/SC Architecture smartcard middleware library"
+arch=('i686' 'x86_64')
+url="https://alioth.debian.org/projects/pcsclite/"
+license=('BSD')
+depends=('python')
+makedepends=('pkg-config')
+options=('!libtool' '!docs')
+source=("https://alioth.debian.org/frs/download.php/3706/pcsc-lite-${pkgver}.tar.bz2"
+ 'pcscd')
+md5sums=('7ad8c97c89f77aab7a00317eb7e811e9'
+ 'c97b6bce695222efb0f003d8e8369010')
+
+build() {
+ cd "${srcdir}/pcsc-lite-${pkgver}"
+
+ ./configure --prefix=/usr \
+ --enable-libudev \
+ --sysconfdir=/etc \
+ --enable-ipcdir=/run/pcscd \
+ --enable-usbdropdir=/usr/lib/pcsc/drivers \
+ --with-systemdsystemunitdir=/usr/lib/systemd/system
+
+ make
+}
+
+package() {
+ cd "${srcdir}/pcsc-lite-${pkgver}"
+
+ make DESTDIR="${pkgdir}" install
+
+ install -D -m644 ${srcdir}/pcsc-lite-${pkgver}/COPYING ${pkgdir}/usr/share/licenses/${pkgname}/LICENSE
+ install -D -m755 ${srcdir}/pcscd ${pkgdir}/etc/rc.d/pcscd
+ install -d ${pkgdir}/usr/lib/pcsc/drivers
+}
diff --git a/community-staging/pcsclite/pcscd b/community-staging/pcsclite/pcscd
new file mode 100644
index 000000000..1dc5e0166
--- /dev/null
+++ b/community-staging/pcsclite/pcscd
@@ -0,0 +1,53 @@
+#!/bin/bash
+
+. /etc/rc.conf
+. /etc/rc.d/functions
+
+DAEMON=/usr/sbin/pcscd
+NAME=pcscd
+DESC="PC/SC smart card daemon"
+PID_FILE=/run/pcscd/pcscd.pid
+PCSCD_OPTIONS=
+
+case "$1" in
+ start)
+ stat_busy "Starting $DESC"
+ $DAEMON $PCSCD_OPTIONS
+ if [ $? -gt 0 ]; then
+ stat_fail
+ else
+ add_daemon $NAME
+ stat_done
+ fi
+ ;;
+
+ stop)
+ stat_busy "Stopping $DESC"
+ [ -f $PID_FILE ] && kill `cat $PID_FILE` &> /dev/null
+ if [ $? -gt 0 ]; then
+ stat_fail
+ else
+ rm_daemon $NAME
+ stat_done
+ fi
+ ;;
+
+ restart)
+ $0 stop
+ sleep 3
+ $0 start
+ ;;
+
+ status)
+ stat_busy "Checking $NAME status";
+ ck_status $NAME
+ ;;
+
+ *)
+ echo "usage: $0 {start|stop|restart|status}"
+ ;;
+
+esac
+
+exit 0
+
diff --git a/community-staging/perl-gstreamer-interfaces/PKGBUILD b/community-staging/perl-gstreamer-interfaces/PKGBUILD
new file mode 100644
index 000000000..2c47cff0a
--- /dev/null
+++ b/community-staging/perl-gstreamer-interfaces/PKGBUILD
@@ -0,0 +1,32 @@
+# $Id: PKGBUILD 71298 2012-05-26 12:32:26Z bluewind $
+# Maintainer: Sergej Pupykin <pupykin.s+arch@gmail.com>
+# Maintainer: Corrado Primier <bardo@aur.archlinux.org>
+
+pkgname=perl-gstreamer-interfaces
+pkgver=0.06
+pkgrel=5
+pkgdesc="GStreamer::Interfaces"
+arch=('i686' 'x86_64')
+url="http://search.cpan.org/dist/GStreamer-Interfaces"
+license=('GPL' 'PerlArtistic')
+depends=('glib-perl' 'gstreamer0.10-base' 'perl-extutils-pkgconfig' 'perl-gstreamer' 'perl-extutils-depends')
+options=('!emptydirs')
+source=("http://www.cpan.org/authors/id/T/TS/TSCH/GStreamer-Interfaces-${pkgver}.tar.gz")
+md5sums=('aa9583a484fa6829935b360887ecda45')
+
+build() {
+ cd GStreamer-Interfaces-${pkgver}
+
+ PERL_MM_USE_DEFAULT=1 perl Makefile.PL INSTALLDIRS=vendor
+
+ make
+}
+
+package() {
+ cd GStreamer-Interfaces-${pkgver}
+
+ make install DESTDIR=${pkgdir}
+
+ find ${pkgdir} -name '.packlist' -delete
+ find ${pkgdir} -name '*.pod' -delete
+}
diff --git a/community-staging/perl-gstreamer/PKGBUILD b/community-staging/perl-gstreamer/PKGBUILD
new file mode 100644
index 000000000..8b325a974
--- /dev/null
+++ b/community-staging/perl-gstreamer/PKGBUILD
@@ -0,0 +1,28 @@
+# $Id: PKGBUILD 71306 2012-05-26 14:01:59Z spupykin $
+# Maintainer: Sergej Pupykin <pupykin.s+arch@gmail.com>
+# Contributor: Corrado Primier <bardo@aur.archlinux.org>
+
+pkgname=perl-gstreamer
+pkgver=0.17
+pkgrel=1
+pkgdesc="Interface to the GStreamer library"
+arch=('i686' 'x86_64')
+url="http://search.cpan.org/dist/GStreamer"
+license=('GPL' 'PerlArtistic')
+depends=('glib-perl>=1.180' 'gstreamer0.10' 'perl-extutils-pkgconfig>=1.07' 'perl-extutils-depends>=0.205')
+options=('!emptydirs')
+source=(http://search.cpan.org/CPAN/authors/id/X/XA/XAOC/GStreamer-$pkgver.tar.gz)
+md5sums=('8fe097daf0e2534452a3f69af05ec9fd')
+
+build() {
+ cd GStreamer-${pkgver}
+ PERL_MM_USE_DEFAULT=1 perl Makefile.PL INSTALLDIRS=vendor
+ make
+}
+
+package() {
+ cd GStreamer-${pkgver}
+ make install DESTDIR=${pkgdir}
+ find ${pkgdir} -name '.packlist' -delete
+ find ${pkgdir} -name '*.pod' -delete
+}
diff --git a/community-staging/perl-linux-pid/PKGBUILD b/community-staging/perl-linux-pid/PKGBUILD
new file mode 100644
index 000000000..001b23842
--- /dev/null
+++ b/community-staging/perl-linux-pid/PKGBUILD
@@ -0,0 +1,44 @@
+# $Id: PKGBUILD 71300 2012-05-26 12:33:28Z bluewind $
+# Maintainer: Angel Velasquez <angvp@archlinux.org>
+# Contributor: Angel Velasquez <angvp@archlinux.org>
+# Generator : CPANPLUS::Dist::Arch 1.12
+
+pkgname='perl-linux-pid'
+pkgver='0.04'
+pkgrel='2'
+pkgdesc="Interface to Linux getpp?id functions"
+arch=('i686' 'x86_64')
+license=('PerlArtistic' 'GPL')
+options=('!emptydirs')
+depends=('perl')
+url='http://search.cpan.org/dist/Linux-Pid'
+source=('http://search.cpan.org/CPAN/authors/id/R/RG/RGARCIA/Linux-Pid-0.04.tar.gz')
+md5sums=('130c4d299f827abf1f2285fddf03fccb')
+_distdir="${srcdir}/Linux-Pid-0.04"
+
+build() {
+ ( export PERL_MM_USE_DEFAULT=1 PERL5LIB="" \
+ PERL_AUTOINSTALL=--skipdeps \
+ PERL_MM_OPT="INSTALLDIRS=vendor DESTDIR='$pkgdir'" \
+ PERL_MB_OPT="--installdirs vendor --destdir '$pkgdir'" \
+ MODULEBUILDRC=/dev/null
+
+ cd "$_distdir"
+ /usr/bin/perl Makefile.PL
+ make
+ )
+}
+
+check() {
+ cd "$_distdir"
+ ( export PERL_MM_USE_DEFAULT=1 PERL5LIB=""
+ make test
+ )
+}
+
+package() {
+ cd "$_distdir"
+ make install
+ find "$pkgdir" -name .packlist -o -name perllocal.pod -delete
+}
+
diff --git a/community-staging/perl-package-stash-xs/PKGBUILD b/community-staging/perl-package-stash-xs/PKGBUILD
new file mode 100644
index 000000000..24f48ca2c
--- /dev/null
+++ b/community-staging/perl-package-stash-xs/PKGBUILD
@@ -0,0 +1,50 @@
+# Maintainer: Justin Davis <jrcd83@gmail.com>
+# $Id: PKGBUILD 71302 2012-05-26 12:34:18Z bluewind $
+
+pkgname=perl-package-stash-xs
+pkgver=0.25
+pkgrel=2
+pkgdesc="faster and more correct implementation of the Package::Stash API"
+arch=(i686 x86_64)
+license=(PerlArtistic GPL)
+options=(!emptydirs)
+depends=('perl>=5.8.1')
+makedepends=('perl-extutils-makemaker>=6.30')
+checkdepends=('perl-test-fatal' 'perl-test-simple')
+url=https://metacpan.org/release/Package-Stash-XS
+source=("http://search.cpan.org/CPAN/authors/id/D/DO/DOY/Package-Stash-XS-${pkgver}.tar.gz")
+md5sums=(52ece18842c46da8fb7a4a14dea910ab)
+sha512sums=(2b539d9ba1a68c5ba681e9eabbcde4b396f66dc8dbd3b1e333286ea7ce39b93b97ec4bd97c31681720a925553b128371ce2c48f11254806aebd5de868a22b528)
+_distdir="${srcdir}/Package-Stash-XS-${pkgver}"
+
+build() {
+ ( export PERL_MM_USE_DEFAULT=1 PERL5LIB="" \
+ PERL_AUTOINSTALL=--skipdeps \
+ PERL_MM_OPT="INSTALLDIRS=vendor DESTDIR='$pkgdir'" \
+ PERL_MB_OPT="--installdirs vendor --destdir '$pkgdir'" \
+ MODULEBUILDRC=/dev/null
+
+ cd "$_distdir"
+ /usr/bin/perl Makefile.PL
+ make
+ )
+}
+
+check() {
+ ( export PERL_MM_USE_DEFAULT=1 PERL5LIB=""
+ cd "$_distdir"
+ make test
+ )
+}
+
+package() {
+ cd "$_distdir"
+ make DESTDIR="$pkgdir" install
+ find "$pkgdir" -name .packlist -o -name perllocal.pod -delete
+}
+
+# Local Variables:
+# mode: shell-script
+# sh-basic-offset: 2
+# End:
+# vim:set ts=2 sw=2 et:
diff --git a/community-staging/perl-params-util/PKGBUILD b/community-staging/perl-params-util/PKGBUILD
new file mode 100644
index 000000000..d1cd22773
--- /dev/null
+++ b/community-staging/perl-params-util/PKGBUILD
@@ -0,0 +1,51 @@
+# Maintainer: Justin Davis <jrcd83@gmail.com>
+# $Id: PKGBUILD 71304 2012-05-26 12:34:54Z bluewind $
+
+pkgname=perl-params-util
+pkgver=1.04
+pkgrel=2
+pkgdesc="Simple, compact and correct param-checking functions"
+arch=(i686 x86_64)
+license=(PerlArtistic GPL)
+options=(!emptydirs)
+depends=('perl>=5.5.30' 'perl-scalar-list-utils')
+makedepends=('perl-extutils-cbuilder>=0.27' 'perl-extutils-makemaker>=6.52'
+ 'perl-pathtools')
+checkdepends=('perl-test-simple')
+url=https://metacpan.org/release/Params-Util
+source=("http://search.cpan.org/CPAN/authors/id/A/AD/ADAMK/Params-Util-${pkgver}.tar.gz")
+md5sums=(84bfb0a16cff67f2077ece0e24408b0f)
+sha512sums=(086b6e37ce24a423439e346c4fc7069cbb5bde6af5c259fa765616bf637597105ee379df5edca82fdeb3bb0e44d83c7704ea1fe09170acea389ffb54d77f3d3d)
+_distdir="${srcdir}/Params-Util-${pkgver}"
+
+build() {
+ ( export PERL_MM_USE_DEFAULT=1 PERL5LIB="" \
+ PERL_AUTOINSTALL=--skipdeps \
+ PERL_MM_OPT="INSTALLDIRS=vendor DESTDIR='$pkgdir'" \
+ PERL_MB_OPT="--installdirs vendor --destdir '$pkgdir'" \
+ MODULEBUILDRC=/dev/null
+
+ cd "$_distdir"
+ /usr/bin/perl Makefile.PL
+ make
+ )
+}
+
+check() {
+ ( export PERL_MM_USE_DEFAULT=1 PERL5LIB=""
+ cd "$_distdir"
+ make test
+ )
+}
+
+package() {
+ cd "$_distdir"
+ make DESTDIR="$pkgdir" install
+ find "$pkgdir" -name .packlist -o -name perllocal.pod -delete
+}
+
+# Local Variables:
+# mode: shell-script
+# sh-basic-offset: 2
+# End:
+# vim:set ts=2 sw=2 et:
diff --git a/community-staging/perl-tk-tablematrix/PKGBUILD b/community-staging/perl-tk-tablematrix/PKGBUILD
new file mode 100644
index 000000000..a1c277836
--- /dev/null
+++ b/community-staging/perl-tk-tablematrix/PKGBUILD
@@ -0,0 +1,33 @@
+# $Id: PKGBUILD 71262 2012-05-26 07:28:02Z spupykin $
+# Maintainer: Sergej Pupykin <pupykin.s+arch@gmail.com>
+# Maintainer: Charles Mauch <cmauch@gmail.com>
+
+pkgname=perl-tk-tablematrix
+pkgver=1.23
+pkgrel=9
+pkgdesc="Display data in TableSpreadsheet format"
+arch=("i686" "x86_64")
+url="http://search.cpan.org/dist/Tk-TableMatrix"
+license=("GPL" "PerlArtistic")
+depends=('perl-tk')
+options=('!emptydirs')
+source=("http://www.cpan.org/authors/id/C/CE/CERNEY/Tk-TableMatrix-${pkgver}.tar.gz")
+md5sums=('6b7653d129bf1a8327054a88b58d6364')
+
+build() {
+ cd Tk-TableMatrix-${pkgver}
+
+ PERL_MM_USE_DEFAULT=1 perl Makefile.PL INSTALLDIRS=vendor
+
+ make
+}
+
+package() {
+ cd Tk-TableMatrix-${pkgver}
+ make install DESTDIR=${pkgdir}
+
+ find ${pkgdir} -name '.packlist' -delete
+ find ${pkgdir} -name '*.pod' -delete
+
+ rm -f ${pkgdir}/usr/lib/perl5/vendor_perl/auto/Tk/pTk/extralibs.ld
+}
diff --git a/community-staging/spacefm/PKGBUILD b/community-staging/spacefm/PKGBUILD
new file mode 100644
index 000000000..818712771
--- /dev/null
+++ b/community-staging/spacefm/PKGBUILD
@@ -0,0 +1,44 @@
+# $Id: PKGBUILD 71258 2012-05-26 07:14:26Z bpiotrowski $
+# Maintainer: Bartłomiej Piotrowski <nospam@bpiotrowski.pl>
+# Contributor: IgnorantGuru http://igurublog.wordpress.com/contact-ignorantguru/
+# Contributor: ridikulus_rat <the.ridikulus.rat@gmail.com>
+
+pkgname=spacefm
+pkgver=0.7.6
+pkgrel=3
+pkgdesc="A multi-panel tabbed file manager"
+arch=('i686' 'x86_64')
+url="http://ignorantguru.github.com/spacefm/"
+license=('GPL2')
+install=$pkgname.install
+depends=('gtk2' 'shared-mime-info' 'desktop-file-utils' 'startup-notification' 'udev')
+makedepends=('intltool' 'gettext')
+optdepends=('lsof: device processes'
+ 'eject: eject media'
+ 'wget: plugin download'
+ 'gksu: perform as root functionality'
+ 'pmount: mount as non-root user'
+ 'udisks: mount as non-root user'
+ 'udisks2: mount as non-root user')
+source=(https://raw.github.com/IgnorantGuru/spacefm/master/packages/${pkgver}/spacefm-${pkgver}.tar.xz)
+md5sums=('572b256ab46073d8bb065999bd531423')
+
+build() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
+
+ # NOTE: To enable hal support add --enable-hal to
+ # configure line below. See README for details.
+ # NOTE: To disable inotify and use fam or gamin instead, add:
+ # --disable-inotify to configure line below.
+ # NOTE: To add a custom su program (mysu in this example), add:
+ # --with-preferable-sudo="mysu" to configure line below.
+
+ ./configure --prefix=/usr
+ make
+}
+
+package() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
+ make DESTDIR="${pkgdir}/" install
+}
+
diff --git a/community-staging/spacefm/spacefm.install b/community-staging/spacefm/spacefm.install
new file mode 100644
index 000000000..1182e768f
--- /dev/null
+++ b/community-staging/spacefm/spacefm.install
@@ -0,0 +1,12 @@
+post_install() {
+ update-mime-database usr/share/mime > /dev/null
+ update-desktop-database -q
+}
+
+post_upgrade() {
+ post_install
+}
+
+post_remove() {
+ post_install
+}
diff --git a/community-testing/conntrack-tools/01-config-file-path.patch b/community-testing/conntrack-tools/01-config-file-path.patch
new file mode 100644
index 000000000..8512cc9ab
--- /dev/null
+++ b/community-testing/conntrack-tools/01-config-file-path.patch
@@ -0,0 +1,11 @@
+--- a/include/conntrackd.h 2012-05-26 15:29:15.630027223 +0200
++++ b/include/conntrackd.h 2012-05-27 02:26:59.426811589 +0200
+@@ -50,7 +50,7 @@
+ #define EXP_DUMP_INT_XML 47 /* dump internal cache in XML */
+ #define EXP_DUMP_EXT_XML 48 /* dump external cache in XML */
+
+-#define DEFAULT_CONFIGFILE "/etc/conntrackd/conntrackd.conf"
++#define DEFAULT_CONFIGFILE "/etc/conntrackd.conf"
+ #define DEFAULT_LOCKFILE "/var/lock/conntrackd.lock"
+ #define DEFAULT_LOGFILE "/var/log/conntrackd.log"
+ #define DEFAULT_STATS_LOGFILE "/var/log/conntrackd-stats.log"
diff --git a/community-testing/conntrack-tools/02-fix-compilation-of-timeout-extension.patch b/community-testing/conntrack-tools/02-fix-compilation-of-timeout-extension.patch
new file mode 100644
index 000000000..746934994
--- /dev/null
+++ b/community-testing/conntrack-tools/02-fix-compilation-of-timeout-extension.patch
@@ -0,0 +1,33 @@
+From 18efbc802479ce042378dc0cccc7577e1c6afa41 Mon Sep 17 00:00:00 2001
+From: Pablo Neira Ayuso <pablo@netfilter.org>
+Date: Sat, 26 May 2012 20:58:16 +0200
+Subject: [PATCH] nfct: fix compilation of timeout extension
+MIME-Version: 1.0
+Content-Type: text/plain; charset=utf8
+Content-Transfer-Encoding: 8bit
+
+nfct-extensions/timeout.c: In function ‘nfct_timeout_cb’:
+nfct-extensions/timeout.c:99:2: warning: passing argument 4 of ‘nfct_timeout_snprintf’ makes integer from pointer without a cast [enabled by default]
+/usr/include/libnetfilter_cttimeout/libnetfilter_cttimeout.h:114:5: note: expected ‘unsigned int’ but argument is of type ‘struct nfct_timeout *’
+
+Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
+---
+ src/nfct-extensions/timeout.c | 2 +-
+ 1 files changed, 1 insertions(+), 1 deletions(-)
+
+diff --git a/src/nfct-extensions/timeout.c b/src/nfct-extensions/timeout.c
+index a1a5c52..5b32023 100644
+--- a/src/nfct-extensions/timeout.c
++++ b/src/nfct-extensions/timeout.c
+@@ -96,7 +96,7 @@ static int nfct_timeout_cb(const struct nlmsghdr *nlh, void *data)
+ goto err_free;
+ }
+
+- nfct_timeout_snprintf(buf, sizeof(buf), t, 0);
++ nfct_timeout_snprintf(buf, sizeof(buf), t, NFCT_TIMEOUT_O_DEFAULT, 0);
+ printf("%s\n", buf);
+
+ err_free:
+--
+1.7.2.5
+
diff --git a/community-testing/conntrack-tools/PKGBUILD b/community-testing/conntrack-tools/PKGBUILD
new file mode 100644
index 000000000..f8c8ba7ef
--- /dev/null
+++ b/community-testing/conntrack-tools/PKGBUILD
@@ -0,0 +1,53 @@
+# $Id: PKGBUILD 71335 2012-05-27 00:50:12Z seblu $
+# Maintainer: Sébastien Luttringer <seblu@aur.archlinux.org>
+# Contributor: Valere Monseur <valere_monseur@hotmail.com>
+# Contributor: Alessandro Sagratini <ale_sagra@hotmail.com>
+# Contributor: Kevin Edmonds <edmondskevin@hotmail.com>
+
+pkgname=conntrack-tools
+pkgver=1.2.0
+pkgrel=1
+pkgdesc='Userspace tools to interact with the Netfilter connection tracking system'
+arch=('i686' 'x86_64')
+url='http://www.netfilter.org/projects/conntrack-tools'
+license=('GPL2')
+depends=('libnetfilter_conntrack' 'libnetfilter_cttimeout')
+backup=('etc/conntrackd.conf' 'etc/conf.d/conntrackd')
+install=$pkgname.install
+source=("http://www.netfilter.org/projects/$pkgname/files/$pkgname-$pkgver.tar.bz2"
+ 'conntrackd.rc'
+ 'conntrackd.conf'
+ 'conntrackd.service'
+ '01-config-file-path.patch'
+ '02-fix-compilation-of-timeout-extension.patch')
+md5sums=('8e20330d6ca3a3f23552aa900b1d467c'
+ '478fe76da0202fcb5249bf65968d1c26'
+ 'd3e73e81b54e3e8166d357d434680684'
+ 'bd135eaefb47923bb8e8d26f084d3e9d'
+ '411fc0eb97c02595aab69b14c26c1d00'
+ '0144021bbec4d5b496ddd86a7ff7a257')
+
+build() {
+ cd $pkgname-$pkgver
+ for i in "$srcdir"/*.patch; do
+ patch -p1 -i "$i"
+ done
+ ./configure --prefix=/usr --sysconfdir=/etc
+ make
+}
+
+package() {
+ # install binaries
+ pushd $pkgname-$pkgver
+ make DESTDIR="$pkgdir" install
+ popd
+ # initscripts & systemd
+ install -D -m 755 conntrackd.rc "$pkgdir/etc/rc.d/conntrackd"
+ install -D -m 644 conntrackd.conf "$pkgdir/etc/conf.d/conntrackd"
+ install -D -m 644 conntrackd.service \
+ "$pkgdir/usr/lib/systemd/system/conntrackd.service"
+ # install empty configuration files
+ install -D -m 644 /dev/null "$pkgdir/etc/conntrackd.conf"
+}
+
+# vim:set ts=2 sw=2 ft=sh et:
diff --git a/community-testing/conntrack-tools/conntrack-tools.install b/community-testing/conntrack-tools/conntrack-tools.install
new file mode 100644
index 000000000..d21a5f92c
--- /dev/null
+++ b/community-testing/conntrack-tools/conntrack-tools.install
@@ -0,0 +1,9 @@
+## arg 1: the new package version
+## arg 2: the old package version
+post_upgrade() {
+ [ $(vercmp "$2" '1.0.1-2') -gt 0 ] || cat <<EOF
+Config file have been moved from /etc/conntrackd/conntrackd.conf to /etc/conntrackd.conf.
+EOF
+}
+
+# vim:set ts=2 sw=2 ft=sh et:
diff --git a/community-testing/conntrack-tools/conntrackd.conf b/community-testing/conntrack-tools/conntrackd.conf
new file mode 100644
index 000000000..285f566d2
--- /dev/null
+++ b/community-testing/conntrack-tools/conntrackd.conf
@@ -0,0 +1,3 @@
+# vim:set ts=2 sw=2 ft=sh noet:
+
+#DAEMON_OPTIONS=''
diff --git a/community-testing/conntrack-tools/conntrackd.rc b/community-testing/conntrack-tools/conntrackd.rc
new file mode 100644
index 000000000..4300a7041
--- /dev/null
+++ b/community-testing/conntrack-tools/conntrackd.rc
@@ -0,0 +1,34 @@
+#!/bin/bash
+
+. /etc/rc.conf
+. /etc/rc.d/functions
+. /etc/conf.d/${0##*/}
+
+DAEMON=/usr/sbin/conntrackd
+PID=$(pidof -o %PPID $DAEMON)
+DAEMON_OPTIONS="-d $DAEMON_OPTIONS"
+
+case "$1" in
+ start)
+ stat_busy "Starting ${0##*/} daemon"
+ [[ ! $PID ]] && $DAEMON $DAEMON_OPTIONS && add_daemon ${0##*/} && stat_done && exit 0
+ stat_fail
+ ;;
+ stop)
+ stat_busy "Stopping ${0##*/} daemon"
+ [[ $PID ]] && kill $PID &> /dev/null && rm_daemon ${0##*/} && stat_done && exit 0
+ stat_fail
+ ;;
+ restart)
+ $0 stop
+ $0 start
+ exit 0
+ ;;
+ *)
+ echo "usage: ${0##*/} {start|stop|restart}" >&2
+ ;;
+esac
+
+exit 1
+
+# vim:set ts=2 sw=2 ft=sh et:
diff --git a/community-testing/conntrack-tools/conntrackd.service b/community-testing/conntrack-tools/conntrackd.service
new file mode 100644
index 000000000..25a113785
--- /dev/null
+++ b/community-testing/conntrack-tools/conntrackd.service
@@ -0,0 +1,8 @@
+[Unit]
+Description=Conntrack Daemon
+
+[Service]
+ExecStart=/usr/sbin/conntrackd
+
+[Install]
+WantedBy=multi-user.target
diff --git a/community-testing/libnetfilter_cttimeout/PKGBUILD b/community-testing/libnetfilter_cttimeout/PKGBUILD
new file mode 100644
index 000000000..53661d122
--- /dev/null
+++ b/community-testing/libnetfilter_cttimeout/PKGBUILD
@@ -0,0 +1,26 @@
+# $Id: PKGBUILD 71339 2012-05-27 00:57:37Z seblu $
+# Maintainer: Sébastien Luttringer <seblu@aur.archlinux.org>
+
+pkgname=libnetfilter_cttimeout
+pkgver=1.0.0
+pkgrel=2
+pkgdesc='Library for the connection tracking timeout infrastructure'
+arch=('i686' 'x86_64')
+url='http://www.netfilter.org/projects/libnetfilter_cttimeout/'
+license=('GPL2')
+depends=('libmnl' 'linux>=3.4')
+options=('!libtool')
+source=("http://www.netfilter.org/projects/$pkgname/files/$pkgname-$pkgver.tar.bz2")
+md5sums=('7697437fc9ebb6f6b83df56a633db7f9')
+
+build() {
+ cd $pkgname-$pkgver
+ ./configure --prefix=/usr
+}
+
+package() {
+ cd $pkgname-$pkgver
+ make DESTDIR="$pkgdir" install
+}
+
+# vim:set ts=2 sw=2 ft=sh et:
diff --git a/community-testing/multipath-tools/PKGBUILD b/community-testing/multipath-tools/PKGBUILD
new file mode 100644
index 000000000..28d08b8f4
--- /dev/null
+++ b/community-testing/multipath-tools/PKGBUILD
@@ -0,0 +1,41 @@
+# $Id: PKGBUILD 71284 2012-05-26 08:37:33Z bpiotrowski $
+# Maintainer: Bartłomiej Piotrowski <nospam@bpiotrowski.pl>
+# Contributor: Thomas S Hatch <thatch45 ar gmail dot com>
+# Contributor: Michael P <ptchinster@archlinux.us>
+# Contributor: Matt Heagney <matt@heagney.com>
+
+pkgname=multipath-tools
+pkgver=0.4.9
+pkgrel=7
+pkgdesc='Multipath tools for Linux'
+arch=('i686' 'x86_64')
+url="http://christophe.varoqui.free.fr/"
+license=('GPL')
+depends=('libaio' 'device-mapper')
+backup=('etc/multipath.conf' 'etc/multipath.conf.annotated')
+install=multipath-tools.install
+options=(!emptydirs)
+source=(http://christophe.varoqui.free.fr/multipath-tools/$pkgname-$pkgver.tar.bz2
+ multipath.conf multipath.conf.annotated multipathd.rc all-in-one.patch)
+md5sums=('a6d4b48afc28f1f50f5ee4b1b06d2765'
+ '9324ff0ba8330dcb21b2fcf64988026f'
+ 'be11462922eeeb9fcd2ba5f3f137b7d9'
+ '7c04ef96441363b0d43a2ebb13a87659'
+ '885c0ba9c90b73cc93aa3f78005f81d6')
+
+build() {
+ patch -Np1 -i all-in-one.patch
+
+ # Needs to be fixed upstream. Refer to
+ # https://bbs.archlinux.org/viewtopic.php?pid=793814#p793814
+ export LDFLAGS=${LDFLAGS/-Wl,--as-needed}
+
+ make
+}
+
+package() {
+ make LIB='usr/lib' DESTDIR="$pkgdir" bindir='/usr/bin' libudevdir='/usr/lib/udev' install
+ install -D -m 644 multipath.conf "$pkgdir"/etc/multipath.conf
+ install -D -m 644 multipath.conf.annotated "$pkgdir"/etc/multipath.conf.annotated
+ install -D -m 755 multipathd.rc "$pkgdir"/etc/rc.d/multipathd
+}
diff --git a/community-testing/multipath-tools/all-in-one.patch b/community-testing/multipath-tools/all-in-one.patch
new file mode 100644
index 000000000..ff8f6824c
--- /dev/null
+++ b/community-testing/multipath-tools/all-in-one.patch
@@ -0,0 +1,209 @@
+diff -rupN upstream/Makefile.inc devel/Makefile.inc
+--- upstream/Makefile.inc 2010-05-22 14:01:58.000000000 +0200
++++ devel/Makefile.inc 2012-05-26 10:14:46.969786387 +0200
+@@ -32,11 +32,10 @@ rcdir = $(prefix)/etc/init.d
+ syslibdir = $(prefix)/$(LIB)
+ libdir = $(prefix)/$(LIB)/multipath
+
+-GZIP = /bin/gzip -9 -c
+ INSTALL_PROGRAM = install
+
+-OPTFLAGS = -pipe -g -Wall -Wunused -Wstrict-prototypes
+-CFLAGS = $(OPTFLAGS) -fPIC -DLIB_STRING=\"${LIB}\"
++OPTFLAGS = -Wall -Wunused -Wstrict-prototypes
++CFLAGS += $(OPTFLAGS) -fPIC -DLIB_STRING=\"${LIB}\"
+ SHARED_FLAGS = -shared
+
+ %.o: %.c
+diff -rupN upstream/kpartx/Makefile devel/kpartx/Makefile
+--- upstream/kpartx/Makefile 2010-05-22 14:01:58.000000000 +0200
++++ devel/kpartx/Makefile 2012-05-26 10:23:38.909780754 +0200
+@@ -6,7 +6,7 @@ include ../Makefile.inc
+
+ CFLAGS += -I. -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64
+
+-LDFLAGS = -ldevmapper
++LIBS = -ldevmapper
+ OBJS = bsd.o dos.o kpartx.o solaris.o unixware.o dasd.o sun.o \
+ gpt.o mac.o crc32.o lopart.o xstrncpy.o devmapper.o
+ EXEC = kpartx
+@@ -14,22 +14,22 @@ EXEC = kpartx
+ all: $(EXEC)
+
+ $(EXEC): $(OBJS)
+- $(CC) $(OBJS) -o $(EXEC) $(LDFLAGS)
+- $(GZIP) $(EXEC).8 > $(EXEC).8.gz
++ $(CC) $(CFLAGS) $(LDFLAGS) $(OBJS) $(LIBS) -o $(EXEC)
+
+ install: $(EXEC) $(EXEC).8
+ $(INSTALL_PROGRAM) -d $(DESTDIR)$(bindir)
+ $(INSTALL_PROGRAM) -m 755 $(EXEC) $(DESTDIR)$(bindir)
+ $(INSTALL_PROGRAM) -d $(DESTDIR)$(libudevdir)
+ $(INSTALL_PROGRAM) -m 755 kpartx_id $(DESTDIR)$(libudevdir)
+- $(INSTALL_PROGRAM) -d $(DESTDIR)/etc/udev/rules.d
+- $(INSTALL_PROGRAM) -m 644 kpartx.rules $(DESTDIR)/etc/udev/rules.d/
++ $(INSTALL_PROGRAM) -d $(DESTDIR)/usr/lib/udev/rules.d
++ $(INSTALL_PROGRAM) -m 644 kpartx.rules $(DESTDIR)/usr/lib/udev/rules.d/66-kpartx.rules
+ $(INSTALL_PROGRAM) -d $(DESTDIR)$(mandir)
+- $(INSTALL_PROGRAM) -m 644 $(EXEC).8.gz $(DESTDIR)$(mandir)
++ $(INSTALL_PROGRAM) -m 644 $(EXEC).8 $(DESTDIR)$(mandir)
+
+ uninstall:
+ rm -f $(DESTDIR)$(bindir)/$(EXEC)
+- rm -f $(DESTDIR)$(mandir)/$(EXEC).8.gz
++ rm -f $(DESTDIR)$(mandir)/$(EXEC).8
++ rm -f $(DESTDIR)/usr/lib/udev/rules.d/66-kpartx.rules
+
+ clean:
+- rm -f core *.o $(EXEC) *.gz
++ rm -f core *.o $(EXEC)
+diff -rupN upstream/kpartx/kpartx.rules devel/kpartx/kpartx.rules
+--- upstream/kpartx/kpartx.rules 2010-05-22 14:01:58.000000000 +0200
++++ devel/kpartx/kpartx.rules 2012-05-26 10:30:32.769776372 +0200
+@@ -27,9 +27,9 @@ ENV{DM_PART}=="?*", \
+
+ # Create dm tables for partitions
+ ENV{DM_STATE}=="ACTIVE", ENV{DM_UUID}=="mpath-*", \
+- RUN+="/sbin/kpartx -a -p -part /dev/$name"
++ RUN+="/usr/sbin/kpartx -a -p -part /dev/$name"
+ ENV{DM_STATE}=="ACTIVE", ENV{DM_UUID}=="dmraid-*", \
+- RUN+="/sbin/kpartx -a -p -part /dev/$name"
++ RUN+="/usr/sbin/kpartx -a -p -part /dev/$name"
+
+ LABEL="kpartx_end"
+
+diff -rupN upstream/multipath/Makefile devel/multipath/Makefile
+--- upstream/multipath/Makefile 2010-05-22 14:01:58.000000000 +0200
++++ devel/multipath/Makefile 2012-05-26 10:22:38.819781391 +0200
+@@ -7,32 +7,30 @@ include ../Makefile.inc
+ OBJS = main.o
+
+ CFLAGS += -I$(multipathdir)
+-LDFLAGS += -lpthread -ldevmapper -ldl -lmultipath -L$(multipathdir)
++LIBS = -lpthread -ldevmapper -ldl -L$(multipathdir) -lmultipath
+
+ EXEC = multipath
+
+ all: $(EXEC)
+
+ $(EXEC): $(OBJS)
+- $(CC) $(CFLAGS) $(OBJS) -o $(EXEC) $(LDFLAGS)
+- $(GZIP) $(EXEC).8 > $(EXEC).8.gz
+- $(GZIP) $(EXEC).conf.5 > $(EXEC).conf.5.gz
++ $(CC) $(CFLAGS) $(LDFLAGS) $(OBJS) $(LIBS) -o $(EXEC)
+
+ install:
+ $(INSTALL_PROGRAM) -d $(DESTDIR)$(bindir)
+ $(INSTALL_PROGRAM) -m 755 $(EXEC) $(DESTDIR)$(bindir)/
+- $(INSTALL_PROGRAM) -d $(DESTDIR)/etc/udev/rules.d
+- $(INSTALL_PROGRAM) -m 644 multipath.rules $(DESTDIR)/etc/udev/rules.d/
++ $(INSTALL_PROGRAM) -d $(DESTDIR)/usr/lib/udev/rules.d
++ $(INSTALL_PROGRAM) -m 644 multipath.rules $(DESTDIR)/usr/lib/udev/rules.d/65-multipath.rules
+ $(INSTALL_PROGRAM) -d $(DESTDIR)$(mandir)
+- $(INSTALL_PROGRAM) -m 644 $(EXEC).8.gz $(DESTDIR)$(mandir)
++ $(INSTALL_PROGRAM) -m 644 $(EXEC).8 $(DESTDIR)$(mandir)
+ $(INSTALL_PROGRAM) -d $(DESTDIR)$(man5dir)
+- $(INSTALL_PROGRAM) -m 644 $(EXEC).conf.5.gz $(DESTDIR)$(man5dir)
++ $(INSTALL_PROGRAM) -m 644 $(EXEC).conf.5 $(DESTDIR)$(man5dir)
+
+ uninstall:
+- rm $(DESTDIR)/etc/udev/rules.d/multipath.rules
+- rm $(DESTDIR)$(bindir)/$(EXEC)
+- rm $(DESTDIR)$(mandir)/$(EXEC).8.gz
+- rm $(DESTDIR)$(man5dir)/$(EXEC).conf.5.gz
++ rm -f $(DESTDIR)/usr/lib/udev/rules.d/65-multipath.rules
++ rm -f $(DESTDIR)$(bindir)/$(EXEC)
++ rm -f $(DESTDIR)$(mandir)/$(EXEC).8
++ rm -f $(DESTDIR)$(man5dir)/$(EXEC).conf.5
+
+ clean:
+- rm -f core *.o $(EXEC) *.gz
++ rm -f core *.o $(EXEC)
+diff -rupN upstream/multipath/multipath.rules devel/multipath/multipath.rules
+--- upstream/multipath/multipath.rules 2010-05-22 14:01:58.000000000 +0200
++++ devel/multipath/multipath.rules 2012-05-26 10:17:34.849784609 +0200
+@@ -1,7 +1,24 @@
+-#
+-# udev rules for multipathing.
+-# The persistent symlinks are created with the kpartx rules
+-#
++# multipath wants the devmaps presented as meaninglful device names
++# so name them after their devmap name
++SUBSYSTEM!="block", GOTO="end_mpath"
+
+-# socket for uevents
+-SUBSYSTEM=="block", RUN+="socket:/org/kernel/dm/multipath_event"
++ENV{MPATH_SBIN_PATH}="/sbin"
++TEST!="$env{MPATH_SBIN_PATH}/multipath", ENV{MPATH_SBIN_PATH}="/usr/sbin"
++
++ACTION=="add", ENV{DEVTYPE}!="partition", \
++ ENV{DM_MULTIPATH_DEVICE_PATH}!="1", \
++ PROGRAM=="$env{MPATH_SBIN_PATH}/multipath -c $tempnode", \
++ ENV{DM_MULTIPATH_DEVICE_PATH}="1"
++
++ENV{DM_MULTIPATH_DEVICE_PATH}=="1", ENV{DEVTYPE}!="partition", \
++ RUN+="/sbin/partx -d --nr 1-1024 $env{DEVNAME}"
++
++RUN+="socket:/org/kernel/dm/multipath_event"
++KERNEL!="dm-*", GOTO="end_mpath"
++ACTION!="change", GOTO="end_mpath"
++ENV{DM_UUID}=="mpath-?*|part[0-9]*-mpath-?*", OPTIONS+="link_priority=10"
++ENV{DM_UUID}!="mpath-?*", GOTO="end_mpath"
++ENV{DM_SUSPENDED}=="1", GOTO="end_mpath"
++ENV{DM_ACTION}=="PATH_FAILED", GOTO="end_mpath"
++RUN+="$env{MPATH_SBIN_PATH}/kpartx -a -p p $tempnode"
++LABEL="end_mpath"
+diff -rupN upstream/multipath-tools.spec.in devel/multipath-tools.spec.in
+--- upstream/multipath-tools.spec.in 2010-05-22 14:01:58.000000000 +0200
++++ devel/multipath-tools.spec.in 2012-05-26 10:24:16.989780353 +0200
+@@ -47,8 +47,8 @@ rm -rf $RPM_BUILD_ROOT
+ %{prefix}/usr/share/man/man8/multipathd.8.gz
+ %{prefix}/usr/share/man/man5/multipath.conf.5.gz
+ %{prefix}/sbin/multipathd
+-%{prefix}/etc/udev/rules.d/multipath.rules
+-%{prefix}/etc/udev/rules.d/kpartx.rules
++%{prefix}/usr/lib/udev/rules.d/multipath.rules
++%{prefix}/usr/lib/udev/rules.d/kpartx.rules
+ %{prefix}/lib/udev/kpartx_id
+ %{prefix}/lib/multipath/*.so
+
+diff -rupN upstream/multipathd/Makefile devel/multipathd/Makefile
+--- upstream/multipathd/Makefile 2010-05-22 14:01:58.000000000 +0200
++++ devel/multipathd/Makefile 2012-05-26 10:14:46.969786387 +0200
+@@ -6,8 +6,8 @@ include ../Makefile.inc
+ # basic flags setting
+ #
+ CFLAGS += -I$(multipathdir)
+-LDFLAGS += -lpthread -ldevmapper -lreadline -lncurses -ldl \
+- -lmultipath -L$(multipathdir)
++LIBS = -lpthread -ldevmapper -lreadline -lncurses -ldl \
++ -L$(multipathdir) -lmultipath
+
+ #
+ # debuging stuff
+@@ -28,21 +28,20 @@ OBJS = main.o pidfile.o uxlsnr.o uxclnt.
+ all : $(EXEC)
+
+ $(EXEC): $(OBJS)
+- $(CC) $(CFLAGS) $(LDFLAGS) -o $(EXEC) $(OBJS)
+- $(GZIP) $(EXEC).8 > $(EXEC).8.gz
++ $(CC) $(CFLAGS) $(LDFLAGS) $(OBJS) $(LIBS) -o $(EXEC)
+
+ install:
+ $(INSTALL_PROGRAM) -d $(DESTDIR)$(bindir)
+ $(INSTALL_PROGRAM) -m 755 $(EXEC) $(DESTDIR)$(bindir)
+ $(INSTALL_PROGRAM) -d $(DESTDIR)$(rcdir)
+ $(INSTALL_PROGRAM) -d $(DESTDIR)$(mandir)
+- $(INSTALL_PROGRAM) -m 644 $(EXEC).8.gz $(DESTDIR)$(mandir)
++ $(INSTALL_PROGRAM) -m 644 $(EXEC).8 $(DESTDIR)$(mandir)
+
+ uninstall:
+ rm -f $(DESTDIR)$(bindir)/$(EXEC)
+ rm -f $(DESTDIR)$(rcdir)/$(EXEC)
+- rm -f $(DESTDIR)$(mandir)/$(EXEC).8.gz
++ rm -f $(DESTDIR)$(mandir)/$(EXEC).8
+
+ clean:
+- rm -f core *.o $(EXEC) *.gz
++ rm -f core *.o $(EXEC)
+
diff --git a/community-testing/multipath-tools/fix-build.patch b/community-testing/multipath-tools/fix-build.patch
new file mode 100644
index 000000000..c6196f73b
--- /dev/null
+++ b/community-testing/multipath-tools/fix-build.patch
@@ -0,0 +1,140 @@
+--- multipath-tools-0.4.9.orig/kpartx/Makefile 2010-05-22 05:01:58.000000000 -0700
++++ multipath-tools-0.4.9/kpartx/Makefile 2010-11-28 12:14:25.763531104 -0800
+@@ -6,7 +6,7 @@
+
+ CFLAGS += -I. -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64
+
+-LDFLAGS = -ldevmapper
++LIBS = -ldevmapper
+ OBJS = bsd.o dos.o kpartx.o solaris.o unixware.o dasd.o sun.o \
+ gpt.o mac.o crc32.o lopart.o xstrncpy.o devmapper.o
+ EXEC = kpartx
+@@ -14,8 +14,7 @@
+ all: $(EXEC)
+
+ $(EXEC): $(OBJS)
+- $(CC) $(OBJS) -o $(EXEC) $(LDFLAGS)
+- $(GZIP) $(EXEC).8 > $(EXEC).8.gz
++ $(CC) $(CFLAGS) $(LDFLAGS) $(OBJS) $(LIBS) -o $(EXEC)
+
+ install: $(EXEC) $(EXEC).8
+ $(INSTALL_PROGRAM) -d $(DESTDIR)$(bindir)
+@@ -23,13 +22,14 @@
+ $(INSTALL_PROGRAM) -d $(DESTDIR)$(libudevdir)
+ $(INSTALL_PROGRAM) -m 755 kpartx_id $(DESTDIR)$(libudevdir)
+ $(INSTALL_PROGRAM) -d $(DESTDIR)/etc/udev/rules.d
+- $(INSTALL_PROGRAM) -m 644 kpartx.rules $(DESTDIR)/etc/udev/rules.d/
++ $(INSTALL_PROGRAM) -m 644 kpartx.rules $(DESTDIR)/etc/udev/rules.d/66-kpartx.rules
+ $(INSTALL_PROGRAM) -d $(DESTDIR)$(mandir)
+- $(INSTALL_PROGRAM) -m 644 $(EXEC).8.gz $(DESTDIR)$(mandir)
++ $(INSTALL_PROGRAM) -m 644 $(EXEC).8 $(DESTDIR)$(mandir)
+
+ uninstall:
+ rm -f $(DESTDIR)$(bindir)/$(EXEC)
+- rm -f $(DESTDIR)$(mandir)/$(EXEC).8.gz
++ rm -f $(DESTDIR)$(mandir)/$(EXEC).8
++ rm -f $(DESTDIR)/etc/udev/rules.d/66-kpartx.rules
+
+ clean:
+- rm -f core *.o $(EXEC) *.gz
++ rm -f core *.o $(EXEC)
+--- multipath-tools-0.4.9.orig/Makefile.inc 2010-05-22 05:01:58.000000000 -0700
++++ multipath-tools-0.4.9/Makefile.inc 2010-11-28 12:14:25.763531104 -0800
+@@ -32,11 +32,10 @@
+ syslibdir = $(prefix)/$(LIB)
+ libdir = $(prefix)/$(LIB)/multipath
+
+-GZIP = /bin/gzip -9 -c
+ INSTALL_PROGRAM = install
+
+-OPTFLAGS = -pipe -g -Wall -Wunused -Wstrict-prototypes
+-CFLAGS = $(OPTFLAGS) -fPIC -DLIB_STRING=\"${LIB}\"
++OPTFLAGS = -Wall -Wunused -Wstrict-prototypes
++CFLAGS += $(OPTFLAGS) -fPIC -DLIB_STRING=\"${LIB}\"
+ SHARED_FLAGS = -shared
+
+ %.o: %.c
+--- multipath-tools-0.4.9.orig/multipath/Makefile 2010-05-22 05:01:58.000000000 -0700
++++ multipath-tools-0.4.9/multipath/Makefile 2010-11-28 12:14:46.718697048 -0800
+@@ -7,32 +7,30 @@
+ OBJS = main.o
+
+ CFLAGS += -I$(multipathdir)
+-LDFLAGS += -lpthread -ldevmapper -ldl -lmultipath -L$(multipathdir)
++LIBS = -lpthread -ldevmapper -ldl -L$(multipathdir) -lmultipath
+
+ EXEC = multipath
+
+ all: $(EXEC)
+
+ $(EXEC): $(OBJS)
+- $(CC) $(CFLAGS) $(OBJS) -o $(EXEC) $(LDFLAGS)
+- $(GZIP) $(EXEC).8 > $(EXEC).8.gz
+- $(GZIP) $(EXEC).conf.5 > $(EXEC).conf.5.gz
++ $(CC) $(CFLAGS) $(LDFLAGS) $(OBJS) $(LIBS) -o $(EXEC)
+
+ install:
+ $(INSTALL_PROGRAM) -d $(DESTDIR)$(bindir)
+ $(INSTALL_PROGRAM) -m 755 $(EXEC) $(DESTDIR)$(bindir)/
+ $(INSTALL_PROGRAM) -d $(DESTDIR)/etc/udev/rules.d
+- $(INSTALL_PROGRAM) -m 644 multipath.rules $(DESTDIR)/etc/udev/rules.d/
++ $(INSTALL_PROGRAM) -m 644 multipath.rules $(DESTDIR)/etc/udev/rules.d/65-multipath.rules
+ $(INSTALL_PROGRAM) -d $(DESTDIR)$(mandir)
+- $(INSTALL_PROGRAM) -m 644 $(EXEC).8.gz $(DESTDIR)$(mandir)
++ $(INSTALL_PROGRAM) -m 644 $(EXEC).8 $(DESTDIR)$(mandir)
+ $(INSTALL_PROGRAM) -d $(DESTDIR)$(man5dir)
+- $(INSTALL_PROGRAM) -m 644 $(EXEC).conf.5.gz $(DESTDIR)$(man5dir)
++ $(INSTALL_PROGRAM) -m 644 $(EXEC).conf.5 $(DESTDIR)$(man5dir)
+
+ uninstall:
+- rm $(DESTDIR)/etc/udev/rules.d/multipath.rules
+- rm $(DESTDIR)$(bindir)/$(EXEC)
+- rm $(DESTDIR)$(mandir)/$(EXEC).8.gz
+- rm $(DESTDIR)$(man5dir)/$(EXEC).conf.5.gz
++ rm -f $(DESTDIR)/etc/udev/rules.d/65-multipath.rules
++ rm -f $(DESTDIR)$(bindir)/$(EXEC)
++ rm -f $(DESTDIR)$(mandir)/$(EXEC).8
++ rm -f $(DESTDIR)$(man5dir)/$(EXEC).conf.5
+
+ clean:
+- rm -f core *.o $(EXEC) *.gz
++ rm -f core *.o $(EXEC)
+--- multipath-tools-0.4.9.orig/multipathd/Makefile 2010-05-22 05:01:58.000000000 -0700
++++ multipath-tools-0.4.9/multipathd/Makefile 2010-11-28 12:15:46.624171566 -0800
+@@ -6,8 +6,8 @@
+ # basic flags setting
+ #
+ CFLAGS += -I$(multipathdir)
+-LDFLAGS += -lpthread -ldevmapper -lreadline -lncurses -ldl \
+- -lmultipath -L$(multipathdir)
++LIBS = -lpthread -ldevmapper -lreadline -lncurses -ldl \
++ -L$(multipathdir) -lmultipath
+
+ #
+ # debuging stuff
+@@ -28,21 +28,20 @@
+ all : $(EXEC)
+
+ $(EXEC): $(OBJS)
+- $(CC) $(CFLAGS) $(LDFLAGS) -o $(EXEC) $(OBJS)
+- $(GZIP) $(EXEC).8 > $(EXEC).8.gz
++ $(CC) $(CFLAGS) $(LDFLAGS) $(OBJS) $(LIBS) -o $(EXEC)
+
+ install:
+ $(INSTALL_PROGRAM) -d $(DESTDIR)$(bindir)
+ $(INSTALL_PROGRAM) -m 755 $(EXEC) $(DESTDIR)$(bindir)
+ $(INSTALL_PROGRAM) -d $(DESTDIR)$(rcdir)
+ $(INSTALL_PROGRAM) -d $(DESTDIR)$(mandir)
+- $(INSTALL_PROGRAM) -m 644 $(EXEC).8.gz $(DESTDIR)$(mandir)
++ $(INSTALL_PROGRAM) -m 644 $(EXEC).8 $(DESTDIR)$(mandir)
+
+ uninstall:
+ rm -f $(DESTDIR)$(bindir)/$(EXEC)
+ rm -f $(DESTDIR)$(rcdir)/$(EXEC)
+- rm -f $(DESTDIR)$(mandir)/$(EXEC).8.gz
++ rm -f $(DESTDIR)$(mandir)/$(EXEC).8
+
+ clean:
+- rm -f core *.o $(EXEC) *.gz
++ rm -f core *.o $(EXEC)
+
diff --git a/community-testing/multipath-tools/multipath-tools.install b/community-testing/multipath-tools/multipath-tools.install
new file mode 100644
index 000000000..fa58bbc35
--- /dev/null
+++ b/community-testing/multipath-tools/multipath-tools.install
@@ -0,0 +1,4 @@
+post_install() {
+
+ echo " * For full functonality ensure that the dm_multipath kernel module is loaded"
+}
diff --git a/community-testing/multipath-tools/multipath.conf b/community-testing/multipath-tools/multipath.conf
new file mode 100644
index 000000000..6dacf093d
--- /dev/null
+++ b/community-testing/multipath-tools/multipath.conf
@@ -0,0 +1,8 @@
+#
+# Very Basic Multipath Configuration File
+#
+
+defaults {
+ getuid_callout "/usr/lib/udev/scsi_id -g -u -d /dev/%n"
+}
+
diff --git a/community-testing/multipath-tools/multipath.conf.annotated b/community-testing/multipath-tools/multipath.conf.annotated
new file mode 100644
index 000000000..b79488413
--- /dev/null
+++ b/community-testing/multipath-tools/multipath.conf.annotated
@@ -0,0 +1,362 @@
+##
+## This is a template multipath-tools configuration file
+## Uncomment the lines relevent to your environment
+##
+#
+##
+## name : defaults
+## desc : multipath-tools default settings
+##
+#defaults {
+# #
+# # name : udev_dir
+# # desc : directory where udev creates its device nodes
+# # default : /dev
+# #
+# udev_dir /dev
+#
+# #
+# # name : polling_interval
+# # scope : multipathd
+# # desc : interval between two path checks in seconds
+# # default : 5
+# #
+# polling_interval 10
+#
+# #
+# # name : selector
+# # scope : multipath
+# # desc : the default path selector algorithm to use
+# # these algorithms are offered by the kernel multipath target
+# # values : "round-robin 0"
+# # default : "round-robin 0"
+# #
+# selector "round-robin 0"
+#
+# #
+# # name : path_grouping_policy
+# # scope : multipath
+# # desc : the default path grouping policy to apply to unspecified
+# # multipaths
+# # default : multibus
+# #
+# path_grouping_policy multibus
+#
+# #
+# # name : getuid_callout
+# # scope : multipath
+# # desc : the default program and args to callout to obtain a unique
+# # path identifier. Absolute path required
+# # default : /usr/lib/udev/scsi_id -g -u -s
+# #
+# getuid_callout "/usr/lib/udev/scsi_id -g -u -s /block/%n"
+#
+# #
+# # name : prio_callout
+# # scope : multipath
+# # desc : the default program and args to callout to obtain a path
+# # priority value. The ALUA bits in SPC-3 provide an
+# # exploitable prio value for example. "none" is a valid value
+# # default : (null)
+# #
+# #prio_callout "/bin/true"
+#
+# #
+# # name : path_checker
+# # scope : multipath & multipathd
+# # desc : the default method used to determine the paths' state
+# # values : readsector0|tur|emc_clariion|hp_sw|directio
+# # default : directio
+# #
+# #path_checker directio
+#
+# #
+# # name : rr_min_io
+# # scope : multipath
+# # desc : the number of IO to route to a path before switching
+# # to the next in the same path group
+# # default : 1000
+# #
+# rr_min_io 100
+#
+# #
+# # name : rr_weight
+# # scope : multipath
+# # desc : if set to priorities the multipath configurator will assign
+# # path weights as "path prio * rr_min_io"
+# # values : priorities|uniform
+# # default : uniform
+# #
+# rr_weight priorities
+#
+# #
+# # name : failback
+# # scope : multipathd
+# # desc : tell the daemon to manage path group failback, or not to.
+# # 0 means immediate failback, values >0 means deffered failback
+# # expressed in seconds.
+# # values : manual|immediate|n > 0
+# # default : immediate
+# #
+# failback manual
+#
+# #
+# # name : no_path_retry
+# # scope : multipath & multipathd
+# # desc : tell the number of retries until disable queueing, or
+# # "fail" means immediate failure (no queueing),
+# # "queue" means never stop queueing
+# # values : queue|fail|n (>0)
+# # default : (null)
+# #
+# #no_path_retry queue
+#
+# #
+# # name : user_friendly_names
+# # scope : multipath
+# # desc : If set to "yes", using the bindings file
+# # /var/lib/multipath/bindings to assign a persistent and
+# # unique alias to the multipath, in the form of mpath<n>.
+# # If set to "no" use the WWID as the alias. In either case
+# # this be will be overriden by any specific aliases in this
+# # file.
+# # values : yes|no
+# # default : no
+# user_friendly_names no
+#
+#}
+#
+##
+## name : blacklist
+## scope : multipath & multipathd
+## desc : list of device names to discard as not multipath candidates
+## default : cciss, fd, hd, md, dm, sr, scd, st, ram, raw, loop
+##
+#blacklist {
+# wwid 26353900f02796769
+# devnode "^(ram|raw|loop|fd|md|dm-|sr|scd|st)[0-9]*"
+# devnode "^hd[a-z][[0-9]*]"
+# devnode "^cciss!c[0-9]d[0-9]*[p[0-9]*]"
+# device {
+# vendor DEC.*
+# product MSA[15]00
+# }
+#}
+##
+## name : blacklist_exceptions
+## scope : multipath & multipathd
+## desc : list of device names to be treated as multipath candidates
+## even if they are on the blacklist.
+## Note: blacklist exceptions are only valid in the same class.
+## It is not possible to blacklist devices using the devnode keyword
+## and to exclude some devices of them using the wwid keyword.
+## default : -
+##
+#blacklist_exceptions {
+# devnode "^dasd[c-d]+[0-9]*"
+# wwid "IBM.75000000092461.4d00.34"
+# wwid "IBM.75000000092461.4d00.35"
+# wwid "IBM.75000000092461.4d00.36"
+#}
+#
+##
+## name : multipaths
+## scope : multipath & multipathd
+## desc : list of multipaths finest-grained settings
+##
+#multipaths {
+# #
+# # name : multipath
+# # scope : multipath & multipathd
+# # desc : container for settings that apply to one specific multipath
+# #
+# multipath {
+# #
+# # name : wwid
+# # scope : multipath & multipathd
+# # desc : index of the container
+# #
+# wwid 3600508b4000156d700012000000b0000
+#
+# #
+# # name : alias
+# # scope : multipath
+# # desc : symbolic name for the multipath
+# #
+# alias yellow
+#
+# #
+# # name : path_grouping_policy
+# # scope : multipath
+# # desc : path grouping policy to apply to this multipath
+# # values : failover, multibus, group_by_serial
+# # default : failover
+# #
+# path_grouping_policy multibus
+#
+# #
+# # name : path_checker
+# # scope : multipathd
+# # desc : path checking alorithm to use to check path state
+# # values : readsector0|tur|emc_clariion|hp_sw|directio
+# # default : directio
+# #
+# # path_checker directio
+#
+# #
+# # name : path_selector
+# # desc : the path selector algorithm to use for this mpath
+# # these algo are offered by the kernel mpath target
+# # values : "round-robin 0"
+# # default : "round-robin 0"
+# #
+# path_selector "round-robin 0"
+#
+# #
+# # name : failback
+# # scope : multipathd
+# # desc : tell the daemon to manage path group failback, or not to.
+# # 0 means immediate failback, values >0 means deffered failback
+# # expressed in seconds.
+# # values : manual|immediate|n > 0
+# # default : immediate
+# #
+# failback manual
+#
+# #
+# # name : no_path_retry
+# # scope : multipath & multipathd
+# # desc : tell the number of retries until disable queueing, or
+# # "fail" means immediate failure (no queueing),
+# # "queue" means never stop queueing
+# # values : queue|fail|n (>0)
+# # default : (null)
+# #
+# #no_path_retry queue
+#
+# #
+# # name : rr_min_io
+# # scope : multipath
+# # desc : the number of IO to route to a path before switching
+# # to the next in the same path group
+# # default : 1000
+# #
+# rr_min_io 100
+# }
+# multipath {
+# wwid 1DEC_____321816758474
+# alias red
+# rr_weight priorities
+# }
+#}
+#
+##
+## name : devices
+## scope : multipath & multipathd
+## desc : list of per storage controller settings
+## overrides default settings (device_maps block)
+## overriden by per multipath settings (multipaths block)
+##
+#devices {
+# #
+# # name : device
+# # scope : multipath & multipathd
+# # desc : settings for this specific storage controller
+# #
+# device {
+# #
+# # name : vendor, product
+# # scope : multipath & multipathd
+# # desc : index for the block
+# #
+# vendor "COMPAQ "
+# product "HSV110 (C)COMPAQ"
+#
+# #
+# # name : path_grouping_policy
+# # scope : multipath
+# # desc : path grouping policy to apply to multipath hosted
+# # by this storage controller
+# # values : failover = 1 path per priority group
+# # multibus = all valid paths in 1 priority
+# # group
+# # group_by_serial = 1 priority group per detected
+# # serial number
+# # default : failover
+# #
+# path_grouping_policy multibus
+#
+# #
+# # name : getuid_callout
+# # scope : multipath
+# # desc : the program and args to callout to obtain a unique
+# # path identifier. Absolute path required
+# # default : /usr/lib/udev/scsi_id -g -u -s
+# #
+# getuid_callout "/usr/lib/udev/scsi_id -g -u -s /block/%n"
+#
+# #
+# # name : prio_callout
+# # scope : multipath
+# # desc : the program and args to callout to obtain a path
+# # weight. Weights are summed for each path group to
+# # determine the next PG to use case of failure.
+# # "none" is a valid value.
+# # default : no callout, all paths equals
+# #
+# prio_callout "/sbin/mpath_prio_balance_units %d"
+#
+# #
+# # name : path_checker
+# # scope : multipathd
+# # desc : path checking alorithm to use to check path state
+# # values : readsector0|tur|emc_clariion|hp_sw|directio
+# # default : directio
+# #
+# path_checker directio
+#
+# #
+# # name : path_selector
+# # desc : the path selector algorithm to use for this mpath
+# # these algo are offered by the kernel mpath target
+# # values : "round-robin 0"
+# # default : "round-robin 0"
+# #
+# path_selector "round-robin 0"
+#
+# #
+# # name : failback
+# # scope : multipathd
+# # desc : tell the daemon to manage path group failback, or not to.
+# # 0 means immediate failback, values >0 means deffered failback
+# # expressed in seconds.
+# # values : manual|immediate|n > 0
+# # default : immediate
+# #
+# failback 30
+#
+# #
+# # name : rr_min_io
+# # scope : multipath
+# # desc : the number of IO to route to a path before switching
+# # to the next in the same path group
+# # default : 1000
+# #
+# rr_min_io 100
+#
+# #
+# # name : product_blacklist
+# # scope : multipath & multipathd
+# # desc : product strings to blacklist for this vendor
+# # default : none
+# #
+# product_blacklist LUN_Z
+# }
+# device {
+# vendor "COMPAQ "
+# product "MSA1000 "
+# path_grouping_policy multibus
+# path_checker tur
+# rr_weight priorities
+# }
+#}
diff --git a/community-testing/multipath-tools/multipathd.rc b/community-testing/multipath-tools/multipathd.rc
new file mode 100644
index 000000000..7f5ef5d6a
--- /dev/null
+++ b/community-testing/multipath-tools/multipathd.rc
@@ -0,0 +1,35 @@
+#!/bin/bash
+
+. /etc/rc.conf
+. /etc/rc.d/functions
+
+case "$1" in
+ start)
+ stat_busy "Starting multipathd"
+ /usr/bin/multipathd
+ if [ $? -gt 0 ]; then
+ stat_fail
+ else
+ add_daemon multipathd
+ stat_done
+ fi
+ ;;
+ stop)
+ stat_busy "Stopping multipathd"
+ [ -f /var/run/multipathd.pid ] && kill `cat /var/run/multipathd.pid` >/dev/null 2>&1
+ if [ $? -gt 0 ]; then
+ stat_fail
+ else
+ rm_daemon multipathd
+ stat_done
+ fi
+ ;;
+ restart)
+ $0 stop
+ sleep 2
+ $0 start
+ ;;
+ *)
+ echo "usage: $0 {start|stop|restart}"
+esac
+exit 0
diff --git a/community/arptables/PKGBUILD b/community/arptables/PKGBUILD
index ac6942bcb..40eba2685 100644
--- a/community/arptables/PKGBUILD
+++ b/community/arptables/PKGBUILD
@@ -1,18 +1,27 @@
-# $Id: PKGBUILD 64145 2012-02-09 09:48:15Z seblu $
+# $Id: PKGBUILD 71317 2012-05-26 14:59:39Z seblu $
# Maintainer: Sébastien Luttringer <seblu@aur.archlinux.org>
# Contributor: Daniel Micay <danielmicay@gmail.com>
# Contributor: Michal Soltys <soltys@ziu.info>
pkgname=arptables
pkgver=0.0.3_4
-pkgrel=2
+pkgrel=3
pkgdesc='ARP filtering utility'
arch=('i686' 'x86_64')
url='http://ebtables.sourceforge.net/'
license=('GPL')
-source=("http://downloads.sourceforge.net/ebtables/$pkgname-v${pkgver//_/-}.tar.gz" 'arptables.rc')
+backup=("etc/$pkgname.conf" "etc/conf.d/$pkgname")
+install=$pkgname.install
+source=("http://downloads.sourceforge.net/ebtables/$pkgname-v${pkgver//_/-}.tar.gz"
+ "$pkgname.conf"
+ "$pkgname.rc"
+ "$pkgname.systemd"
+ "$pkgname.service")
md5sums=('1d4ab05761f063b0751645d8f2b8f8e5'
- 'f8c0ecad9151a16347c133e043232d4a')
+ '00bfb5bd8a83a5b466c650ee5d8f86f3'
+ '60e0319b55b1ef9e13d9ac03dd98c8d4'
+ '65a9ed0b866f727184a87e4d480975bd'
+ 'b26771191e52905d8aea6333c26cb1c3')
build() {
cd $pkgname-v${pkgver//_/-}
@@ -20,8 +29,7 @@ build() {
}
package() {
- # setup arptables
- cd $pkgname-v${pkgver//_/-}
+ pushd $pkgname-v${pkgver//_/-}
make install \
DESTDIR="$pkgdir" \
PREFIX=/usr \
@@ -29,10 +37,18 @@ package() {
BINDIR=/usr/sbin \
MANDIR=/usr/share/man \
INITDIR=/etc/rc.d \
- SYSCONFIGDIR=/etc/arptables
-
- # install rc script
- install -D -m 0755 ../arptables.rc "$pkgdir/etc/rc.d/arptables"
+ SYSCONFIGDIR=/etc
+ popd
+ # install initscripts
+ install -Dm 755 $pkgname.rc "$pkgdir/etc/rc.d/$pkgname"
+ install -Dm 644 $pkgname.conf "$pkgdir/etc/conf.d/$pkgname"
+ # install systemd service
+ install -Dm 755 $pkgname.systemd \
+ "$pkgdir/usr/lib/systemd/scripts/$pkgname"
+ install -Dm 644 $pkgname.service \
+ "$pkgdir/usr/lib/systemd/system/$pkgname.service"
+ # default config file
+ install -Dm 644 /dev/null "$pkgdir/etc/$pkgname.conf"
}
# vim:set ts=2 sw=2 ft=sh et:
diff --git a/community/arptables/arptables.conf b/community/arptables/arptables.conf
new file mode 100644
index 000000000..8b5456788
--- /dev/null
+++ b/community/arptables/arptables.conf
@@ -0,0 +1,7 @@
+# Configuration file used to load/save configuration.
+CONFIG_FILE='/etc/arptables.conf'
+
+# Save configuration on stop/restart.
+#SAVE_ON_STOP=yes
+
+# vim:set ts=2 sw=2 ft=sh et:
diff --git a/community/arptables/arptables.install b/community/arptables/arptables.install
new file mode 100644
index 000000000..5f03b6e24
--- /dev/null
+++ b/community/arptables/arptables.install
@@ -0,0 +1,10 @@
+## arg 1: the new package version
+## arg 2: the old package version
+post_upgrade() {
+ [ $(vercmp "$2" '0.0.3_4-2') -gt 0 ] || cat <<EOF
+Config file have been moved from /etc/arptables/arptables to /etc/arptables.conf.
+You can revert to the previous location by editing /etc/conf.d/arptables.
+EOF
+}
+
+# vim:set ts=2 sw=2 ft=sh et:
diff --git a/community/arptables/arptables.rc b/community/arptables/arptables.rc
index dae90ac2a..a188c65c1 100644
--- a/community/arptables/arptables.rc
+++ b/community/arptables/arptables.rc
@@ -2,57 +2,33 @@
. /etc/rc.conf
. /etc/rc.d/functions
-
-[[ -x /usr/sbin/arptables ]] || exit 1
-[[ -x /usr/sbin/arptables-save ]] || exit 1
-[[ -x /usr/sbin/arptables-restore ]] || exit 1
-
-do_start() {
- stat_busy "Restore arptables rules"
- if [[ -r /etc/arptables/arptables ]]; then
- /usr/sbin/arptables-restore </etc/arptables/arptables
- (( $? == 0 )) && stat_done && add_daemon arptables && return
- fi
- stat_fail
-}
-
-do_stop() {
- stat_busy "Flushing arptables rules"
- /usr/sbin/arptables-restore </dev/null
- if (( $? == 0 )); then
- stat_done
- rm_daemon arptables
- else
- stat_fail
- fi
-}
-
-do_save() {
- stat_busy "Saving arptables rules"
- /usr/sbin/arptables-save >/etc/arptables/arptables
- (( $? == 0 )) && stat_done || stat_fail
-}
+. /etc/conf.d/${0##*/}
case "$1" in
start)
- do_start
- ;;
+ stat_busy 'Loading arptables rules'
+ arptables-restore < "$CONFIG_FILE" &&
+ add_daemon ${0##*/} && stat_done || stat_die
+ ;;
stop)
- do_stop
- ;;
+ [[ $SAVE_ON_STOP =~ [yY][eE][sS] ]] && $0 save
+ stat_busy 'Clearing arptables rules'
+ arptables-restore < /dev/null &&
+ rm_daemon ${0##*/} && stat_done || stat_die
+ ;;
restart)
- do_stop
- do_start
- ;;
+ $0 start
+ $0 stop
+ ;;
save)
- do_save
- ;;
- status)
- /usr/sbin/arptables-save
- ;;
+ stat_busy 'Saving arptables rules'
+ arptables-save > "$CONFIG_FILE" &&
+ stat_done || stat_die
+ ;;
*)
- echo "Usage $0 {start|stop|restart|save|status}" >&2
+ echo "usage: ${0##*/} {start|stop|restart|save}" >&2
exit 1
+ ;;
esac
# vim:set ts=2 sw=2 ft=sh et:
diff --git a/community/arptables/arptables.service b/community/arptables/arptables.service
new file mode 100644
index 000000000..4fc11f17d
--- /dev/null
+++ b/community/arptables/arptables.service
@@ -0,0 +1,11 @@
+[Unit]
+Description=ARP Tables
+
+[Service]
+Type=oneshot
+RemainAfterExit=yes
+ExecStart=/usr/lib/systemd/scripts/arptables start
+ExecStop=/usr/lib/systemd/scripts/arptables stop
+
+[Install]
+WantedBy=multi-user.target
diff --git a/community/arptables/arptables.systemd b/community/arptables/arptables.systemd
new file mode 100644
index 000000000..bc5acdbcf
--- /dev/null
+++ b/community/arptables/arptables.systemd
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+. /etc/conf.d/arptables
+
+case $1 in
+ start)
+ arptables-restore < "$CONFIG_FILE"
+ ;;
+ stop)
+ [[ $SAVE_ON_STOP =~ [yY][eE][sS] ]] && $0 save
+ arptables-restore < /dev/null
+ ;;
+ save)
+ arptables-save > "$CONFIG_FILE"
+ ;;
+ *)
+ echo "usage: ${0##*/} {start|stop|save}" >&2
+ exit 1
+ ;;
+esac
+
+# vim:set ts=2 sw=2 ft=sh et:
diff --git a/community/cgit/PKGBUILD b/community/cgit/PKGBUILD
index 93507ca60..b1479a41f 100644
--- a/community/cgit/PKGBUILD
+++ b/community/cgit/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 65084 2012-02-20 03:33:55Z spupykin $
+# $Id: PKGBUILD 71264 2012-05-26 07:35:52Z spupykin $
# Maintainer: Sergej Pupykin <pupykin.s+arch@gmail.com>
# Current Maintainer: Patrick Palka <patrick@parcs.ath.cx>
# Previous Maintainer: Loui Chang <louipc.ist at gmail com>
@@ -6,9 +6,9 @@
# Development: http://closure.ath.cx/aur-dev
pkgname=cgit
-pkgver=0.9.0.2
+pkgver=0.9.0.3
_gitver=1.7.4
-pkgrel=4
+pkgrel=1
pkgdesc="A web interface for git written in plain C"
arch=('i686' 'x86_64')
url="http://hjemli.net/git/cgit"
@@ -20,7 +20,7 @@ install=cgit.install
source=("http://hjemli.net/git/cgit/snapshot/$pkgname-$pkgver.tar.bz2"
"http://arch.p5n.pp.ru/~sergej/dl/2011/git-${_gitver}.tar.bz2"
"apache.example.conf")
-md5sums=('5b92b07e0107ff24a783adfb8c0cd1f2'
+md5sums=('3d5481bf8a507694108f0996b8bde235'
'fa24dc1ef0b663327ea0fe1981365b39'
'bd5696bea0654bfcf98f249b1a36737d')
diff --git a/community/ebtables/PKGBUILD b/community/ebtables/PKGBUILD
index f3400453c..ffc3b451b 100644
--- a/community/ebtables/PKGBUILD
+++ b/community/ebtables/PKGBUILD
@@ -1,48 +1,56 @@
-# $Id: PKGBUILD 60674 2011-12-16 19:18:54Z seblu $
-# Maintainer: Sebastien Luttringer <seblu+arch@seblu.net>
+# $Id: PKGBUILD 71322 2012-05-26 15:04:32Z seblu $
+# Maintainer: Sébastien Luttringer <seblu@aur.archlinux.org>
# Contributor: Michal Soltys <soltys@ziu.info>
pkgname=ebtables
pkgver=2.0.10_4
-pkgrel=1
+pkgrel=2
pkgdesc='Ethernet bridge filtering utilities'
arch=('i686' 'x86_64')
-backup=('etc/conf.d/ebtables')
url='http://ebtables.sourceforge.net/'
license=('GPL2')
+backup=("etc/$pkgname.conf" "etc/conf.d/$pkgname")
# ebtables segfault with --as-needed
options=('!buildflags')
-source=(
- "http://downloads.sourceforge.net/${pkgname}/${pkgname}-v${pkgver/_/-}.tar.gz"
- 'ebtables.rc'
- 'ebtables.conf'
- )
+install=$pkgname.install
+source=("http://downloads.sourceforge.net/${pkgname}/${pkgname}-v${pkgver/_/-}.tar.gz"
+ "$pkgname.conf"
+ "$pkgname.rc"
+ "$pkgname.systemd"
+ "$pkgname.service")
md5sums=('506742a3d44b9925955425a659c1a8d0'
- '368825c83a2b1180d2223e61b9f3bd07'
- '86fc3622e6fc0a7a7920c90ff576cc38')
+ 'c6f0838de4429af68d21b4d61f00db59'
+ 'd0e340f2cefe91b1569c0e87c2a1288f'
+ '5a49ea09af202cb438c8a1b15abf9147'
+ 'baf923443c3b16277e50d60d2e68f534')
build() {
- cd ${pkgname}-v${pkgver/_/-}
+ cd $pkgname-v${pkgver/_/-}
make CFLAGS='-Wunused -Wall -Werror -Wno-error=unused-but-set-variable'
}
package() {
- cd "${pkgname}-v${pkgver/_/-}"
+ pushd $pkgname-v${pkgver/_/-}
make install \
- DESTDIR="${pkgdir}" \
+ DESTDIR="$pkgdir" \
LIBDIR=/usr/lib \
MANDIR=/usr/share/man \
BINDIR=/usr/sbin \
INITDIR=/etc/rc.d \
- SYSCONFIGDIR=/etc/ebtables
-
+ SYSCONFIGDIR=/etc
+ popd
# rm package ebtables rc.d scripts
- rm "${pkgdir}/etc/rc.d/ebtables"
- rm "${pkgdir}/etc/ebtables/ebtables-config"
-
- # install custom ebtables rc.d scripts
- install -D -m 0755 "${srcdir}/$pkgname.rc" "${pkgdir}/etc/rc.d/$pkgname"
- install -D -m 0644 "${srcdir}/$pkgname.conf" "${pkgdir}/etc/conf.d/$pkgname"
+ rm "$pkgdir/etc/ebtables-config"
+ # install initscripts
+ install -Dm 755 $pkgname.rc "$pkgdir/etc/rc.d/$pkgname"
+ install -Dm 644 $pkgname.conf "$pkgdir/etc/conf.d/$pkgname"
+ # install systemd service
+ install -Dm 755 $pkgname.systemd \
+ "$pkgdir/usr/lib/systemd/scripts/$pkgname"
+ install -Dm 644 $pkgname.service \
+ "$pkgdir/usr/lib/systemd/system/$pkgname.service"
+ # default config file
+ install -Dm 644 /dev/null "$pkgdir/etc/$pkgname.conf"
}
# vim:set ts=2 sw=2 ft=sh et:
diff --git a/community/ebtables/ebtables.conf b/community/ebtables/ebtables.conf
index 0005444e7..386f94249 100644
--- a/community/ebtables/ebtables.conf
+++ b/community/ebtables/ebtables.conf
@@ -1,37 +1,7 @@
-# Save (and possibly restore) in text format.
-# Value: yes|no, default: yes
-# Save the firewall rules in text format to /etc/conf.d/ebtables
-# If EBTABLES_BINARY_FORMAT="no" then restoring the firewall rules
-# is done using this text format.
-EBTABLES_TEXT_FORMAT="yes"
+# Configuration file used to load/save configuration.
+CONFIG_FILE='/etc/ebtables.conf'
-# Save (and restore) in binary format.
-# Value: yes|no, default: yes
-# Save (and restore) the firewall rules in binary format to (and from)
-# /etc/ebtables/ebtables.<chain>. Enabling this option will make
-# firewall initialisation a lot faster.
-EBTABLES_BINARY_FORMAT="yes"
+# Save configuration on stop/restart.
+#SAVE_ON_STOP=yes
-# Unload modules on restart and stop
-# Value: yes|no, default: yes
-# This option has to be 'yes' to get to a sane state for a firewall
-# restart or stop. Only set to 'no' if there are problems unloading netfilter
-# modules.
-EBTABLES_MODULES_UNLOAD="yes"
-
-# Save current firewall rules on stop.
-# Value: yes|no, default: no
-# Saves all firewall rules if firewall gets stopped
-# (e.g. on system shutdown).
-EBTABLES_SAVE_ON_STOP="no"
-
-# Save current firewall rules on restart.
-# Value: yes|no, default: no
-# Saves all firewall rules if firewall gets restarted.
-EBTABLES_SAVE_ON_RESTART="no"
-
-# Save (and restore) rule counters.
-# Value: yes|no, default: no
-# Save rule counters when saving a kernel table to a file. If the
-# rule counters were saved, they will be restored when restoring the table.
-EBTABLES_SAVE_COUNTER="no"
+# vim:set ts=2 sw=2 ft=sh et:
diff --git a/community/ebtables/ebtables.install b/community/ebtables/ebtables.install
new file mode 100644
index 000000000..7dd6921ed
--- /dev/null
+++ b/community/ebtables/ebtables.install
@@ -0,0 +1,9 @@
+## arg 1: the new package version
+## arg 2: the old package version
+post_upgrade() {
+ [ $(vercmp "$2" '2.0.10_4-1') -gt 0 ] || cat <<EOF
+Config file have been moved to /etc/ebtables.conf and only support text format.
+EOF
+}
+
+# vim:set ts=2 sw=2 ft=sh et:
diff --git a/community/ebtables/ebtables.rc b/community/ebtables/ebtables.rc
index 3a889b914..a845449fe 100644
--- a/community/ebtables/ebtables.rc
+++ b/community/ebtables/ebtables.rc
@@ -1,128 +1,31 @@
#!/bin/bash
-# Credits to:
-# Sebastien Luttringer <seblu+arch@seblu.net>
-# Bart De Schuymer <bdschuym@pandora.be>
-# Rok Papez <rok.papez@arnes.si>
-# Dag Wieers <dag@wieers.com>
-
. /etc/rc.conf
. /etc/rc.d/functions
-
-#default configuration:
-EBTABLES_TEXT_FORMAT="yes"
-EBTABLES_BINARY_FORMAT="yes"
-EBTABLES_MODULES_UNLOAD="yes"
-EBTABLES_SAVE_ON_STOP="no"
-EBTABLES_SAVE_ON_RESTART="no"
-EBTABLES_SAVE_COUNTER="no"
-
-[[ -r "/etc/conf.d/ebtables" ]] && . "/etc/conf.d/ebtables"
-
-RETVAL=0
-
-start() {
- stat_busy "Starting ebtables"
- ! ck_daemon ebtables && stat_done && RETVAL=0 && return
- if [[ "$EBTABLES_BINARY_FORMAT" = yes ]]; then
- for table in $(ls /etc/ebtables/ebtables.* 2>/dev/null | sed -e 's/.*ebtables\.//' -e '/save/d' ); do
- /usr/sbin/ebtables -t ${table} --atomic-file /etc/ebtables/ebtables.${table} --atomic-commit || RETVAL=1
- done
- elif [[ "$EBTABLES_TEXT_FORMAT" = "yes" ]]; then
- [[ ! -r /etc/ebtables/ebtables ]] && :>/etc/ebtables/ebtables
- /usr/sbin/ebtables-restore </etc/ebtables/ebtables || RETVAL=1
- else
- RETVAL=1
- fi
-
- if (( RETVAL == 0 )); then
- stat_done
- add_daemon ebtables
- else
- stat_fail
- fi
-}
-
-stop() {
- stat_busy "Stopping ebtables"
- ck_daemon ebtables && stat_done && RETVAL=0 && return
- for table in $(grep '^ebtable_' /proc/modules | sed -e 's/ebtable_\([^ ]*\).*/\1/'); do
- /usr/sbin/ebtables -t $table --init-table || RETVAL=1
- done
-
- if [[ "$EBTABLES_MODULES_UNLOAD" = yes ]]; then
- for mod in $(grep -E '^(ebt|ebtable)_' /proc/modules | cut -f1 -d' ') ebtables; do
- /sbin/rmmod $mod 2> /dev/null
- done
- fi
-
- if (( RETVAL == 0 )); then
- rm_daemon ebtables
- stat_done
- else
- stat_fail
- fi
-}
-
-restart() {
- stop
- sleep 1
- start
-}
-
-save() {
- stat_busy "Saving ebtables"
- if [[ "$EBTABLES_TEXT_FORMAT" = yes ]]; then
- if [[ -r /etc/ebtables/ebtables ]]; then
- mv -f /etc/ebtables/ebtables /etc/ebtables/ebtables.save
- fi
- /usr/sbin/ebtables-save >/etc/ebtables/ebtables || RETVAL=1
- fi
- if [[ "$EBTABLES_BINARY_FORMAT" = yes ]]; then
- rm -f /etc/ebtables/ebtables.*.save
- for oldtable in $(ls /etc/ebtables/ebtables.* 2>/dev/null | grep -vF 'ebtables.save'); do
- mv -f $oldtable $oldtable.save
- done
- for table in $(grep '^ebtable_' /proc/modules | sed -e 's/ebtable_\([^ ]*\).*/\1/'); do
- :> /etc/ebtables/ebtables.$table
- /usr/sbin/ebtables -t $table --atomic-file /etc/ebtables/ebtables.$table --atomic-save || RETVAL=1
- if [[ "$EBTABLES_SAVE_COUNTER" = no ]]; then
- /usr/sbin/ebtables -t $table --atomic-file /etc/ebtables/ebtables.$table -Z || RETVAL=1
- fi
- done
- fi
-
- (( RETVAL == 0 )) && stat_done || stat_fail
-}
+. /etc/conf.d/${0##*/}
case "$1" in
start)
- start
- ;;
+ stat_busy 'Loading ebtables rules'
+ ebtables-restore < "$CONFIG_FILE" &&
+ add_daemon ${0##*/} && stat_done || stat_die
+ ;;
stop)
- [[ "$EBTABLES_SAVE_ON_STOP" = yes ]] && save
- stop
- ;;
- restart|reload)
- [[ "$EBTABLES_SAVE_ON_RESTART" = yes ]] && save
- restart
- ;;
- condrestart)
- ! ck_daemon ebtables && restart
- RETVAL=$?
- ;;
+ [[ $SAVE_ON_STOP =~ [yY][eE][sS] ]] && $0 save
+ status 'Clearing ebtables rules' ebtables -F && rm_daemon ${0##*/} || exit 1
+ ;;
+ restart)
+ $0 stop
+ $0 start
+ ;;
save)
- save
- ;;
- status)
- /usr/sbin/ebtables-save
- RETVAL=$?
- ;;
+ stat_busy 'Saving ebtables rules'
+ ebtables-save > "$CONFIG_FILE" && stat_done || stat_die
+ ;;
*)
- echo "Usage $0 {start|stop|restart|condrestart|save|status}"
- RETVAL=1
+ echo "usage: ${0##*/} {start|stop|restart|save}" >&2
+ exit 1
+ ;;
esac
-exit $RETVAL
-
-# vim:set ts=2 sw=2 ft=sh noet:
+# vim:set ts=2 sw=2 ft=sh et:
diff --git a/community/ebtables/ebtables.service b/community/ebtables/ebtables.service
new file mode 100644
index 000000000..25e6b76cc
--- /dev/null
+++ b/community/ebtables/ebtables.service
@@ -0,0 +1,11 @@
+[Unit]
+Description=Ethernet bridge table
+
+[Service]
+Type=oneshot
+RemainAfterExit=yes
+ExecStart=/usr/lib/systemd/scripts/ebtables start
+ExecStop=/usr/lib/systemd/scripts/ebtables stop
+
+[Install]
+WantedBy=multi-user.target
diff --git a/community/ebtables/ebtables.systemd b/community/ebtables/ebtables.systemd
new file mode 100644
index 000000000..4c51e9b6f
--- /dev/null
+++ b/community/ebtables/ebtables.systemd
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+. /etc/conf.d/ebtables
+
+case $1 in
+ start)
+ ebtables-restore < "$CONFIG_FILE"
+ ;;
+ stop)
+ [[ $SAVE_ON_STOP =~ [yY][eE][sS] ]] && $0 save
+ ebtables -F
+ ;;
+ save)
+ ebtables-save > "$CONFIG_FILE"
+ ;;
+ *)
+ echo "usage: ${0##*/} {start|stop|save}" >&2
+ exit 1
+ ;;
+esac
+
+# vim:set ts=2 sw=2 ft=sh et:
diff --git a/community/gambas2/PKGBUILD b/community/gambas2/PKGBUILD
index 53693e857..7591abe02 100644
--- a/community/gambas2/PKGBUILD
+++ b/community/gambas2/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 70013 2012-04-28 09:24:06Z allan $
+# $Id: PKGBUILD 71272 2012-05-26 07:54:42Z pschmitz $
# Maintainer : Laurent Carlier <lordheavym@gmail.com>
# Contributor: Biru Ionut <ionut@archlinux.ro>
# Contributor: Andrea Scarpino <andrea@archlinux.org>
@@ -19,8 +19,8 @@ pkgname=('gambas2-meta' 'gambas2-runtime' 'gambas2-devel' 'gambas2-ide' 'gambas2
'gambas2-gb-qt-kde' 'gambas2-gb-qt-kde-html' 'gambas2-gb-report' 'gambas2-gb-sdl'
'gambas2-gb-sdl-sound' 'gambas2-gb-settings' 'gambas2-gb-v4l' 'gambas2-gb-vb'
'gambas2-gb-web' 'gambas2-gb-xml' 'gambas2-gb-xml-rpc' 'gambas2-gb-xml-xslt')
-pkgver=2.23.1
-pkgrel=10
+pkgver=2.24.0
+pkgrel=1
pkgdesc="A free development environment based on a Basic interpreter."
arch=('i686' 'x86_64')
url="http://gambas.sourceforge.net"
@@ -34,13 +34,11 @@ groups=('gambas2')
replaces=('gambas2')
conflicts=('gambas2')
source=(http://downloads.sourceforge.net/gambas/$pkgbase-$pkgver.tar.bz2
- 'fix-gbi-gba-path.patch' 'db.firebird.gcc-4.6.0-fix.patch'
- 'poppler-0.18.patch'
- 'gambas2-script.install' 'gambas2-runtime.install')
-md5sums=('ff8d2c1f310222c150b114e7ce247dfd'
+ 'fix-gbi-gba-path.patch'
+ 'gambas2-script.install' 'gambas2-runtime.install'
+ 'poppler-0.20.patch')
+md5sums=('b59072b6f57b681d586cc84c02333690'
'9dda03a1bbfb7e7ba8b6a4ae91b6752b'
- 'ac9703b390502ed3242c8d34485c9236'
- 'a551b4b216bbdb3489f3c264bf73ee66'
'870ff5b4b33cd75aa9c290539e6fdd5d'
'ab5667175c4945282d2f40a35d0e9e5b')
_gbfiles="${srcdir}/$pkgbase-$pkgver/main/gbc"
@@ -66,12 +64,14 @@ _buildgbcomp() {
build() {
cd "${srcdir}/$pkgbase-$pkgver"
- ## workaround to allow package splitting
msg "Applying patches ..."
- patch -Np1 -i "${srcdir}/fix-gbi-gba-path.patch"
- # merged upstream
- patch -Np3 -i "${srcdir}/db.firebird.gcc-4.6.0-fix.patch"
- patch -Np2 -i "${srcdir}/poppler-0.18.patch"
+ # workaround to allow package splitting
+ patch -Np1 -i ../fix-gbi-gba-path.patch
+ # fix building with poppler-0.20.x (merged upstream)
+ cd gb.pdf
+ patch -Np0 -i ../../poppler-0.20.patch
+ cd ..
+
./reconf-all
##
@@ -947,3 +947,8 @@ package_gambas2-gb-xml-xslt() {
rm -rf ${pkgdir}/usr/bin
##
}
+md5sums=('b59072b6f57b681d586cc84c02333690'
+ '9dda03a1bbfb7e7ba8b6a4ae91b6752b'
+ '870ff5b4b33cd75aa9c290539e6fdd5d'
+ 'ab5667175c4945282d2f40a35d0e9e5b'
+ '5eb70afe712c0f8667a700df4d9a6735')
diff --git a/community/gambas2/poppler-0.20.patch b/community/gambas2/poppler-0.20.patch
new file mode 100644
index 000000000..a73d42a7f
--- /dev/null
+++ b/community/gambas2/poppler-0.20.patch
@@ -0,0 +1,100 @@
+Index: src/CPdfDocument.cpp
+===================================================================
+--- src/CPdfDocument.cpp (révision 4732)
++++ src/CPdfDocument.cpp (copie de travail)
+@@ -407,7 +407,11 @@
+ white[0] = 0xFF; white[1] = 0xFF; white[2] = 0xFF;
+ THIS->dev=new SplashOutputDev(splashModeRGB8, 3, gFalse, white);
+
++ #if POPPLER_VERSION_0_20
++ THIS->dev->startDoc(THIS->doc);
++ #else
+ THIS->dev->startDoc(THIS->doc->getXRef ());
++ #endif
+
+ outline=THIS->doc->getOutline();
+ if (outline) THIS->index=outline->getItems();
+@@ -833,13 +837,22 @@
+
+ if ( (w<0) || (h<0) ) return NULL;
+
++ #if POPPLER_VERSION_0_20
+ THIS->page->displaySlice(THIS->dev,72.0*scale,72.0*scale,
+ rotation,
+ gFalse,
+ gTrue,
+ x,y,w,h,
++ gFalse);
++ #else
++ THIS->page->displaySlice(THIS->dev,72.0*scale,72.0*scale,
++ rotation,
+ gFalse,
++ gTrue,
++ x,y,w,h,
++ gFalse,
+ THIS->doc->getCatalog ());
++ #endif
+
+ map=THIS->dev->getBitmap();
+
+@@ -929,9 +942,14 @@
+ w = VARGOPT(W, (int32_t)THIS->page->getMediaWidth());
+ h = VARGOPT(H, (int32_t)THIS->page->getMediaHeight());
+
++ #if POPPLER_VERSION_0_20
++ dev = new TextOutputDev (NULL, gTrue, 0, gFalse, gFalse);
++ gfx = THIS->page->createGfx(dev,72.0,72.0,0,gFalse,gTrue,-1, -1, -1, -1, gFalse, NULL, NULL);
++ #else
+ dev = new TextOutputDev (NULL, gTrue, gFalse, gFalse);
+ gfx = THIS->page->createGfx(dev,72.0,72.0,0,gFalse,gTrue,-1, -1, -1, -1, \
+ gFalse,THIS->doc->getCatalog (),NULL, NULL, NULL, NULL);
++ #endif
+
+ THIS->page->display(gfx);
+ dev->endPage();
+@@ -960,7 +978,9 @@
+
+ void aux_fill_links(void *_object)
+ {
+- #if POPPLER_VERSION_0_17
++ #if POPPLER_VERSION_0_20
++ THIS->links = new Links (THIS->page->getAnnots ());
++ #elif POPPLER_VERSION_0_17
+ THIS->links = new Links (THIS->page->getAnnots (THIS->doc->getCatalog()));
+ #else
+ Object obj;
+@@ -1200,12 +1220,21 @@
+
+ if (!MISSING(Sensitive)) sensitive=VARG(Sensitive);
+
++ #if POPPLER_VERSION_0_20
++ textdev = new TextOutputDev (NULL, true, 0, false, false);
++ THIS->page->display (textdev, 72, 72, 0, false, false, false);
++ #else
+ textdev = new TextOutputDev (NULL, true, false, false);
+ THIS->page->display (textdev, 72, 72, 0, false, false, false, THIS->doc->getCatalog());
++ #endif
+
+ if (THIS->Found) { GB.FreeArray(POINTER(&THIS->Found)); THIS->Found=NULL; }
+
++ #if POPPLER_VERSION_0_20
++ while (textdev->findText (block,nlen,gFalse,gTrue,gTrue,gFalse,sensitive,gFalse,gFalse,&x0,&y0,&x1,&y1))
++ #else
+ while (textdev->findText (block,nlen,gFalse,gTrue,gTrue,gFalse,sensitive,gFalse,&x0,&y0,&x1,&y1))
++ #endif
+ {
+ if (!THIS->Found) {
+ GB.NewArray(POINTER(&THIS->Found),sizeof(FoundRect),1);
+Index: configure.ac
+===================================================================
+--- configure.ac (révision 4732)
++++ configure.ac (copie de travail)
+@@ -25,6 +25,8 @@
+ AC_DEFINE_UNQUOTED(POPPLER_VERSION_0_11_3, $((1-$?)), Poppler version >= 0.11.3)
+ pkg-config --atleast-version=0.17.0 poppler
+ AC_DEFINE_UNQUOTED(POPPLER_VERSION_0_17, $((1-$?)), Poppler version >= 0.17)
++ pkg-config --atleast-version=0.20.0 poppler
++ AC_DEFINE_UNQUOTED(POPPLER_VERSION_0_20, $((1-$?)), Poppler version >= 0.20)
+ fi
+
+ AC_OUTPUT( \
diff --git a/community/gambas3/PKGBUILD b/community/gambas3/PKGBUILD
index be9037be9..cf13c1a9b 100644
--- a/community/gambas3/PKGBUILD
+++ b/community/gambas3/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 70015 2012-04-28 09:24:08Z allan $
+# $Id: PKGBUILD 71274 2012-05-26 07:54:52Z pschmitz $
# Maintainer: Laurent Carlier <lordheavym@gmail.com>
pkgbase=gambas3
@@ -13,7 +13,7 @@ pkgname=('gambas3-runtime' 'gambas3-devel' 'gambas3-ide' 'gambas3-script' 'gamba
'gambas3-gb-report' 'gambas3-gb-sdl' 'gambas3-gb-sdl-sound' 'gambas3-gb-settings' 'gambas3-gb-signal'
'gambas3-gb-v4l' 'gambas3-gb-vb' 'gambas3-gb-xml' 'gambas3-gb-xml-rpc' 'gambas3-gb-xml-xslt' 'gambas3-gb-web')
pkgver=3.1.1
-pkgrel=2
+pkgrel=3
pkgdesc="A free development environment based on a Basic interpreter."
arch=('i686' 'x86_64')
url="http://gambas.sourceforge.net/"
@@ -27,14 +27,21 @@ makedepends=('intltool' 'mysql' 'postgresql' 'libffi' 'bzip2' 'glib2' 'v4l-utils
'gsl')
options=('!emptydirs' '!makeflags')
source=("http://downloads.sourceforge.net/gambas/${pkgbase}-${pkgver}.tar.bz2"
- 'gambas3-script.install' 'gambas3-runtime.install')
+ 'gambas3-script.install' 'gambas3-runtime.install'
+ 'poppler-0-20.patch')
md5sums=('bdf387f435d7aeedb7efa488ea1a5d62'
'b284be39d147ec799f1116a6abc068b4'
- 'b5cc403990f31b8ea1c5cf37366d3d29')
+ 'b5cc403990f31b8ea1c5cf37366d3d29'
+ '39d2ae1e2096a29df7857fce083eafaf')
build() {
cd ${srcdir}/${pkgbase}-${pkgver}
+ # fix building with poppler-0.20.x (merged upstream)
+ cd gb.pdf
+ patch -Np1 -i ../../poppler-0-20.patch
+ cd ..
+
./reconf-all
./configure --prefix=/usr -C
diff --git a/community/gambas3/poppler-0-20.patch b/community/gambas3/poppler-0-20.patch
new file mode 100644
index 000000000..3b0e4612a
--- /dev/null
+++ b/community/gambas3/poppler-0-20.patch
@@ -0,0 +1,106 @@
+diff -ur gb.pdf/configure.ac gb.pdf.fixed/configure.ac
+--- gb.pdf/configure.ac 2012-05-14 08:55:02.448921378 +0200
++++ gb.pdf.fixed/configure.ac 2012-05-14 08:52:19.098596499 +0200
+@@ -24,6 +24,8 @@
+ AC_DEFINE_UNQUOTED(POPPLER_VERSION_0_11_3, $((1-$?)), Poppler version >= 0.11.3)
+ pkg-config --atleast-version=0.17.0 poppler
+ AC_DEFINE_UNQUOTED(POPPLER_VERSION_0_17, $((1-$?)), Poppler version >= 0.17)
++ pkg-config --atleast-version=0.20.0 poppler
++ AC_DEFINE_UNQUOTED(POPPLER_VERSION_0_20, $((1-$?)), Poppler version >= 0.20)
+ fi
+
+ AC_OUTPUT( \
+diff -ur gb.pdf/src/CPdfDocument.cpp gb.pdf.fixed/src/CPdfDocument.cpp
+--- gb.pdf/src/CPdfDocument.cpp 2012-05-14 08:55:02.388922483 +0200
++++ gb.pdf.fixed/src/CPdfDocument.cpp 2012-05-15 09:25:45.168457227 +0200
+@@ -449,9 +449,13 @@
+
+ white[0] = 0xFF; white[1] = 0xFF; white[2] = 0xFF;
+ THIS->dev=new SplashOutputDev(splashModeRGB8, 3, gFalse, white);
+-
+- THIS->dev->startDoc(THIS->doc->getXRef ());
+
++ #if POPPLER_VERSION_0_20
++ THIS->dev->startDoc(THIS->doc);
++ #else
++ THIS->dev->startDoc(THIS->doc->getXRef ());
++ #endif
++
+ outline=THIS->doc->getOutline();
+ if (outline) THIS->index=outline->getItems();
+
+@@ -875,6 +879,14 @@
+
+ if ( (w<0) || (h<0) ) return NULL;
+
++ #if POPPLER_VERSION_0_20
++ THIS->page->displaySlice(THIS->dev,72.0*scale,72.0*scale,
++ rotation,
++ gFalse,
++ gTrue,
++ x,y,w,h,
++ gFalse);
++ #else
+ THIS->page->displaySlice(THIS->dev,72.0*scale,72.0*scale,
+ rotation,
+ gFalse,
+@@ -882,7 +894,8 @@
+ x,y,w,h,
+ gFalse,
+ THIS->doc->getCatalog ());
+-
++ #endif
++
+ map=THIS->dev->getBitmap();
+
+ data=(uint32_t*)map->getDataPtr();
+@@ -940,9 +953,14 @@
+ w = VARGOPT(W, (int32_t)THIS->page->getMediaWidth());
+ h = VARGOPT(H, (int32_t)THIS->page->getMediaHeight());
+
++ #if POPPLER_VERSION_0_20
++ dev = new TextOutputDev (NULL, gTrue, 0, gFalse, gFalse);
++ gfx = THIS->page->createGfx(dev,72.0,72.0,0,gFalse,gTrue,-1, -1, -1, -1, gFalse, NULL, NULL);
++ #else
+ dev = new TextOutputDev (NULL, gTrue, gFalse, gFalse);
+ gfx = THIS->page->createGfx(dev,72.0,72.0,0,gFalse,gTrue,-1, -1, -1, -1, gFalse,THIS->doc->getCatalog (),NULL, NULL, NULL, NULL);
+-
++ #endif
++
+ THIS->page->display(gfx);
+ dev->endPage();
+
+@@ -970,7 +988,9 @@
+
+ void aux_fill_links(void *_object)
+ {
+- #if POPPLER_VERSION_0_17
++ #if POPPLER_VERSION_0_20
++ THIS->links = new Links (THIS->page->getAnnots ());
++ #elif POPPLER_VERSION_0_17
+ THIS->links = new Links (THIS->page->getAnnots (THIS->doc->getCatalog()));
+ #else
+ Object obj;
+@@ -1152,13 +1172,22 @@
+
+ if (!MISSING(Sensitive)) sensitive=VARG(Sensitive);
+
++ #if POPPLER_VERSION_0_20
++ textdev = new TextOutputDev (NULL, true, 0, false, false);
++ THIS->page->display (textdev, 72, 72, 0, false, false, false);
++ #else
+ textdev = new TextOutputDev (NULL, true, false, false);
+ THIS->page->display (textdev, 72, 72, 0, false, false, false, THIS->doc->getCatalog());
++ #endif
+
+ if (THIS->Found) { GB.FreeArray(POINTER(&THIS->Found)); THIS->Found=NULL; }
+
+ count = 0;
++ #if POPPLER_VERSION_0_20
++ while (textdev->findText (block,nlen,gFalse,gTrue,gTrue,gFalse,sensitive,gFalse,gFalse,&x0,&y0,&x1,&y1))
++ #else
+ while (textdev->findText (block,nlen,gFalse,gTrue,gTrue,gFalse,sensitive,gFalse,&x0,&y0,&x1,&y1))
++ #endif
+ {
+ if (!THIS->Found)
+ GB.NewArray(POINTER(&THIS->Found),sizeof(CPDFFIND),1);
diff --git a/community/ipset/PKGBUILD b/community/ipset/PKGBUILD
index 76c732531..9a7ebc1e5 100644
--- a/community/ipset/PKGBUILD
+++ b/community/ipset/PKGBUILD
@@ -1,15 +1,15 @@
-# $Id: PKGBUILD 70556 2012-05-11 12:51:57Z seblu $
+# $Id: PKGBUILD 71313 2012-05-26 14:56:36Z seblu $
# Maintainer: Sébastien Luttringer <seblu@aur.archlinux.org>
pkgname=ipset
pkgver=6.12.1
-pkgrel=1
+pkgrel=2
pkgdesc='Administration tool for IP sets'
arch=('i686' 'x86_64')
url='http://ipset.netfilter.org'
license=('GPL2')
depends=('libmnl')
-backup=('etc/ipset.conf' "etc/conf.d/$pkgname")
+backup=("etc/$pkgname.conf" "etc/conf.d/$pkgname")
options=('!libtool')
source=("http://ipset.netfilter.org/$pkgname-$pkgver.tar.bz2"
"$pkgname.conf"
@@ -17,10 +17,10 @@ source=("http://ipset.netfilter.org/$pkgname-$pkgver.tar.bz2"
"$pkgname.systemd"
"$pkgname.service")
md5sums=('80df500a4d93cb14e1373ae290716cda'
- '61963bda45c002fb37977e58bb5b829c'
- '888bf1eadffcc076b9e97de02e2147c8'
- 'c5f38e5f3027066c1491a563e734796e'
- 'b9ff3bd7b959cb1b97b8c492b52b8377')
+ '3e606a2823a700b4e9c5f17511a6f6a5'
+ 'de89b054d967036e08b13bc6a7235286'
+ 'dfc3105b89ed41fc4a1feb4f4f13f2a3'
+ 'b032241b96b5802975fe4321cc511c6b')
build() {
cd $pkgname-$pkgver
@@ -29,13 +29,13 @@ build() {
}
package() {
- cd $pkgname-$pkgver
+ pushd $pkgname-$pkgver
make DESTDIR="$pkgdir" install
# install doc
install -dm755 "$pkgdir/usr/share/doc/$pkgname"
install -m644 README UPGRADE ChangeLog "$pkgdir/usr/share/doc/$pkgname"
+ popd
# install initscripts
- cd ..
install -Dm 755 $pkgname.rc "$pkgdir/etc/rc.d/$pkgname"
install -Dm 644 $pkgname.conf "$pkgdir/etc/conf.d/$pkgname"
# install systemd service
diff --git a/community/ipset/ipset.conf b/community/ipset/ipset.conf
index 686931f4c..d5d3cb699 100644
--- a/community/ipset/ipset.conf
+++ b/community/ipset/ipset.conf
@@ -1,3 +1,7 @@
-# vim:set ts=2 sw=2 ft=sh et:
+# Configuration file used to load/save configuration.
+CONFIG_FILE='/etc/ipset.conf'
+
+# Save configuration on stop/restart.
+#SAVE_ON_STOP=yes
-IPSET_CONF='/etc/ipset.conf'
+# vim:set ts=2 sw=2 ft=sh et:
diff --git a/community/ipset/ipset.rc b/community/ipset/ipset.rc
index 1d5f7df8b..517eff1ea 100644
--- a/community/ipset/ipset.rc
+++ b/community/ipset/ipset.rc
@@ -2,38 +2,32 @@
. /etc/rc.conf
. /etc/rc.d/functions
-. /etc/conf.d/ipset
+. /etc/conf.d/${0##*/}
case "$1" in
start)
- stat_busy 'Loading IP Sets'
- if [[ -f $IPSET_CONF ]] && ipset restore < "$IPSET_CONF"; then
- add_daemon ipset
- stat_done
- else
- stat_fail
- fi
+ stat_busy 'Loading IP sets'
+ ipset restore < "$CONFIG_FILE" && add_daemon ${0##*/} && stat_done || stat_die
;;
stop)
- status 'Clearing IP Sets' ipset destroy
- rm_daemon ipset
+ [[ $SAVE_ON_STOP =~ [yY][eE][sS] ]] && $0 save
+ stat_busy 'Clearing IP sets'
+ ipset destroy &&
+ rm_daemon ${0##*/} && stat_done || stat_die
;;
restart)
$0 stop
- sleep 1
$0 start
;;
save)
- stat_busy 'Saving IP Sets'
- if ipset save > "$IPSET_CONF" 2>/dev/null; then
- stat_done
- else
- stat_fail
- fi
+ stat_busy 'Saving IP sets'
+ ipset save > "$CONFIG_FILE" &&
+ stat_done || stat_die
;;
*)
- echo "usage: ${0##*/} {start|stop|restart|save}"
+ echo "usage: ${0##*/} {start|stop|restart|save}" >&2
+ exit 1
+ ;;
esac
-exit 0
# vim:set ts=2 sw=2 ft=sh et:
diff --git a/community/ipset/ipset.service b/community/ipset/ipset.service
index 0e0dd4ff7..8c4889d3c 100644
--- a/community/ipset/ipset.service
+++ b/community/ipset/ipset.service
@@ -1,12 +1,12 @@
[Unit]
Description=IP Sets
+Before=iptables.service
[Service]
Type=oneshot
-ExecStart=/usr/lib/systemd/scripts/ipset start
-ExecStop=/usr/sbin/ipset destroy
RemainAfterExit=yes
+ExecStart=/usr/lib/systemd/scripts/ipset start
+ExecStop=/usr/lib/systemd/scripts/ipset stop
[Install]
WantedBy=multi-user.target
-Before=iptables.service
diff --git a/community/ipset/ipset.systemd b/community/ipset/ipset.systemd
index 36df5124a..92397f3a7 100644
--- a/community/ipset/ipset.systemd
+++ b/community/ipset/ipset.systemd
@@ -2,7 +2,21 @@
. /etc/conf.d/ipset
-[[ -f $IPSET_CONF ]] || exit 1
-ipset restore < "$IPSET_CONF"
+case $1 in
+ start)
+ ipset restore < "$CONFIG_FILE"
+ ;;
+ stop)
+ [[ $SAVE_ON_STOP =~ [yY][eE][sS] ]] && $0 save
+ ipset destroy
+ ;;
+ save)
+ ipset save > "$CONFIG_FILE"
+ ;;
+ *)
+ echo "usage: ${0##*/} {start|stop|save}" >&2
+ exit 1
+ ;;
+esac
# vim:set ts=2 sw=2 ft=sh et:
diff --git a/community/ipvsadm/PKGBUILD b/community/ipvsadm/PKGBUILD
index a8126aca1..42132b7b6 100644
--- a/community/ipvsadm/PKGBUILD
+++ b/community/ipvsadm/PKGBUILD
@@ -1,47 +1,56 @@
-# $Id: PKGBUILD 69082 2012-04-09 02:20:59Z seblu $
+# $Id: PKGBUILD 71320 2012-05-26 15:01:34Z seblu $
# Maintainer: Sébastien Luttringer <seblu@aur.archlinux.org>
# Contributor: Judd Vinet <jvinet@zeroflux.org>
pkgname=ipvsadm
pkgver=1.26
-pkgrel=4
+pkgrel=5
pkgdesc='The IP Virtual Server administration utility'
arch=('i686' 'x86_64')
url='http://www.linuxvirtualserver.org/software/ipvs.html'
license=('GPL2')
depends=('libnl1' 'popt')
-backup=('etc/conf.d/ipvsadm')
+backup=("etc/$pkgname.conf" "etc/conf.d/$pkgname")
+options=('!makeflags')
+install=$pkgname.install
source=("http://www.linuxvirtualserver.org/software/kernel-2.6/$pkgname-$pkgver.tar.gz"
- 'ipvsadm.rc'
- 'ipvsadm.conf'
- 'ipvsadm.rules'
+ "$pkgname.conf"
+ "$pkgname.rc"
+ "$pkgname.systemd"
+ "$pkgname.service"
'01-fix-not-showing-all-server.patch')
md5sums=('eac3ba3f62cd4dea2da353aeddd353a8'
- '89b15096bb243dc694b6c5d4200561fd'
- 'cd358130967a9cc0d31fc61282df43e7'
- 'cd6649c647e495d4d6f981542ce5a93b'
+ 'b6cb7724aa6c61c3a9cdd40e8eaa973e'
+ 'f2f4a7c6d57c5301c5f12f9b323fdea8'
+ 'df28308873b437eeb55657f6aa438ecd'
+ 'dc87684064f85b64c1e79c1eac336303'
'e9fb77d2fbe2d3f41d60257316338543')
build() {
cd $pkgname-$pkgver
patch -p1 -i ../01-fix-not-showing-all-server.patch
- make INCLUDE="-I/usr/src/linux-$(uname -r)/include -I.. -I."
+ make #INCLUDE="-I/usr/src/linux-$(uname -r)/include -I.. -I."
}
package() {
- cd $pkgname-$pkgver
+ pushd $pkgname-$pkgver
make \
BUILD_ROOT="$pkgdir" \
MANDIR=usr/share/man \
SBIN="$pkgdir/usr/sbin" \
INIT="$pkgdir/etc/rc.d" \
install
- cd "$srcdir"
- # add initscripts
- install -D -m 755 $pkgname.rc "$pkgdir/etc/rc.d/$pkgname"
- install -D -m 644 $pkgname.conf "$pkgdir/etc/conf.d/$pkgname"
- # add ipvsadm rules
- install -D -m 644 $pkgname.rules "$pkgdir/etc/$pkgname.rules"
+ popd
+ # install initscripts
+ install -Dm 755 $pkgname.rc "$pkgdir/etc/rc.d/$pkgname"
+ install -Dm 644 $pkgname.conf "$pkgdir/etc/conf.d/$pkgname"
+ # install systemd service
+ install -Dm 755 $pkgname.systemd \
+ "$pkgdir/usr/lib/systemd/scripts/$pkgname"
+ install -Dm 644 $pkgname.service \
+ "$pkgdir/usr/lib/systemd/system/$pkgname.service"
+ # default config file
+ install -Dm 644 /dev/null "$pkgdir/etc/$pkgname.conf"
}
# vim:set ts=2 sw=2 ft=sh et:
diff --git a/community/ipvsadm/ipvsadm.conf b/community/ipvsadm/ipvsadm.conf
index aac7ba729..b9a98a36e 100644
--- a/community/ipvsadm/ipvsadm.conf
+++ b/community/ipvsadm/ipvsadm.conf
@@ -1,3 +1,7 @@
-# vim:set ts=2 sw=2 ft=sh et:
+# Configuration file used to load/save configuration.
+CONFIG_FILE='/etc/ipvsadm.conf'
+
+# Save configuration on stop/restart.
+#SAVE_ON_STOP=yes
-IPVSADM_CONF='/etc/ipvsadm.rules'
+# vim:set ts=2 sw=2 ft=sh et:
diff --git a/community/ipvsadm/ipvsadm.install b/community/ipvsadm/ipvsadm.install
new file mode 100644
index 000000000..d235b560a
--- /dev/null
+++ b/community/ipvsadm/ipvsadm.install
@@ -0,0 +1,10 @@
+## arg 1: the new package version
+## arg 2: the old package version
+post_upgrade() {
+ [ $(vercmp "$2" '1.26-4') -gt 0 ] || cat <<EOF
+Config file have been moved from /etc/ipvsadm.rules to /etc/ipvsadm.conf.
+You can revert to the previous location by editing /etc/conf.d/ipvsadm.
+EOF
+}
+
+# vim:set ts=2 sw=2 ft=sh et:
diff --git a/community/ipvsadm/ipvsadm.rc b/community/ipvsadm/ipvsadm.rc
index 5a9614106..b810dcd62 100644
--- a/community/ipvsadm/ipvsadm.rc
+++ b/community/ipvsadm/ipvsadm.rc
@@ -2,38 +2,30 @@
. /etc/rc.conf
. /etc/rc.d/functions
-. /etc/conf.d/ipvsadm
+. /etc/conf.d/${0##*/}
case "$1" in
- start)
+ start)
stat_busy 'Loading IPVS table'
- if [[ -f $IPVSADM_CONF ]] && ipvsadm-restore < "$IPVSADM_CONF"; then
- add_daemon ipvsadm
- stat_done
- else
- stat_fail
- fi
- ;;
- stop)
- status 'Clearing IPVS table' ipvsadm -C
- rm_daemon ipvsadm
- ;;
- restart)
- $0 stop
- sleep 1
- $0 start
- ;;
- save)
- stat_busy 'Saving IPVS table'
- if ipvsadm-save -n > "$IPVSADM_CONF" 2>/dev/null; then
- stat_done
- else
- stat_fail
- fi
- ;;
- *)
- echo "usage: ${0##*/} {start|stop|restart|save}"
+ ipvsadm-restore < "$CONFIG_FILE" &&
+ add_daemon ${0##*/} && stat_done || stat_die
+ ;;
+ stop)
+ [[ $SAVE_ON_STOP =~ [yY][eE][sS] ]] && $0 save
+ stat_busy 'Clearing IPVS table'
+ ipvsadm -C && rm_daemon ${0##*/} && stat_done || stat_die
+ ;;
+ restart)
+ $0 stop
+ $0 start
+ ;;
+ save)
+ stat_busy 'Saving IPVS table'
+ ipvsadm-save -n > "$CONFIG_FILE" && stat_done || stat_die
+ ;;
+ *)
+ echo "usage: ${0##*/} {start|stop|restart|save}" >&2
+ exit 1
esac
-exit 0
# vim:set ts=2 sw=2 ft=sh et:
diff --git a/community/ipvsadm/ipvsadm.service b/community/ipvsadm/ipvsadm.service
new file mode 100644
index 000000000..bb6b01c3f
--- /dev/null
+++ b/community/ipvsadm/ipvsadm.service
@@ -0,0 +1,11 @@
+[Unit]
+Description=IP Virtual Server
+
+[Service]
+Type=oneshot
+RemainAfterExit=yes
+ExecStart=/usr/lib/systemd/scripts/ipvsadm start
+ExecStop=/usr/lib/systemd/scripts/ipvsadm stop
+
+[Install]
+WantedBy=multi-user.target
diff --git a/community/ipvsadm/ipvsadm.systemd b/community/ipvsadm/ipvsadm.systemd
new file mode 100644
index 000000000..3b72bd3ef
--- /dev/null
+++ b/community/ipvsadm/ipvsadm.systemd
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+. /etc/conf.d/ipvsadm
+
+case $1 in
+ start)
+ ipvsadm-restore < "$CONFIG_FILE"
+ ;;
+ stop)
+ [[ $SAVE_ON_STOP =~ [yY][eE][sS] ]] && $0 save
+ ipvsadm -C
+ ;;
+ save)
+ ipvsadm-save -n > "$CONFIG_FILE"
+ ;;
+ *)
+ echo "usage: ${0##*/} {start|stop|save}" >&2
+ exit 1
+ ;;
+esac
+
+# vim:set ts=2 sw=2 ft=sh et:
diff --git a/community/ktikz/PKGBUILD b/community/ktikz/PKGBUILD
index 850a926be..d20dfbdcb 100644
--- a/community/ktikz/PKGBUILD
+++ b/community/ktikz/PKGBUILD
@@ -4,7 +4,7 @@
pkgname=ktikz
pkgver=0.10
-pkgrel=3
+pkgrel=4
pkgdesc="A small application helping you to create TikZ diagrams (from the LaTeX pgf package)"
arch=('i686' 'x86_64')
url="http://www.hackenberger.at/blog/ktikz-editor-for-the-tikz-language/"
@@ -13,7 +13,6 @@ depends=('poppler-qt' 'kdelibs')
makedepends=('automoc4' 'cmake' 'docbook-xml')
source=("http://www.hackenberger.at/ktikz/"$pkgname"_"$pkgver".tar.gz")
md5sums=('e8f0826cba2447250bcdcd389a71a2ac')
-install=ktikz.install
build() {
cd "$srcdir"/"$pkgname"
diff --git a/community/libextractor/PKGBUILD b/community/libextractor/PKGBUILD
index 9f71b9bb1..512560db8 100644
--- a/community/libextractor/PKGBUILD
+++ b/community/libextractor/PKGBUILD
@@ -1,10 +1,10 @@
-# $Id: PKGBUILD 70977 2012-05-21 07:59:49Z spupykin $
+# $Id: PKGBUILD 71278 2012-05-26 07:55:04Z pschmitz $
# Maintainer: Sergej Pupykin <pupykin.s@gmail.com>
# Contributor: damir <damir@archlinux.org>
pkgname=libextractor
pkgver=0.6.3
-pkgrel=3
+pkgrel=4
pkgdesc="A library used to extract meta-data from files of arbitrary type"
arch=("i686" "x86_64")
license=('GPL')
diff --git a/community/libmnl/PKGBUILD b/community/libmnl/PKGBUILD
index 8a00d0a65..bc4e355c2 100644
--- a/community/libmnl/PKGBUILD
+++ b/community/libmnl/PKGBUILD
@@ -1,16 +1,18 @@
-# $Id: PKGBUILD 61555 2012-01-02 21:43:24Z seblu $
-# Maintainer: Sebastien Luttringer <seblu+arch@seblu.net
+# $Id: PKGBUILD 71327 2012-05-26 23:26:09Z seblu $
+# Maintainer: Sébastien Luttringer <seblu@aur.archlinux.org>
# Contributor: Christian Hesse <mail@earthworm.de>
pkgname=libmnl
-pkgver=1.0.2
+pkgver=1.0.3
pkgrel=1
pkgdesc='Minimalistic user-space library oriented to Netlink developers.'
arch=('i686' 'x86_64')
url='http://www.netfilter.org/projects/libmnl/'
license=('LGPL2.1')
+depends=('glibc')
+options=('!libtool')
source=("http://www.netfilter.org/projects/$pkgname/files/$pkgname-$pkgver.tar.bz2")
-sha1sums=('62440193d128adc0946a8737e86dc0068424eedb')
+sha1sums=('c27e25f67c6422ebf893fc3a844af8085a1c5b63')
build() {
cd $pkgname-$pkgver
diff --git a/community/milkytracker/PKGBUILD b/community/milkytracker/PKGBUILD
index ecee22ddf..e8e54ee08 100644
--- a/community/milkytracker/PKGBUILD
+++ b/community/milkytracker/PKGBUILD
@@ -4,7 +4,7 @@
pkgname=milkytracker
pkgver=0.90.85
-pkgrel=4
+pkgrel=5
pkgdesc="Fast Tracker II inspired music tracker"
arch=('x86_64' 'i686')
url="http://www.milkytracker.org/"
@@ -12,7 +12,7 @@ license=('GPL3')
depends=('sdl>=1.2.0' 'alsa-lib' 'zlib' 'gcc-libs')
makedepends=('jack-audio-connection-kit')
optdepends=('jack-audio-connection-kit: JACK audio support')
-options=('docs')
+options=('docs' '!strip')
install=$pkgname.install
source=("http://milkytracker.org/files/$pkgname-$pkgver.tar.bz2"
'arch.patch'
diff --git a/community/mplayer2/PKGBUILD b/community/mplayer2/PKGBUILD
index 0025391bb..d7da983a3 100644
--- a/community/mplayer2/PKGBUILD
+++ b/community/mplayer2/PKGBUILD
@@ -1,10 +1,11 @@
+# $Id: PKGBUILD 71255 2012-05-26 06:36:27Z bpiotrowski $
# Maintainer: Bartłomiej Piotrowski <nospam@bpiotrowski.pl>
# Contributor: Martin Panter <vadmium+aur@gmail.com>
# Contributor: Stéphane Gaudreault <stephane@archlinux.org>
pkgname=mplayer2
-pkgver=20120414
-pkgrel=4
+pkgver=20120517
+pkgrel=1
pkgdesc="An advanced general-purpose media player. A fork of the original MPlayer project"
arch=('i686' 'x86_64')
license=('GPL')
@@ -20,19 +21,17 @@ provides=('mplayer')
conflicts=('mplayer')
options=(!emptydirs)
source=(ftp://ftp.archlinux.org/other/community/$pkgname/$pkgname-$pkgver.tar.xz)
-md5sums=('95d981808cbfa66ad238f6c044f4f746')
+md5sums=('814cc9545937e13796df1d4747c3c5d0')
build() {
cd "${srcdir}"/$pkgname-$pkgver
./configure --prefix=/usr \
--enable-runtime-cpudetection \
- --disable-arts \
--disable-speex \
--disable-openal \
--disable-libdv \
--disable-musepack \
- --disable-esd \
--disable-mga \
--language=all \
--enable-translation \
diff --git a/community/ngircd/PKGBUILD b/community/ngircd/PKGBUILD
index 3e4ec0182..65c255a9a 100644
--- a/community/ngircd/PKGBUILD
+++ b/community/ngircd/PKGBUILD
@@ -1,10 +1,10 @@
-# $Id: PKGBUILD 67247 2012-03-05 20:22:45Z kkeen $
+# $Id: PKGBUILD 71251 2012-05-26 05:48:55Z kkeen $
# Maintainer: Kyle Keen <keenerd@gmail.com>
# Contributor: Mateusz Herych <heniekk@gmail.com>
# Contributor: Alexander Rødseth <rodseth@gmail.com>
pkgname=ngircd
-pkgver=19
+pkgver=19.1
pkgrel=1
pkgdesc="Next Generation IRC Daemon"
arch=('x86_64' 'i686')
@@ -14,7 +14,7 @@ license=('GPL')
depends=('openssl' 'libident')
source=("http://ngircd.barton.de/pub/ngircd/ngircd-$pkgver.tar.gz"
ngircd.sh)
-sha256sums=('10d153ea88f5108aedf49e044b5daf8f19ad8053b7721e72408aabe77505388b'
+sha256sums=('3e5cf62ab5164a310aa47f384387803a4c2b5221005ad1eb648ae2c5f0796f60'
'f8c28546090af8ce67471b9b4d577f6926007615356dd11afd2bc16f61d698d5')
build() {
diff --git a/community/pdf2djvu/PKGBUILD b/community/pdf2djvu/PKGBUILD
index a1376c92c..40fe354a8 100644
--- a/community/pdf2djvu/PKGBUILD
+++ b/community/pdf2djvu/PKGBUILD
@@ -1,21 +1,24 @@
-# $Id: PKGBUILD 58479 2011-11-13 13:51:40Z jelle $
+# $Id: PKGBUILD 71280 2012-05-26 07:55:10Z pschmitz $
# Contributor: Paulo Matias <matiasΘarchlinux-br·org>
# Maintainer: Jelle van der Waa <jelle@vdwaa.nl>
pkgname=pdf2djvu
-pkgver=0.7.11
-pkgrel=3
+pkgver=0.7.12
+pkgrel=1
pkgdesc="Creates DjVu files from PDF files"
arch=('i686' 'x86_64')
url="http://pdf2djvu.googlecode.com"
license=('GPL')
depends=('poppler' 'djvulibre' 'libxslt' 'gcc-libs')
makedepends=('pstreams')
-source=("http://pdf2djvu.googlecode.com/files/${pkgname}_${pkgver}.tar.gz")
-md5sums=('cdc0cbb46512aaf7109d6ebc7aef1a7a')
+source=("http://pdf2djvu.googlecode.com/files/${pkgname}_${pkgver}.tar.gz"
+ "poppler-0.20.patch")
+md5sums=('4fd56c0763b56b4081fc9c85be16d9d7'
+ '9f9c5b098a3a13256beac04553ee67c3')
build() {
cd ${srcdir}/${pkgname}-${pkgver}
+ patch -p1 <$srcdir/poppler-0.20.patch
./configure --prefix=/usr
make
}
@@ -25,4 +28,3 @@ package() {
make install DESTDIR=${pkgdir}
install -Dm644 doc/${pkgname}.1 ${pkgdir}/usr/share/man/man1/${pkgname}.1
}
-md5sums=('37c3d5a31c155bc65a39912da4c6bce1')
diff --git a/community/pdf2djvu/poppler-0.20.patch b/community/pdf2djvu/poppler-0.20.patch
new file mode 100644
index 000000000..36d23f73a
--- /dev/null
+++ b/community/pdf2djvu/poppler-0.20.patch
@@ -0,0 +1,69 @@
+diff -wbBur pdf2djvu-0.7.12/configure pdf2djvu-0.7.12.my/configure
+--- pdf2djvu-0.7.12/configure 2012-01-22 03:17:01.000000000 +0400
++++ pdf2djvu-0.7.12.my/configure 2012-05-17 20:44:06.000000000 +0400
+@@ -6653,7 +6653,7 @@
+
+ if test "$GXX" = yes
+ then
+- CXXFLAGS="$CXXFLAGS -Werror=overloaded-virtual"
++ CXXFLAGS="$CXXFLAGS "
+ fi
+
+ # Output files
+diff -wbBur pdf2djvu-0.7.12/configure.ac pdf2djvu-0.7.12.my/configure.ac
+--- pdf2djvu-0.7.12/configure.ac 2012-01-22 03:16:50.000000000 +0400
++++ pdf2djvu-0.7.12.my/configure.ac 2012-05-17 20:43:37.000000000 +0400
+@@ -225,7 +225,7 @@
+ AX_CXXFLAGS_WARN_ALL(CXXFLAGS)
+ if test "$GXX" = yes
+ then
+- CXXFLAGS="$CXXFLAGS -Werror=overloaded-virtual"
++ CXXFLAGS="$CXXFLAGS "
+ fi
+
+ # Output files
+diff -wbBur pdf2djvu-0.7.12/pdf-backend.cc pdf2djvu-0.7.12.my/pdf-backend.cc
+--- pdf2djvu-0.7.12/pdf-backend.cc 2012-01-22 03:16:50.000000000 +0400
++++ pdf2djvu-0.7.12.my/pdf-backend.cc 2012-05-17 20:47:24.000000000 +0400
+@@ -32,10 +32,10 @@
+ * ======================
+ */
+
+-static void poppler_error_handler(int pos, char *message, va_list args)
++static void poppler_error_handler(void *data, ErrorCategory ec, int pos, char *message)
+ {
+ std::string format;
+- std::string expanded_message = string_vprintf(message, args);
++ std::string expanded_message = message;
+ const char *c_message = expanded_message.c_str();
+ if (pos >= 0)
+ {
+@@ -61,7 +61,7 @@
+ Cwd cwd(argv0_dir_name);
+ #endif
+ globalParams = new GlobalParams();
+- setErrorFunction(poppler_error_handler);
++ setErrorCallback(poppler_error_handler, 0);
+ }
+
+ void pdf::Environment::set_antialias(bool value)
+diff -wbBur pdf2djvu-0.7.12/pdf2djvu.cc pdf2djvu-0.7.12.my/pdf2djvu.cc
+--- pdf2djvu-0.7.12/pdf2djvu.cc 2012-01-22 03:16:50.000000000 +0400
++++ pdf2djvu-0.7.12.my/pdf2djvu.cc 2012-05-17 20:55:07.000000000 +0400
+@@ -1387,13 +1387,13 @@
+ debug(0)++;
+ }
+ out1.reset(new pdf::Renderer(paper_color, config.monochrome));
+- out1->startDoc(doc->getXRef());
++ out1->startDoc((PDFDoc*)doc->getXRef());
+ outm.reset(new MutedRenderer(paper_color, config.monochrome, *page_files));
+- outm->startDoc(doc->getXRef());
++ outm->startDoc((PDFDoc*)doc->getXRef());
+ if (!config.monochrome)
+ {
+ outs.reset(new MutedRenderer(paper_color, config.monochrome, *page_files));
+- outs->startDoc(doc->getXRef());
++ outs->startDoc((PDFDoc*)doc->getXRef());
+ }
+ }
+ assert(doc.get() != NULL);
diff --git a/community/qmmp/PKGBUILD b/community/qmmp/PKGBUILD
index 1ba831faa..021ad1b5b 100644
--- a/community/qmmp/PKGBUILD
+++ b/community/qmmp/PKGBUILD
@@ -1,8 +1,8 @@
-#$Id: PKGBUILD 68175 2012-03-18 20:53:22Z jlichtblau $
+#$Id: PKGBUILD 71311 2012-05-26 14:22:36Z jlichtblau $
# Maintainer: Jaroslav Lichtblau <dragonlord@aur.archlinux.org>
pkgname=qmmp
-pkgver=0.5.4
+pkgver=0.5.5
pkgrel=1
pkgdesc="Qt4 based audio-player"
arch=('i686' 'x86_64')
@@ -22,7 +22,7 @@ optdepends=('flac: native FLAC support'
'ffmpeg' 'libsamplerate' 'wavpack')
install=$pkgname.install
source=(http://qmmp.ylsoftware.com/files/$pkgname-$pkgver.tar.bz2)
-sha256sums=('6f95d1bb97cb1ef91b9d664f4d5ce013c6cc93f3aefb24cd64cf2500a525be0f')
+sha256sums=('525d7528c58c885e45149f698125dfff6bedca0e9af979b2490e3f0b902943a6')
build() {
cd ${srcdir}/$pkgname-$pkgver
diff --git a/community/qmmp/qmmp.changelog b/community/qmmp/qmmp.changelog
index a69c0df58..04be7b9e8 100644
--- a/community/qmmp/qmmp.changelog
+++ b/community/qmmp/qmmp.changelog
@@ -1,3 +1,6 @@
+2012-05-26 Jaroslav Lichtblau <dragonlord@aur.archlinux.org>
+ * qmmp 0.5.5-1
+
2012-03-18 Jaroslav Lichtblau <dragonlord@aur.archlinux.org>
* qmmp 0.5.4-1
diff --git a/community/springlobby/PKGBUILD b/community/springlobby/PKGBUILD
index ec363d5ec..3e44c662f 100644
--- a/community/springlobby/PKGBUILD
+++ b/community/springlobby/PKGBUILD
@@ -1,9 +1,9 @@
-# $Id: PKGBUILD 68098 2012-03-18 05:46:56Z svenstaro $
+# $Id: PKGBUILD 71324 2012-05-26 15:26:22Z svenstaro $
# Maintainer: Sven-Hendrik Haase <sh@lutzhaase.com>
# Contributor: DuGi <dugi@irc.pl>
pkgname=springlobby
-pkgver=0.144
+pkgver=0.147
pkgrel=1
pkgdesc="A free cross-platform lobby client for the Spring RTS project."
arch=('i686' 'x86_64')
@@ -14,12 +14,12 @@ optdepends=('sdl' 'sdl_sound' 'sdl_mixer')
makedepends=('boost' 'asio' 'cmake')
install=springlobby.install
source=(http://www.springlobby.info/tarballs/${pkgname}-${pkgver}.tar.bz2)
-md5sums=('facde8ab25100e50be5fc9b33deceb5c')
+md5sums=('1dd17f3f573d40b10b66bdbdc77181f0')
build() {
cd $srcdir/${pkgname}-$pkgver
- export CXXFLAGS="${CXXFLAGS} -DBOOST_FILESYSTEM_VERSION=2"
+ #export CXXFLAGS="${CXXFLAGS} -DBOOST_FILESYSTEM_VERSION=2"
sed -i 's/boost_system-mt/boost_system/g' $srcdir/$pkgname-$pkgver/CMakeLists.txt
diff --git a/community/tellico/PKGBUILD b/community/tellico/PKGBUILD
index 4377089ff..d4b132fd5 100644
--- a/community/tellico/PKGBUILD
+++ b/community/tellico/PKGBUILD
@@ -1,37 +1,38 @@
-# $Id: PKGBUILD 62153 2012-01-16 21:08:22Z andrea $
-# Maintainer: Ray Rashif <schiv@archlinux.org
+# $Id: PKGBUILD 71282 2012-05-26 07:55:16Z pschmitz $
+# Maintainer: Jaroslav Lichtblau <dragonlord@aur.archlinux.org>
+# Contributor: Maintainer: Ray Rashif <schiv@archlinux.org
# Contributor: Andrea Scarpino <andrea@archlinux.org>
# Contributor: Douglas Soares de Andrade <dsa@aur.archlinux.org>
pkgname=tellico
pkgver=2.3.5
-pkgrel=1
+pkgrel=2
pkgdesc="A collection manager for KDE"
arch=('i686' 'x86_64')
url="http://tellico-project.org/"
license=('GPL')
-depends=('kdebase-workspace' 'yaz' 'exempi' 'libksane' 'taglib'
- 'kdemultimedia-kioslave' 'poppler-qt' 'qjson')
+depends=('kdebase-workspace' 'yaz' 'exempi' 'libksane' 'taglib' 'kdemultimedia-kioslave' 'poppler-qt' 'qjson')
makedepends=('automoc4' 'cmake')
install=$pkgname.install
-source=("http://tellico-project.org/files/${pkgname}-${pkgver}.tar.bz2")
-md5sums=('e6a1835d2622b79c4bfd95271bce858e')
+source=(http://tellico-project.org/files/${pkgname}-${pkgver}.tar.bz2)
+sha256sums=('b31db35589cae7f9af56a17e6589f8c5de68e36d9fc5fbaea4154e8238bf041c')
build() {
- cd "${srcdir}"
+ cd ${srcdir}
+
mkdir build
cd build
cmake ../${pkgname}-${pkgver} \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_INSTALL_PREFIX=/usr
-
make
}
package() {
- cd "${srcdir}"/build
- make DESTDIR="${pkgdir}" install
+ cd ${srcdir}/build
+
+ make DESTDIR=${pkgdir} install
- # fix python 2.7 path
- find "$pkgdir" -iname "*.py" | xargs sed -i 's|#!/usr/bin/env python|#!/usr/bin/env python2|'
+# fix python 2.7 path
+ find ${pkgdir} -iname "*.py" | xargs sed -i 's|#!/usr/bin/env python|#!/usr/bin/env python2|'
}
diff --git a/community/tellico/tellico.install b/community/tellico/tellico.install
index 3f06b8deb..3b3aff7d9 100644
--- a/community/tellico/tellico.install
+++ b/community/tellico/tellico.install
@@ -1,12 +1,13 @@
post_install() {
- xdg-icon-resource forceupdate --theme hicolor &> /dev/null
- update-mime-database usr/share/mime &> /dev/null
+ xdg-icon-resource forceupdate --theme hicolor &> /dev/null
+ update-mime-database usr/share/mime &> /dev/null
+ update-desktop-database -q
}
post_upgrade() {
- post_install
+ post_install
}
post_remove() {
- post_install
+ post_install
}
diff --git a/core/libssh2/PKGBUILD b/core/libssh2/PKGBUILD
index fcdd8d45f..520b900f5 100644
--- a/core/libssh2/PKGBUILD
+++ b/core/libssh2/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 156610 2012-04-21 17:49:44Z dreisner $
+# $Id: PKGBUILD 159788 2012-05-27 02:25:20Z dreisner $
# Maintainer: Dave Reisner <dreisner@archlinux.org>
# Contributor: Angel Velasquez <angvp@archlinux.org>
# Contributor: Sergej Pupykin <pupykin.s+arch@gmail.com>
@@ -6,7 +6,7 @@
# Contributor: ice-man <icemanf@gmail.com>
pkgname=libssh2
-pkgver=1.4.1
+pkgver=1.4.2
pkgrel=1
pkgdesc="A library implementing the SSH2 protocol as defined by Internet Drafts"
url="http://www.libssh2.org/"
@@ -17,8 +17,8 @@ makedepends=('zlib')
provides=('libssh2.so')
options=('!libtool')
source=("http://www.libssh2.org/download/$pkgname-$pkgver.tar.gz"{,.asc})
-md5sums=('b94106e046af37fdc0734e487842fe66'
- 'd120a091e9f594c6608815d72b07c7a3')
+md5sums=('42e2b3796ac07fc1dbafc7abcc002cd3'
+ '872cfb1d61dbd5acd0481ab030e8f130')
build() {
cd "$pkgname-$pkgver"
diff --git a/extra/audacious/PKGBUILD b/extra/audacious/PKGBUILD
index b068bd7f9..05d3b9d86 100644
--- a/extra/audacious/PKGBUILD
+++ b/extra/audacious/PKGBUILD
@@ -1,10 +1,10 @@
-# $Id: PKGBUILD 155354 2012-04-02 08:13:23Z bisson $
+# $Id: PKGBUILD 159763 2012-05-26 15:34:45Z bisson $
# Contributor: Alexander Fehr <pizzapunk gmail com>
# Contributor: Giovanni Scafora <giovanni@archlinux.org>
# Maintainer: Gaetan Bisson <bisson@archlinux.org>
pkgname=audacious
-pkgver=3.2.2
+pkgver=3.2.3
pkgrel=1
pkgdesc='Lightweight, advanced audio player focused on audio quality'
url='http://audacious-media-player.org/'
@@ -14,7 +14,7 @@ depends=('gtk3' 'dbus-glib' 'libguess' 'libsm' 'audacious-plugins'
'hicolor-icon-theme' 'gtk-update-icon-cache' 'desktop-file-utils')
optdepends=('unzip: zipped skins support')
source=("http://distfiles.audacious-media-player.org/${pkgname}-${pkgver}.tar.bz2")
-sha1sums=('50d2ef08d3dd48c2efb194a9fdf216fa4f8afd24')
+sha1sums=('23be0fcb0a7d5ec2bc4d4fee436e77f2138903ef')
provides=('audacious-player')
replaces=('audacious-player')
diff --git a/extra/bzflag/PKGBUILD b/extra/bzflag/PKGBUILD
index 08871b559..2dae85048 100644
--- a/extra/bzflag/PKGBUILD
+++ b/extra/bzflag/PKGBUILD
@@ -1,11 +1,11 @@
-# $Id: PKGBUILD 138478 2011-09-24 16:46:33Z stephane $
+# $Id: PKGBUILD 159790 2012-05-27 03:26:02Z bisson $
# Contributor: Damir Perisa <damir.perisa@bluewin.ch>
# Contributor: Kevin Piche <kevin@archlinux.org>
# Maintainer: Gaetan Bisson <bisson@archlinux.org>
pkgname=bzflag
pkgver=2.4.0
-pkgrel=2
+pkgrel=3
pkgdesc='Multiplayer 3D tank battle game'
url='http://bzflag.org/'
license=('LGPL')
diff --git a/extra/calligra/PKGBUILD b/extra/calligra/PKGBUILD
index f0ad1d7bc..9ebfa2ad9 100644
--- a/extra/calligra/PKGBUILD
+++ b/extra/calligra/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 157224 2012-04-26 06:42:14Z andrea $
+# $Id: PKGBUILD 159702 2012-05-26 07:54:08Z andyrtr $
# Maintainer: Ronald van Haren <ronald.archlinux.org>
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
@@ -23,7 +23,7 @@ pkgname=('calligra-filters'
'calligra-braindump'
'calligra-flow')
pkgver=2.4.1
-pkgrel=1
+pkgrel=2
arch=('i686' 'x86_64')
url='http://www.calligra-suite.org/'
license=('FDL1.2' 'GPL2' 'LGPL')
diff --git a/extra/cups-filters/PKGBUILD b/extra/cups-filters/PKGBUILD
index 8483f5f02..aa3ac50f0 100644
--- a/extra/cups-filters/PKGBUILD
+++ b/extra/cups-filters/PKGBUILD
@@ -1,15 +1,15 @@
-# $Id: PKGBUILD 157192 2012-04-25 13:19:30Z andyrtr $
+# $Id: PKGBUILD 159704 2012-05-26 07:54:13Z andyrtr $
# Maintainer: Andreas Radke <andyrtr@archlinux.org>
pkgname=cups-filters
pkgver=1.0.17
-pkgrel=1
+pkgrel=2
pkgdesc="OpenPrinting CUPS Filters"
arch=('i686' 'x86_64')
url="http://www.linuxfoundation.org/collaborate/workgroups/openprinting"
license=('GPL')
groups=()
-depends=('ghostscript' 'lcms2' 'poppler')
+depends=('ghostscript' 'lcms2' 'poppler') # bc ? https://bugs.archlinux.org/task/29808
makedepends=()
optdepends=()
provides=()
diff --git a/extra/gimp/PKGBUILD b/extra/gimp/PKGBUILD
index 7d7a1f464..91ee40019 100644
--- a/extra/gimp/PKGBUILD
+++ b/extra/gimp/PKGBUILD
@@ -1,15 +1,15 @@
-# $Id: PKGBUILD 158544 2012-05-04 19:10:38Z daniel $
+# $Id: PKGBUILD 159779 2012-05-26 19:57:17Z daniel $
# Maintainer: Daniel Isenmann <daniel@archlinux.org>
pkgname=gimp
pkgver=2.8.0
-pkgrel=1
+pkgrel=2
pkgdesc="GNU Image Manipulation Program"
arch=('i686' 'x86_64')
url="http://www.gimp.org/"
license=('GPL' 'LGPL')
depends=('pygtk' 'lcms' 'libxpm' 'libwmf' 'libxmu' 'librsvg' 'libmng' 'dbus-glib' \
- 'libexif' 'gegl' 'desktop-file-utils' 'hicolor-icon-theme' 'babl')
+ 'libexif' 'gegl' 'jasper' 'desktop-file-utils' 'hicolor-icon-theme' 'babl')
makedepends=('intltool' 'libwebkit' 'poppler-glib' 'alsa-lib' 'iso-codes' 'curl')
optdepends=('gutenprint: for sophisticated printing only as gimp has built-in cups print support'
'libwebkit: for the help browser'
diff --git a/extra/inkscape/PKGBUILD b/extra/inkscape/PKGBUILD
index 94ef284c4..b7003ad51 100644
--- a/extra/inkscape/PKGBUILD
+++ b/extra/inkscape/PKGBUILD
@@ -1,11 +1,11 @@
-# $Id: PKGBUILD 153551 2012-03-15 23:11:38Z eric $
+# $Id: PKGBUILD 159706 2012-05-26 07:54:18Z andyrtr $
# Contributor: tobias <tobias@archlinux.org>
# Contributor: Tobias Kieslich <tobias@justdreams.de>
# Maintainer: Gaetan Bisson <bisson@archlinux.org>
pkgname=inkscape
pkgver=0.48.3.1
-pkgrel=2
+pkgrel=3
pkgdesc='Vector graphics editor using the SVG file format'
url='http://inkscape.sourceforge.net/'
license=('GPL' 'LGPL')
@@ -21,8 +21,10 @@ optdepends=('pstoedit: latex formulas'
'uniconvertor: reading/writing to some proprietary formats')
options=('!libtool')
source=("http://downloads.sourceforge.net/project/${pkgname}/${pkgname}/${pkgver}/${pkgname}-${pkgver}.tar.gz"
+ 'poppler20.patch'
'libpng15.patch')
sha1sums=('9a09a97d184e09c2ee7f9956bfe073b7313e919e'
+ '7316c2903c157781838cce289a709d100dc40fec'
'd6512f3cb38ca8e2436dc485aa652490d17b3a52')
install=install
@@ -36,6 +38,7 @@ build() {
sed -i 's|python -c|python2 -c|g' configure share/extensions/uniconv*.py
sed -i 's|"python"|"python2"|g' src/main.cpp
+ patch -p1 -i ../poppler20.patch
patch -p1 -i ../libpng15.patch
./configure \
diff --git a/extra/inkscape/poppler20.patch b/extra/inkscape/poppler20.patch
new file mode 100644
index 000000000..ecb74603f
--- /dev/null
+++ b/extra/inkscape/poppler20.patch
@@ -0,0 +1,642 @@
+diff -Naur old/src/extension/internal/pdfinput/pdf-parser.cpp new/src/extension/internal/pdfinput/pdf-parser.cpp
+--- old/src/extension/internal/pdfinput/pdf-parser.cpp 2011-07-08 20:25:09.468790000 +0200
++++ new/src/extension/internal/pdfinput/pdf-parser.cpp 2012-05-13 21:07:11.334781215 +0200
+@@ -367,14 +367,14 @@
+ for (i = 0; i < obj->arrayGetLength(); ++i) {
+ obj->arrayGet(i, &obj2);
+ if (!obj2.isStream()) {
+- error(-1, const_cast<char*>("Weird page contents"));
++ error(errInternal, -1, const_cast<char*>("Weird page contents"));
+ obj2.free();
+ return;
+ }
+ obj2.free();
+ }
+ } else if (!obj->isStream()) {
+- error(-1, const_cast<char*>("Weird page contents"));
++ error(errInternal, -1, const_cast<char*>("Weird page contents"));
+ return;
+ }
+ parser = new Parser(xref, new Lexer(xref, obj), gFalse);
+@@ -419,7 +419,7 @@
+
+ // too many arguments - something is wrong
+ } else {
+- error(getPos(), const_cast<char*>("Too many args in content stream"));
++ error(errInternal, getPos(), const_cast<char*>("Too many args in content stream"));
+ if (printCommands) {
+ printf("throwing away arg: ");
+ obj.print(stdout);
+@@ -436,7 +436,7 @@
+
+ // args at end with no command
+ if (numArgs > 0) {
+- error(getPos(), const_cast<char*>("Leftover args in content stream"));
++ error(errInternal, getPos(), const_cast<char*>("Leftover args in content stream"));
+ if (printCommands) {
+ printf("%d leftovers:", numArgs);
+ for (i = 0; i < numArgs; ++i) {
+@@ -502,7 +502,7 @@
+ name = cmd->getCmd();
+ if (!(op = findOp(name))) {
+ if (ignoreUndef == 0)
+- error(getPos(), const_cast<char*>("Unknown operator '%s'"), name);
++ error(errInternal, getPos(), const_cast<char*>("Unknown operator '%s'"), name);
+ return;
+ }
+
+@@ -510,26 +510,26 @@
+ argPtr = args;
+ if (op->numArgs >= 0) {
+ if (numArgs < op->numArgs) {
+- error(getPos(), const_cast<char*>("Too few (%d) args to '%s' operator"), numArgs, name);
++ error(errInternal, getPos(), const_cast<char*>("Too few (%d) args to '%s' operator"), numArgs, name);
+ return;
+ }
+ if (numArgs > op->numArgs) {
+ #if 0
+- error(getPos(), "Too many (%d) args to '%s' operator", numArgs, name);
++ error(errInternal, getPos(), "Too many (%d) args to '%s' operator", numArgs, name);
+ #endif
+ argPtr += numArgs - op->numArgs;
+ numArgs = op->numArgs;
+ }
+ } else {
+ if (numArgs > -op->numArgs) {
+- error(getPos(), const_cast<char*>("Too many (%d) args to '%s' operator"),
++ error(errInternal, getPos(), const_cast<char*>("Too many (%d) args to '%s' operator"),
+ numArgs, name);
+ return;
+ }
+ }
+ for (i = 0; i < numArgs; ++i) {
+ if (!checkArg(&argPtr[i], op->tchk[i])) {
+- error(getPos(), const_cast<char*>("Arg #%d to '%s' operator is wrong type (%s)"),
++ error(errInternal, getPos(), const_cast<char*>("Arg #%d to '%s' operator is wrong type (%s)"),
+ i, name, argPtr[i].getTypeName());
+ return;
+ }
+@@ -690,7 +690,7 @@
+ return;
+ }
+ if (!obj1.isDict()) {
+- error(getPos(), const_cast<char*>("ExtGState '%s' is wrong type"), args[0].getName());
++ error(errInternal, getPos(), const_cast<char*>("ExtGState '%s' is wrong type"), args[0].getName());
+ obj1.free();
+ return;
+ }
+@@ -705,7 +705,7 @@
+ if (state->parseBlendMode(&obj2, &mode)) {
+ state->setBlendMode(mode);
+ } else {
+- error(getPos(), const_cast<char*>("Invalid blend mode in ExtGState"));
++ error(errInternal, getPos(), const_cast<char*>("Invalid blend mode in ExtGState"));
+ }
+ }
+ obj2.free();
+@@ -764,7 +764,7 @@
+ state->setTransfer(funcs);
+ }
+ } else if (!obj2.isNull()) {
+- error(getPos(), const_cast<char*>("Invalid transfer function in ExtGState"));
++ error(errInternal, getPos(), const_cast<char*>("Invalid transfer function in ExtGState"));
+ }
+ obj2.free();
+
+@@ -784,7 +784,7 @@
+ funcs[0] = Function::parse(&obj3);
+ if (funcs[0]->getInputSize() != 1 ||
+ funcs[0]->getOutputSize() != 1) {
+- error(getPos(),
++ error(errInternal, getPos(),
+ const_cast<char*>("Invalid transfer function in soft mask in ExtGState"));
+ delete funcs[0];
+ funcs[0] = NULL;
+@@ -809,11 +809,7 @@
+ blendingColorSpace = NULL;
+ isolated = knockout = gFalse;
+ if (!obj4.dictLookup(const_cast<char*>("CS"), &obj5)->isNull()) {
+-#ifdef POPPLER_NEW_COLOR_SPACE_API
+ blendingColorSpace = GfxColorSpace::parse(&obj5, NULL);
+-#else
+- blendingColorSpace = GfxColorSpace::parse(&obj5);
+-#endif
+ }
+ obj5.free();
+ if (obj4.dictLookup(const_cast<char*>("I"), &obj5)->isBool()) {
+@@ -840,15 +836,15 @@
+ delete funcs[0];
+ }
+ } else {
+- error(getPos(), const_cast<char*>("Invalid soft mask in ExtGState - missing group"));
++ error(errInternal, getPos(), const_cast<char*>("Invalid soft mask in ExtGState - missing group"));
+ }
+ obj4.free();
+ } else {
+- error(getPos(), const_cast<char*>("Invalid soft mask in ExtGState - missing group"));
++ error(errInternal, getPos(), const_cast<char*>("Invalid soft mask in ExtGState - missing group"));
+ }
+ obj3.free();
+ } else if (!obj2.isNull()) {
+- error(getPos(), const_cast<char*>("Invalid soft mask in ExtGState"));
++ error(errInternal, getPos(), const_cast<char*>("Invalid soft mask in ExtGState"));
+ }
+ }
+ obj2.free();
+@@ -876,7 +872,7 @@
+ // check form type
+ dict->lookup(const_cast<char*>("FormType"), &obj1);
+ if (!(obj1.isNull() || (obj1.isInt() && obj1.getInt() == 1))) {
+- error(getPos(), const_cast<char*>("Unknown form type"));
++ error(errInternal, getPos(), const_cast<char*>("Unknown form type"));
+ }
+ obj1.free();
+
+@@ -884,7 +880,7 @@
+ dict->lookup(const_cast<char*>("BBox"), &obj1);
+ if (!obj1.isArray()) {
+ obj1.free();
+- error(getPos(), const_cast<char*>("Bad form bounding box"));
++ error(errInternal, getPos(), const_cast<char*>("Bad form bounding box"));
+ return;
+ }
+ for (i = 0; i < 4; ++i) {
+@@ -1012,19 +1008,11 @@
+
+ state->setFillPattern(NULL);
+ res->lookupColorSpace(args[0].getName(), &obj);
+-#ifdef POPPLER_NEW_COLOR_SPACE_API
+ if (obj.isNull()) {
+ colorSpace = GfxColorSpace::parse(&args[0], NULL);
+ } else {
+ colorSpace = GfxColorSpace::parse(&obj, NULL);
+ }
+-#else
+- if (obj.isNull()) {
+- colorSpace = GfxColorSpace::parse(&args[0]);
+- } else {
+- colorSpace = GfxColorSpace::parse(&obj);
+- }
+-#endif
+ obj.free();
+ if (colorSpace) {
+ state->setFillColorSpace(colorSpace);
+@@ -1032,7 +1020,7 @@
+ state->setFillColor(&color);
+ builder->updateStyle(state);
+ } else {
+- error(getPos(), const_cast<char*>("Bad color space (fill)"));
++ error(errInternal, getPos(), const_cast<char*>("Bad color space (fill)"));
+ }
+ }
+
+@@ -1043,19 +1031,11 @@
+
+ state->setStrokePattern(NULL);
+ res->lookupColorSpace(args[0].getName(), &obj);
+-#ifdef POPPLER_NEW_COLOR_SPACE_API
+ if (obj.isNull()) {
+ colorSpace = GfxColorSpace::parse(&args[0], NULL);
+ } else {
+ colorSpace = GfxColorSpace::parse(&obj, NULL);
+ }
+-#else
+- if (obj.isNull()) {
+- colorSpace = GfxColorSpace::parse(&args[0]);
+- } else {
+- colorSpace = GfxColorSpace::parse(&obj);
+- }
+-#endif
+ obj.free();
+ if (colorSpace) {
+ state->setStrokeColorSpace(colorSpace);
+@@ -1063,7 +1043,7 @@
+ state->setStrokeColor(&color);
+ builder->updateStyle(state);
+ } else {
+- error(getPos(), const_cast<char*>("Bad color space (stroke)"));
++ error(errInternal, getPos(), const_cast<char*>("Bad color space (stroke)"));
+ }
+ }
+
+@@ -1072,7 +1052,7 @@
+ int i;
+
+ if (numArgs != state->getFillColorSpace()->getNComps()) {
+- error(getPos(), const_cast<char*>("Incorrect number of arguments in 'sc' command"));
++ error(errInternal, getPos(), const_cast<char*>("Incorrect number of arguments in 'sc' command"));
+ return;
+ }
+ state->setFillPattern(NULL);
+@@ -1088,7 +1068,7 @@
+ int i;
+
+ if (numArgs != state->getStrokeColorSpace()->getNComps()) {
+- error(getPos(), const_cast<char*>("Incorrect number of arguments in 'SC' command"));
++ error(errInternal, getPos(), const_cast<char*>("Incorrect number of arguments in 'SC' command"));
+ return;
+ }
+ state->setStrokePattern(NULL);
+@@ -1109,7 +1089,7 @@
+ if (!((GfxPatternColorSpace *)state->getFillColorSpace())->getUnder() ||
+ numArgs - 1 != ((GfxPatternColorSpace *)state->getFillColorSpace())
+ ->getUnder()->getNComps()) {
+- error(getPos(), const_cast<char*>("Incorrect number of arguments in 'scn' command"));
++ error(errInternal, getPos(), const_cast<char*>("Incorrect number of arguments in 'scn' command"));
+ return;
+ }
+ for (i = 0; i < numArgs - 1 && i < gfxColorMaxComps; ++i) {
+@@ -1120,23 +1100,15 @@
+ state->setFillColor(&color);
+ builder->updateStyle(state);
+ }
+-#ifdef POPPLER_NEW_COLOR_SPACE_API
+ if (args[numArgs-1].isName() &&
+ (pattern = res->lookupPattern(args[numArgs-1].getName(), NULL))) {
+ state->setFillPattern(pattern);
+ builder->updateStyle(state);
+ }
+-#else
+- if (args[numArgs-1].isName() &&
+- (pattern = res->lookupPattern(args[numArgs-1].getName()))) {
+- state->setFillPattern(pattern);
+- builder->updateStyle(state);
+- }
+-#endif
+
+ } else {
+ if (numArgs != state->getFillColorSpace()->getNComps()) {
+- error(getPos(), const_cast<char*>("Incorrect number of arguments in 'scn' command"));
++ error(errInternal, getPos(), const_cast<char*>("Incorrect number of arguments in 'scn' command"));
+ return;
+ }
+ state->setFillPattern(NULL);
+@@ -1161,7 +1133,7 @@
+ ->getUnder() ||
+ numArgs - 1 != ((GfxPatternColorSpace *)state->getStrokeColorSpace())
+ ->getUnder()->getNComps()) {
+- error(getPos(), const_cast<char*>("Incorrect number of arguments in 'SCN' command"));
++ error(errInternal, getPos(), const_cast<char*>("Incorrect number of arguments in 'SCN' command"));
+ return;
+ }
+ for (i = 0; i < numArgs - 1 && i < gfxColorMaxComps; ++i) {
+@@ -1172,23 +1144,15 @@
+ state->setStrokeColor(&color);
+ builder->updateStyle(state);
+ }
+-#ifdef POPPLER_NEW_COLOR_SPACE_API
+ if (args[numArgs-1].isName() &&
+ (pattern = res->lookupPattern(args[numArgs-1].getName(), NULL))) {
+ state->setStrokePattern(pattern);
+ builder->updateStyle(state);
+ }
+-#else
+- if (args[numArgs-1].isName() &&
+- (pattern = res->lookupPattern(args[numArgs-1].getName()))) {
+- state->setStrokePattern(pattern);
+- builder->updateStyle(state);
+- }
+-#endif
+
+ } else {
+ if (numArgs != state->getStrokeColorSpace()->getNComps()) {
+- error(getPos(), const_cast<char*>("Incorrect number of arguments in 'SCN' command"));
++ error(errInternal, getPos(), const_cast<char*>("Incorrect number of arguments in 'SCN' command"));
+ return;
+ }
+ state->setStrokePattern(NULL);
+@@ -1212,7 +1176,7 @@
+
+ void PdfParser::opLineTo(Object args[], int numArgs) {
+ if (!state->isCurPt()) {
+- error(getPos(), const_cast<char*>("No current point in lineto"));
++ error(errInternal, getPos(), const_cast<char*>("No current point in lineto"));
+ return;
+ }
+ state->lineTo(args[0].getNum(), args[1].getNum());
+@@ -1222,7 +1186,7 @@
+ double x1, y1, x2, y2, x3, y3;
+
+ if (!state->isCurPt()) {
+- error(getPos(), const_cast<char*>("No current point in curveto"));
++ error(errInternal, getPos(), const_cast<char*>("No current point in curveto"));
+ return;
+ }
+ x1 = args[0].getNum();
+@@ -1238,7 +1202,7 @@
+ double x1, y1, x2, y2, x3, y3;
+
+ if (!state->isCurPt()) {
+- error(getPos(), const_cast<char*>("No current point in curveto1"));
++ error(errInternal, getPos(), const_cast<char*>("No current point in curveto1"));
+ return;
+ }
+ x1 = state->getCurX();
+@@ -1254,7 +1218,7 @@
+ double x1, y1, x2, y2, x3, y3;
+
+ if (!state->isCurPt()) {
+- error(getPos(), const_cast<char*>("No current point in curveto2"));
++ error(errInternal, getPos(), const_cast<char*>("No current point in curveto2"));
+ return;
+ }
+ x1 = args[0].getNum();
+@@ -1282,7 +1246,7 @@
+
+ void PdfParser::opClosePath(Object args[], int numArgs) {
+ if (!state->isCurPt()) {
+- error(getPos(), const_cast<char*>("No current point in closepath"));
++ error(errInternal, getPos(), const_cast<char*>("No current point in closepath"));
+ return;
+ }
+ state->closePath();
+@@ -1298,7 +1262,7 @@
+
+ void PdfParser::opStroke(Object args[], int numArgs) {
+ if (!state->isCurPt()) {
+- //error(getPos(), const_cast<char*>("No path in stroke"));
++ //error(errInternal, getPos(), const_cast<char*>("No path in stroke"));
+ return;
+ }
+ if (state->isPath()) {
+@@ -1314,7 +1278,7 @@
+
+ void PdfParser::opCloseStroke(Object * /*args[]*/, int /*numArgs*/) {
+ if (!state->isCurPt()) {
+- //error(getPos(), const_cast<char*>("No path in closepath/stroke"));
++ //error(errInternal, getPos(), const_cast<char*>("No path in closepath/stroke"));
+ return;
+ }
+ state->closePath();
+@@ -1331,7 +1295,7 @@
+
+ void PdfParser::opFill(Object args[], int numArgs) {
+ if (!state->isCurPt()) {
+- //error(getPos(), const_cast<char*>("No path in fill"));
++ //error(errInternal, getPos(), const_cast<char*>("No path in fill"));
+ return;
+ }
+ if (state->isPath()) {
+@@ -1347,7 +1311,7 @@
+
+ void PdfParser::opEOFill(Object args[], int numArgs) {
+ if (!state->isCurPt()) {
+- //error(getPos(), const_cast<char*>("No path in eofill"));
++ //error(errInternal, getPos(), const_cast<char*>("No path in eofill"));
+ return;
+ }
+ if (state->isPath()) {
+@@ -1363,7 +1327,7 @@
+
+ void PdfParser::opFillStroke(Object args[], int numArgs) {
+ if (!state->isCurPt()) {
+- //error(getPos(), const_cast<char*>("No path in fill/stroke"));
++ //error(errInternal, getPos(), const_cast<char*>("No path in fill/stroke"));
+ return;
+ }
+ if (state->isPath()) {
+@@ -1376,7 +1340,7 @@
+
+ void PdfParser::opCloseFillStroke(Object args[], int numArgs) {
+ if (!state->isCurPt()) {
+- //error(getPos(), const_cast<char*>("No path in closepath/fill/stroke"));
++ //error(errInternal, getPos(), const_cast<char*>("No path in closepath/fill/stroke"));
+ return;
+ }
+ if (state->isPath()) {
+@@ -1388,7 +1352,7 @@
+
+ void PdfParser::opEOFillStroke(Object args[], int numArgs) {
+ if (!state->isCurPt()) {
+- //error(getPos(), const_cast<char*>("No path in eofill/stroke"));
++ //error(errInternal, getPos(), const_cast<char*>("No path in eofill/stroke"));
+ return;
+ }
+ if (state->isPath()) {
+@@ -1399,7 +1363,7 @@
+
+ void PdfParser::opCloseEOFillStroke(Object args[], int numArgs) {
+ if (!state->isCurPt()) {
+- //error(getPos(), const_cast<char*>("No path in closepath/eofill/stroke"));
++ //error(errInternal, getPos(), const_cast<char*>("No path in closepath/eofill/stroke"));
+ return;
+ }
+ if (state->isPath()) {
+@@ -1440,7 +1404,7 @@
+ doShadingPatternFillFallback((GfxShadingPattern *)pattern, gFalse, eoFill);
+ break;
+ default:
+- error(getPos(), const_cast<char*>("Unimplemented pattern type (%d) in fill"),
++ error(errInternal, getPos(), const_cast<char*>("Unimplemented pattern type (%d) in fill"),
+ pattern->getType());
+ break;
+ }
+@@ -1459,7 +1423,7 @@
+ doShadingPatternFillFallback((GfxShadingPattern *)pattern, gTrue, gFalse);
+ break;
+ default:
+- error(getPos(), const_cast<char*>("Unimplemented pattern type (%d) in stroke"),
++ error(errInternal, getPos(), const_cast<char*>("Unimplemented pattern type (%d) in stroke"),
+ pattern->getType());
+ break;
+ }
+@@ -1579,15 +1543,9 @@
+ double *matrix = NULL;
+ GBool savedState = gFalse;
+
+-#ifdef POPPLER_NEW_COLOR_SPACE_API
+ if (!(shading = res->lookupShading(args[0].getName(), NULL))) {
+ return;
+ }
+-#else
+- if (!(shading = res->lookupShading(args[0].getName()))) {
+- return;
+- }
+-#endif
+
+ // save current graphics state
+ if (shading->getType() != 2 && shading->getType() != 3) {
+@@ -2156,7 +2114,7 @@
+
+ void PdfParser::opShowText(Object args[], int numArgs) {
+ if (!state->getFont()) {
+- error(getPos(), const_cast<char*>("No font in show"));
++ error(errInternal, getPos(), const_cast<char*>("No font in show"));
+ return;
+ }
+ if (fontChanged) {
+@@ -2170,7 +2128,7 @@
+ double tx, ty;
+
+ if (!state->getFont()) {
+- error(getPos(), const_cast<char*>("No font in move/show"));
++ error(errInternal, getPos(), const_cast<char*>("No font in move/show"));
+ return;
+ }
+ if (fontChanged) {
+@@ -2188,7 +2146,7 @@
+ double tx, ty;
+
+ if (!state->getFont()) {
+- error(getPos(), const_cast<char*>("No font in move/set/show"));
++ error(errInternal, getPos(), const_cast<char*>("No font in move/set/show"));
+ return;
+ }
+ if (fontChanged) {
+@@ -2211,7 +2169,7 @@
+ int i;
+
+ if (!state->getFont()) {
+- error(getPos(), const_cast<char*>("No font in show/space"));
++ error(errInternal, getPos(), const_cast<char*>("No font in show/space"));
+ return;
+ }
+ if (fontChanged) {
+@@ -2236,7 +2194,7 @@
+ } else if (obj.isString()) {
+ doShowText(obj.getString());
+ } else {
+- error(getPos(), const_cast<char*>("Element of show/space array must be number or string"));
++ error(errInternal, getPos(), const_cast<char*>("Element of show/space array must be number or string"));
+ }
+ obj.free();
+ }
+@@ -2334,7 +2292,7 @@
+ if (charProc.isStream()) {
+ //parse(&charProc, gFalse); // TODO: parse into SVG font
+ } else {
+- error(getPos(), const_cast<char*>("Missing or bad Type3 CharProc entry"));
++ error(errInternal, getPos(), const_cast<char*>("Missing or bad Type3 CharProc entry"));
+ }
+ //out->endType3Char(state);
+ if (resDict) {
+@@ -2410,7 +2368,7 @@
+ return;
+ }
+ if (!obj1.isStream()) {
+- error(getPos(), const_cast<char*>("XObject '%s' is wrong type"), name);
++ error(errInternal, getPos(), const_cast<char*>("XObject '%s' is wrong type"), name);
+ obj1.free();
+ return;
+ }
+@@ -2426,9 +2384,9 @@
+ /* out->psXObject(obj1.getStream(),
+ obj3.isStream() ? obj3.getStream() : (Stream *)NULL);*/
+ } else if (obj2.isName()) {
+- error(getPos(), const_cast<char*>("Unknown XObject subtype '%s'"), obj2.getName());
++ error(errInternal, getPos(), const_cast<char*>("Unknown XObject subtype '%s'"), obj2.getName());
+ } else {
+- error(getPos(), const_cast<char*>("XObject subtype is missing or wrong type"));
++ error(errInternal, getPos(), const_cast<char*>("XObject subtype is missing or wrong type"));
+ }
+ obj2.free();
+ obj1.free();
+@@ -2559,11 +2517,7 @@
+ }
+ }
+ if (!obj1.isNull()) {
+-#ifdef POPPLER_NEW_COLOR_SPACE_API
+ colorSpace = GfxColorSpace::parse(&obj1, NULL);
+-#else
+- colorSpace = GfxColorSpace::parse(&obj1);
+-#endif
+ } else if (csMode == streamCSDeviceGray) {
+ colorSpace = new GfxDeviceGrayColorSpace();
+ } else if (csMode == streamCSDeviceRGB) {
+@@ -2648,11 +2602,7 @@
+ obj2.free();
+ }
+ }
+-#ifdef POPPLER_NEW_COLOR_SPACE_API
+ maskColorSpace = GfxColorSpace::parse(&obj1, NULL);
+-#else
+- maskColorSpace = GfxColorSpace::parse(&obj1);
+-#endif
+ obj1.free();
+ if (!maskColorSpace || maskColorSpace->getMode() != csDeviceGray) {
+ goto err1;
+@@ -2758,7 +2708,7 @@
+ err2:
+ obj1.free();
+ err1:
+- error(getPos(), const_cast<char*>("Bad image parameters"));
++ error(errInternal, getPos(), const_cast<char*>("Bad image parameters"));
+ }
+
+ void PdfParser::doForm(Object *str) {
+@@ -2783,7 +2733,7 @@
+ // check form type
+ dict->lookup(const_cast<char*>("FormType"), &obj1);
+ if (!(obj1.isNull() || (obj1.isInt() && obj1.getInt() == 1))) {
+- error(getPos(), const_cast<char*>("Unknown form type"));
++ error(errInternal, getPos(), const_cast<char*>("Unknown form type"));
+ }
+ obj1.free();
+
+@@ -2791,7 +2741,7 @@
+ dict->lookup(const_cast<char*>("BBox"), &bboxObj);
+ if (!bboxObj.isArray()) {
+ bboxObj.free();
+- error(getPos(), const_cast<char*>("Bad form bounding box"));
++ error(errInternal, getPos(), const_cast<char*>("Bad form bounding box"));
+ return;
+ }
+ for (i = 0; i < 4; ++i) {
+@@ -2827,11 +2777,7 @@
+ if (obj1.dictLookup(const_cast<char*>("S"), &obj2)->isName(const_cast<char*>("Transparency"))) {
+ transpGroup = gTrue;
+ if (!obj1.dictLookup(const_cast<char*>("CS"), &obj3)->isNull()) {
+-#ifdef POPPLER_NEW_COLOR_SPACE_API
+ blendingColorSpace = GfxColorSpace::parse(&obj3, NULL);
+-#else
+- blendingColorSpace = GfxColorSpace::parse(&obj3);
+-#endif
+ }
+ obj3.free();
+ if (obj1.dictLookup(const_cast<char*>("I"), &obj3)->isBool()) {
+@@ -2990,7 +2936,7 @@
+ parser->getObj(&obj);
+ while (!obj.isCmd(const_cast<char*>("ID")) && !obj.isEOF()) {
+ if (!obj.isName()) {
+- error(getPos(), const_cast<char*>("Inline image dictionary key must be a name object"));
++ error(errInternal, getPos(), const_cast<char*>("Inline image dictionary key must be a name object"));
+ obj.free();
+ } else {
+ key = copyString(obj.getName());
+@@ -3005,7 +2951,7 @@
+ parser->getObj(&obj);
+ }
+ if (obj.isEOF()) {
+- error(getPos(), const_cast<char*>("End of file in inline image"));
++ error(errInternal, getPos(), const_cast<char*>("End of file in inline image"));
+ obj.free();
+ dict.free();
+ return NULL;
+@@ -3020,11 +2966,11 @@
+ }
+
+ void PdfParser::opImageData(Object args[], int numArgs) {
+- error(getPos(), const_cast<char*>("Internal: got 'ID' operator"));
++ error(errInternal, getPos(), const_cast<char*>("Internal: got 'ID' operator"));
+ }
+
+ void PdfParser::opEndImage(Object args[], int numArgs) {
+- error(getPos(), const_cast<char*>("Internal: got 'EI' operator"));
++ error(errInternal, getPos(), const_cast<char*>("Internal: got 'EI' operator"));
+ }
+
+ //------------------------------------------------------------------------
+diff -Naur old/src/extension/internal/pdfinput/svg-builder.cpp new/src/extension/internal/pdfinput/svg-builder.cpp
+--- old/src/extension/internal/pdfinput/svg-builder.cpp 2011-07-08 20:25:09.468790000 +0200
++++ new/src/extension/internal/pdfinput/svg-builder.cpp 2012-05-13 20:45:22.303804308 +0200
+@@ -961,9 +961,7 @@
+ _font_style = sp_repr_css_attr_new();
+ GfxFont *font = state->getFont();
+ // Store original name
+- if (font->getOrigName()) {
+- _font_specification = font->getOrigName()->getCString();
+- } else if (font->getName()) {
++ if (font->getName()) {
+ _font_specification = font->getName()->getCString();
+ } else {
+ _font_specification = (char*) "Arial";
diff --git a/extra/kdegraphics-okular/PKGBUILD b/extra/kdegraphics-okular/PKGBUILD
index ba61ec9af..165b3352e 100644
--- a/extra/kdegraphics-okular/PKGBUILD
+++ b/extra/kdegraphics-okular/PKGBUILD
@@ -1,9 +1,9 @@
-# $Id: PKGBUILD 158361 2012-05-03 22:30:29Z andrea $
+# $Id: PKGBUILD 159708 2012-05-26 07:54:21Z andyrtr $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdegraphics-okular
pkgver=4.8.3
-pkgrel=1
+pkgrel=2
pkgdesc='Document Viewer'
arch=('i686' 'x86_64')
url="http://kde.org/applications/graphics/okular/"
diff --git a/extra/libreoffice/PKGBUILD b/extra/libreoffice/PKGBUILD
index f32828c7a..66f6216c4 100644
--- a/extra/libreoffice/PKGBUILD
+++ b/extra/libreoffice/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 158917 2012-05-13 06:19:42Z andyrtr $
+# $Id: PKGBUILD 159710 2012-05-26 07:54:26Z andyrtr $
# Maintainer: AndyRTR <andyrtr@archlinux.org>
pkgbase="libreoffice"
@@ -18,10 +18,13 @@ pkgname=('libreoffice-common'
'libreoffice-extension-pdfimport'
'libreoffice-extension-presenter-screen'
'libreoffice-extension-presentation-minimizer'
- 'libreoffice-extension-report-builder')
+ 'libreoffice-extension-report-builder'
+ 'libreoffice-scripting-beanshell'
+ 'libreoffice-scripting-javascript'
+ 'libreoffice-extension-scripting-python') # svn up -r 142692 (last one with all extensions built
_LOver=3.5.3.2
pkgver=3.5.3
-pkgrel=1
+pkgrel=3
arch=('i686' 'x86_64')
license=('LGPL3')
url="http://www.libreoffice.org/"
@@ -75,6 +78,8 @@ source=(${_mirror}/${pkgbase}-{core,help,translations}-${_LOver}.tar.xz
http://download.go-oo.org/extern/185d60944ea767075d27247c3162b3bc-unowinreg.dll
gmake_install.diff::http://cgit.freedesktop.org/libreoffice/core/patch/?id=1048d8fa4abd3e55a45dfb6884db808da1d72c9e
smp_buildfix.diff::http://cgit.freedesktop.org/libreoffice/core/patch/?id=cf23f57ae6bb7af689a45e0a850c3c2f67a8f810
+ poppler_buildfix.diff::http://cgit.freedesktop.org/libreoffice/core/patch/?id=ac68934592ec7d838cf5c22744be8d97aa4a1a47
+ fix_broken_hebrew_wordwrapping.diff
buildfix_icu49.diff
libreoffice-common.sh libreoffice-common.csh)
noextract=(2fa6028324347860e684e75310818d43-libvisio-0.0.16.tar.bz2
@@ -138,6 +143,8 @@ md5sums=('d22cd79e7463ac4caf0a4b47d78a82ac'
'185d60944ea767075d27247c3162b3bc'
'60ce5dc9bd098f95c2e621a930c98dd9'
'661a52a02a31b3afbe4b3b3146061afd'
+ '72ba8d57cefdc25a6f1bc845edfd4d78'
+ '025d9b17d9eb90dc282c5c1289a666aa'
'9734ea20c9f67e1b6e1c5a1247fbd3ff'
'f0e72d0e1bc93a50a3aa9d31350b156c'
'867c682b45f477f916786e00c45d7ab7')
@@ -164,7 +171,10 @@ build() {
# one late fix to solve make distro-pack-install issue
patch -Np1 -i ${srcdir}/gmake_install.diff
patch -Np1 -i ${srcdir}/smp_buildfix.diff
- patch -Np0 -i ${srcdir}/buildfix_icu49.diff
+ #patch -Np0 -i ${srcdir}/buildfix_icu49.diff
+ patch -Np1 -i ${srcdir}/poppler_buildfix.diff
+ # https://bugs.archlinux.org/task/29854 based on 3.6/master patch http://cgit.freedesktop.org/libreoffice/core/patch/?id=20c24114143d6d38774b56a142fd4ae05094308e
+ patch -Np1 -i ${srcdir}/fix_broken_hebrew_wordwrapping.diff
# unset C(XX)FLAGS
# http://www.openoffice.org/issues/show_bug.cgi?id=103205
@@ -210,6 +220,8 @@ build() {
--enable-mergelibs \
--enable-opengl \
--enable-odk\
+ --enable-ext-scripting-beanshell \
+ --enable-ext-scripting-javascript \
--disable-ext-mysql-connector \
--with-system-mysql \
--enable-librsvg=system \
@@ -281,7 +293,7 @@ build() {
package_libreoffice-common() {
pkgdesc="common files for LibreOffice - a productivity suite that is compatible with other major office suites"
- install=${pkgbase}.install
+ install=libreoffice-common.install
depends=('libreoffice-langpack' "hunspell>=1.2.8" "python2>=2.7" "neon>=0.28.6"
'nspr' 'libsm' 'redland' 'hyphen' 'graphite' "icu>=49.1"
'hicolor-icon-theme' 'desktop-file-utils' 'shared-mime-info' 'xdg-utils' 'orbit2')
@@ -345,6 +357,7 @@ package_libreoffice-common() {
package_libreoffice-base() {
pkgdesc="GUI Spreadsheet Applicationdatabase front-end for LibreOffice. Allows creation and management of databases through a GUI."
+ install=libreoffice-base.install
depends=('libreoffice-common' 'hsqldb-java')
optdepends=('libreoffice-postgresql-connector')
backup=()
@@ -396,6 +409,7 @@ package_libreoffice-postgresql-connector() {
package_libreoffice-calc() {
pkgdesc="Spreadsheet application for LibreOffice."
+ install=libreoffice-calc.install
depends=('libreoffice-common' 'lpsolve' )
optdepends=()
backup=()
@@ -418,6 +432,7 @@ package_libreoffice-calc() {
package_libreoffice-draw() {
pkgdesc="Drawing Application for LibreOffice."
+ install=libreoffice-draw.install
depends=('libreoffice-common')
optdepends=()
backup=()
@@ -461,6 +476,7 @@ package_libreoffice-gnome() {
package_libreoffice-impress() {
pkgdesc="Presentation Application for LibreOffice."
+ install=libreoffice-impress.install
depends=('libreoffice-common')
optdepends=('mesa: for the OGLTrans extension')
backup=()
@@ -575,6 +591,7 @@ package_libreoffice-sdk-doc() {
package_libreoffice-writer() {
pkgdesc="Word Processor Applicationfor LibreOffice."
+ install=libreoffice-writer.install
depends=('libreoffice-common' 'libwpd>=0.9.2' 'libwps' 'libxml2')
optdepends=('libwpg: library for importing and converting Corel WordPerfect(tm) Graphics images')
backup=()
@@ -656,3 +673,35 @@ package_libreoffice-extension-report-builder() {
install -dm755 ${pkgdir}/usr/lib/libreoffice/share/extensions
unzip -q ${srcdir}/libreoffice-core-$_LOver/solver/unxlng*/bin/report-builder.oxt -d ${pkgdir}/usr/lib/libreoffice/share/extensions/report-builder
}
+
+package_libreoffice-scripting-beanshell() {
+
+ pkgdesc="LibreOffice extension - Enables support for scripts in BeanShell"
+ depends=('libreoffice-common' 'java-environment')
+ groups=('libreoffice-extensions')
+
+ install -dm755 ${pkgdir}/usr/lib/libreoffice/program/{classes,services}
+ mv ${srcdir}/fakeinstall/usr/lib/libreoffice/program/classes/ScriptProviderForBeanShell.jar ${pkgdir}/usr/lib/libreoffice/program/classes/
+ mv ${srcdir}/fakeinstall/usr/lib/libreoffice/program/services/scriptproviderforbeanshell.rdb ${pkgdir}/usr/lib/libreoffice/program/services/
+}
+
+package_libreoffice-scripting-javascript() {
+
+ pkgdesc="LibreOffice extension - Enables support for scripts in JavaScript"
+ depends=('libreoffice-common' 'java-environment')
+ groups=('libreoffice-extensions')
+
+ install -dm755 ${pkgdir}/usr/lib/libreoffice/program/{classes,services}
+ mv ${srcdir}/fakeinstall/usr/lib/libreoffice/program/classes/{js.jar,ScriptProviderForJavaScript.jar} ${pkgdir}/usr/lib/libreoffice/program/classes/
+ mv ${srcdir}/fakeinstall/usr/lib/libreoffice/program/services/scriptproviderforjavascript.rdb ${pkgdir}/usr/lib/libreoffice/program/services/
+}
+
+package_libreoffice-extension-scripting-python() {
+
+ pkgdesc="LibreOffice extension - Enables support for scripts in Python"
+ depends=('libreoffice-common' 'python2')
+ groups=('libreoffice-extensions')
+
+ install -dm755 ${pkgdir}/usr/lib/libreoffice/share/extensions
+ unzip -q ${srcdir}/libreoffice-core-$_LOver/solver/unxlng*/bin/script-provider-for-python.oxt -d ${pkgdir}/usr/lib/libreoffice/share/extensions/script-provider-for-python
+}
diff --git a/extra/libreoffice/fix_broken_hebrew_wordwrapping.diff b/extra/libreoffice/fix_broken_hebrew_wordwrapping.diff
new file mode 100644
index 000000000..ba4850c77
--- /dev/null
+++ b/extra/libreoffice/fix_broken_hebrew_wordwrapping.diff
@@ -0,0 +1,360 @@
+From 20c24114143d6d38774b56a142fd4ae05094308e Mon Sep 17 00:00:00 2001
+From: Caolán McNamara <caolanm@redhat.com>
+Date: Sun, 13 May 2012 21:41:30 +0000
+Subject: Resolves: fdo#49849 implement Unicode 6.1 hebrew line breaking rules
+
+i.e. sync with svn diff -c 31071
+http://source.icu-project.org/repos/icu/icu/trunk/source/data/brkitr/line.txt
+
+Change-Id: I I I41b3d02f1a0da3b83a9684f29d466660d96254c6
+---
+diff --git a/i18npool/qa/cppunit/test_breakiterator.cxx b/i18npool/qa/cppunit/test_breakiterator.cxx
+index 14051d4..ffd590c 100644
+--- a/i18npool/qa/cppunit/test_breakiterator.cxx
++++ b/i18npool/qa/cppunit/test_breakiterator.cxx
+@@ -42,6 +42,7 @@
+ #include <unotest/bootstrapfixturebase.hxx>
+
+ #include <rtl/strbuf.hxx>
++#include <rtl/ustrbuf.hxx>
+
+ #include <string.h>
+
+@@ -58,6 +59,9 @@ public:
+ void testWeak();
+ void testAsian();
+ void testThai();
++#if TODO
++ void testNorthernThai();
++#endif
+
+ CPPUNIT_TEST_SUITE(TestBreakIterator);
+ CPPUNIT_TEST(testLineBreaking);
+@@ -71,6 +71,9 @@
+ CPPUNIT_TEST(testWeak);
+ CPPUNIT_TEST(testAsian);
+ CPPUNIT_TEST(testThai);
++#if TODO
++ CPPUNIT_TEST(testNorthernThai);
++#endif
+ CPPUNIT_TEST_SUITE_END();
+
+ private:
+@@ -80,28 +83,46 @@
+ uno::Reference<i18n::XBreakIterator> m_xBreak;
+ };
+
+-//See https://bugs.freedesktop.org/show_bug.cgi?id=31271 for motivation
+ void TestBreakIterator::testLineBreaking()
+ {
+- ::rtl::OUString aTest1(RTL_CONSTASCII_USTRINGPARAM("(some text here)"));
+-
+ i18n::LineBreakHyphenationOptions aHyphOptions;
+ i18n::LineBreakUserOptions aUserOptions;
+ lang::Locale aLocale;
+
+- aLocale.Language = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("en"));
+- aLocale.Country = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("US"));
+-
++ //See https://bugs.freedesktop.org/show_bug.cgi?id=31271
+ {
+- //Here we want the line break to leave text here) on the next line
+- i18n::LineBreakResults aResult = m_xBreak->getLineBreak(aTest1, strlen("(some tex"), aLocale, 0, aHyphOptions, aUserOptions);
+- CPPUNIT_ASSERT_MESSAGE("Expected a break at the the start of the word", aResult.breakIndex == 6);
++ ::rtl::OUString aTest(RTL_CONSTASCII_USTRINGPARAM("(some text here)"));
++
++ aLocale.Language = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("en"));
++ aLocale.Country = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("US"));
++
++ {
++ //Here we want the line break to leave text here) on the next line
++ i18n::LineBreakResults aResult = m_xBreak->getLineBreak(aTest, strlen("(some tex"), aLocale, 0, aHyphOptions, aUserOptions);
++ CPPUNIT_ASSERT_MESSAGE("Expected a break at the the start of the word", aResult.breakIndex == 6);
++ }
++
++ {
++ //Here we want the line break to leave "here)" on the next line
++ i18n::LineBreakResults aResult = m_xBreak->getLineBreak(aTest, strlen("(some text here"), aLocale, 0, aHyphOptions, aUserOptions);
++ CPPUNIT_ASSERT_MESSAGE("Expected a break at the the start of the word", aResult.breakIndex == 11);
++ }
+ }
+
++ //See https://bugs.freedesktop.org/show_bug.cgi?id=49849
+ {
+- //Here we want the line break to leave "here)" on the next line
+- i18n::LineBreakResults aResult = m_xBreak->getLineBreak(aTest1, strlen("(some text here"), aLocale, 0, aHyphOptions, aUserOptions);
+- CPPUNIT_ASSERT_MESSAGE("Expected a break at the the start of the word", aResult.breakIndex == 11);
++ const sal_Unicode HEBREW1[] = { 0x05DE, 0x05D9, 0x05DC, 0x05D9, 0x5DD };
++ ::rtl::OUString aWord(HEBREW1, SAL_N_ELEMENTS(HEBREW1));
++ ::rtl::OUString aTest(rtl::OUStringBuffer(aWord).append(' ').append(aWord).makeStringAndClear());
++
++ aLocale.Language = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("he"));
++ aLocale.Country = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("IL"));
++
++ {
++ //Here we want the line break to happen at the whitespace
++ i18n::LineBreakResults aResult = m_xBreak->getLineBreak(aTest, aTest.getLength()-1, aLocale, 0, aHyphOptions, aUserOptions);
++ CPPUNIT_ASSERT_MESSAGE("Expected a break at the the start of the word", aResult.breakIndex == aWord.getLength()+1);
++ }
+ }
+ }
+
+@@ -295,27 +320,29 @@ void TestBreakIterator::testThai()
+ aLocale.Language = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("th"));
+ aLocale.Country = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("TH"));
+
+- i18n::Boundary aBounds;
+- {
+- const sal_Unicode THAI1[] = { 0x0E01, 0x0E38, 0x0E2B, 0x0E25, 0x0E32, 0x0E1A };
+- ::rtl::OUString aTest(THAI1, SAL_N_ELEMENTS(THAI1));
+- aBounds = m_xBreak->getWordBoundary(aTest, 0, aLocale,
+- i18n::WordType::DICTIONARY_WORD, true);
+- CPPUNIT_ASSERT_MESSAGE("Should skip full word",
+- aBounds.startPos == 0 && aBounds.endPos == aTest.getLength());
+- }
++ const sal_Unicode THAI1[] = { 0x0E01, 0x0E38, 0x0E2B, 0x0E25, 0x0E32, 0x0E1A };
++ ::rtl::OUString aTest(THAI1, SAL_N_ELEMENTS(THAI1));
++ i18n::Boundary aBounds = m_xBreak->getWordBoundary(aTest, 0, aLocale,
++ i18n::WordType::DICTIONARY_WORD, true);
++ CPPUNIT_ASSERT_MESSAGE("Should skip full word",
++ aBounds.startPos == 0 && aBounds.endPos == aTest.getLength());
++}
+
+-#ifdef TODO
+- {
+- const sal_Unicode NORTHERN_THAI1[] = { 0x0E01, 0x0E38, 0x0E4A, 0x0E2B, 0x0E25, 0x0E32, 0x0E1A };
+- ::rtl::OUString aTest(NORTHERN_THAI1, SAL_N_ELEMENTS(NORTHERN_THAI1));
+- aBounds = m_xBreak->getWordBoundary(aTest, 0, aLocale,
+- i18n::WordType::DICTIONARY_WORD, true);
+- CPPUNIT_ASSERT_MESSAGE("Should skip full word",
+- aBounds.startPos == 0 && aBounds.endPos == aTest.getLength());
+- }
+-#endif
++#if TODO
++void TestBreakIterator::testNorthernThai()
++{
++ lang::Locale aLocale;
++ aLocale.Language = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("nod"));
++ aLocale.Country = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("TH"));
++
++ const sal_Unicode NORTHERN_THAI1[] = { 0x0E01, 0x0E38, 0x0E4A, 0x0E2B, 0x0E25, 0x0E32, 0x0E1A };
++ ::rtl::OUString aTest(NORTHERN_THAI1, SAL_N_ELEMENTS(NORTHERN_THAI1));
++ i18n::Boundary aBounds = m_xBreak->getWordBoundary(aTest, 0, aLocale,
++ i18n::WordType::DICTIONARY_WORD, true);
++ CPPUNIT_ASSERT_MESSAGE("Should skip full word",
++ aBounds.startPos == 0 && aBounds.endPos == aTest.getLength());
+ }
++#endif
+
+ void TestBreakIterator::setUp()
+ {
+diff --git a/i18npool/source/breakiterator/data/README b/i18npool/source/breakiterator/data/README
+new file mode 100644
+index 0000000..8d7598d
+--- a/dev/null
++++ b/i18npool/source/breakiterator/data/README
+@@ -0,0 +1,12 @@
++The originals of these come from svn checkout
++http://source.icu-project.org/repos/icu/icu/trunk/source/data/brkitr they no
++longer appear in the icu tarballs, but are in icu's svn
++
++At various stages these copies have been customized and are not horribly out of
++sync. It unclear which diffs from the base versions are deliberate and which
++are now accidental :-(
++
++We need to review the various issues referenced in the commits that caused
++custimizations and see if they're still relevant or not, write regression tests
++for them, if any are still relavant then apply the changes back on top of the
++latest versions.
+diff --git a/i18npool/source/breakiterator/data/line.txt b/i18npool/source/breakiterator/data/line.txt
+index cbabee6..91c8f3d 100644
+--- a/i18npool/source/breakiterator/data/line.txt
++++ b/i18npool/source/breakiterator/data/line.txt
+@@ -61,11 +61,13 @@ $BB = [:LineBreak = Break_Before:];
+ $BK = [:LineBreak = Mandatory_Break:];
+ $B2 = [:LineBreak = Break_Both:];
+ $CB = [:LineBreak = Contingent_Break:];
++$CJ = [:LineBreak = Conditional_Japanese_Starter:];
+ $CL = [:LineBreak = Close_Punctuation:] ;
+ $CM = [:LineBreak = Combining_Mark:];
+ $CR = [:LineBreak = Carriage_Return:];
+ $EX = [:LineBreak = Exclamation:];
+ $GL = [:LineBreak = Glue:];
++$HL = [:LineBreak = Hebrew_Letter:];
+ $HY = [:LineBreak = Hyphen:];
+ $H2 = [:LineBreak = H2:];
+ $H3 = [:LineBreak = H3:];
+@@ -77,7 +79,7 @@ $JV = [:LineBreak = JV:];
+ $JT = [:LineBreak = JT:];
+ $LF = [:LineBreak = Line_Feed:];
+ $NL = [:LineBreak = Next_Line:];
+-$NS = [:LineBreak = Nonstarter:];
++$NS = [[:LineBreak = Nonstarter:] $CJ];
+ $NU = [:LineBreak = Numeric:];
+ $OP = [[:LineBreak = Open_Punctuation:] - $DG];
+ $PO = [:LineBreak = Postfix_Numeric:];
+@@ -118,6 +120,7 @@ $B2cm = $B2 $CM*;
+ $CLcm = $CL $CM*;
+ $EXcm = $EX $CM*;
+ $GLcm = $GL $CM*;
++$HLcm = $HL $CM*;
+ $HYcm = $HY $CM*;
+ $H2cm = $H2 $CM*;
+ $H3cm = $H3 $CM*;
+@@ -150,6 +153,7 @@ $B2 $CM+;
+ $CL $CM+;
+ $EX $CM+;
+ $GL $CM+;
++$HL $CM+;
+ $HY $CM+;
+ $H2 $CM+;
+ $H3 $CM+;
+@@ -186,7 +190,7 @@ $CANT_CM = [ $SP $BK $CR $LF $NL $ZW $CM]; # Bases that can't take CMs
+ # so for this one case we need to manually list out longer sequences.
+ #
+ $AL_FOLLOW_NOCM = [$BK $CR $LF $NL $ZW $SP];
+-$AL_FOLLOW_CM = [$CL $EX $IS $SY $WJ $GL $QU $BA $HY $NS $IN $NU $ALPlus $OP];
++$AL_FOLLOW_CM = [$CL $EX $HL $IS $SY $WJ $GL $QU $BA $HY $NS $IN $NU $ALPlus $OP];
+ $AL_FOLLOW = [$AL_FOLLOW_NOCM $AL_FOLLOW_CM];
+
+
+@@ -320,8 +324,13 @@ $LB20NonBreaks $CM* ($BAcm | $HYcm | $NScm);
+ $BBcm [^$CB]; # $BB x
+ $BBcm $LB20NonBreaks $CM*;
+
++# LB 21a Don't break after Hebrew + Hyphen
++# HL (HY | BA) x
++#
++$HLcm ($HYcm | $BAcm) [^$CB]?;
++
+ # LB 22
+-$ALcm $INcm;
++($ALcm | $HLcm) $INcm;
+ $CM+ $INcm; # by rule 10, any otherwise unattached CM behaves as AL
+ $IDcm $INcm;
+ $INcm $INcm;
+@@ -331,16 +340,18 @@ $NUcm $INcm;
+ # $LB 23
+ $IDcm $POcm;
+ $ALcm $NUcm; # includes $LB19
++$HLcm $NUcm;
+ $CM+ $NUcm; # Rule 10, any otherwise unattached CM behaves as AL
+ $NUcm $ALcm;
++$NUcm $HLcm;
+
+ #
+ # LB 24
+ #
+ $PRcm $IDcm;
+ $ALcm $PRcm;
+-$PRcm $ALcm;
+-$POcm $ALcm;
++$PRcm ($ALcm | $HLcm);
++$POcm ($ALcm | $HLcm);
+
+ #
+ # LB 25 Numbers.
+@@ -361,8 +372,8 @@ $PRcm ($JLcm | $JVcm | $JTcm | $H2cm | $H3cm);
+
+ # LB 28 Do not break between alphabetics
+ #
+-$ALcm $ALcm;
+-$CM+ $ALcm; # The $CM+ is from rule 10, and unattached CM is treated as AL
++($ALcm | $HLcm) ($ALcm | $HLcm);
++$CM+ ($ALcm | $HLcm); # The $CM+ is from rule 10, an unattached CM is treated as AL
+
+ # LB 29
+ $IScm ($ALcm | $NUcm);
+@@ -371,11 +382,9 @@ $IScm ($ALcm | $NUcm);
+ # Rule 30 Do not break between letters, numbers or ordinary symbols
+ # and opening or closing punctuation
+ #
+-($ALcm | $NUcm) $OPcm;
++($ALcm | $HLcm | $NUcm) $OPcm;
+ $CM+ $OPcm;
+-$CLcm ($ALcm | $NUcm);
+-
+-
++$CLcm ($ALcm | $HLcm | $NUcm);
+
+ #
+ # Reverse Rules.
+@@ -391,6 +400,7 @@ $CM+ $B2;
+ $CM+ $CL;
+ $CM+ $EX;
+ $CM+ $GL;
++$CM+ $HL;
+ $CM+ $HY;
+ $CM+ $H2;
+ $CM+ $H3;
+@@ -544,24 +554,25 @@ $CM* ($BA | $HY | $NS) $CM* [$LB20NonBreaks-$CM]; # . x (BA | HY | NS)
+ $CM* [$LB20NonBreaks-$CM] $CM* $BB; # BB x .
+ [^$CB] $CM* $BB; #
+
+-
++# LB21a
++[^$CB] $CM* ($HY | $BA) $CM* $HL;
+
+ # LB 22
+-$CM* $IN $CM* $ALPlus;
++$CM* $IN $CM* ($ALPlus | $HL);
+ $CM* $IN $CM* $ID;
+ $CM* $IN $CM* $IN;
+ $CM* $IN $CM* $NU;
+
+ # LB 23
+ $CM* $PO $CM* $ID;
+-$CM* $NU $CM* $ALPlus;
+-$CM* $ALPlus $CM* $NU;
++$CM* $NU $CM* ($ALPlus | $HL);
++$CM* ($ALPlus | $HL) $CM* $NU;
+
+ # LB 24
+ $CM* $ID $CM* $PR;
+ $CM* $PR $CM* $ALPlus;
+-$CM* $ALPlus $CM* $PR;
+-$CM* $ALPlus $CM* $PO;
++$CM* ($ALPlus | $HL) $CM* $PR;
++$CM* ($ALPlus | $HL) $CM* $PO;
+
+ $CM* $ALPlus $CM* ($IS | $SY | $HY)+ / $SP;
+ $CM* $NU+ $CM* $HY+ / $SP;
+@@ -580,15 +591,14 @@ $CM* $PO $CM* ($H3 | $H2 | $JT | $JV | $JL);
+ $CM* ($H3 | $H2 | $JT | $JV | $JL) $CM* $PR;
+
+ # LB 28
+-$CM* $ALPlus $CM* $ALPlus;
+-
++$CM* ($ALPlus | $HL) $CM* ($ALPlus | $HL);
+
+ # LB 29
+ $CM* ($NU | $ALPlus) $CM* $IS+ [^$SP];
+
+ # LB 30
+-$CM* $OP $CM* ($NU | $ALPlus);
+-$CM* ($NU | $ALPlus) $CM* ($CL | $SY)+ [^$SP];
++$CM* $OP $CM* ($ALPlus | $HL | $NU);
++$CM* ($ALPlus | $HL | $NU) $CM* ($CL | $SY)+ [^$SP];
+
+
+ ## -------------------------------------------------
+@@ -609,6 +619,9 @@ $SP+ $CM* $QU;
+ $SP+ $CM* $CL;
+ $SP+ $CM* $B2;
+
++# LB 21
++$CM* ($HY | $BA) $CM* $HL;
++
+ # LB 18
+ ($CM* ($IS | $SY))+ $CM* $NU;
+ $CL $CM* ($NU | $IS | $SY);
+@@ -629,6 +642,6 @@ $dictionary $dictionary;
+ # turn off rule chaining. We don't want to move more
+ # than necessary.
+ #
+-[$CM $OP $QU $CL $B2 $PR $HY $SP $dictionary]+ [^$CM $OP $QU $CL $B2 $PR $HY $dictionary];
++[$CM $OP $QU $CL $B2 $PR $HY $BA $SP $dictionary]+ [^$CM $OP $QU $CL $B2 $PR $HY $BA $dictionary];
+ $dictionary $dictionary;
+
+--
+cgit v0.9.0.2-2-gbebe
diff --git a/extra/libreoffice/libreoffice-base.install b/extra/libreoffice/libreoffice-base.install
new file mode 100644
index 000000000..80312d4a6
--- /dev/null
+++ b/extra/libreoffice/libreoffice-base.install
@@ -0,0 +1,11 @@
+post_install() {
+ update-desktop-database -q
+}
+
+post_upgrade() {
+ update-desktop-database -q
+}
+
+post_remove() {
+ update-desktop-database -q
+}
diff --git a/extra/libreoffice/libreoffice-calc.install b/extra/libreoffice/libreoffice-calc.install
new file mode 100644
index 000000000..80312d4a6
--- /dev/null
+++ b/extra/libreoffice/libreoffice-calc.install
@@ -0,0 +1,11 @@
+post_install() {
+ update-desktop-database -q
+}
+
+post_upgrade() {
+ update-desktop-database -q
+}
+
+post_remove() {
+ update-desktop-database -q
+}
diff --git a/extra/libreoffice/libreoffice-common.install b/extra/libreoffice/libreoffice-common.install
new file mode 100644
index 000000000..e66b66f3d
--- /dev/null
+++ b/extra/libreoffice/libreoffice-common.install
@@ -0,0 +1,47 @@
+post_install() {
+
+xdg-icon-resource forceupdate --theme hicolor
+update-desktop-database -q
+update-mime-database usr/share/mime > /dev/null 2>&1
+
+echo " * see https://wiki.archlinux.org/index.php/LibreOffice"
+echo "-------------------------------------------------------------------"
+echo "LibreOffice has been split into several packages:"
+echo "- libreoffice-common"
+echo "- libreoffice-{base,calc,draw,impress,math,writer} - frontend applications"
+echo "- libreoffice-{gnome,kde4} - desktop integration plugins"
+echo "- libreoffice-{sdk,sdk-doc} - add-on and doc for programming using"
+echo " the LibreOffice APIs and for creating"
+echo " extensions (UNO components)."
+echo "-------------------------------------------------------------------"
+echo " * you need to install at least one libreoffice-langpack"
+echo " * you may want to pacman -Ss libreoffice-extensions"
+echo " to see what additional extensions are prepared to install"
+echo " * it's recommended to install {hunspell,mythes,hyphen}-xx pkg
+ for spell checking"
+echo " * make sure you have installed some ttf font (ttf-dejavu recommended)"
+}
+
+post_upgrade() {
+# post_install $1
+xdg-icon-resource forceupdate --theme hicolor
+update-desktop-database -q
+update-mime-database usr/share/mime > /dev/null 2>&1
+ if [ "`vercmp $2 3.4.2rc1`" -lt 0 ]; then
+ # important upgrade notice
+ echo "LibreOffice has been split into several packages:"
+ echo "- libreoffice-common"
+ echo "- libreoffice-{base,calc,draw,impress,math,writer} - frontend applications"
+ echo "- libreoffice-{gnome,kde4} - desktop integration plugins"
+ echo "- libreoffice-{sdk,sdk-doc} - add-on and doc for programming using"
+ echo " the LibreOffice APIs and for creating"
+ echo " extensions (UNO components)."
+ echo "Now you need to install at least one libreoffice-langpack!"
+ fi
+}
+
+post_remove() {
+update-desktop-database -q
+xdg-icon-resource forceupdate --theme hicolor
+update-mime-database usr/share/mime > /dev/null 2>&1
+}
diff --git a/extra/libreoffice/libreoffice-draw.install b/extra/libreoffice/libreoffice-draw.install
new file mode 100644
index 000000000..80312d4a6
--- /dev/null
+++ b/extra/libreoffice/libreoffice-draw.install
@@ -0,0 +1,11 @@
+post_install() {
+ update-desktop-database -q
+}
+
+post_upgrade() {
+ update-desktop-database -q
+}
+
+post_remove() {
+ update-desktop-database -q
+}
diff --git a/extra/libreoffice/libreoffice-impress.install b/extra/libreoffice/libreoffice-impress.install
new file mode 100644
index 000000000..80312d4a6
--- /dev/null
+++ b/extra/libreoffice/libreoffice-impress.install
@@ -0,0 +1,11 @@
+post_install() {
+ update-desktop-database -q
+}
+
+post_upgrade() {
+ update-desktop-database -q
+}
+
+post_remove() {
+ update-desktop-database -q
+}
diff --git a/extra/libreoffice/libreoffice-writer.install b/extra/libreoffice/libreoffice-writer.install
new file mode 100644
index 000000000..80312d4a6
--- /dev/null
+++ b/extra/libreoffice/libreoffice-writer.install
@@ -0,0 +1,11 @@
+post_install() {
+ update-desktop-database -q
+}
+
+post_upgrade() {
+ update-desktop-database -q
+}
+
+post_remove() {
+ update-desktop-database -q
+}
diff --git a/extra/poppler/PKGBUILD b/extra/poppler/PKGBUILD
index 6ecf34a2a..21bf5f959 100644
--- a/extra/poppler/PKGBUILD
+++ b/extra/poppler/PKGBUILD
@@ -1,10 +1,10 @@
-# $Id: PKGBUILD 158944 2012-05-13 14:56:03Z jgc $
+# $Id: PKGBUILD 159712 2012-05-26 07:54:31Z andyrtr $
# Maintainer: Jan de Groot <jgc@archlinux.org>
pkgbase=poppler
pkgname=('poppler' 'poppler-glib' 'poppler-qt')
-pkgver=0.18.4
-pkgrel=2
+pkgver=0.20.0
+pkgrel=1
arch=(i686 x86_64)
license=('GPL')
makedepends=('libjpeg' 'gcc-libs' 'cairo' 'fontconfig' 'openjpeg' 'gtk2' 'qt' 'pkgconfig' 'lcms' 'gobject-introspection')
@@ -13,7 +13,7 @@ url="http://poppler.freedesktop.org/"
_testtag=0d2bfd4af4c76a3bac27ccaff793d9129df7b57a
source=(http://poppler.freedesktop.org/${pkgbase}-${pkgver}.tar.gz
http://cgit.freedesktop.org/poppler/test/snapshot/test-${_testtag}.tar.bz2)
-md5sums=('12658f3308597e57f3faff538cc73baf'
+md5sums=('5bca54b9561bf5b14d9344efce2cd4f3'
'9dc64c254a31e570507bdd4ad4ba629a')
build() {
diff --git a/extra/thunar/PKGBUILD b/extra/thunar/PKGBUILD
index e0b8e003e..563ec2d2c 100644
--- a/extra/thunar/PKGBUILD
+++ b/extra/thunar/PKGBUILD
@@ -1,10 +1,10 @@
-# $Id: PKGBUILD 157829 2012-04-30 04:19:49Z foutrelis $
+# $Id: PKGBUILD 159694 2012-05-26 04:30:08Z foutrelis $
# Maintainer: Evangelos Foutras <evangelos@foutrelis.com>
# Contributor: Andrew Simmons <andrew.simmons@gmail.com>
pkgname=thunar
pkgver=1.4.0
-pkgrel=1
+pkgrel=2
pkgdesc="Modern file manager for Xfce"
arch=('i686' 'x86_64')
url="http://thunar.xfce.org"
@@ -22,12 +22,19 @@ optdepends=('gvfs: for trash support, mounting with udisk and remote filesystems
'thunar-media-tags-plugin: view/edit id3/ogg tags')
options=('!libtool')
install=$pkgname.install
-source=(http://archive.xfce.org/src/xfce/$pkgname/1.4/Thunar-$pkgver.tar.bz2)
-sha256sums=('2c11a19e64cef708a264fb4d5d933389899c3d132fe7b1e313dd6e37bfe4c8ba')
+source=(http://archive.xfce.org/src/xfce/$pkgname/1.4/Thunar-$pkgver.tar.bz2
+ thunar-1.4.0-show-loop-devices-hack.patch)
+sha256sums=('2c11a19e64cef708a264fb4d5d933389899c3d132fe7b1e313dd6e37bfe4c8ba'
+ '185c44db9bdf578d22cb69b81dce7fcc3e2ee6031b1547de6453ff0752dbc97e')
build() {
cd "$srcdir/Thunar-$pkgver"
+ # Fix: Loop devices not appearing in Thunar side pane
+ # https://bugs.archlinux.org/task/29894
+ # https://bugzilla.xfce.org/show_bug.cgi?id=8947
+ patch -Np1 -i "$srcdir/thunar-1.4.0-show-loop-devices-hack.patch"
+
./configure \
--prefix=/usr \
--sysconfdir=/etc \
diff --git a/extra/thunar/thunar-1.4.0-show-loop-devices-hack.patch b/extra/thunar/thunar-1.4.0-show-loop-devices-hack.patch
new file mode 100644
index 000000000..95bbc6665
--- /dev/null
+++ b/extra/thunar/thunar-1.4.0-show-loop-devices-hack.patch
@@ -0,0 +1,15 @@
+diff -upr Thunar-1.4.0.orig/thunar/thunar-gio-extensions.c Thunar-1.4.0/thunar/thunar-gio-extensions.c
+--- Thunar-1.4.0.orig/thunar/thunar-gio-extensions.c 2012-05-26 07:03:39.000000000 +0300
++++ Thunar-1.4.0/thunar/thunar-gio-extensions.c 2012-05-26 07:05:06.000000000 +0300
+@@ -550,6 +550,11 @@ thunar_g_volume_is_present (GVolume *vol
+ has_media = g_drive_has_media (drive);
+ g_object_unref (drive);
+ }
++ else
++ {
++ /* XXX: hack to show loop devices with gvfs 1.12 / udisks2 */
++ has_media = g_volume_can_mount (volume);
++ }
+
+ mount = g_volume_get_mount (volume);
+ if (mount != NULL)
diff --git a/extra/windowmaker/PKGBUILD b/extra/windowmaker/PKGBUILD
index e9a98534e..3b20bf518 100644
--- a/extra/windowmaker/PKGBUILD
+++ b/extra/windowmaker/PKGBUILD
@@ -1,8 +1,8 @@
-# $Id: PKGBUILD 150208 2012-02-14 20:50:29Z daniel $
+# $Id: PKGBUILD 159727 2012-05-26 10:06:04Z daniel $
# Maintainer: Daniel Isenmann <daniel@archlinux.org>
# Contributor: Judd Vinet <jvinet@zeroflux.org>
pkgname=windowmaker
-pkgver=0.95.2
+pkgver=0.95.3
pkgrel=1
pkgdesc="An X11 window manager with a NEXTSTEP look and feel"
arch=(i686 x86_64)
@@ -11,7 +11,7 @@ license=('GPL' 'custom')
depends=('libxinerama' 'libxrandr' 'libxmu' 'libpng' 'libxpm' 'libxft' 'libtiff' 'giflib')
options=('!libtool')
source=(http://windowmaker.org/pub/source/release/WindowMaker-$pkgver.tar.gz wmaker.desktop)
-md5sums=('ae62bad9c4dee504066e0f172b565ff0'
+md5sums=('305af9d862e853a5d7977e801cb66ca3'
'2fba97bebfd691836b92b8f0db79ff13')
build() {
diff --git a/extra/xpdf/PKGBUILD b/extra/xpdf/PKGBUILD
index 12e63382c..f10a1b24f 100644
--- a/extra/xpdf/PKGBUILD
+++ b/extra/xpdf/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 135889 2011-08-20 02:28:50Z bisson $
+# $Id: PKGBUILD 159716 2012-05-26 07:54:51Z andyrtr $
# Maintainer: Gaetan Bisson <bisson@archlinux.org>
# Contributor: tobias <tobias@archlinux.org>
# Contributor: Sarah Hay <sarahhay@mb.sympatico.ca>
@@ -6,7 +6,7 @@
pkgname=xpdf
#pkgver=3.03_pl1
pkgver=3.03
-pkgrel=1
+pkgrel=2
pkgdesc='Viewer for Portable Document Format (PDF) files'
url='http://www.foolabs.com/xpdf/'
license=('GPL2')
@@ -57,10 +57,8 @@ package() {
install -Dm644 ../desktop "${pkgdir}/usr/share/applications/xpdf.desktop"
install -Dm644 xpdf/xpdfIcon.xpm "${pkgdir}/usr/share/pixmaps/xpdf.xpm"
- # remove libs and manpages provided by poppler
- # pdfdetach should go there too once it is in poppler
- for tool in pdffonts pdfimages pdfinfo pdftoppm pdftops pdftotext ; do
- rm "${pkgdir}/usr/bin/${tool}"
- rm "${pkgdir}/usr/share/man/man1/${tool}.1"
+ # stuff provided by poppler
+ for tool in pdfdetach pdffonts pdfimages pdfinfo pdftoppm pdftops pdftotext; do
+ rm "${pkgdir}/usr/bin/${tool}" "${pkgdir}/usr/share/man/man1/${tool}.1"
done
}
diff --git a/multilib/wine/PKGBUILD b/multilib/wine/PKGBUILD
index df9f03560..d66c99cc2 100644
--- a/multilib/wine/PKGBUILD
+++ b/multilib/wine/PKGBUILD
@@ -1,17 +1,17 @@
-# $Id: PKGBUILD 70576 2012-05-12 00:22:47Z svenstaro $
+# $Id: PKGBUILD 71289 2012-05-26 10:04:51Z svenstaro $
# Maintainer: Sven-Hendrik Haase <sh@lutzhaase.com>
# Contributor: Jan "heftig" Steffens <jan.steffens@gmail.com>
# Contributor: Eduardo Romero <eduardo@archlinux.org>
# Contributor: Giovanni Scafora <giovanni@archlinux.org>
pkgname=wine
-pkgver=1.5.4
+pkgver=1.5.5
pkgrel=1
_pkgbasever=${pkgver/rc/-rc}
source=(http://ibiblio.org/pub/linux/system/emulators/$pkgname/$pkgname-$_pkgbasever.tar.bz2)
-md5sums=('e7eb0f4b1f16359005fef12e00bd12df')
+md5sums=('63639cfe9addb75cd40726cac36bcf8a')
pkgdesc="A compatibility layer for running Windows programs"
url="http://www.winehq.com"
diff --git a/staging/bluez/PKGBUILD b/staging/bluez/PKGBUILD
new file mode 100644
index 000000000..9d9043e53
--- /dev/null
+++ b/staging/bluez/PKGBUILD
@@ -0,0 +1,87 @@
+# $Id: PKGBUILD 159751 2012-05-26 12:43:04Z tomegun $
+# Maintainer: Tom Gundersen <teg@jklm.no>
+# Contributor: Andrea Scarpino <andrea@archlinux.org>
+# Contributor: Geoffroy Carrier <geoffroy@archlinux.org>
+
+pkgname=bluez
+pkgver=4.99
+pkgrel=3
+pkgdesc="Libraries and tools for the Bluetooth protocol stack"
+url="http://www.bluez.org/"
+arch=('i686' 'x86_64')
+license=('GPL2')
+depends=('dbus-core' 'python2' 'udev')
+makedepends=('gstreamer0.10-base' 'libusb-compat' 'libsndfile')
+optdepends=("gstreamer0.10-base: bluetooth GStreamer support"
+ "alsa-lib: Audio bluetooth devices support"
+ "dbus-python: to run bluez-simple-agent"
+ "pygobject: to run bluez-simple-agent"
+ "libusb-compat: USB adapters support"
+ "cups: CUPS backend")
+conflicts=('bluez-libs' 'bluez-utils')
+provides=('bluez-libs' 'bluez-utils')
+replaces=('bluez-libs' 'bluez-utils')
+options=('!libtool')
+backup=(etc/bluetooth/{main,rfcomm,audio,network,input,serial}.conf
+ 'etc/conf.d/bluetooth' 'etc/dbus-1/system.d/bluetooth.conf')
+source=("http://www.kernel.org/pub/linux/bluetooth/${pkgname}-${pkgver}.tar.bz2"
+ 'bluetooth.conf.d'
+ 'rc.bluetooth')
+
+build() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
+
+ ./configure --prefix=/usr \
+ --sysconfdir=/etc \
+ --localstatedir=/var \
+ --libexecdir=/lib \
+ --enable-gstreamer \
+ --enable-alsa \
+ --enable-usb \
+ --enable-tools \
+ --enable-bccmd \
+ --enable-dfutool \
+ --enable-hid2hci \
+ --enable-hidd \
+ --enable-pand \
+ --enable-dund \
+ --enable-cups \
+ --enable-wiimote \
+ --disable-test
+
+ sed -ri 's,udev_get_(dev|sys)_path([^)]+\)),"/\1",g' tools/hid2hci.c
+
+ make
+}
+
+package() {
+ cd ${srcdir}/${pkgname}-${pkgver}
+ make DESTDIR=${pkgdir} install
+
+ install -Dm755 ${srcdir}/rc.bluetooth ${pkgdir}/etc/rc.d/bluetooth
+
+ install -d ${pkgdir}/etc/bluetooth
+ install -m644 network/network.conf \
+ input/input.conf \
+ audio/audio.conf \
+ serial/serial.conf \
+ ${pkgdir}/etc/bluetooth/
+
+ install -Dm644 ${srcdir}/bluetooth.conf.d \
+ ${pkgdir}/etc/conf.d/bluetooth
+
+ # FS#27630
+ install -Dm755 test/simple-agent "${pkgdir}"/usr/bin/bluez-simple-agent
+ install -Dm755 test/test-device "${pkgdir}"/usr/bin/bluez-test-device
+ install -Dm755 test/test-input "${pkgdir}"/usr/bin/bluez-test-input
+ sed -i 's#/usr/bin/python#/usr/bin/python2#' \
+ "${pkgdir}"/usr/bin/bluez-simple-agent \
+ "${pkgdir}"/usr/bin/bluez-test-device \
+ "${pkgdir}"/usr/bin/bluez-test-input
+
+ # http://mailman.archlinux.org/pipermail/arch-general/2011-April/019787.html
+# rm "${pkgdir}"/usr/lib/udev/rules.d/97-bluetooth.rules
+}
+md5sums=('2387053eb5a7b02f37df4871df022a02'
+ '7412982b440f29fa7f76a41a87fef985'
+ '8f9498707f809506928b2e480d3b6789')
diff --git a/staging/bluez/bluetooth.conf.d b/staging/bluez/bluetooth.conf.d
new file mode 100644
index 000000000..1c1e02589
--- /dev/null
+++ b/staging/bluez/bluetooth.conf.d
@@ -0,0 +1,30 @@
+# Bluetooth configuraton file
+
+# Bluetooth services (allowed values are "true" and "false")
+
+# Run the bluetoothd daemon (default: true)
+#DAEMON_ENABLE="false"
+
+# Run the sdp daemon (default: false)
+# If this is disabled, hcid's internal sdp daemon will be used
+#SDPD_ENABLE="true"
+
+# Run the bluetooth HID daemon (default: false)
+#HIDD_ENABLE="true"
+
+# Activate rfcomm ports (default: false)
+#RFCOMM_ENABLE="true"
+
+# Run bluetooth dial-up networking daemon (default: false)
+#DUND_ENABLE="true"
+
+# Run bluetooth PAN daemon (default: false)
+#PAND_ENABLE="true"
+
+# rfcomm configuration file (default: /etc/bluetooth/rfcomm.conf)
+#RFCOMM_CONFIG="/etc/bluetooth/rfcomm.conf"
+
+# Options for hidd, dund and pand (default: none)
+HIDD_OPTIONS="--server"
+#DUND_OPTIONS=""
+#PAND_OPTIONS=""
diff --git a/staging/bluez/rc.bluetooth b/staging/bluez/rc.bluetooth
new file mode 100644
index 000000000..a46ee2abb
--- /dev/null
+++ b/staging/bluez/rc.bluetooth
@@ -0,0 +1,100 @@
+#!/bin/bash
+#
+# Start/stop the Bluetooth daemons
+#
+
+. /etc/rc.conf
+. /etc/rc.d/functions
+
+DAEMON_NAME="bluetoothd"
+HIDD_NAME="hidd"
+RFCOMM_NAME="rfcomm"
+PAND_NAME="pand"
+DUND_NAME="dund"
+
+DAEMON_EXEC="/usr/sbin/bluetoothd"
+HIDD_EXEC="/usr/bin/hidd"
+RFCOMM_EXEC="/usr/bin/rfcomm"
+PAND_EXEC="/usr/bin/pand"
+DUND_EXEC="/usr/bin/dund"
+
+DAEMON_ENABLE="true"
+HIDD_ENABLE="false"
+RFCOMM_ENABLE="false"
+DUND_ENABLE="false"
+PAND_ENABLE="false"
+
+RFCOMM_CONFIG="/etc/bluetooth/rfcomm.conf"
+
+HIDD_OPTIONS=""
+DUND_OPTIONS=""
+PAND_OPTIONS=""
+
+[ -f /etc/conf.d/bluetooth ] && . /etc/conf.d/bluetooth
+
+case "$1" in
+ start)
+ stat_busy "Starting bluetooth subsystem:"
+ if [ "$DAEMON_ENABLE" = "true" -a -x "$DAEMON_EXEC" ] ; then
+ stat_append " $DAEMON_NAME"
+ $DAEMON_EXEC
+ sleep 1
+ fi
+ if [ "$SDPD_ENABLE" = "true" -a -x "$SDPD_EXEC" ] ; then
+ stat_append " $SDPD_NAME"
+ $SDPD_EXEC
+ fi
+ if [ "$HIDD_ENABLE" = "true" -a -x "$HIDD_EXEC" ]; then
+ stat_append " $HIDD_NAME"
+ $HIDD_EXEC $HIDD_OPTIONS
+ fi
+ if [ "$RFCOMM_ENABLE" = "true" -a -x "$RFCOMM_EXEC" -a -f "$RFCOMM_CONFIG" ]; then
+ stat_append " $RFCOMM_NAME"
+ $RFCOMM_EXEC -f $RFCOMM_CONFIG bind all
+ fi
+ if [ "$DUND_ENABLE" = "true" -a -x "$DUND_EXEC" -a -n "$DUND_OPTIONS" ]; then
+ stat_append " $DUND_NAME"
+ $DUND_EXEC $DUND_OPTIONS
+ fi
+ if [ "$PAND_ENABLE" = "true" -a -x "$PAND_EXEC" -a -n "$PAND_OPTIONS" ]; then
+ stat_append " $PAND_NAME"
+ $PAND_EXEC $PAND_OPTIONS
+ fi
+ add_daemon bluetooth
+ stat_done
+ ;;
+ stop)
+ stat_busy "Stopping bluetooth subsystem:"
+
+ stat_append " $PAND_NAME"
+ killall $PAND_NAME >/dev/null 2>&1
+
+ stat_append " $DUND_NAME"
+ killall $DUND_NAME >/dev/null 2>&1
+
+ if [ -x "$RFCOMM_EXEC" ]; then
+ stat_append " $RFCOMM_NAME"
+ $RFCOMM_EXEC release all >/dev/null 2>&1
+ fi
+
+ stat_append " $HIDD_NAME"
+ killall $HIDD_NAME >/dev/null 2>&1
+
+ stat_append " $SDPD_NAME"
+ killall $SDPD_NAME >/dev/null 2>&1
+
+ stat_append " $DAEMON_NAME"
+ killall $DAEMON_NAME >/dev/null 2>&1
+
+ rm_daemon bluetooth
+ stat_done
+ ;;
+ restart)
+ $0 stop
+ sleep 1
+ $0 start
+ ;;
+ *)
+ echo "usage: $0 {start|stop|restart}"
+esac
+exit 0
diff --git a/staging/cairo-perl/PKGBUILD b/staging/cairo-perl/PKGBUILD
new file mode 100644
index 000000000..ba76f82c8
--- /dev/null
+++ b/staging/cairo-perl/PKGBUILD
@@ -0,0 +1,34 @@
+# $Id: PKGBUILD 159743 2012-05-26 12:14:50Z bluewind $
+# Maintainer: Jan de Groot <jgc@archlinux.org>
+
+pkgname=cairo-perl
+pkgver=1.082
+pkgrel=2
+pkgdesc="Perl wrappers for cairo"
+arch=(i686 x86_64)
+license=('LGPL')
+url="http://gtk2-perl.sourceforge.net/"
+options=('!emptydirs')
+depends=('cairo' 'perl')
+makedepends=('perl-extutils-depends' 'perl-extutils-pkgconfig')
+source=(http://downloads.sourceforge.net/sourceforge/gtk2-perl/Cairo-${pkgver}.tar.gz
+ testsuite.patch)
+md5sums=('cfd61e519ff20023979c255d4040fe06'
+ '6a3ceac304a5a53f8fdd5652d98f6855')
+
+build() {
+ cd "${srcdir}/Cairo-${pkgver}"
+ patch -Np1 -i "${srcdir}/testsuite.patch"
+ perl Makefile.PL INSTALLDIRS=vendor
+ make
+}
+
+check() {
+ cd "${srcdir}/Cairo-${pkgver}"
+ make test
+}
+
+package() {
+ cd "${srcdir}/Cairo-${pkgver}"
+ make DESTDIR="${pkgdir}" install
+}
diff --git a/staging/cairo-perl/testsuite.patch b/staging/cairo-perl/testsuite.patch
new file mode 100644
index 000000000..59cb58f28
--- /dev/null
+++ b/staging/cairo-perl/testsuite.patch
@@ -0,0 +1,135 @@
+From 21dd8a0600cbfac46723c7745b377fce94c8bdc3 Mon Sep 17 00:00:00 2001
+From: Torsten Schönfeld <kaffeetisch@gmx.de>
+Date: Sat, 31 Mar 2012 10:34:11 +0000
+Subject: Fix compiling and testing against older versions of cairo
+
+---
+(limited to 't/CairoPath.t')
+
+diff --git a/t/CairoPath.t b/t/CairoPath.t
+index e515172..770e464 100644
+--- a/t/CairoPath.t
++++ b/t/CairoPath.t
+@@ -11,11 +11,17 @@ use strict;
+ use warnings;
+ use Cairo;
+
+-use Test::More tests => 6;
++use Test::More;
+
+ use constant IMG_WIDTH => 256;
+ use constant IMG_HEIGHT => 256;
+
++if (Cairo::VERSION >= Cairo::VERSION_ENCODE (1, 4, 0)) {
++ plan tests => 6;
++} else {
++ plan skip_all => 'path behavior not predictable on cairo < 1.4';
++}
++
+ my $surf = Cairo::ImageSurface->create ('rgb24', IMG_WIDTH, IMG_HEIGHT);
+ my $cr = Cairo::Context->create ($surf);
+
+--
+cgit v0.9.0.2
+From a1cd2e45b4ee49a724ae5d7e854ad9829eebf00d Mon Sep 17 00:00:00 2001
+From: Torsten Schönfeld <kaffeetisch@gmx.de>
+Date: Sat, 07 Apr 2012 18:01:31 +0000
+Subject: Make t/CairoPath.t more robust
+
+The end of a path that took a round trip into cairo and back might differ
+for different versions of cairo. Hence, compare only the beginning with
+the expected path.
+---
+diff --git a/t/CairoPath.t b/t/CairoPath.t
+index 770e464..27a3aad 100644
+--- a/t/CairoPath.t
++++ b/t/CairoPath.t
+@@ -11,17 +11,11 @@ use strict;
+ use warnings;
+ use Cairo;
+
+-use Test::More;
++use Test::More tests => 18;
+
+ use constant IMG_WIDTH => 256;
+ use constant IMG_HEIGHT => 256;
+
+-if (Cairo::VERSION >= Cairo::VERSION_ENCODE (1, 4, 0)) {
+- plan tests => 6;
+-} else {
+- plan skip_all => 'path behavior not predictable on cairo < 1.4';
+-}
+-
+ my $surf = Cairo::ImageSurface->create ('rgb24', IMG_WIDTH, IMG_HEIGHT);
+ my $cr = Cairo::Context->create ($surf);
+
+@@ -40,14 +34,7 @@ my $expected_path = [
+ ];
+
+ my $path = $cr->copy_path;
+-is_deeply ($path, $expected_path);
+-
+-sub paths_agree {
+- my ($cr, $path, $expected_path) = @_;
+- $cr->new_path;
+- $cr->append_path ($path);
+- is_deeply ($cr->copy_path, $expected_path);
+-}
++paths_agree ($path, $expected_path);
+
+ # Modifying single point values.
+ foreach ($path, $expected_path) {
+@@ -57,21 +44,21 @@ foreach ($path, $expected_path) {
+ $_->[2]{points}[2][0] = 99;
+ $_->[2]{points}[2][1] = 1010;
+ }
+-paths_agree ($cr, $path, $expected_path);
++path_round_trip_ok ($cr, $path, $expected_path);
+
+ # Modifying single points.
+ foreach ($path, $expected_path) {
+ $_->[1]{points}[0] = [333, 444];
+ $_->[2]{points}[2] = [77, 88];
+ }
+-paths_agree ($cr, $path, $expected_path);
++path_round_trip_ok ($cr, $path, $expected_path);
+
+ # Replacing all points.
+ foreach ($path, $expected_path) {
+ $_->[1]{points} = [[3333, 4444]];
+ $_->[2]{points} = [[55, 66], [77, 88], [99, 1010]];
+ }
+-paths_agree ($cr, $path, $expected_path);
++path_round_trip_ok ($cr, $path, $expected_path);
+
+ # Replacing and adding path segments.
+ my @cloned_path = @{$path};
+@@ -86,9 +73,24 @@ foreach (\@cloned_path, $expected_path) {
+ type => 'line-to',
+ points => [[23, 42]] };
+ }
+-paths_agree ($cr, \@cloned_path, $expected_path);
++path_round_trip_ok ($cr, \@cloned_path, $expected_path);
+
+ # Passing bare arrays into Cairo.
+ $cr->new_path;
+ $cr->append_path ($expected_path);
+-is_deeply ($cr->copy_path, $expected_path);
++paths_agree ($cr->copy_path, $expected_path);
++
++sub path_round_trip_ok {
++ my ($cr, $path, $expected_path) = @_;
++ $cr->new_path;
++ $cr->append_path ($path);
++ paths_agree ($cr->copy_path, $expected_path);
++}
++
++sub paths_agree {
++ my ($path, $expected_path) = @_;
++ # Only the first three entries seem to be reliable across cairo versions.
++ for (0..2) {
++ is_deeply ($path->[$_], $expected_path->[$_]);
++ }
++}
+--
+cgit v0.9.0.2
diff --git a/staging/easytag/PKGBUILD b/staging/easytag/PKGBUILD
new file mode 100644
index 000000000..eb59f4ae0
--- /dev/null
+++ b/staging/easytag/PKGBUILD
@@ -0,0 +1,28 @@
+# $Id: PKGBUILD 159784 2012-05-26 23:49:07Z tomegun $
+# Maintainer:
+# Contributor: Kevin Piche <kevin@archlinux.org>
+# Contributor: Aaron Griffin <aaron@archlinux.org>
+# Contributor: dorphell <dorphell@archlinux.org>
+
+pkgname=easytag
+pkgver=2.1.7
+pkgrel=2
+pkgdesc="Utility for viewing, editing and writing ID3 tags of your MP3 files"
+arch=('i686' 'x86_64')
+license=('GPL')
+url='http://easytag.sourceforge.net/'
+depends=('id3lib' 'libid3tag' 'gtk2' 'libvorbis' 'flac' 'speex' 'wavpack' 'desktop-file-utils')
+install=${pkgname}.install
+source=("http://downloads.sourceforge.net/${pkgname}/${pkgname}-${pkgver}.tar.bz2")
+md5sums=('9df3e800d80e754670642f2ba5e03539')
+
+build() {
+ cd ${srcdir}/${pkgname}-${pkgver}
+ ./configure --prefix=/usr
+ make
+}
+
+package() {
+ cd ${srcdir}/${pkgname}-${pkgver}
+ make DESTDIR=${pkgdir} install
+}
diff --git a/staging/easytag/easytag.install b/staging/easytag/easytag.install
new file mode 100644
index 000000000..93908edac
--- /dev/null
+++ b/staging/easytag/easytag.install
@@ -0,0 +1,11 @@
+post_install() {
+ [[ -x usr/bin/update-desktop-database ]] && update-desktop-database -q || true
+}
+
+post_upgrade() {
+ post_install
+}
+
+post_remove() {
+ post_install
+}
diff --git a/staging/frozen-bubble/PKGBUILD b/staging/frozen-bubble/PKGBUILD
new file mode 100644
index 000000000..c4428993a
--- /dev/null
+++ b/staging/frozen-bubble/PKGBUILD
@@ -0,0 +1,41 @@
+# $Id: PKGBUILD 159777 2012-05-26 19:52:21Z foutrelis $
+# Maintainer: Jan "heftig" Steffens <jan.steffens@gmail.com>
+# Contributor: Allan McRae <allan@archlinux.org>
+# Contributor: Brandon Niemczyk <maccorin@cfl.rr.com>
+
+pkgname=frozen-bubble
+_pkgver=2.2.1-beta1
+pkgver=${_pkgver/-/}
+pkgrel=4
+pkgdesc="A game in which you throw colorful bubbles and build groups to destroy the bubbles"
+arch=(i686 x86_64)
+url="http://www.frozen-bubble.org"
+license=(GPL2)
+depends=(perl-sdl perl-ipc-system-simple perl-compress-bzip2 perl-file-which)
+makedepends=(perl-file-slurp perl-locale-maketext-lexicon)
+options=('!emptydirs')
+source=(http://www.frozen-bubble.org/data/$pkgname-$_pkgver.tar.bz2 \
+ frozen-bubble.desktop)
+md5sums=('825cc23ed806838b9d86de9982a5687a'
+ '01b10b77ba6ad856f5c199121c582272')
+
+build() {
+ cd "$srcdir/$pkgname-$_pkgver"
+ unset CFLAGS
+ # install module in vendor directories
+ perl Build.PL installdirs=vendor
+ perl Build
+}
+
+check() {
+ cd "$srcdir/$pkgname-$_pkgver"
+ perl Build test
+}
+
+package() {
+ cd "$srcdir/$pkgname-$_pkgver"
+ perl Build install destdir="$pkgdir"
+
+ install -D -m644 share/icons/frozen-bubble-icon-64x64.png "$pkgdir/usr/share/pixmaps/frozen-bubble.png"
+ install -D -m644 "$srcdir/frozen-bubble.desktop" "$pkgdir/usr/share/applications/frozen-bubble.desktop"
+}
diff --git a/staging/frozen-bubble/frozen-bubble.desktop b/staging/frozen-bubble/frozen-bubble.desktop
new file mode 100644
index 000000000..76a7bcd88
--- /dev/null
+++ b/staging/frozen-bubble/frozen-bubble.desktop
@@ -0,0 +1,9 @@
+[Desktop Entry]
+Type=Application
+Version=1.0
+Encoding=UTF-8
+Name=Frozen Bubble
+Icon=frozen-bubble.png
+Exec=/usr/bin/vendor_perl/frozen-bubble
+Terminal=false
+Categories=Game;
diff --git a/staging/gconf-perl/PKGBUILD b/staging/gconf-perl/PKGBUILD
new file mode 100644
index 000000000..e63bf621d
--- /dev/null
+++ b/staging/gconf-perl/PKGBUILD
@@ -0,0 +1,34 @@
+# $Id: PKGBUILD 159747 2012-05-26 12:22:57Z bluewind $
+# Maintainer: Jan de Groot <jgc@archlinux.org>
+
+pkgname=gconf-perl
+pkgver=1.044
+pkgrel=7
+pkgdesc="Gnome2-GConf perl bindings for gconf"
+arch=('i686' 'x86_64')
+license=('LGPL')
+url="http://gtk2-perl.sourceforge.net/"
+makedepends=('perl-extutils-pkgconfig' 'perl-extutils-depends')
+depends=('glib-perl' 'gconf' 'perl')
+options=(!emptydirs)
+source=(http://downloads.sourceforge.net/sourceforge/gtk2-perl/Gnome2-GConf-${pkgver}.tar.gz
+ disable-orbit.patch)
+md5sums=('ea386003b18f067524833b0eeb271330'
+ '14852fc936ce7b552eb204913d55fd1c')
+
+build() {
+ cd "${srcdir}/Gnome2-GConf-${pkgver}"
+ patch -Np1 -i "${srcdir}/disable-orbit.patch"
+ perl Makefile.PL INSTALLDIRS=vendor
+ make
+}
+
+check() {
+ cd "${srcdir}/Gnome2-GConf-${pkgver}"
+ dbus-launch --exit-with-session make test
+}
+
+package() {
+ cd "${srcdir}/Gnome2-GConf-${pkgver}"
+ make DESTDIR="${pkgdir}" install
+}
diff --git a/staging/gconf-perl/disable-orbit.patch b/staging/gconf-perl/disable-orbit.patch
new file mode 100644
index 000000000..da526ec2e
--- /dev/null
+++ b/staging/gconf-perl/disable-orbit.patch
@@ -0,0 +1,30 @@
+Description: Disable gconf_engine_key_is_writable
+ This symbol is not available in libgconf when it is configured without
+ ORBit support, which is currently the case in Debian.
+Author: Colin Watson <cjwatson@ubuntu.com>
+Bug-Debian: http://bugs.debian.org/649055
+Forwarded: no
+Last-Update: 2011-11-17
+
+Index: b/xs/GConfEngine.xs
+===================================================================
+--- a/xs/GConfEngine.xs
++++ b/xs/GConfEngine.xs
+@@ -350,6 +350,8 @@
+ if (err)
+ gperl_croak_gerror (NULL, err);
+
++#if 0 /* requires gconf to be configured with ORBit support */
++
+ ##gboolean gconf_engine_key_is_writable (GConfEngine *conf,
+ ## const gchar *key,
+ ## GError **err);
+@@ -366,6 +368,8 @@
+ OUTPUT:
+ RETVAL
+
++#endif
++
+ guint
+ gconf_engine_notify_add (engine, namespace_section, func, data=NULL)
+ GConfEngine * engine
diff --git a/staging/glib-perl/PKGBUILD b/staging/glib-perl/PKGBUILD
new file mode 100644
index 000000000..6f0b83b09
--- /dev/null
+++ b/staging/glib-perl/PKGBUILD
@@ -0,0 +1,32 @@
+# $Id: PKGBUILD 159741 2012-05-26 12:00:57Z bluewind $
+# Maintainer: Jan de Groot <jgc@archlinux.org>
+# Contributor: Sarah Hay <sarah@archlinux.org>
+
+pkgname=glib-perl
+pkgver=1.242
+pkgrel=2
+pkgdesc="Perl wrappers for glib 2.x, including GObject"
+arch=(i686 x86_64)
+license=('LGPL')
+url="http://gtk2-perl.sourceforge.net/"
+options=('!emptydirs')
+depends=('glib2>=2.24.1' 'perl>=5.14')
+makedepends=('perl-extutils-depends>=0.302' 'perl-extutils-pkgconfig>=1.12')
+source=(http://downloads.sourceforge.net/sourceforge/gtk2-perl/Glib-${pkgver}.tar.gz)
+md5sums=('59c176888e8ef8139c4e1b8c2d45f1d0')
+
+build() {
+ cd "${srcdir}/Glib-${pkgver}"
+ perl Makefile.PL INSTALLDIRS=vendor
+ make
+}
+
+check() {
+ cd "${srcdir}/Glib-${pkgver}"
+ make test
+}
+
+package() {
+ cd "${srcdir}/Glib-${pkgver}"
+ make DESTDIR="${pkgdir}" install
+}
diff --git a/staging/graphicsmagick/PKGBUILD b/staging/graphicsmagick/PKGBUILD
new file mode 100644
index 000000000..96cb72b92
--- /dev/null
+++ b/staging/graphicsmagick/PKGBUILD
@@ -0,0 +1,60 @@
+# $Id: PKGBUILD 159767 2012-05-26 17:25:12Z bluewind $
+# Maintainer: Ronald van Haren <ronald.archlinux.org>
+# Maintainer: Gaetan Bisson <bisson@archlinux.org>
+# Contributor: Jaroslav Lichtblau <dragonlord@aur.archlinux.org>
+# Contributor: Anton Leontiev <bunder@t-25.ru>
+
+pkgname=graphicsmagick
+pkgver=1.3.15
+pkgrel=2
+pkgdesc='Image processing system'
+url='http://www.graphicsmagick.org/'
+arch=('i686' 'x86_64')
+license=('MIT')
+makedepends=('perl')
+depends=('bzip2' 'freetype2' 'ghostscript' 'jasper' 'lcms2' 'xz'
+ 'libtiff' 'libwmf' 'libsm' 'libxml2' 'libltdl')
+options=('!libtool')
+source=("http://downloads.sourceforge.net/project/${pkgname}/${pkgname}/${pkgver}/GraphicsMagick-${pkgver}.tar.xz")
+sha1sums=('d5df4000d5531fad3ede9e008f9c8dc2d085d546')
+
+build() {
+ cd "${srcdir}/GraphicsMagick-${pkgver}"
+
+ # fix typemap bug
+ # https://rt.cpan.org/Public/Bug/Display.html?id=70150
+ # http://trac.imagemagick.org/browser/ImageMagick/branches/ImageMagick-6.7.7/PerlMagick/typemap
+ echo 'Graphics::Magick T_PTROBJ' > typemap
+
+ ./configure \
+ --prefix=/usr \
+ --with-perl \
+ --enable-shared \
+ --disable-static \
+ --with-gs-font-dir=/usr/share/fonts/Type1 \
+
+ make
+}
+
+package() {
+ cd "${srcdir}/GraphicsMagick-${pkgver}"
+
+ make DESTDIR="${pkgdir}" install
+
+ # Install MIT license
+ install -Dm644 "Copyright.txt" "${pkgdir}/usr/share/licenses/${pkgname}/Copyright.txt"
+
+ # Install perl bindings
+ # The patching was introduced in order to build perl module without installing package itself and
+ # not to introduce unnecessary path into LD_RUN_PATH
+ cd PerlMagick
+ sed -i -e "s:'LDDLFLAGS' => \"\(.*\)\":'LDDLFLAGS' => \"-L${pkgdir}/usr/lib \1\":" Makefile.PL
+ perl Makefile.PL INSTALLDIRS=vendor PREFIX=/usr DESTDIR="${pkgdir}"
+ sed -i -e "s/LDLOADLIBS =/LDLOADLIBS = -lGraphicsMagick/" Makefile
+ make
+ make install
+
+ # Remove perllocal.pod and .packlist
+ rm -rf "${pkgdir}/usr/lib/perl5/core_perl"
+ rm "${pkgdir}/usr/lib/perl5/vendor_perl/auto/Graphics/Magick/.packlist"
+}
diff --git a/staging/gvfs/PKGBUILD b/staging/gvfs/PKGBUILD
new file mode 100644
index 000000000..bb8fa6d9c
--- /dev/null
+++ b/staging/gvfs/PKGBUILD
@@ -0,0 +1,112 @@
+# $Id: PKGBUILD 159759 2012-05-26 15:13:31Z ibiru $
+# Maintainer: Jan de Groot <jgc@archlinux.org>
+
+pkgbase=gvfs
+pkgname=('gvfs' 'gvfs-smb' 'gvfs-afc' 'gvfs-afp' 'gvfs-gphoto2' 'gvfs-obexftp')
+pkgver=1.12.3
+pkgrel=2
+arch=('i686' 'x86_64')
+license=('LGPL')
+makedepends=('avahi' 'bluez' 'dbus-glib' 'fuse' 'intltool' 'libarchive' 'libcdio' 'libgphoto2' 'libimobiledevice' 'libsoup-gnome' 'smbclient' 'udisks2')
+url="http://www.gnome.org"
+options=(!libtool)
+source=(http://ftp.gnome.org/pub/gnome/sources/$pkgbase/${pkgver%.*}/$pkgbase-$pkgver.tar.xz)
+sha256sums=('38f69ec92083f86a51e7814e98d2861151f16dfb3abe4b3b39488408e12fd9c2')
+
+build() {
+ cd "$pkgbase-$pkgver"
+ ./configure --prefix=/usr --sysconfdir=/etc \
+ --localstatedir=/var --disable-static \
+ --libexecdir=/usr/lib/gvfs \
+ --with-bash-completion-dir=/usr/share/bash-completion/completions
+ make
+}
+
+package_gvfs() {
+ pkgdesc="Userspace virtual filesystem implemented as a pluggable module for gio"
+ depends=('avahi' 'dconf' 'fuse' 'libarchive' 'libcdio' 'libsoup-gnome' 'udisks2')
+ optdepends=('gvfs-afc: AFC (mobile devices) support'
+ 'gvfs-smb: SMB/CIFS (Windows client) support'
+ 'gvfs-gphoto2: gphoto2 (PTP camera/MTP media player) support'
+ 'gvfs-obexftp: ObexFTP (bluetooth) support'
+ 'gvfs-afp: Apple Filing Protocol (AFP) support')
+ install=gvfs.install
+
+ cd "$pkgbase-$pkgver"
+ sed -e 's/^am__append_4/#am__append_4/' \
+ -e 's/^am__append_5/#am__append_5/' \
+ -i monitor/Makefile
+ make DESTDIR="$pkgdir" install
+
+ cd "$pkgdir"
+ rm usr/lib/gvfs/gvfsd-{smb,smb-browse,afc,afp,afp-browse,gphoto2,obexftp}
+ rm usr/share/gvfs/mounts/{smb,smb-browse,afc,afp,afp-browse,gphoto2,obexftp}.mount
+ rm usr/share/glib-2.0/schemas/org.gnome.system.smb.gschema.xml
+ rm usr/share/GConf/gsettings/gvfs-smb.convert
+}
+
+package_gvfs-smb() {
+ pkgdesc="SMB/CIFS (Windows client) backend for gvfs"
+ depends=("gvfs=$pkgver" 'smbclient' 'libgnome-keyring')
+ install=gvfs-smb.install
+
+ cd "$pkgbase-$pkgver/daemon"
+ install -m755 -d "$pkgdir/usr/lib/gvfs"
+ install -m755 -d "$pkgdir/usr/share/gvfs/mounts"
+
+ install -m755 .libs/gvfsd-smb{,-browse} "$pkgdir/usr/lib/gvfs/"
+ install -m644 smb{,-browse}.mount "$pkgdir/usr/share/gvfs/mounts/"
+
+ install -Dm644 org.gnome.system.smb.gschema.xml \
+ "$pkgdir/usr/share/glib-2.0/schemas/org.gnome.system.smb.gschema.xml"
+ install -Dm644 gvfs-smb.convert \
+ "$pkgdir/usr/share/GConf/gsettings/gvfs-smb.convert"
+}
+
+package_gvfs-afc() {
+ pkgdesc="AFC (mobile devices) backend for gvfs"
+ depends=("gvfs=$pkgver" 'libimobiledevice')
+ install=gvfs-module.install
+
+ cd "$pkgbase-$pkgver/daemon"
+ install -D .libs/gvfsd-afc "$pkgdir/usr/lib/gvfs/gvfsd-afc"
+ install -Dm644 afc.mount "$pkgdir/usr/share/gvfs/mounts/afc.mount"
+
+ cd "$srcdir/$pkgbase-$pkgver/monitor/afc"
+ make DESTDIR="$pkgdir" install
+}
+
+package_gvfs-gphoto2() {
+ pkgdesc="gphoto2 (PTP camera/MTP media player) backend for gvfs"
+ depends=("gvfs=$pkgver" 'dbus-core' 'libgphoto2' 'udev')
+ install=gvfs-module.install
+
+ cd "$pkgbase-$pkgver/daemon"
+ install -D .libs/gvfsd-gphoto2 "$pkgdir/usr/lib/gvfs/gvfsd-gphoto2"
+ install -Dm644 gphoto2.mount "$pkgdir/usr/share/gvfs/mounts/gphoto2.mount"
+
+ cd "$srcdir/$pkgbase-$pkgver/monitor/gphoto2"
+ make DESTDIR="$pkgdir" install
+}
+
+package_gvfs-obexftp() {
+ pkgdesc="ObexFTP (bluetooth) backend for gvfs"
+ depends=("gvfs=$pkgver" 'dbus-glib' 'bluez' 'obex-data-server')
+ install=gvfs-module.install
+
+ cd "$pkgbase-$pkgver/daemon"
+ install -D .libs/gvfsd-obexftp "$pkgdir/usr/lib/gvfs/gvfsd-obexftp"
+ install -Dm644 obexftp.mount "$pkgdir/usr/share/gvfs/mounts/obexftp.mount"
+}
+
+package_gvfs-afp() {
+ pkgdesc="Apple Filing Protocol (AFP) backend for gvfs"
+ depends=("gvfs=$pkgver")
+ install=gvfs-module.install
+ install -m755 -d "$pkgdir/usr/lib/gvfs"
+ install -m755 -d "$pkgdir/usr/share/gvfs/mounts"
+
+ cd "$pkgbase-$pkgver/daemon"
+ install -m755 .libs/gvfsd-afp{,-browse} "$pkgdir/usr/lib/gvfs/"
+ install -m644 afp{,-browse}.mount "$pkgdir/usr/share/gvfs/mounts/"
+}
diff --git a/staging/gvfs/gvfs-module.install b/staging/gvfs/gvfs-module.install
new file mode 100644
index 000000000..09d1f11ec
--- /dev/null
+++ b/staging/gvfs/gvfs-module.install
@@ -0,0 +1,7 @@
+post_install() {
+ killall -USR1 gvfsd >&/dev/null || :
+}
+
+post_upgrade() {
+ post_install
+}
diff --git a/staging/gvfs/gvfs-smb.install b/staging/gvfs/gvfs-smb.install
new file mode 100644
index 000000000..da6a2ab6d
--- /dev/null
+++ b/staging/gvfs/gvfs-smb.install
@@ -0,0 +1,12 @@
+post_install() {
+ glib-compile-schemas /usr/share/glib-2.0/schemas
+ killall -USR1 gvfsd >&/dev/null || :
+}
+
+post_upgrade() {
+ post_install
+}
+
+post_remove() {
+ glib-compile-schemas /usr/share/glib-2.0/schemas
+}
diff --git a/staging/gvfs/gvfs.install b/staging/gvfs/gvfs.install
new file mode 100644
index 000000000..3482d99e3
--- /dev/null
+++ b/staging/gvfs/gvfs.install
@@ -0,0 +1,14 @@
+post_install() {
+ gio-querymodules /usr/lib/gio/modules
+ glib-compile-schemas /usr/share/glib-2.0/schemas
+ killall -USR1 gvfsd >&/dev/null || :
+}
+
+post_upgrade() {
+ post_install
+}
+
+post_remove() {
+ gio-querymodules /usr/lib/gio/modules
+ glib-compile-schemas /usr/share/glib-2.0/schemas
+}
diff --git a/staging/libatasmart/PKGBUILD b/staging/libatasmart/PKGBUILD
new file mode 100644
index 000000000..7981b0536
--- /dev/null
+++ b/staging/libatasmart/PKGBUILD
@@ -0,0 +1,28 @@
+# $Id: PKGBUILD 159755 2012-05-26 15:06:57Z ibiru $
+# Maintainer: Jan de Groot <jgc@archlinux.org>
+
+pkgname=libatasmart
+pkgver=0.18
+pkgrel=2
+pkgdesc="ATA S.M.A.R.T. Reading and Parsing Library"
+arch=('i686' 'x86_64')
+license=('LGPL')
+depends=('udev')
+url="http://0pointer.de/blog/projects/being-smart.html"
+options=('!libtool')
+source=("http://0pointer.de/public/${pkgname}-${pkgver}.tar.gz")
+md5sums=('dc22b7acda1c2230f55ae98737e8b159')
+
+build() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
+ ./configure --prefix=/usr \
+ --sysconfdir=/etc \
+ --localstatedir=/var \
+ --disable-static
+ make
+}
+
+package() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
+ make DESTDIR="${pkgdir}" install
+}
diff --git a/staging/mesa/LICENSE b/staging/mesa/LICENSE
new file mode 100644
index 000000000..ae33d2709
--- /dev/null
+++ b/staging/mesa/LICENSE
@@ -0,0 +1,82 @@
+Disclaimer
+
+Mesa is a 3-D graphics library with an API which is very similar to
+that of OpenGL*
+To the extent that Mesa utilizes the OpenGL command syntax or state
+machine, it is being used with authorization from Silicon Graphics,
+Inc.(SGI). However, the author does not possess an OpenGL license
+from SGI, and makes no claim that Mesa is in any way a compatible
+replacement for OpenGL or associated with SGI. Those who want a
+licensed implementation of OpenGL should contact a licensed
+vendor.
+
+Please do not refer to the library as MesaGL (for legal
+reasons). It's just Mesa or The Mesa 3-D graphics
+library
+
+* OpenGL is a trademark of Silicon Graphics Incorporated.
+
+License / Copyright Information
+
+The Mesa distribution consists of several components. Different copyrights
+and licenses apply to different components. For example, GLUT is copyrighted
+by Mark Kilgard, some demo programs are copyrighted by SGI, some of the Mesa
+device drivers are copyrighted by their authors. See below for a list of
+Mesa's main components and the license for each.
+
+The core Mesa library is licensed according to the terms of the MIT license.
+This allows integration with the XFree86, Xorg and DRI projects.
+
+The default Mesa license is as follows:
+
+Copyright (C) 1999-2007 Brian Paul All Rights Reserved.
+
+Permission is hereby granted, free of charge, to any person obtaining a
+copy of this software and associated documentation files (the "Software"),
+to deal in the Software without restriction, including without limitation
+the rights to use, copy, modify, merge, publish, distribute, sublicense,
+and/or sell copies of the Software, and to permit persons to whom the
+Software is furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included
+in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
+BRIAN PAUL BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
+AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
+CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+Attention, Contributors
+
+When contributing to the Mesa project you must agree to the licensing terms
+of the component to which you're contributing.
+The following section lists the primary components of the Mesa distribution
+and their respective licenses.
+
+
+Mesa Component Licenses
+
+Component Location Primary Author License
+----------------------------------------------------------------------------
+Main Mesa code src/mesa/ Brian Paul Mesa (MIT)
+
+Device drivers src/mesa/drivers/* See drivers See drivers
+
+Ext headers include/GL/glext.h SGI SGI Free B
+ include/GL/glxext.h
+
+GLUT src/glut/ Mark Kilgard Mark's copyright
+
+Mesa GLU library src/glu/mesa/ Brian Paul GNU-LGPL
+
+SGI GLU library src/glu/sgi/ SGI SGI Free B
+
+demo programs progs/demos/ various see source files
+
+X demos progs/xdemos/ Brian Paul see source files
+
+SGI demos progs/samples/ SGI SGI copyright
+
+RedBook demos progs/redbook/ SGI SGI copyright
diff --git a/staging/mesa/PKGBUILD b/staging/mesa/PKGBUILD
new file mode 100644
index 000000000..7bcb4ad10
--- /dev/null
+++ b/staging/mesa/PKGBUILD
@@ -0,0 +1,268 @@
+# $Id: PKGBUILD 159718 2012-05-26 09:28:14Z andyrtr $
+# Maintainer: Jan de Groot <jgc@archlinux.org>
+# Maintainer: Andreas Radke <andyrtr@archlinux.org>
+
+pkgbase=mesa
+pkgname=('mesa' 'libgl' 'osmesa' 'libglapi' 'libgbm' 'libgles' 'libegl' 'khrplatform-devel' 'ati-dri' 'intel-dri' 'nouveau-dri' 'svga-dri')
+
+#_git=true
+_gitdate=20111031
+_git=false
+
+if [ "${_git}" = "true" ]; then
+ pkgver=7.10.99.git20110709
+ #pkgver=7.11
+ else
+ pkgver=8.0.3
+fi
+pkgrel=2
+arch=('i686' 'x86_64')
+makedepends=('glproto>=1.4.15' 'libdrm>=2.4.30' 'libxxf86vm>=1.1.1' 'libxdamage>=1.1.3' 'expat>=2.0.1' 'libx11>=1.4.99.1' 'libxt>=1.1.1'
+ 'gcc-libs>=4.6.1' 'dri2proto>=2.6' 'python2' 'libxml2' 'imake' 'llvm' 'udev>=183')
+url="http://mesa3d.sourceforge.net"
+license=('custom')
+source=(LICENSE
+ mesa-8.0.3-llvm-3.1-fixes.patch)
+if [ "${_git}" = "true" ]; then
+ # mesa git shot from 7.11 branch - see for state: http://cgit.freedesktop.org/mesa/mesa/commit/?h=7.11&id=1ae00c5960af83bea9545a18a1754bad83d5cbd0
+ #source=(${source[@]} 'ftp://ftp.archlinux.org/other/mesa/mesa-1ae00c5960af83bea9545a18a1754bad83d5cbd0.tar.bz2')
+ source=(${source[@]} "MesaLib-git${_gitdate}.zip"::"http://cgit.freedesktop.org/mesa/mesa/snapshot/mesa-ef9f16f6322a89fb699fbe3da868b10f9acaef98.tar.bz2")
+ else
+ source=(${source[@]} "ftp://ftp.freedesktop.org/pub/mesa/${pkgver}/MesaLib-${pkgver}.tar.bz2"
+ #source=(${source[@]} "ftp://ftp.freedesktop.org/pub/mesa/8.0/MesaLib-8.0-rc2.tar.bz2"
+ #source=(${source[@]} "MesaLib-git${_gitdate}.zip"::"http://cgit.freedesktop.org/mesa/mesa/snapshot/mesa-4464ee1a9aa3745109cee23531e3fb2323234d07.tar.bz2"
+)
+fi
+md5sums=('5c65a0fe315dd347e09b1f2826a1df5a'
+ 'c452ed3392468170726c004c2f4e02ca'
+ 'cc5ee15e306b8c15da6a478923797171')
+
+build() {
+ cd ${srcdir}/?esa-*
+
+ patch -Np1 -i "${srcdir}/mesa-8.0.3-llvm-3.1-fixes.patch"
+
+if [ "${_git}" = "true" ]; then
+ autoreconf -vfi
+ ./autogen.sh --prefix=/usr \
+ --with-dri-driverdir=/usr/lib/xorg/modules/dri \
+ --with-gallium-drivers=r300,r600,nouveau,svga,swrast \
+ --enable-gallium-llvm \
+ --enable-gallium-egl \
+ --enable-shared-glapi \
+ --enable-gbm \
+ --enable-glx-tls \
+ --enable-dri \
+ --enable-glx \
+ --enable-osmesa \
+ --enable-gles1 \
+ --enable-gles2 \
+ --enable-egl \
+ --enable-texture-float \
+ --enable-xa \
+ --enable-shared-dricore
+ #--enable-gbm \
+ # --enable-gallium-svga \
+
+ else
+ autoreconf -vfi
+ ./configure --prefix=/usr \
+ --with-dri-driverdir=/usr/lib/xorg/modules/dri \
+ --with-gallium-drivers=r300,r600,nouveau,svga,swrast \
+ --enable-gallium-llvm \
+ --enable-gallium-egl \
+ --enable-shared-glapi \
+ --enable-gbm \
+ --enable-glx-tls \
+ --enable-dri \
+ --enable-glx \
+ --enable-osmesa \
+ --enable-gles1 \
+ --enable-gles2 \
+ --enable-egl \
+ --enable-texture-float \
+ --enable-xa \
+ --enable-shared-dricore
+fi
+
+ make
+}
+
+package_libgl() {
+ depends=('libdrm>=2.4.31' 'libxxf86vm>=1.1.1' 'libxdamage>=1.1.3' 'expat>=2.0.1' 'libglapi' 'gcc-libs')
+ pkgdesc="Mesa 3-D graphics library and DRI software rasterizer"
+ #replaces=('unichrome-dri' 'mach64-dri' 'mga-dri' 'r128-dri' 'savage-dri' 'sis-dri' 'tdfx-dri')
+
+ cd ${srcdir}/?esa-*
+ install -m755 -d "${pkgdir}/usr/lib"
+ install -m755 -d "${pkgdir}/usr/lib/xorg/modules/extensions"
+
+ bin/minstall lib/libGL.so* "${pkgdir}/usr/lib/"
+ bin/minstall lib/libdricore.so* "${pkgdir}/usr/lib/"
+ bin/minstall lib/libglsl.so* "${pkgdir}/usr/lib/"
+
+ cd src/mesa/drivers/dri
+ make -C ${srcdir}/?esa-*/src/gallium/targets/dri-swrast DESTDIR="${pkgdir}" install
+
+ ln -s libglx.xorg "${pkgdir}/usr/lib/xorg/modules/extensions/libglx.so"
+
+ install -m755 -d "${pkgdir}/usr/share/licenses/libgl"
+ install -m644 "${srcdir}/LICENSE" "${pkgdir}/usr/share/licenses/libgl/"
+}
+
+package_osmesa() {
+ depends=('mesa')
+ optdepends=('opengl-man-pages: for the OpenGL API man pages')
+ pkgdesc="Mesa 3D off-screen rendering library"
+
+ make -C ${srcdir}/?esa-*/src/mesa DESTDIR="${pkgdir}" install-osmesa
+}
+
+package_libglapi() {
+ depends=('glibc')
+ pkgdesc="free implementation of the GL API -- shared library. The Mesa GL API module is responsible for dispatching all the gl* functions"
+
+ cd ${srcdir}/?esa-*
+ install -m755 -d "${pkgdir}/usr/lib"
+ bin/minstall lib/libglapi.so* "${pkgdir}/usr/lib/"
+
+ install -m755 -d "${pkgdir}/usr/share/licenses/libglapi"
+ install -m644 "${srcdir}/LICENSE" "${pkgdir}/usr/share/licenses/libglapi/"
+}
+
+package_libgbm() {
+ depends=('glibc')
+ pkgdesc="Mesa gbm library"
+
+ cd ${srcdir}/?esa-*
+ install -m755 -d "${pkgdir}/usr/lib"
+ bin/minstall lib/libgbm.so* "${pkgdir}/usr/lib/"
+ install -m755 -d "${pkgdir}/usr/lib/pkgconfig"
+ bin/minstall src/gbm/main/gbm.pc "${pkgdir}/usr/lib/pkgconfig/"
+
+ install -m755 -d "${pkgdir}/usr/share/licenses/libgbm"
+ install -m644 "${srcdir}/LICENSE" "${pkgdir}/usr/share/licenses/libgbm/"
+}
+
+package_libgles() {
+ depends=('libglapi' 'khrplatform-devel')
+ pkgdesc="Mesa GLES libraries and headers"
+
+ cd ${srcdir}/?esa-*
+ install -m755 -d "${pkgdir}/usr/lib"
+ install -m755 -d "${pkgdir}/usr/lib/pkgconfig"
+ install -m755 -d "${pkgdir}/usr/include"
+ install -m755 -d "${pkgdir}/usr/include/GLES"
+ install -m755 -d "${pkgdir}/usr/include/GLES2"
+ bin/minstall lib/libGLESv* "${pkgdir}/usr/lib/"
+ bin/minstall src/mapi/es1api/glesv1_cm.pc "${pkgdir}/usr/lib/pkgconfig/"
+ bin/minstall src/mapi/es2api/glesv2.pc "${pkgdir}/usr/lib/pkgconfig/"
+ bin/minstall include/GLES/* "${pkgdir}/usr/include/GLES/"
+ bin/minstall include/GLES2/* "${pkgdir}/usr/include/GLES2/"
+ bin/minstall include/GLES2/* "${pkgdir}/usr/include/GLES2/"
+
+ install -m755 -d "${pkgdir}/usr/share/licenses/libgles"
+ install -m644 "${srcdir}/LICENSE" "${pkgdir}/usr/share/licenses/libgles/"
+}
+
+package_libegl() {
+ depends=('libglapi' 'libdrm' 'libxext' 'libxfixes' 'udev' 'khrplatform-devel')
+ pkgdesc="Mesa EGL libraries and headers"
+
+ cd ${srcdir}/?esa-*
+ make -C src/gallium/targets/egl-static DESTDIR="${pkgdir}" install
+ install -m755 -d "${pkgdir}/usr/lib"
+ install -m755 -d "${pkgdir}/usr/lib/pkgconfig"
+ install -m755 -d "${pkgdir}/usr/include"
+ install -m755 -d "${pkgdir}/usr/include/"
+ install -m755 -d "${pkgdir}/usr/include/EGL"
+ install -m755 -d "${pkgdir}/usr/share"
+ install -m755 -d "${pkgdir}/usr/share/doc"
+ install -m755 -d "${pkgdir}/usr/share/doc/libegl"
+ bin/minstall lib/libEGL.so* "${pkgdir}/usr/lib/"
+ install -m755 -d "${pkgdir}/usr/lib/egl"
+ bin/minstall lib/egl/* "${pkgdir}/usr/lib/egl/"
+ bin/minstall src/egl/main/egl.pc "${pkgdir}/usr/lib/pkgconfig/"
+ bin/minstall include/EGL/* "${pkgdir}/usr/include/EGL/"
+ bin/minstall docs/egl.html "${pkgdir}/usr/share/doc/libegl/"
+
+ install -m755 -d "${pkgdir}/usr/share/licenses/libegl"
+ install -m644 "${srcdir}/LICENSE" "${pkgdir}/usr/share/licenses/libegl/"
+}
+
+package_khrplatform-devel() {
+ #depends=('')
+ pkgdesc="Khronos platform development package"
+
+ cd ${srcdir}/?esa-*
+ install -m755 -d "${pkgdir}/usr/include/KHR"
+ bin/minstall include/KHR/khrplatform.h "${pkgdir}/usr/include/KHR/"
+
+ install -m755 -d "${pkgdir}/usr/share/licenses/khrplatform-devel"
+ install -m644 "${srcdir}/LICENSE" "${pkgdir}/usr/share/licenses/khrplatform-devel/"
+}
+
+package_mesa() {
+ depends=('libgl' 'libx11>=1.4.3' 'libxt>=1.1.1' 'gcc-libs>=4.6' 'dri2proto>=2.6' 'glproto>=1.4.14') #dri2proto + glproto needed for gl.pc
+ optdepends=('opengl-man-pages: for the OpenGL API man pages')
+ pkgdesc="Mesa 3-D graphics libraries and include files"
+
+ cd ${srcdir}/?esa-*
+ make DESTDIR="${pkgdir}" install
+
+ rm -f "${pkgdir}/usr/lib/libGL.so"*
+ rm -f "${pkgdir}/usr/lib/libglapi.so"*
+ rm -f "${pkgdir}/usr/lib/libgbm.so"*
+ rm -f "${pkgdir}/usr/lib/libGLESv"*
+ rm -f "${pkgdir}/usr/lib/libEGL"*
+ rm -rf "${pkgdir}/usr/lib/egl"
+ rm -f "${pkgdir}/usr/lib/libOSMesa"*
+ rm -f ${pkgdir}/usr/lib/pkgconfig/{glesv1_cm.pc,glesv2.pc,egl.pc,osmesa.pc,gbm.pc}
+ rm -rf "${pkgdir}/usr/lib/xorg"
+ rm -f "${pkgdir}/usr/include/GL/glew.h"
+ rm -f "${pkgdir}/usr/include/GL/glxew.h"
+ rm -f "${pkgdir}/usr/include/GL/wglew.h"
+ rm -f "${pkgdir}/usr/include/GL/glut.h"
+ rm -rf ${pkgdir}/usr/include/{GLES,GLES2,EGL,KHR}
+
+ install -m755 -d "${pkgdir}/usr/share/licenses/mesa"
+ install -m644 "${srcdir}/LICENSE" "${pkgdir}/usr/share/licenses/mesa/"
+}
+
+package_ati-dri() {
+ depends=("libgl=${pkgver}")
+ pkgdesc="Mesa DRI radeon/r200 + Gallium3D r300,r600 drivers for AMD/ATI Radeon"
+ conflicts=('xf86-video-ati<6.9.0-6')
+
+ # classic mesa drivers for radeon,r200
+ make -C ${srcdir}/?esa-*/src/mesa/drivers/dri/radeon DESTDIR="${pkgdir}" install
+ make -C ${srcdir}/?esa-*/src/mesa/drivers/dri/r200 DESTDIR="${pkgdir}" install
+ # gallium3D driver for r300,r600
+ make -C ${srcdir}/?esa-*/src/gallium/targets/dri-r300 DESTDIR="${pkgdir}" install
+ make -C ${srcdir}/?esa-*/src/gallium/targets/dri-r600 DESTDIR="${pkgdir}" install
+}
+
+package_intel-dri() {
+ depends=("libgl=${pkgver}")
+ pkgdesc="Mesa DRI drivers for Intel"
+
+ make -C ${srcdir}/?esa-*/src/mesa/drivers/dri/i915 DESTDIR="${pkgdir}" install
+ make -C ${srcdir}/?esa-*/src/mesa/drivers/dri/i965 DESTDIR="${pkgdir}" install
+}
+
+package_nouveau-dri() {
+ depends=("libgl=${pkgver}")
+ pkgdesc="Mesa classic DRI + Gallium3D drivers for Nouveau"
+
+ # classic mesa driver for nv10 , nv20 nouveau_vieux_dri.so
+ make -C ${srcdir}/?esa-*/src/mesa/drivers/dri/nouveau DESTDIR="${pkgdir}" install
+ # gallium3D driver for nv30 - nv40 - nv50 nouveau_dri.so
+ make -C ${srcdir}/?esa-*/src/gallium/targets/dri-nouveau DESTDIR="${pkgdir}" install
+}
+
+package_svga-dri() {
+ depends=("mesa=${pkgver}")
+ pkgdesc="Gallium3D VMware guest GL driver"
+
+ make -C ${srcdir}/?esa-*/src/gallium/targets/dri-vmwgfx DESTDIR="${pkgdir}" install
+}
diff --git a/staging/mesa/mesa-8.0.3-llvm-3.1-fixes.patch b/staging/mesa/mesa-8.0.3-llvm-3.1-fixes.patch
new file mode 100644
index 000000000..a567b5926
--- /dev/null
+++ b/staging/mesa/mesa-8.0.3-llvm-3.1-fixes.patch
@@ -0,0 +1,46 @@
+diff --git a/src/gallium/auxiliary/gallivm/lp_bld_debug.cpp b/src/gallium/auxiliary/gallivm/lp_bld_debug.cpp
+index a50a51d..f1bb4d9 100644
+--- a/src/gallium/auxiliary/gallivm/lp_bld_debug.cpp
++++ b/src/gallium/auxiliary/gallivm/lp_bld_debug.cpp
+@@ -235,7 +235,24 @@ lp_disassemble(const void* func)
+ int AsmPrinterVariant = AsmInfo->getAssemblerDialect();
+ #endif
+
+-#if HAVE_LLVM >= 0x0300
++#if HAVE_LLVM >= 0x0301
++ OwningPtr<const MCRegisterInfo> MRI(T->createMCRegInfo(Triple));
++ if (!MRI) {
++ debug_printf("error: no register info for target %s\n", Triple.c_str());
++ return;
++ }
++
++ OwningPtr<const MCInstrInfo> MII(T->createMCInstrInfo());
++ if (!MII) {
++ debug_printf("error: no instruction info for target %s\n", Triple.c_str());
++ return;
++ }
++#endif
++
++#if HAVE_LLVM >= 0x0301
++ OwningPtr<MCInstPrinter> Printer(
++ T->createMCInstPrinter(AsmPrinterVariant, *AsmInfo, *MII, *MRI, *STI));
++#elif HAVE_LLVM == 0x0300
+ OwningPtr<MCInstPrinter> Printer(
+ T->createMCInstPrinter(AsmPrinterVariant, *AsmInfo, *STI));
+ #elif HAVE_LLVM >= 0x0208
+diff --git a/src/gallium/auxiliary/gallivm/lp_bld_misc.cpp b/src/gallium/auxiliary/gallivm/lp_bld_misc.cpp
+index fe7616b..68f8808 100644
+--- a/src/gallium/auxiliary/gallivm/lp_bld_misc.cpp
++++ b/src/gallium/auxiliary/gallivm/lp_bld_misc.cpp
+@@ -62,7 +62,11 @@
+ extern "C" void
+ lp_register_oprofile_jit_event_listener(LLVMExecutionEngineRef EE)
+ {
++#if HAVE_LLVM >= 0x0301
++ llvm::unwrap(EE)->RegisterJITEventListener(llvm::JITEventListener::createOProfileJITEventListener());
++#else
+ llvm::unwrap(EE)->RegisterJITEventListener(llvm::createOProfileJITEventListener());
++#endif
+ }
+
+
diff --git a/staging/mod_perl/PKGBUILD b/staging/mod_perl/PKGBUILD
new file mode 100644
index 000000000..1802ed461
--- /dev/null
+++ b/staging/mod_perl/PKGBUILD
@@ -0,0 +1,45 @@
+# $Id: PKGBUILD 159775 2012-05-26 19:41:32Z foutrelis $
+# Maintainer:
+# Contributor: Firmicus <francois.archlinux.org>
+# Contributor: Tom K <tomk@runbox.com>
+
+pkgname=mod_perl
+pkgver=2.0.6
+pkgrel=1
+pkgdesc="Apache module that embeds the Perl interpreter within the server"
+arch=('i686' 'x86_64')
+url="http://perl.apache.org/"
+license=('APACHE')
+depends=('perl' 'apache' 'db' 'apr-util' 'perl-linux-pid')
+options=('!emptydirs')
+source=(http://perl.apache.org/dist/$pkgname-$pkgver.tar.gz
+ mod_perl-2.0.6-nolfs.patch
+ mod_perl-2.0.6-perl-5.16-fixes.patch)
+sha256sums=('8cf768d2c55291e10542ef8d9a4f4ebe835365e43b4584771e654079405827dc'
+ '5d1b6a051d847108b23b5dc06ea5885c37dd81d3a9156b69d179d95b5cf92f08'
+ 'c6cde22806b1b2d919545b21c49536c8c377c8d1f921e8948e1289bb2ab413d9')
+
+build() {
+ cd "$srcdir/$pkgname-$pkgver"
+
+ # Patch from openSUSE to fix segfaults on i686 (FS#25008):
+ # avoid a conflict between apache's LARGEFILE64_SOURCE and perl's
+ # FILE_OFFSET_BITS=64 because the conflict isn't real and causes the perl
+ # structures to be invalid if only the apache flags are used
+ patch -Np1 -i "$srcdir/mod_perl-2.0.6-nolfs.patch"
+
+ # Fix build with Perl 5.16
+ # http://search.cpan.org/dist/perl-5.16.0/pod/perldelta.pod#$%3C,_$%3E,_$%28_and_$%29_are_no_longer_cached
+ patch -Np1 -i "$srcdir/mod_perl-2.0.6-perl-5.16-fixes.patch"
+
+ # install module in vendor directories.
+ perl Makefile.PL INSTALLDIRS=vendor MP_APXS=/usr/sbin/apxs
+ make
+}
+
+package() {
+ cd "$srcdir/$pkgname-$pkgver"
+ make install DESTDIR="$pkgdir"
+}
+
+# vim:set ts=2 sw=2 et:
diff --git a/staging/mod_perl/mod_perl-2.0.6-nolfs.patch b/staging/mod_perl/mod_perl-2.0.6-nolfs.patch
new file mode 100644
index 000000000..13e5cccee
--- /dev/null
+++ b/staging/mod_perl/mod_perl-2.0.6-nolfs.patch
@@ -0,0 +1,13 @@
+diff -upr mod_perl-2.0.6.orig/lib/Apache2/Build.pm mod_perl-2.0.6/lib/Apache2/Build.pm
+--- mod_perl-2.0.6.orig/lib/Apache2/Build.pm 2012-05-26 22:31:00.000000000 +0300
++++ mod_perl-2.0.6/lib/Apache2/Build.pm 2012-05-26 22:31:32.000000000 +0300
+@@ -2207,7 +2207,8 @@ sub has_large_files_conflict {
+ # with it is that we didn't have such a case yet, but may need to
+ # deal with it later
+
+- return $perl_lfs64 ^ $apr_lfs64;
++ return 0;
++ # $perl_lfs64 ^ $apr_lfs64;
+ }
+
+ # if perl is built with uselargefiles, but apr not, the build won't
diff --git a/staging/mod_perl/mod_perl-2.0.6-perl-5.16-fixes.patch b/staging/mod_perl/mod_perl-2.0.6-perl-5.16-fixes.patch
new file mode 100644
index 000000000..4e26fd87d
--- /dev/null
+++ b/staging/mod_perl/mod_perl-2.0.6-perl-5.16-fixes.patch
@@ -0,0 +1,17 @@
+diff -upr mod_perl-2.0.6.orig/src/modules/perl/modperl_perl.c mod_perl-2.0.6/src/modules/perl/modperl_perl.c
+--- mod_perl-2.0.6.orig/src/modules/perl/modperl_perl.c 2012-05-26 21:49:27.000000000 +0300
++++ mod_perl-2.0.6/src/modules/perl/modperl_perl.c 2012-05-26 21:55:39.000000000 +0300
+@@ -102,13 +102,4 @@ static void modperl_perl_init_ids(pTHX_
+ sv_setiv(GvSV(gv_fetchpv("$", TRUE, SVt_PV)), ids->pid);
+
+-#ifndef WIN32
+- PL_uid = ids->uid;
+- PL_euid = ids->euid;
+- PL_gid = ids->gid;
+- PL_egid = ids->egid;
+-#endif
+-#ifdef MP_MAINTAIN_PPID
+- PL_ppid = ids->ppid;
+-#endif
+ }
+
diff --git a/staging/net-snmp/PKGBUILD b/staging/net-snmp/PKGBUILD
new file mode 100644
index 000000000..e9930ec14
--- /dev/null
+++ b/staging/net-snmp/PKGBUILD
@@ -0,0 +1,58 @@
+# $Id: PKGBUILD 159781 2012-05-26 20:12:07Z foutrelis $
+# Maintainer:
+# Contributor: Dale Blount <dale@archlinux.org>
+
+pkgname=net-snmp
+pkgver=5.7.1
+pkgrel=3
+pkgdesc="A suite of applications used to implement SNMP v1, SNMP v2c and SNMP v3 using both IPv4 and IPv6"
+arch=('i686' 'x86_64')
+url="http://www.net-snmp.org/"
+license=('BSD')
+depends=('openssl' 'libnl' 'pciutils')
+makedepends=('python2-distribute')
+optdepends=('perl-term-readkey: for snmpcheck application'
+ 'perl-tk: for snmpcheck and tkmib applications'
+ 'python2: for the python modules')
+provides=('ucd-snmp')
+backup=('etc/conf.d/snmpd')
+options=('!libtool' '!makeflags' '!emptydirs')
+source=(http://downloads.sourceforge.net/${pkgname}/${pkgname}-${pkgver}.tar.gz{,.asc}
+ snmpd.confd snmpd.rc libnl32.patch)
+sha1sums=('ddb82ce1112ef0642869d3c8d7c7e585f151849a'
+ '2bdc2839ce09d7daa608cd54687fa8beb47ed907'
+ 'cf811da9e57bbca34d8e2a3c358bb3bfc0c2b33b'
+ '90600c0141eed10d6e3ca3ccc97ad8dda15c2112'
+ '74a9848b95f63378eb1753fc309d2b74de5afb0f')
+
+build() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
+
+ # http://sourceforge.net/tracker/index.php?func=detail&aid=3250304&group_id=12694&atid=112694
+ patch -Np1 -i "$srcdir/libnl32.patch"
+ autoreconf -f -i
+
+ sed -i -e "s:\(install --basedir=\$\$dir\):\1 --root='${pkgdir}':" Makefile.in
+ PYTHONPROG=/usr/bin/python2 ./configure --prefix=/usr \
+ --sysconfdir=/etc \
+ --mandir=/usr/share/man \
+ --enable-ucd-snmp-compatibility \
+ --enable-ipv6 \
+ --with-python-modules \
+ --with-default-snmp-version="3" \
+ --with-sys-contact="root@localhost" \
+ --with-sys-location="Unknown" \
+ --with-logfile="/var/log/snmpd.log" \
+ --with-mib-modules="host misc/ipfwacc ucd-snmp/diskio tunnel ucd-snmp/dlmod" \
+ --with-persistent-directory="/var/net-snmp" \
+ --disable-static
+ make NETSNMP_DONT_CHECK_VERSION=1
+}
+
+package() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
+ make DESTDIR="${pkgdir}" INSTALL_PREFIX="${pkgdir}" INSTALLDIRS=vendor install
+ install -D -m755 "${srcdir}/snmpd.rc" "${pkgdir}/etc/rc.d/snmpd"
+ install -D -m644 "${srcdir}/snmpd.confd" "${pkgdir}/etc/conf.d/snmpd"
+ install -D -m644 COPYING "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
+}
diff --git a/staging/net-snmp/libnl32.patch b/staging/net-snmp/libnl32.patch
new file mode 100644
index 000000000..d93d7ef67
--- /dev/null
+++ b/staging/net-snmp/libnl32.patch
@@ -0,0 +1,80 @@
+diff -u -r net-snmp-5.7.1/agent/mibgroup/mibII/tcpTable.c net-snmp-5.7.1-libnl32/agent/mibgroup/mibII/tcpTable.c
+--- net-snmp-5.7.1/agent/mibgroup/mibII/tcpTable.c 2011-09-28 06:53:47.000000000 +0200
++++ net-snmp-5.7.1-libnl32/agent/mibgroup/mibII/tcpTable.c 2012-02-09 20:02:49.136022132 +0100
+@@ -566,8 +566,9 @@
+ static int
+ tcpTable_load_netlink(void)
+ {
++ int err;
+ /* TODO: perhaps use permanent nl handle? */
+- struct nl_handle *nl = nl_handle_alloc();
++ struct nl_sock *nl = nl_socket_alloc();
+
+ if (nl == NULL) {
+ DEBUGMSGTL(("mibII/tcpTable", "Failed to allocate netlink handle\n"));
+@@ -575,10 +576,10 @@
+ return -1;
+ }
+
+- if (nl_connect(nl, NETLINK_INET_DIAG) < 0) {
+- DEBUGMSGTL(("mibII/tcpTable", "Failed to connect to netlink: %s\n", nl_geterror()));
+- snmp_log(LOG_ERR, "snmpd: Couldn't connect to netlink: %s\n", nl_geterror());
+- nl_handle_destroy(nl);
++ if ((err = nl_connect(nl, NETLINK_INET_DIAG)) < 0) {
++ DEBUGMSGTL(("mibII/tcpTable", "Failed to connect to netlink: %s\n", nl_geterror(err)));
++ snmp_log(LOG_ERR, "snmpd: Couldn't connect to netlink: %s\n", nl_geterror(err));
++ nl_socket_free(nl);
+ return -1;
+ }
+
+@@ -590,10 +591,10 @@
+ struct nl_msg *nm = nlmsg_alloc_simple(TCPDIAG_GETSOCK, NLM_F_ROOT|NLM_F_MATCH|NLM_F_REQUEST);
+ nlmsg_append(nm, &req, sizeof(struct inet_diag_req), 0);
+
+- if (nl_send_auto_complete(nl, nm) < 0) {
+- DEBUGMSGTL(("mibII/tcpTable", "nl_send_autocomplete(): %s\n", nl_geterror()));
+- snmp_log(LOG_ERR, "snmpd: nl_send_autocomplete(): %s\n", nl_geterror());
+- nl_handle_destroy(nl);
++ if ((err = nl_send_auto_complete(nl, nm)) < 0) {
++ DEBUGMSGTL(("mibII/tcpTable", "nl_send_autocomplete(): %s\n", nl_geterror(err)));
++ snmp_log(LOG_ERR, "snmpd: nl_send_autocomplete(): %s\n", nl_geterror(err));
++ nl_socket_free(nl);
+ return -1;
+ }
+ nlmsg_free(nm);
+@@ -604,9 +605,9 @@
+
+ while (running) {
+ if ((len = nl_recv(nl, &peer, &buf, NULL)) <= 0) {
+- DEBUGMSGTL(("mibII/tcpTable", "nl_recv(): %s\n", nl_geterror()));
+- snmp_log(LOG_ERR, "snmpd: nl_recv(): %s\n", nl_geterror());
+- nl_handle_destroy(nl);
++ DEBUGMSGTL(("mibII/tcpTable", "nl_recv(): %s\n", nl_geterror(len)));
++ snmp_log(LOG_ERR, "snmpd: nl_recv(): %s\n", nl_geterror(len));
++ nl_socket_free(nl);
+ return -1;
+ }
+
+@@ -655,7 +656,7 @@
+ free(buf);
+ }
+
+- nl_handle_destroy(nl);
++ nl_socket_free(nl);
+
+ if (tcp_head) {
+ DEBUGMSGTL(("mibII/tcpTable", "Loaded TCP Table using netlink\n"));
+diff -u -r net-snmp-5.7.1/configure.d/config_os_libs2 net-snmp-5.7.1-libnl32/configure.d/config_os_libs2
+--- net-snmp-5.7.1/configure.d/config_os_libs2 2011-09-28 06:53:47.000000000 +0200
++++ net-snmp-5.7.1-libnl32/configure.d/config_os_libs2 2012-02-09 20:10:44.282165275 +0100
+@@ -224,8 +224,9 @@
+ if test "x$with_nl" != "xno"; then
+ case $target_os in
+ linux*) # Check for libnl (linux)
++ CPPFLAGS="$CPPFLAGS $(pkg-config --cflags-only-I libnl-3.0)"
+ NETSNMP_SEARCH_LIBS(
+- nl_connect, nl,
++ nl_connect, nl-3,
+ [AC_CHECK_HEADERS(netlink/netlink.h)],,, LMIBLIBS)
+ ;;
+ esac
diff --git a/staging/net-snmp/snmpd.confd b/staging/net-snmp/snmpd.confd
new file mode 100644
index 000000000..926b09bbf
--- /dev/null
+++ b/staging/net-snmp/snmpd.confd
@@ -0,0 +1,5 @@
+#
+# Parameters to be passed to snmpd
+#
+SNMPD_ARGS=""
+
diff --git a/staging/net-snmp/snmpd.rc b/staging/net-snmp/snmpd.rc
new file mode 100644
index 000000000..b00c09f4f
--- /dev/null
+++ b/staging/net-snmp/snmpd.rc
@@ -0,0 +1,39 @@
+#!/bin/bash
+
+. /etc/rc.conf
+. /etc/rc.d/functions
+. /etc/conf.d/snmpd
+
+PID=`pidof -o %PPID /usr/sbin/snmpd`
+case "$1" in
+ start)
+ stat_busy "Starting Net-SNMP"
+ [ -z "$PID" ] && /usr/sbin/snmpd $SNMPD_ARGS
+ if [ $? -gt 0 ]; then
+ stat_fail
+ else
+ echo $PID > /var/run/snmpd.pid
+ add_daemon snmpd
+ stat_done
+ fi
+ ;;
+ stop)
+ stat_busy "Stopping Net-SNMP"
+ [ ! -z "$PID" ] && kill $PID &> /dev/null
+ if [ $? -gt 0 ]; then
+ stat_fail
+ else
+ rm /var/run/snmpd.pid
+ rm_daemon snmpd
+ stat_done
+ fi
+ ;;
+ restart)
+ $0 stop
+ sleep 2
+ $0 start
+ ;;
+ *)
+ echo "usage: $0 {start|stop|restart}"
+esac
+exit 0
diff --git a/staging/pango-perl/PKGBUILD b/staging/pango-perl/PKGBUILD
new file mode 100644
index 000000000..64805ec07
--- /dev/null
+++ b/staging/pango-perl/PKGBUILD
@@ -0,0 +1,31 @@
+# $Id: PKGBUILD 159745 2012-05-26 12:16:38Z bluewind $
+# Maintainer: Jan de Groot <jgc@archlinux.org>
+
+pkgname=pango-perl
+pkgver=1.223
+pkgrel=2
+pkgdesc="Perl bindings for Pango"
+arch=(i686 x86_64)
+license=('LGPL')
+url="http://gtk2-perl.sourceforge.net/"
+makedepends=('perl-extutils-pkgconfig' 'perl-extutils-depends')
+depends=('pango' 'glib-perl' 'cairo-perl')
+options=('!emptydirs')
+source=(http://downloads.sourceforge.net/sourceforge/gtk2-perl/Pango-${pkgver}.tar.gz)
+md5sums=('628a6de54f47b6791c6b45edfb835215')
+
+build() {
+ cd "${srcdir}/Pango-${pkgver}"
+ PERL_MM_USE_DEFAULT=1 perl Makefile.PL INSTALLDIRS=vendor
+ make
+}
+
+check() {
+ cd "${srcdir}/Pango-${pkgver}"
+ make test
+}
+
+package() {
+ cd "${srcdir}/Pango-${pkgver}"
+ make install DESTDIR="${pkgdir}"
+}
diff --git a/staging/perl-async-interrupt/PKGBUILD b/staging/perl-async-interrupt/PKGBUILD
new file mode 100644
index 000000000..1fa3cdbda
--- /dev/null
+++ b/staging/perl-async-interrupt/PKGBUILD
@@ -0,0 +1,47 @@
+# Packager: Justin Davis (juster) <jrcd83@gmail.com>
+# $Id: PKGBUILD 159729 2012-05-26 11:40:38Z bluewind $
+
+pkgname=perl-async-interrupt
+_ver=1.1
+pkgver=1.10
+pkgrel=2
+pkgdesc='allow C/XS libraries to interrupt perl asynchronously'
+arch=(i686 x86_64)
+license=(PerlArtistic GPL)
+options=(!emptydirs)
+depends=(perl-common-sense)
+url=https://metacpan.org/release/Async-Interrupt
+source=("http://search.cpan.org/CPAN/authors/id/M/ML/MLEHMANN/Async-Interrupt-$_ver.tar.gz")
+md5sums=(18f19b1537ecf5d6195a6a243110e64b)
+sha512sums=(e8e62efc053c8103f509c08a19bfa0fefbfe760ca4e1e4670187de4ed4fbdec2e5a9a19bba1696cd2b721ad7fa6d4b723c24e342118b69dc8b7b1597f5e1385e)
+_dir="$srcdir/Async-Interrupt-$_ver"
+
+build()
+(
+ cd "$_dir"
+ export PERL_MM_USE_DEFAULT=1 PERL_AUTOINSTALL=--skipdeps
+ unset PERL5LIB PERL_MM_OPT
+ /usr/bin/perl Makefile.PL
+ make
+)
+
+check()
+(
+ cd "$_dir"
+ export PERL_MM_USE_DEFAULT=1
+ unset PERL5LIB
+ make test
+)
+
+package()
+(
+ cd "$_dir"
+ make install INSTALLDIRS=vendor DESTDIR="$pkgdir"
+ find "$pkgdir" -name .packlist -o -name perllocal.pod -delete
+)
+
+# Local Variables:
+# mode: shell-script
+# sh-basic-offset: 2
+# End:
+# vim:set ts=2 sw=2 et:
diff --git a/staging/perl-ev/PKGBUILD b/staging/perl-ev/PKGBUILD
new file mode 100644
index 000000000..41e569b0d
--- /dev/null
+++ b/staging/perl-ev/PKGBUILD
@@ -0,0 +1,46 @@
+# Packager: Justin Davis (juster) <jrcd83@gmail.com>
+# $Id: PKGBUILD 159731 2012-05-26 11:42:13Z bluewind $
+
+pkgname=perl-ev
+pkgver=4.11
+pkgrel=2
+pkgdesc='perl interface to libev, a high performance full-featured event loop'
+arch=(i686 x86_64)
+license=(PerlArtistic GPL)
+options=(!emptydirs)
+depends=(perl-common-sense)
+url=https://metacpan.org/release/EV
+source=("http://search.cpan.org/CPAN/authors/id/M/ML/MLEHMANN/EV-$pkgver.tar.gz")
+md5sums=(405c6d74f9dff12918b12560c1a57877)
+sha512sums=(6aca3eeb617a313de7947b760558c12ed85af4fa8efd5bb4fd8bc2f271b4556312989aebf77cda4e212fd3b1351c268624aeaf2b1cf700507ff46c0c9dcc9db8)
+_dir="$srcdir/EV-$pkgver"
+
+build()
+(
+ cd "$_dir"
+ export PERL_MM_USE_DEFAULT=1 PERL_AUTOINSTALL=--skipdeps
+ unset PERL5LIB PERL_MM_OPT
+ /usr/bin/perl Makefile.PL
+ make
+)
+
+check()
+(
+ cd "$_dir"
+ export PERL_MM_USE_DEFAULT=1
+ unset PERL5LIB
+ make test
+)
+
+package()
+(
+ cd "$_dir"
+ make install INSTALLDIRS=vendor DESTDIR="$pkgdir"
+ find "$pkgdir" -name .packlist -o -name perllocal.pod -delete
+)
+
+# Local Variables:
+# mode: shell-script
+# sh-basic-offset: 2
+# End:
+# vim:set ts=2 sw=2 et:
diff --git a/staging/perl-guard/PKGBUILD b/staging/perl-guard/PKGBUILD
new file mode 100644
index 000000000..da440e55c
--- /dev/null
+++ b/staging/perl-guard/PKGBUILD
@@ -0,0 +1,48 @@
+# Packager: Justin Davis <jrcd83@gmail.com>
+# $Id: PKGBUILD 159733 2012-05-26 11:43:47Z bluewind $
+
+pkgname=perl-guard
+pkgver=1.022
+pkgrel=2
+pkgdesc="safe cleanup blocks"
+arch=(i686 x86_64)
+license=(custom:unknown)
+options=(!emptydirs)
+depends=('perl')
+url=https://metacpan.org/release/Guard
+source=("http://search.cpan.org/CPAN/authors/id/M/ML/MLEHMANN/Guard-${pkgver}.tar.gz")
+md5sums=(8d1d8b942fd5d0240f47906a6d6fac8c)
+sha512sums=(9eb1c4fa29f6190115fe11215ff5d27bb3e7f5ab60c7f40c4142ad9ff8aad91b0b169204e4d0f1b1638381c0c99e6a0b5627b8b6d60fad62f1392a9d1e49751e)
+_distdir="${srcdir}/Guard-${pkgver}"
+
+build() {
+ ( export PERL_MM_USE_DEFAULT=1 PERL5LIB="" \
+ PERL_AUTOINSTALL=--skipdeps \
+ PERL_MM_OPT="INSTALLDIRS=vendor DESTDIR='$pkgdir'" \
+ PERL_MB_OPT="--installdirs vendor --destdir '$pkgdir'" \
+ MODULEBUILDRC=/dev/null
+
+ cd "$_distdir"
+ /usr/bin/perl Makefile.PL
+ make
+ )
+}
+
+check() {
+ ( export PERL_MM_USE_DEFAULT=1 PERL5LIB=""
+ cd "$_distdir"
+ make test
+ )
+}
+
+package() {
+ cd "$_distdir"
+ make DESTDIR="$pkgdir" install
+ find "$pkgdir" -name .packlist -o -name perllocal.pod -delete
+}
+
+# Local Variables:
+# mode: shell-script
+# sh-basic-offset: 2
+# End:
+# vim:set ts=2 sw=2 et:
diff --git a/staging/perl-list-moreutils/PKGBUILD b/staging/perl-list-moreutils/PKGBUILD
new file mode 100644
index 000000000..3b0b7b33f
--- /dev/null
+++ b/staging/perl-list-moreutils/PKGBUILD
@@ -0,0 +1,49 @@
+# $Id: PKGBUILD 159735 2012-05-26 11:45:02Z bluewind $
+# Maintainer : Justin "juster" Davis <jrcd83@gmail.com>
+# Generator : pbjam 0.01
+
+pkgname=perl-list-moreutils
+pkgver=0.33
+pkgrel=3
+pkgdesc="Provide the stuff missing in List::Util"
+arch=(i686 x86_64)
+license=(PerlArtistic GPL)
+options=(!emptydirs)
+depends=('perl>=5.5.30')
+url=http://search.cpan.org/dist/List-MoreUtils
+source=("http://search.cpan.org/CPAN/authors/id/A/AD/ADAMK/List-MoreUtils-${pkgver}.tar.gz")
+md5sums=(8a33c84028cc2ff3e92c92434b326c0f)
+sha512sums=(e758b995438c5c5322317aab3602e89b9f683c42d403a0ac97ccd8cc20d0db1a75caefc22f34ad088314867c0bdd9c2b8264e8f2f6a43eab1421aa8c482233b5)
+_distdir="${srcdir}/List-MoreUtils-${pkgver}"
+
+build() {
+ ( export PERL_MM_USE_DEFAULT=1 PERL5LIB="" \
+ PERL_AUTOINSTALL=--skipdeps \
+ PERL_MM_OPT="INSTALLDIRS=vendor DESTDIR='$pkgdir'" \
+ PERL_MB_OPT="--installdirs vendor --destdir '$pkgdir'" \
+ MODULEBUILDRC=/dev/null
+
+ cd "$_distdir"
+ /usr/bin/perl Makefile.PL
+ make
+ )
+}
+
+check() {
+ ( export PERL_MM_USE_DEFAULT=1 PERL5LIB=""
+ cd "$_distdir"
+ make test
+ )
+}
+
+package() {
+ cd "$_distdir"
+ make DESTDIR="$pkgdir" install
+ find "$pkgdir" -name .packlist -o -name perllocal.pod -delete
+}
+
+# Local Variables:
+# mode: shell-script
+# sh-basic-offset: 2
+# End:
+# vim:set ts=2 sw=2 et:
diff --git a/staging/perl-socket6/PKGBUILD b/staging/perl-socket6/PKGBUILD
new file mode 100644
index 000000000..88c8acc07
--- /dev/null
+++ b/staging/perl-socket6/PKGBUILD
@@ -0,0 +1,49 @@
+# Maintainer: Florian Pritz <bluewind@xinu.at>
+# Generator : CPANPLUS::Dist::Arch 1.18
+
+pkgname='perl-socket6'
+pkgver='0.23'
+pkgrel='2'
+pkgdesc="getaddrinfo/getnameinfo support module"
+arch=('i686' 'x86_64')
+license=('PerlArtistic' 'GPL')
+options=('!emptydirs')
+depends=('perl')
+makedepends=()
+url='http://search.cpan.org/dist/Socket6'
+source=('http://search.cpan.org/CPAN/authors/id/U/UM/UMEMOTO/Socket6-0.23.tar.gz')
+md5sums=('2c02adb13c449d48d232bb704ddbd492')
+sha512sums=('39ced223ecdef89e6fa241031019bb5a73e63d2dfdaf3edb55bfea0cb81b91bea09f1cc26b2d15fa28d32227cc13cdb093c70f0ba346c9bdb523359de53d96f9')
+_distdir="${srcdir}/Socket6-0.23"
+
+build() {
+ ( export PERL_MM_USE_DEFAULT=1 PERL5LIB="" \
+ PERL_AUTOINSTALL=--skipdeps \
+ PERL_MM_OPT="INSTALLDIRS=vendor DESTDIR='$pkgdir'" \
+ PERL_MB_OPT="--installdirs vendor --destdir '$pkgdir'" \
+ MODULEBUILDRC=/dev/null
+
+ cd "$_distdir"
+ /usr/bin/perl Makefile.PL
+ make
+ )
+}
+
+check() {
+ cd "$_distdir"
+ ( export PERL_MM_USE_DEFAULT=1 PERL5LIB=""
+ make test
+ )
+}
+
+package() {
+ cd "$_distdir"
+ make install
+ find "$pkgdir" -name .packlist -o -name perllocal.pod -delete
+}
+
+# Local Variables:
+# mode: shell-script
+# sh-basic-offset: 2
+# End:
+# vim:set ts=2 sw=2 et:
diff --git a/staging/perl-template-toolkit/PKGBUILD b/staging/perl-template-toolkit/PKGBUILD
new file mode 100644
index 000000000..fdce31abc
--- /dev/null
+++ b/staging/perl-template-toolkit/PKGBUILD
@@ -0,0 +1,32 @@
+# Maintainer: Firmicus <francois.archlinux.org>
+# Contributor: Tom Killian <tomk@runbox.com>
+# Contributor: FJ <joostef@gmail.com>
+
+pkgname=perl-template-toolkit
+_realname=Template-Toolkit
+pkgver=2.22
+pkgrel=5
+pkgdesc="Perl template processing system"
+arch=(i686 x86_64)
+license=('PerlArtistic')
+url="http://search.cpan.org/dist/${_realname}/"
+depends=('perl-appconfig' 'perl>=5.10.0')
+options=(!emptydirs)
+source=(http://search.cpan.org/CPAN/authors/id/A/AB/ABW/${_realname}-$pkgver.tar.gz)
+md5sums=('d98277f6420e5da6b93d99a8db2b3934')
+
+build() {
+ cd ${srcdir}/${_realname}-$pkgver
+ # install module in vendor directories.
+ PERL_MM_USE_DEFAULT=1 perl Makefile.PL INSTALLDIRS=vendor
+ make
+}
+
+package() {
+ cd ${srcdir}/${_realname}-$pkgver
+ make install DESTDIR=${startdir}/pkg
+
+ # remove perllocal.pod and .packlist
+ find ${startdir}/pkg -name perllocal.pod -delete
+ find ${startdir}/pkg -name .packlist -delete
+}
diff --git a/staging/razor/PKGBUILD b/staging/razor/PKGBUILD
new file mode 100644
index 000000000..50d808a21
--- /dev/null
+++ b/staging/razor/PKGBUILD
@@ -0,0 +1,41 @@
+# $Id: PKGBUILD 159771 2012-05-26 18:11:56Z eric $
+# Maintainer:
+# Contributor: Dale Blount <dale@archlinux.org>
+# Contributor: Manolis Tzanidakis
+
+pkgname=razor
+pkgver=2.84
+pkgrel=7
+pkgdesc="A distributed, collaborative, spam detection and filtering network"
+arch=('i686' 'x86_64')
+url="http://razor.sourceforge.net"
+license=('PerlArtistic')
+depends=('perl-net-dns' 'perl-digest-sha1' 'perl-uri' 'perl-digest-nilsimsa' 'perl')
+options=('!emptydirs')
+source=("http://downloads.sourceforge.net/${pkgname}/${pkgname}-agents-${pkgver}.tar.bz2")
+md5sums=('8b9a11a6ce020383c32c45d1530d77c2')
+
+build() {
+ cd "${srcdir}"/${pkgname}-agents-${pkgver}
+
+ # skip install_razor_agents (we'll do the linking later)
+ # /bin/sed -i "s|install :: all pure_install doc_install install_razor_agents|install :: all pure_install doc_install|g" Makefile
+
+ perl Makefile.PL INSTALLDIRS=vendor
+ make
+}
+
+check() {
+ cd "${srcdir}"/${pkgname}-agents-${pkgver}
+ make test
+}
+
+package() {
+ cd "${srcdir}"/${pkgname}-agents-${pkgver}
+ make DESTDIR="${pkgdir}" install
+
+ # cd ${pkgdir}/usr/bin
+ # for i in razor-check razor-report razor-revoke razor-admin; do
+ # /bin/ln -sf razor-client $i;
+ # done
+}
diff --git a/staging/rrdtool/PKGBUILD b/staging/rrdtool/PKGBUILD
new file mode 100644
index 000000000..469ba4ceb
--- /dev/null
+++ b/staging/rrdtool/PKGBUILD
@@ -0,0 +1,38 @@
+# $Id: PKGBUILD 159769 2012-05-26 17:51:59Z eric $
+# Maintainer: Eric Bélanger <eric@archlinux.org>
+
+pkgname=rrdtool
+pkgver=1.4.7
+pkgrel=2
+pkgdesc="Data logging and graphing application"
+arch=('i686' 'x86_64')
+url="http://www.rrdtool.org"
+license=('GPL' 'custom')
+depends=('libxml2' 'pango' 'ttf-dejavu')
+makedepends=('intltool' 'ruby' 'python2' 'tcl' 'lua')
+optdepends=('tcl: to use corresponding binding' \
+ 'python2: to use corresponding binding' \
+ 'ruby: to use corresponding binding' \
+ 'lua: to use corresponding binding')
+options=('!libtool' '!emptydirs' '!makeflags')
+source=(http://oss.oetiker.ch/rrdtool/pub/rrdtool-${pkgver}.tar.gz)
+sha1sums=('faab7df7696b69f85d6f89dd9708d7cf0c9a273b')
+
+build() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
+
+ # fix FS#28521 make ruby install to vendor_ruby instead of site_ruby
+ sed -e 's/$(RUBY) extconf.rb/& --vendor/' -i bindings/Makefile.in
+
+ PYTHON=python2 ./configure --prefix=/usr --localstatedir=/var --disable-rpath \
+ --enable-perl --enable-perl-site-install --with-perl-options='INSTALLDIRS=vendor' \
+ --enable-ruby --enable-ruby-site-install --enable-python \
+ --enable-lua --enable-lua-site-install --enable-tcl --disable-libwrap
+ make
+}
+
+package() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
+ make DESTDIR="${pkgdir}" install
+ install -D -m644 COPYRIGHT "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
+}
diff --git a/staging/subversion/PKGBUILD b/staging/subversion/PKGBUILD
new file mode 100644
index 000000000..cf8ba275f
--- /dev/null
+++ b/staging/subversion/PKGBUILD
@@ -0,0 +1,79 @@
+# $Id: PKGBUILD 159761 2012-05-26 15:28:27Z stephane $
+# Maintainer: Stéphane Gaudreault <stephane@archlinux.org>
+# Contributor: Paul Mattal <paul@archlinux.org>
+# Contributor: Jason Chu <jason@archlinux.org>
+
+pkgname=subversion
+pkgver=1.7.5
+pkgrel=2
+pkgdesc="A Modern Concurrent Version Control System"
+arch=('i686' 'x86_64')
+license=('APACHE')
+depends=('neon' 'apr-util' 'sqlite' 'file')
+optdepends=('libgnome-keyring' 'kdeutils-kwallet' 'bash-completion: for svn bash completion' \
+ 'python2: for some hook scripts') # 'ruby: for some hook scripts' 'java-environment')
+makedepends=('krb5' 'apache' 'python2' 'perl' 'swig' 'java-runtime' 'java-environment'
+ 'autoconf' 'db' 'e2fsprogs' 'libgnome-keyring' 'kdelibs')
+backup=('etc/xinetd.d/svn' 'etc/conf.d/svnserve')
+url="http://subversion.apache.org/"
+provides=('svn')
+options=('!makeflags' '!libtool' '!emptydirs')
+source=(http://apache.mirror.rafal.ca/subversion/$pkgname-$pkgver.tar.bz2{,.asc}
+ svnserve svn svnserve.conf subversion.rpath.fix.patch)
+sha1sums=('05c079762690d5ac1ccd2549742e7ef70fa45cf1'
+ 'b267cba19b4f56360657a5bf5b231950e027a45a'
+ '64ba3e6ebafc08ac62f59d788f7a825fdce69573'
+ '73b36c046c09cec2093354911c89e3ba8056af6c'
+ 'ad117bf3b2a838a9a678a93fd8db1a066ad46c41'
+ '3d1e28408a9abb42af2e531adc0d01ce21acfad6')
+
+build() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
+ export PYTHON=/usr/bin/python2
+
+ patch -p0 -i ../subversion.rpath.fix.patch
+ sed -i 's|/usr/bin/env python|/usr/bin/env python2|' tools/hook-scripts/{,mailer/{,tests/}}*.py
+
+ ./configure --prefix=/usr --with-apr=/usr --with-apr-util=/usr \
+ --with-zlib=/usr --with-neon=/usr --with-apxs \
+ --with-sqlite=/usr --with-berkeley-db=:/usr/include/:/usr/lib:db-5.3 \
+ --enable-javahl --with-gnome-keyring --with-kwallet
+
+ make external-all
+ make LT_LDFLAGS="-L$Fdestdir/usr/lib" local-all
+ make swig_pydir=/usr/lib/python2.7/site-packages/libsvn \
+ swig_pydir_extra=/usr/lib/python2.7/site-packages/svn swig-py swig-pl javahl # swig-rb
+}
+
+#check() {
+# cd "${srcdir}/${pkgname}-${pkgver}"
+# export LANG=C LC_ALL=C
+# make check check-swig-pl check-swig-py check-javahl CLEANUP=yes # check-swig-rb
+#}
+
+package() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
+
+ export LD_LIBRARY_PATH="${pkgdir}"/usr/lib:${LD_LIBRARY_PATH}
+ make DESTDIR="${pkgdir}" INSTALLDIRS=vendor \
+ swig_pydir=/usr/lib/python2.7/site-packages/libsvn \
+ swig_pydir_extra=/usr/lib/python2.7/site-packages/svn \
+ install install-swig-py install-swig-pl install-javahl # install-swig-rb
+
+ install -d "${pkgdir}"/usr/share/subversion
+ cp -a tools/hook-scripts "${pkgdir}"/usr/share/subversion/
+ rm "${pkgdir}"/usr/share/subversion/hook-scripts/*.in
+
+ rm "${pkgdir}"/usr/lib/perl5/vendor_perl/auto/SVN/_Core/.packlist
+ rm -r "${pkgdir}"/usr/lib/perl5/core_perl
+
+ install -D -m 755 "${srcdir}"/svnserve "${pkgdir}"/etc/rc.d/svnserve
+ install -D -m 644 "${srcdir}"/svn "${pkgdir}"/etc/xinetd.d/svn
+ install -D -m 644 "${srcdir}"/svnserve.conf "${pkgdir}"/etc/conf.d/svnserve
+
+ install -Dm 644 tools/client-side/bash_completion \
+ "${pkgdir}"/usr/share/bash-completion/completions/subversion
+ for i in svn svnadmin svndumpfilter svnlook svnsync svnversion; do
+ ln -sf subversion "${pkgdir}"/usr/share/bash-completion/completions/${i}
+ done
+}
diff --git a/staging/subversion/subversion.rpath.fix.patch b/staging/subversion/subversion.rpath.fix.patch
new file mode 100644
index 000000000..ba6ee9e4e
--- /dev/null
+++ b/staging/subversion/subversion.rpath.fix.patch
@@ -0,0 +1,10 @@
+--- Makefile.in.orig 2009-02-16 14:10:48.000000000 -0200
++++ Makefile.in 2009-06-04 00:56:29.000000000 -0300
+@@ -678,6 +678,7 @@
+
+ $(SWIG_PL_DIR)/native/Makefile: $(SWIG_PL_DIR)/native/Makefile.PL
+ cd $(SWIG_PL_DIR)/native; $(PERL) Makefile.PL
++ cd $(SWIG_PL_DIR)/native; sed -i 's|LD_RUN_PATH|DIE_RPATH_DIE|g' Makefile{,.{client,delta,fs,ra,repos,wc}}
+
+ swig-pl_DEPS = autogen-swig-pl libsvn_swig_perl \
+ $(SWIG_PL_DIR)/native/Makefile
diff --git a/staging/subversion/svn b/staging/subversion/svn
new file mode 100644
index 000000000..8988aaf63
--- /dev/null
+++ b/staging/subversion/svn
@@ -0,0 +1,11 @@
+service svn
+{
+ flags = REUSE
+ socket_type = stream
+ wait = no
+ user = root
+ server = /usr/bin/svnserve
+ server_args = -i
+ log_on_failure += USERID
+ disable = yes
+}
diff --git a/staging/subversion/svnserve b/staging/subversion/svnserve
new file mode 100755
index 000000000..670fee742
--- /dev/null
+++ b/staging/subversion/svnserve
@@ -0,0 +1,42 @@
+#!/bin/bash
+
+. /etc/rc.conf
+. /etc/rc.d/functions
+. /etc/conf.d/svnserve
+
+PID=`pidof -o %PPID /usr/bin/svnserve`
+case "$1" in
+ start)
+ stat_busy "Starting svnserve"
+ if [ -z "$PID" ]; then
+ if [ -n "$SVNSERVE_USER" ]; then
+ su -s '/bin/sh' $SVNSERVE_USER -c "/usr/bin/svnserve -d $SVNSERVE_ARGS" &
+ else
+ /usr/bin/svnserve -d $SVNSERVE_ARGS &
+ fi
+ fi
+ if [ ! -z "$PID" -o $? -gt 0 ]; then
+ stat_fail
+ else
+ add_daemon svnserve
+ stat_done
+ fi
+ ;;
+ stop)
+ stat_busy "Stopping svnserve"
+ [ ! -z "$PID" ] && kill $PID &> /dev/null
+ if [ $? -gt 0 ]; then
+ stat_fail
+ else
+ rm_daemon svnserve
+ stat_done
+ fi
+ ;;
+ restart)
+ $0 stop
+ sleep 1
+ $0 start
+ ;;
+ *)
+ echo "usage: $0 {start|stop|restart}"
+esac
diff --git a/staging/subversion/svnserve.conf b/staging/subversion/svnserve.conf
new file mode 100644
index 000000000..37fb7ea10
--- /dev/null
+++ b/staging/subversion/svnserve.conf
@@ -0,0 +1,7 @@
+#
+# Parameters to be passed to svnserve
+#
+#SVNSERVE_ARGS="-r /path/to/some/repos"
+SVNSERVE_ARGS=""
+
+#SVNSERVE_USER="svn"
diff --git a/staging/udisks/PKGBUILD b/staging/udisks/PKGBUILD
new file mode 100644
index 000000000..79fd768d9
--- /dev/null
+++ b/staging/udisks/PKGBUILD
@@ -0,0 +1,31 @@
+# $Id: PKGBUILD 159757 2012-05-26 15:09:57Z ibiru $
+# Maintainer: Jan de Groot <jgc@archlinux.org>
+
+pkgname=udisks
+pkgver=1.0.4
+pkgrel=4
+pkgdesc="Disk Management Service"
+arch=('i686' 'x86_64')
+url="http://www.freedesktop.org/wiki/Software/udisks"
+license=('GPL')
+depends=('udev' 'sg3_utils' 'glib2' 'dbus-glib' 'polkit' 'parted' 'device-mapper' 'libatasmart' 'lsof' 'eject')
+makedepends=('intltool' 'docbook-xsl')
+options=(!libtool)
+source=(http://hal.freedesktop.org/releases/${pkgname}-${pkgver}.tar.gz)
+sha256sums=('854b89368733b9c3a577101b761ad5397ae75a05110c8698ac5b29de9a8bf8f5')
+
+build() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
+ ./configure --prefix=/usr --sysconfdir=/etc --localstatedir=/var \
+ --libexecdir=/usr/lib/udisks --disable-static
+ make
+}
+
+package() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
+ make profiledir=/usr/share/bash-completion/completions DESTDIR="${pkgdir}" install
+ chmod 644 "${pkgdir}/usr/share/bash-completion/completions/udisks-bash-completion.sh"
+ # move udev helpers and rules to /usr/lib
+ mv "${pkgdir}"/lib/udev "${pkgdir}"/usr/lib/
+ rm -r "${pkgdir}"/lib
+}
diff --git a/staging/util-linux/PKGBUILD b/staging/util-linux/PKGBUILD
new file mode 100644
index 000000000..8fa507437
--- /dev/null
+++ b/staging/util-linux/PKGBUILD
@@ -0,0 +1,55 @@
+# $Id: PKGBUILD 159749 2012-05-26 12:39:32Z tomegun $
+# Maintainer: Tom Gundersen <teg@jklm.no>
+# Contributor: judd <jvinet@zeroflux.org>
+
+pkgname=util-linux
+pkgver=2.21.2
+pkgrel=1
+pkgdesc="Miscellaneous system utilities for Linux"
+url="http://www.kernel.org/pub/linux/utils/util-linux/"
+arch=('i686' 'x86_64')
+groups=('base')
+depends=('udev' 'pam')
+conflicts=('util-linux-ng')
+provides=("util-linux-ng=${pkgver}")
+license=('GPL2')
+options=('!libtool')
+source=(ftp://ftp.kernel.org/pub/linux/utils/${pkgname}/v2.21/${pkgname}-${pkgver}.tar.xz)
+
+build() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
+
+ # hardware clock
+ sed -e 's%etc/adjtime%var/lib/hwclock/adjtime%' -i include/pathnames.h
+
+ ./configure --prefix=/usr \
+ --libdir=/usr/lib \
+ --enable-fs-paths-extra=/usr/bin:/usr/sbin \
+ --enable-write \
+ --enable-raw \
+ --disable-wall \
+ --enable-new-mount
+
+ make
+}
+
+check() {
+ make -C "$pkgname-$pkgver" check
+}
+
+package() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
+
+ make DESTDIR="${pkgdir}" install
+
+ cd "${pkgdir}"
+
+ install -dm755 var/lib/hwclock
+
+ # broken tool, going away in next major release, so just remove it now
+ rm "${pkgdir}"/usr/{bin/chkdupexe,share/man/man1/chkdupexe.1}
+
+ # delete stray empty dir, fixed upstream
+ rm -r usr/share/man/ru
+}
+md5sums=('54ba880f1d66782c2287ee2c898520e9')
diff --git a/staging/vlc/PKGBUILD b/staging/vlc/PKGBUILD
new file mode 100644
index 000000000..9c48c6b9f
--- /dev/null
+++ b/staging/vlc/PKGBUILD
@@ -0,0 +1,88 @@
+# $Id: PKGBUILD 159698 2012-05-26 06:51:40Z giovanni $
+# Maintainer: Giovanni Scafora <giovanni@archlinux.org>
+# Contributor: Sarah Hay <sarahhay@mb.sympatico.ca>
+# Contributor: Martin Sandsmark <martin.sandsmark@kde.org>
+
+pkgname=vlc
+pkgver=2.0.1
+pkgrel=2
+pkgdesc="A multi-platform MPEG, VCD/DVD, and DivX player"
+arch=('i686' 'x86_64')
+url="http://www.videolan.org/vlc/"
+license=('LGPL2.1' 'GPL2')
+depends=('a52dec' 'libdvbpsi' 'libxpm' 'libdca' 'qt' 'libproxy'
+ 'sdl_image' 'libdvdnav' 'libtiger' 'lua' 'libmatroska'
+ 'zvbi' 'taglib' 'libmpcdec' 'ffmpeg' 'faad2' 'libupnp'
+ 'libshout' 'libmad' 'libmpeg2' 'libmodplug' 'libass'
+ 'xcb-util-keysyms' 'ttf-freefont')
+makedepends=('live-media' 'libnotify' 'libbluray' 'flac' 'kdelibs'
+ 'fluidsynth' 'libdc1394' 'libavc1394' 'lirc-utils'
+ 'libcaca' 'librsvg' 'portaudio' 'oss' 'libgme' 'xosd'
+ 'projectm' 'twolame' 'aalib' 'libmtp' 'libdvdcss'
+ 'gnome-vfs' 'libgoom2' 'libtar' 'vcdimager')
+optdepends=('avahi: for service discovery using bonjour protocol'
+ 'libnotify: for notification plugin'
+ 'ncurses: for ncurses interface support'
+ 'libdvdcss: for decoding encrypted DVDs'
+ 'lirc-utils: for lirc plugin'
+ 'libavc1394: for devices using the 1394ta AV/C'
+ 'libdc1394: for IEEE 1394 plugin'
+ 'kdelibs: KDE Solid hardware integration'
+ 'vdpau-video: vdpau back-end for nvidia'
+ 'libva-driver-intel: back-end for intel cards'
+ 'libbluray: for Blu-Ray support'
+ 'flac: for Free Lossless Audio Codec plugin'
+ 'oss: for OSS audio support'
+ 'portaudio: for portaudio support'
+ 'twolame: for TwoLAME mpeg2 encoder plugin'
+ 'projectm: for ProjectM visualisation plugin'
+ 'libcaca: for colored ASCII art video output'
+ 'libgme: for libgme plugin'
+ 'librsvg: for SVG plugin'
+ 'gnome-vfs: for GNOME Virtual File System support'
+ 'libgoom2: for libgoom plugin'
+ 'vcdimager: navigate VCD with libvcdinfo'
+ 'xosd: for xosd support'
+ 'aalib: for ASCII art plugin'
+ 'libmtp: for MTP devices support'
+ 'fluidsynth: for synthesizer MIDI FluidSynth'
+ 'smbclient: for SMB access plugin')
+conflicts=('vlc-plugin')
+replaces=('vlc-plugin')
+backup=('usr/share/vlc/lua/http/.hosts'
+ 'usr/share/vlc/lua/http/dialogs/.hosts')
+options=('!libtool' '!emptydirs')
+install=vlc.install
+source=("http://download.videolan.org/pub/videolan/${pkgname}/${pkgver}/${pkgname}-${pkgver}.tar.xz")
+md5sums=('5ad114755670e4881a2b35354e2f79bc')
+
+build() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
+
+ sed -i -e 's:truetype/freefont:TTF:g' modules/text_renderer/freetype.c
+
+ ./configure --prefix=/usr \
+ --disable-rpath \
+ --enable-oss \
+ --enable-faad \
+ --enable-nls \
+ --enable-lirc \
+ --enable-pvr \
+ --enable-ncurses \
+ --enable-realrtsp \
+ --enable-xosd \
+ --enable-aa \
+ --enable-vcdx
+ make
+}
+
+package() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
+
+ make DESTDIR="${pkgdir}" install
+
+ for res in 16 32 48 128; do
+ install -D -m644 "${srcdir}/vlc-${pkgver}/share/icons/${res}x${res}/vlc.png" \
+ "${pkgdir}/usr/share/icons/hicolor/${res}x${res}/apps/vlc.png"
+ done
+}
diff --git a/staging/vlc/vlc.install b/staging/vlc/vlc.install
new file mode 100644
index 000000000..dc4961cae
--- /dev/null
+++ b/staging/vlc/vlc.install
@@ -0,0 +1,18 @@
+post_install() {
+ xdg-icon-resource forceupdate --theme hicolor &> /dev/null
+ usr/lib/vlc/vlc-cache-gen -f /usr/lib/vlc/plugins
+ update-desktop-database -q
+}
+
+post_upgrade() {
+ post_install
+}
+
+pre_remove() {
+ rm -f usr/lib/vlc/plugins/plugins-*.dat
+}
+
+post_remove() {
+ xdg-icon-resource forceupdate --theme hicolor &> /dev/null
+ update-desktop-database -q
+}
diff --git a/staging/xf86-video-ati/0000-poor-man-s-solid-picture-support-for-r300-r600.patch b/staging/xf86-video-ati/0000-poor-man-s-solid-picture-support-for-r300-r600.patch
new file mode 100644
index 000000000..bcfbf94db
--- /dev/null
+++ b/staging/xf86-video-ati/0000-poor-man-s-solid-picture-support-for-r300-r600.patch
@@ -0,0 +1,571 @@
+From 837149c63929d7d5a8ef6f8204d396f8e6d5acd7 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Michel=20D=C3=A4nzer?= <michel@daenzer.net>
+Date: Fri, 13 Apr 2012 11:12:51 +0200
+Subject: [PATCH 1/4] Poor man's acceleration of solid pictures for R3xx-R7xx
+
+The patch below implements basic acceleration of solid pictures via
+scratch 1x1 pixmaps. It seems to at least alleviate some of the
+corruption and performance issues exposed by Cairo 1.12, and should also
+improve performance for other toolkits/apps using solid pictures.
+
+If there are no objections to this approach, maybe someone else can beat
+me to extending this for Evergreen+ and R1/2xx.
+---
+ src/r600_exa.c | 160 ++++++++++++++++++++++++++--------------------
+ src/radeon_exa_render.c | 115 ++++++++++++++++++++--------------
+ src/radeon_exa_shared.c | 19 ++++++
+ src/radeon_exa_shared.h | 1 +
+ 4 files changed, 179 insertions(+), 116 deletions(-)
+
+diff --git a/src/r600_exa.c b/src/r600_exa.c
+index e1eb62f..c3ae553 100644
+--- a/src/r600_exa.c
++++ b/src/r600_exa.c
+@@ -901,17 +901,8 @@ static Bool R600CheckCompositeTexture(PicturePtr pPict,
+ int op,
+ int unit)
+ {
+- int w = pPict->pDrawable->width;
+- int h = pPict->pDrawable->height;
+ unsigned int repeatType = pPict->repeat ? pPict->repeatType : RepeatNone;
+ unsigned int i;
+- int max_tex_w, max_tex_h;
+-
+- max_tex_w = 8192;
+- max_tex_h = 8192;
+-
+- if ((w > max_tex_w) || (h > max_tex_h))
+- RADEON_FALLBACK(("Picture w/h too large (%dx%d)\n", w, h));
+
+ for (i = 0; i < sizeof(R600TexFormats) / sizeof(R600TexFormats[0]); i++) {
+ if (R600TexFormats[i].fmt == pPict->format)
+@@ -951,9 +942,7 @@ static Bool R600TextureSetup(PicturePtr pPict, PixmapPtr pPix,
+ ScrnInfoPtr pScrn = xf86Screens[pPix->drawable.pScreen->myNum];
+ RADEONInfoPtr info = RADEONPTR(pScrn);
+ struct radeon_accel_state *accel_state = info->accel_state;
+- int w = pPict->pDrawable->width;
+- int h = pPict->pDrawable->height;
+- unsigned int repeatType = pPict->repeat ? pPict->repeatType : RepeatNone;
++ unsigned int repeatType;
+ unsigned int i;
+ tex_resource_t tex_res;
+ tex_sampler_t tex_samp;
+@@ -969,9 +958,16 @@ static Bool R600TextureSetup(PicturePtr pPict, PixmapPtr pPix,
+ }
+
+ /* Texture */
++ if (pPict->pDrawable) {
++ tex_res.w = pPict->pDrawable->width;
++ tex_res.h = pPict->pDrawable->height;
++ repeatType = pPict->repeat ? pPict->repeatType : RepeatNone;
++ } else {
++ tex_res.w = 1;
++ tex_res.h = 1;
++ repeatType = RepeatNormal;
++ }
+ tex_res.id = unit;
+- tex_res.w = w;
+- tex_res.h = h;
+ tex_res.pitch = accel_state->src_obj[unit].pitch;
+ tex_res.depth = 0;
+ tex_res.dim = SQ_TEX_DIM_2D;
+@@ -1170,24 +1166,24 @@ static Bool R600TextureSetup(PicturePtr pPict, PixmapPtr pPix,
+ vs_alu_consts[0] = xFixedToFloat(pPict->transform->matrix[0][0]);
+ vs_alu_consts[1] = xFixedToFloat(pPict->transform->matrix[0][1]);
+ vs_alu_consts[2] = xFixedToFloat(pPict->transform->matrix[0][2]);
+- vs_alu_consts[3] = 1.0 / w;
++ vs_alu_consts[3] = 1.0 / tex_res.w;
+
+ vs_alu_consts[4] = xFixedToFloat(pPict->transform->matrix[1][0]);
+ vs_alu_consts[5] = xFixedToFloat(pPict->transform->matrix[1][1]);
+ vs_alu_consts[6] = xFixedToFloat(pPict->transform->matrix[1][2]);
+- vs_alu_consts[7] = 1.0 / h;
++ vs_alu_consts[7] = 1.0 / tex_res.h;
+ } else {
+ accel_state->is_transform[unit] = FALSE;
+
+ vs_alu_consts[0] = 1.0;
+ vs_alu_consts[1] = 0.0;
+ vs_alu_consts[2] = 0.0;
+- vs_alu_consts[3] = 1.0 / w;
++ vs_alu_consts[3] = 1.0 / tex_res.w;
+
+ vs_alu_consts[4] = 0.0;
+ vs_alu_consts[5] = 1.0;
+ vs_alu_consts[6] = 0.0;
+- vs_alu_consts[7] = 1.0 / h;
++ vs_alu_consts[7] = 1.0 / tex_res.h;
+ }
+
+ /* VS alu constants */
+@@ -1202,33 +1198,30 @@ static Bool R600CheckComposite(int op, PicturePtr pSrcPicture, PicturePtr pMaskP
+ {
+ uint32_t tmp1;
+ PixmapPtr pSrcPixmap, pDstPixmap;
+- int max_tex_w, max_tex_h, max_dst_w, max_dst_h;
+
+ /* Check for unsupported compositing operations. */
+ if (op >= (int) (sizeof(R600BlendOp) / sizeof(R600BlendOp[0])))
+ RADEON_FALLBACK(("Unsupported Composite op 0x%x\n", op));
+
+- if (!pSrcPicture->pDrawable)
+- RADEON_FALLBACK(("Solid or gradient pictures not supported yet\n"));
+-
+- pSrcPixmap = RADEONGetDrawablePixmap(pSrcPicture->pDrawable);
++ if (pSrcPicture->pDrawable) {
++ pSrcPixmap = RADEONGetDrawablePixmap(pSrcPicture->pDrawable);
+
+- max_tex_w = 8192;
+- max_tex_h = 8192;
+- max_dst_w = 8192;
+- max_dst_h = 8192;
++ if (pSrcPixmap->drawable.width >= 8192 ||
++ pSrcPixmap->drawable.height >= 8192) {
++ RADEON_FALLBACK(("Source w/h too large (%d,%d).\n",
++ pSrcPixmap->drawable.width,
++ pSrcPixmap->drawable.height));
++ }
+
+- if (pSrcPixmap->drawable.width >= max_tex_w ||
+- pSrcPixmap->drawable.height >= max_tex_h) {
+- RADEON_FALLBACK(("Source w/h too large (%d,%d).\n",
+- pSrcPixmap->drawable.width,
+- pSrcPixmap->drawable.height));
+- }
++ if (!R600CheckCompositeTexture(pSrcPicture, pDstPicture, op, 0))
++ return FALSE;
++ } else if (pSrcPicture->pSourcePict->type != SourcePictTypeSolidFill)
++ RADEON_FALLBACK(("Gradient pictures not supported yet\n"));
+
+ pDstPixmap = RADEONGetDrawablePixmap(pDstPicture->pDrawable);
+
+- if (pDstPixmap->drawable.width >= max_dst_w ||
+- pDstPixmap->drawable.height >= max_dst_h) {
++ if (pDstPixmap->drawable.width >= 8192 ||
++ pDstPixmap->drawable.height >= 8192) {
+ RADEON_FALLBACK(("Dest w/h too large (%d,%d).\n",
+ pDstPixmap->drawable.width,
+ pDstPixmap->drawable.height));
+@@ -1237,38 +1230,35 @@ static Bool R600CheckComposite(int op, PicturePtr pSrcPicture, PicturePtr pMaskP
+ if (pMaskPicture) {
+ PixmapPtr pMaskPixmap;
+
+- if (!pMaskPicture->pDrawable)
+- RADEON_FALLBACK(("Solid or gradient pictures not supported yet\n"));
++ if (pMaskPicture->pDrawable) {
++ pMaskPixmap = RADEONGetDrawablePixmap(pMaskPicture->pDrawable);
+
+- pMaskPixmap = RADEONGetDrawablePixmap(pMaskPicture->pDrawable);
+-
+- if (pMaskPixmap->drawable.width >= max_tex_w ||
+- pMaskPixmap->drawable.height >= max_tex_h) {
+- RADEON_FALLBACK(("Mask w/h too large (%d,%d).\n",
+- pMaskPixmap->drawable.width,
+- pMaskPixmap->drawable.height));
+- }
++ if (pMaskPixmap->drawable.width >= 8192 ||
++ pMaskPixmap->drawable.height >= 8192) {
++ RADEON_FALLBACK(("Mask w/h too large (%d,%d).\n",
++ pMaskPixmap->drawable.width,
++ pMaskPixmap->drawable.height));
++ }
+
+- if (pMaskPicture->componentAlpha) {
+- /* Check if it's component alpha that relies on a source alpha and
+- * on the source value. We can only get one of those into the
+- * single source value that we get to blend with.
+- */
+- if (R600BlendOp[op].src_alpha &&
+- (R600BlendOp[op].blend_cntl & COLOR_SRCBLEND_mask) !=
+- (BLEND_ZERO << COLOR_SRCBLEND_shift)) {
+- RADEON_FALLBACK(("Component alpha not supported with source "
+- "alpha and source value blending.\n"));
++ if (pMaskPicture->componentAlpha) {
++ /* Check if it's component alpha that relies on a source alpha and
++ * on the source value. We can only get one of those into the
++ * single source value that we get to blend with.
++ */
++ if (R600BlendOp[op].src_alpha &&
++ (R600BlendOp[op].blend_cntl & COLOR_SRCBLEND_mask) !=
++ (BLEND_ZERO << COLOR_SRCBLEND_shift)) {
++ RADEON_FALLBACK(("Component alpha not supported with source "
++ "alpha and source value blending.\n"));
++ }
+ }
+- }
+
+- if (!R600CheckCompositeTexture(pMaskPicture, pDstPicture, op, 1))
+- return FALSE;
++ if (!R600CheckCompositeTexture(pMaskPicture, pDstPicture, op, 1))
++ return FALSE;
++ } else if (pMaskPicture->pSourcePict->type != SourcePictTypeSolidFill)
++ RADEON_FALLBACK(("Gradient pictures not supported yet\n"));
+ }
+
+- if (!R600CheckCompositeTexture(pSrcPicture, pDstPicture, op, 0))
+- return FALSE;
+-
+ if (!R600GetDestFormat(pDstPicture, &tmp1))
+ return FALSE;
+
+@@ -1280,7 +1270,8 @@ static Bool R600PrepareComposite(int op, PicturePtr pSrcPicture,
+ PicturePtr pMaskPicture, PicturePtr pDstPicture,
+ PixmapPtr pSrc, PixmapPtr pMask, PixmapPtr pDst)
+ {
+- ScrnInfoPtr pScrn = xf86Screens[pSrc->drawable.pScreen->myNum];
++ ScreenPtr pScreen = pDst->drawable.pScreen;
++ ScrnInfoPtr pScrn = xf86Screens[pScreen->myNum];
+ RADEONInfoPtr info = RADEONPTR(pScrn);
+ struct radeon_accel_state *accel_state = info->accel_state;
+ uint32_t dst_format;
+@@ -1288,15 +1279,21 @@ static Bool R600PrepareComposite(int op, PicturePtr pSrcPicture,
+ shader_config_t vs_conf, ps_conf;
+ struct r600_accel_object src_obj, mask_obj, dst_obj;
+
+- if (pDst->drawable.bitsPerPixel < 8 || pSrc->drawable.bitsPerPixel < 8)
++ if (pDst->drawable.bitsPerPixel < 8 || (pSrc && pSrc->drawable.bitsPerPixel < 8))
+ return FALSE;
+
++ if (!pSrc) {
++ pSrc = RADEONSolidPixmap(pScreen, pSrcPicture->pSourcePict->solidFill.color);
++ if (!pSrc)
++ RADEON_FALLBACK("Failed to create solid scratch pixmap\n");
++ }
++
+ #if defined(XF86DRM_MODE)
+ if (info->cs) {
+ src_obj.offset = 0;
+ dst_obj.offset = 0;
+- src_obj.bo = radeon_get_pixmap_bo(pSrc);
+ dst_obj.bo = radeon_get_pixmap_bo(pDst);
++ src_obj.bo = radeon_get_pixmap_bo(pSrc);
+ dst_obj.tiling_flags = radeon_get_pixmap_tiling(pDst);
+ src_obj.tiling_flags = radeon_get_pixmap_tiling(pSrc);
+ dst_obj.surface = radeon_get_pixmap_surface(pDst);
+@@ -1322,7 +1319,16 @@ static Bool R600PrepareComposite(int op, PicturePtr pSrcPicture,
+ dst_obj.bpp = pDst->drawable.bitsPerPixel;
+ dst_obj.domain = RADEON_GEM_DOMAIN_VRAM;
+
+- if (pMask) {
++ if (pMaskPicture) {
++ if (!pMask) {
++ pMask = RADEONSolidPixmap(pScreen, pMaskPicture->pSourcePict->solidFill.color);
++ if (!pMask) {
++ if (!pSrcPicture->pDrawable)
++ pScreen->DestroyPixmap(pSrc);
++ RADEON_FALLBACK("Failed to create solid scratch pixmap\n");
++ }
++ }
++
+ #if defined(XF86DRM_MODE)
+ if (info->cs) {
+ mask_obj.offset = 0;
+@@ -1509,11 +1515,9 @@ static Bool R600PrepareComposite(int op, PicturePtr pSrcPicture,
+ return TRUE;
+ }
+
+-static void R600DoneComposite(PixmapPtr pDst)
++static void R600FinishComposite(ScrnInfoPtr pScrn, PixmapPtr pDst,
++ struct radeon_accel_state *accel_state)
+ {
+- ScrnInfoPtr pScrn = xf86Screens[pDst->drawable.pScreen->myNum];
+- RADEONInfoPtr info = RADEONPTR(pScrn);
+- struct radeon_accel_state *accel_state = info->accel_state;
+ int vtx_size;
+
+ if (accel_state->vsync)
+@@ -1527,6 +1531,22 @@ static void R600DoneComposite(PixmapPtr pDst)
+ r600_finish_op(pScrn, vtx_size);
+ }
+
++static void R600DoneComposite(PixmapPtr pDst)
++{
++ ScreenPtr pScreen = pDst->drawable.pScreen;
++ ScrnInfoPtr pScrn = xf86Screens[pScreen->myNum];
++ RADEONInfoPtr info = RADEONPTR(pScrn);
++ struct radeon_accel_state *accel_state = info->accel_state;
++
++ R600FinishComposite(pScrn, pDst, accel_state);
++
++ if (!accel_state->src_pic->pDrawable)
++ pScreen->DestroyPixmap(accel_state->src_pix);
++
++ if (accel_state->msk_pic && !accel_state->msk_pic->pDrawable)
++ pScreen->DestroyPixmap(accel_state->msk_pix);
++}
++
+ static void R600Composite(PixmapPtr pDst,
+ int srcX, int srcY,
+ int maskX, int maskY,
+@@ -1543,7 +1563,7 @@ static void R600Composite(PixmapPtr pDst,
+
+ #ifdef XF86DRM_MODE
+ if (info->cs && CS_FULL(info->cs)) {
+- R600DoneComposite(info->accel_state->dst_pix);
++ R600FinishComposite(pScrn, pDst, info->accel_state);
+ radeon_cs_flush_indirect(pScrn);
+ R600PrepareComposite(info->accel_state->composite_op,
+ info->accel_state->src_pic,
+diff --git a/src/radeon_exa_render.c b/src/radeon_exa_render.c
+index e5c231f..b6cc9e4 100644
+--- a/src/radeon_exa_render.c
++++ b/src/radeon_exa_render.c
+@@ -299,8 +299,8 @@ static Bool RADEONSetupSourceTile(PicturePtr pPict,
+ if (repeatType == RepeatNormal || repeatType == RepeatReflect) {
+ Bool badPitch = needMatchingPitch && !RADEONPitchMatches(pPix);
+
+- int w = pPict->pDrawable->width;
+- int h = pPict->pDrawable->height;
++ int w = pPict->pDrawable ? pPict->pDrawable->width : 1;
++ int h = pPict->pDrawable ? pPict->pDrawable->height : 1;
+
+ if (pPict->transform) {
+ if (badPitch)
+@@ -1112,23 +1112,8 @@ static Bool R300CheckCompositeTexture(PicturePtr pPict,
+ ScreenPtr pScreen = pDstPict->pDrawable->pScreen;
+ ScrnInfoPtr pScrn = xf86Screens[pScreen->myNum];
+ RADEONInfoPtr info = RADEONPTR(pScrn);
+-
+ unsigned int repeatType = pPict->repeat ? pPict->repeatType : RepeatNone;
+- int w = pPict->pDrawable->width;
+- int h = pPict->pDrawable->height;
+ int i;
+- int max_tex_w, max_tex_h;
+-
+- if (is_r500) {
+- max_tex_w = 4096;
+- max_tex_h = 4096;
+- } else {
+- max_tex_w = 2048;
+- max_tex_h = 2048;
+- }
+-
+- if ((w > max_tex_w) || (h > max_tex_h))
+- RADEON_FALLBACK(("Picture w/h too large (%dx%d)\n", w, h));
+
+ for (i = 0; i < sizeof(R300TexFormats) / sizeof(R300TexFormats[0]); i++)
+ {
+@@ -1139,7 +1124,7 @@ static Bool R300CheckCompositeTexture(PicturePtr pPict,
+ RADEON_FALLBACK(("Unsupported picture format 0x%x\n",
+ (int)pPict->format));
+
+- if (!RADEONCheckTexturePOT(pPict, unit == 0)) {
++ if (pPict->pDrawable && !RADEONCheckTexturePOT(pPict, unit == 0)) {
+ if (info->cs) {
+ struct radeon_exa_pixmap_priv *driver_priv;
+ PixmapPtr pPix;
+@@ -1181,15 +1166,23 @@ static Bool FUNC_NAME(R300TextureSetup)(PicturePtr pPict, PixmapPtr pPix,
+ {
+ RINFO_FROM_SCREEN(pPix->drawable.pScreen);
+ uint32_t txfilter, txformat0, txformat1, txoffset, txpitch, us_format = 0;
+- int w = pPict->pDrawable->width;
+- int h = pPict->pDrawable->height;
++ int w, h;
+ int i, pixel_shift, out_size = 6;
+- unsigned int repeatType = pPict->repeat ? pPict->repeatType : RepeatNone;
++ unsigned int repeatType;
+ struct radeon_exa_pixmap_priv *driver_priv;
+ ACCEL_PREAMBLE();
+
+ TRACE;
+
++ if (pPict->pDrawable) {
++ w = pPict->pDrawable->width;
++ h = pPict->pDrawable->height;
++ repeatType = pPict->repeat ? pPict->repeatType : RepeatNone;
++ } else {
++ w = h = 1;
++ repeatType = RepeatNormal;
++ }
++
+ txpitch = exaGetPixmapPitch(pPix);
+ txoffset = 0;
+
+@@ -1394,11 +1387,6 @@ static Bool R300CheckComposite(int op, PicturePtr pSrcPicture, PicturePtr pMaskP
+ if (op >= sizeof(RadeonBlendOp) / sizeof(RadeonBlendOp[0]))
+ RADEON_FALLBACK(("Unsupported Composite op 0x%x\n", op));
+
+- if (!pSrcPicture->pDrawable)
+- RADEON_FALLBACK(("Solid or gradient pictures not supported yet\n"));
+-
+- pSrcPixmap = RADEONGetDrawablePixmap(pSrcPicture->pDrawable);
+-
+ if (IS_R500_3D) {
+ max_tex_w = 4096;
+ max_tex_h = 4096;
+@@ -1416,13 +1404,6 @@ static Bool R300CheckComposite(int op, PicturePtr pSrcPicture, PicturePtr pMaskP
+ }
+ }
+
+- if (pSrcPixmap->drawable.width > max_tex_w ||
+- pSrcPixmap->drawable.height > max_tex_h) {
+- RADEON_FALLBACK(("Source w/h too large (%d,%d).\n",
+- pSrcPixmap->drawable.width,
+- pSrcPixmap->drawable.height));
+- }
+-
+ pDstPixmap = RADEONGetDrawablePixmap(pDstPicture->pDrawable);
+
+ if (pDstPixmap->drawable.width > max_dst_w ||
+@@ -1432,20 +1413,32 @@ static Bool R300CheckComposite(int op, PicturePtr pSrcPicture, PicturePtr pMaskP
+ pDstPixmap->drawable.height));
+ }
+
++ if (pSrcPicture->pDrawable) {
++ pSrcPixmap = RADEONGetDrawablePixmap(pSrcPicture->pDrawable);
++
++ if (pSrcPixmap->drawable.width > max_tex_w ||
++ pSrcPixmap->drawable.height > max_tex_h) {
++ RADEON_FALLBACK(("Source w/h too large (%d,%d).\n",
++ pSrcPixmap->drawable.width,
++ pSrcPixmap->drawable.height));
++ }
++ } else if (pSrcPicture->pSourcePict->type != SourcePictTypeSolidFill)
++ RADEON_FALLBACK(("Gradient pictures not supported yet\n"));
++
+ if (pMaskPicture) {
+ PixmapPtr pMaskPixmap;
+
+- if (!pMaskPicture->pDrawable)
+- RADEON_FALLBACK(("Solid or gradient pictures not supported yet\n"));
++ if (pMaskPicture->pDrawable) {
++ pMaskPixmap = RADEONGetDrawablePixmap(pMaskPicture->pDrawable);
+
+- pMaskPixmap = RADEONGetDrawablePixmap(pMaskPicture->pDrawable);
+-
+- if (pMaskPixmap->drawable.width > max_tex_w ||
+- pMaskPixmap->drawable.height > max_tex_h) {
+- RADEON_FALLBACK(("Mask w/h too large (%d,%d).\n",
+- pMaskPixmap->drawable.width,
+- pMaskPixmap->drawable.height));
+- }
++ if (pMaskPixmap->drawable.width > max_tex_w ||
++ pMaskPixmap->drawable.height > max_tex_h) {
++ RADEON_FALLBACK(("Mask w/h too large (%d,%d).\n",
++ pMaskPixmap->drawable.width,
++ pMaskPixmap->drawable.height));
++ }
++ } else if (pMaskPicture->pSourcePict->type != SourcePictTypeSolidFill)
++ RADEON_FALLBACK(("Gradient pictures not supported yet\n"));
+
+ if (pMaskPicture->componentAlpha) {
+ /* Check if it's component alpha that relies on a source alpha and
+@@ -1479,7 +1472,8 @@ static Bool FUNC_NAME(R300PrepareComposite)(int op, PicturePtr pSrcPicture,
+ PicturePtr pMaskPicture, PicturePtr pDstPicture,
+ PixmapPtr pSrc, PixmapPtr pMask, PixmapPtr pDst)
+ {
+- RINFO_FROM_SCREEN(pDst->drawable.pScreen);
++ ScreenPtr pScreen = pDst->drawable.pScreen;
++ RINFO_FROM_SCREEN(pScreen);
+ uint32_t dst_format, dst_pitch;
+ uint32_t txenable, colorpitch;
+ uint32_t blendcntl, output_fmt;
+@@ -1508,9 +1502,24 @@ static Bool FUNC_NAME(R300PrepareComposite)(int op, PicturePtr pSrcPicture,
+ if (((dst_pitch >> pixel_shift) & 0x7) != 0)
+ RADEON_FALLBACK(("Bad destination pitch 0x%x\n", (int)dst_pitch));
+
++ if (!pSrc) {
++ pSrc = RADEONSolidPixmap(pScreen, cpu_to_le32(pSrcPicture->pSourcePict->solidFill.color));
++ if (!pSrc)
++ RADEON_FALLBACK("Failed to create solid scratch pixmap\n");
++ }
++
+ if (!RADEONSetupSourceTile(pSrcPicture, pSrc, TRUE, FALSE))
+ return FALSE;
+
++ if (pMaskPicture && !pMask) {
++ pMask = RADEONSolidPixmap(pScreen, cpu_to_le32(pMaskPicture->pSourcePict->solidFill.color));
++ if (!pMask) {
++ if (!pSrcPicture->pDrawable)
++ pScreen->DestroyPixmap(pSrc);
++ RADEON_FALLBACK("Failed to create solid scratch pixmap\n");
++ }
++ }
++
+ RADEONPrepareCompositeCS(op, pSrcPicture, pMaskPicture, pDstPicture,
+ pSrc, pMask, pDst);
+
+@@ -2132,7 +2141,7 @@ static Bool FUNC_NAME(R300PrepareComposite)(int op, PicturePtr pSrcPicture,
+ return TRUE;
+ }
+
+-static void FUNC_NAME(RadeonDoneComposite)(PixmapPtr pDst)
++static void FUNC_NAME(RadeonFinishComposite)(PixmapPtr pDst)
+ {
+ RINFO_FROM_SCREEN(pDst->drawable.pScreen);
+ ACCEL_PREAMBLE();
+@@ -2179,6 +2188,20 @@ static void FUNC_NAME(RadeonDoneComposite)(PixmapPtr pDst)
+ LEAVE_DRAW(0);
+ }
+
++static void FUNC_NAME(RadeonDoneComposite)(PixmapPtr pDst)
++{
++ ScreenPtr pScreen = pDst->drawable.pScreen;
++ RINFO_FROM_SCREEN(pScreen);
++ struct radeon_accel_state *accel_state = info->accel_state;
++
++ FUNC_NAME(RadeonFinishComposite)(pDst);
++
++ if (!accel_state->src_pic->pDrawable)
++ pScreen->DestroyPixmap(accel_state->src_pix);
++
++ if (accel_state->msk_pic && !accel_state->msk_pic->pDrawable)
++ pScreen->DestroyPixmap(accel_state->msk_pix);
++}
+
+ #ifdef ACCEL_CP
+
+@@ -2257,7 +2280,7 @@ static void FUNC_NAME(RadeonCompositeTile)(ScrnInfoPtr pScrn,
+ if ((info->cs && CS_FULL(info->cs)) ||
+ (!info->cs && (info->cp->indirectBuffer->used + 4 * 32) >
+ info->cp->indirectBuffer->total)) {
+- FUNC_NAME(RadeonDoneComposite)(info->accel_state->dst_pix);
++ FUNC_NAME(RadeonFinishComposite)(info->accel_state->dst_pix);
+ if (info->cs)
+ radeon_cs_flush_indirect(pScrn);
+ else
+diff --git a/src/radeon_exa_shared.c b/src/radeon_exa_shared.c
+index be1d2fa..28dc335 100644
+--- a/src/radeon_exa_shared.c
++++ b/src/radeon_exa_shared.c
+@@ -126,6 +126,25 @@ Bool RADEONCheckBPP(int bpp)
+ return FALSE;
+ }
+
++PixmapPtr RADEONSolidPixmap(ScreenPtr pScreen, uint32_t solid)
++{
++ PixmapPtr pPix = pScreen->CreatePixmap(pScreen, 1, 1, 32, 0);
++ struct radeon_bo *bo;
++
++ exaMoveInPixmap(pPix);
++ bo = radeon_get_pixmap_bo(pPix);
++
++ if (radeon_bo_map(bo, 1)) {
++ pScreen->DestroyPixmap(pPix);
++ return NULL;
++ }
++
++ memcpy(bo->ptr, &solid, 4);
++ radeon_bo_unmap(bo);
++
++ return pPix;
++}
++
+ static Bool radeon_vb_get(ScrnInfoPtr pScrn)
+ {
+ RADEONInfoPtr info = RADEONPTR(pScrn);
+diff --git a/src/radeon_exa_shared.h b/src/radeon_exa_shared.h
+index 7b8b5ca..60a1045 100644
+--- a/src/radeon_exa_shared.h
++++ b/src/radeon_exa_shared.h
+@@ -40,6 +40,7 @@ extern void RADEONVlineHelperClear(ScrnInfoPtr pScrn);
+ extern void RADEONVlineHelperSet(ScrnInfoPtr pScrn, int x1, int y1, int x2, int y2);
+ extern Bool RADEONValidPM(uint32_t pm, int bpp);
+ extern Bool RADEONCheckBPP(int bpp);
++extern PixmapPtr RADEONSolidPixmap(ScreenPtr pScreen, uint32_t solid);
+
+ #define RADEON_TRACE_FALL 0
+ #define RADEON_TRACE_DRAW 0
+--
+1.7.7.5
+
diff --git a/staging/xf86-video-ati/0001-poor-man-s-solid-picture-support-for-evergreen.patch b/staging/xf86-video-ati/0001-poor-man-s-solid-picture-support-for-evergreen.patch
new file mode 100644
index 000000000..e6b5433e1
--- /dev/null
+++ b/staging/xf86-video-ati/0001-poor-man-s-solid-picture-support-for-evergreen.patch
@@ -0,0 +1,290 @@
+From 761ef4b340e689490a76ec5ce520c858335e2106 Mon Sep 17 00:00:00 2001
+From: Alex Deucher <alexander.deucher@amd.com>
+Date: Sat, 14 Apr 2012 08:53:39 -0400
+Subject: [PATCH] poor man's solid picture support for evergreen
+
+Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
+---
+ src/evergreen_exa.c | 163 ++++++++++++++++++++++++++++++---------------------
+ 1 files changed, 95 insertions(+), 68 deletions(-)
+
+diff --git a/src/evergreen_exa.c b/src/evergreen_exa.c
+index cee3ec2..61b47a4 100644
+--- a/src/evergreen_exa.c
++++ b/src/evergreen_exa.c
+@@ -748,17 +748,8 @@ static Bool EVERGREENCheckCompositeTexture(PicturePtr pPict,
+ int op,
+ int unit)
+ {
+- int w = pPict->pDrawable->width;
+- int h = pPict->pDrawable->height;
+ unsigned int repeatType = pPict->repeat ? pPict->repeatType : RepeatNone;
+ unsigned int i;
+- int max_tex_w, max_tex_h;
+-
+- max_tex_w = 16384;
+- max_tex_h = 16384;
+-
+- if ((w > max_tex_w) || (h > max_tex_h))
+- RADEON_FALLBACK(("Picture w/h too large (%dx%d)\n", w, h));
+
+ for (i = 0; i < sizeof(EVERGREENTexFormats) / sizeof(EVERGREENTexFormats[0]); i++) {
+ if (EVERGREENTexFormats[i].fmt == pPict->format)
+@@ -798,9 +789,16 @@ static void EVERGREENXFormSetup(PicturePtr pPict, PixmapPtr pPix,
+ ScrnInfoPtr pScrn = xf86Screens[pPix->drawable.pScreen->myNum];
+ RADEONInfoPtr info = RADEONPTR(pScrn);
+ struct radeon_accel_state *accel_state = info->accel_state;
+- int w = pPict->pDrawable->width;
+- int h = pPict->pDrawable->height;
+ int const_offset = unit * 8;
++ int w, h;
++
++ if (pPict->pDrawable) {
++ w = pPict->pDrawable->width;
++ h = pPict->pDrawable->height;
++ } else {
++ w = 1;
++ h = 1;
++ }
+
+ if (pPict->transform != 0) {
+ accel_state->is_transform[unit] = TRUE;
+@@ -837,9 +835,7 @@ static Bool EVERGREENTextureSetup(PicturePtr pPict, PixmapPtr pPix,
+ ScrnInfoPtr pScrn = xf86Screens[pPix->drawable.pScreen->myNum];
+ RADEONInfoPtr info = RADEONPTR(pScrn);
+ struct radeon_accel_state *accel_state = info->accel_state;
+- int w = pPict->pDrawable->width;
+- int h = pPict->pDrawable->height;
+- unsigned int repeatType = pPict->repeat ? pPict->repeatType : RepeatNone;
++ unsigned int repeatType;
+ unsigned int i;
+ tex_resource_t tex_res;
+ tex_sampler_t tex_samp;
+@@ -854,9 +850,17 @@ static Bool EVERGREENTextureSetup(PicturePtr pPict, PixmapPtr pPix,
+ }
+
+ /* Texture */
++ if (pPict->pDrawable) {
++ tex_res.w = pPict->pDrawable->width;
++ tex_res.h = pPict->pDrawable->height;
++ repeatType = pPict->repeat ? pPict->repeatType : RepeatNone;
++ } else {
++ tex_res.w = 1;
++ tex_res.h = 1;
++ repeatType = RepeatNormal;
++ }
++
+ tex_res.id = unit;
+- tex_res.w = w;
+- tex_res.h = h;
+ tex_res.pitch = accel_state->src_obj[unit].pitch;
+ tex_res.depth = 0;
+ tex_res.dim = SQ_TEX_DIM_2D;
+@@ -1054,33 +1058,30 @@ static Bool EVERGREENCheckComposite(int op, PicturePtr pSrcPicture,
+ {
+ uint32_t tmp1;
+ PixmapPtr pSrcPixmap, pDstPixmap;
+- int max_tex_w, max_tex_h, max_dst_w, max_dst_h;
+
+ /* Check for unsupported compositing operations. */
+ if (op >= (int) (sizeof(EVERGREENBlendOp) / sizeof(EVERGREENBlendOp[0])))
+ RADEON_FALLBACK(("Unsupported Composite op 0x%x\n", op));
+
+- if (!pSrcPicture->pDrawable)
+- RADEON_FALLBACK(("Solid or gradient pictures not supported yet\n"));
++ if (pSrcPicture->pDrawable) {
++ pSrcPixmap = RADEONGetDrawablePixmap(pSrcPicture->pDrawable);
+
+- pSrcPixmap = RADEONGetDrawablePixmap(pSrcPicture->pDrawable);
+-
+- max_tex_w = 8192;
+- max_tex_h = 8192;
+- max_dst_w = 8192;
+- max_dst_h = 8192;
++ if (pSrcPixmap->drawable.width >= 16384 ||
++ pSrcPixmap->drawable.height >= 16384) {
++ RADEON_FALLBACK(("Source w/h too large (%d,%d).\n",
++ pSrcPixmap->drawable.width,
++ pSrcPixmap->drawable.height));
++ }
+
+- if (pSrcPixmap->drawable.width >= max_tex_w ||
+- pSrcPixmap->drawable.height >= max_tex_h) {
+- RADEON_FALLBACK(("Source w/h too large (%d,%d).\n",
+- pSrcPixmap->drawable.width,
+- pSrcPixmap->drawable.height));
+- }
++ if (!EVERGREENCheckCompositeTexture(pSrcPicture, pDstPicture, op, 0))
++ return FALSE;
++ } else if (pSrcPicture->pSourcePict->type != SourcePictTypeSolidFill)
++ RADEON_FALLBACK(("Gradient pictures not supported yet\n"));
+
+ pDstPixmap = RADEONGetDrawablePixmap(pDstPicture->pDrawable);
+
+- if (pDstPixmap->drawable.width >= max_dst_w ||
+- pDstPixmap->drawable.height >= max_dst_h) {
++ if (pDstPixmap->drawable.width >= 16384 ||
++ pDstPixmap->drawable.height >= 16384) {
+ RADEON_FALLBACK(("Dest w/h too large (%d,%d).\n",
+ pDstPixmap->drawable.width,
+ pDstPixmap->drawable.height));
+@@ -1089,38 +1090,35 @@ static Bool EVERGREENCheckComposite(int op, PicturePtr pSrcPicture,
+ if (pMaskPicture) {
+ PixmapPtr pMaskPixmap;
+
+- if (!pMaskPicture->pDrawable)
+- RADEON_FALLBACK(("Solid or gradient pictures not supported yet\n"));
+-
+- pMaskPixmap = RADEONGetDrawablePixmap(pMaskPicture->pDrawable);
++ if (pMaskPicture->pDrawable) {
++ pMaskPixmap = RADEONGetDrawablePixmap(pMaskPicture->pDrawable);
+
+- if (pMaskPixmap->drawable.width >= max_tex_w ||
+- pMaskPixmap->drawable.height >= max_tex_h) {
+- RADEON_FALLBACK(("Mask w/h too large (%d,%d).\n",
+- pMaskPixmap->drawable.width,
+- pMaskPixmap->drawable.height));
+- }
++ if (pMaskPixmap->drawable.width >= 16384 ||
++ pMaskPixmap->drawable.height >= 16384) {
++ RADEON_FALLBACK(("Mask w/h too large (%d,%d).\n",
++ pMaskPixmap->drawable.width,
++ pMaskPixmap->drawable.height));
++ }
+
+- if (pMaskPicture->componentAlpha) {
+- /* Check if it's component alpha that relies on a source alpha and
+- * on the source value. We can only get one of those into the
+- * single source value that we get to blend with.
+- */
+- if (EVERGREENBlendOp[op].src_alpha &&
+- (EVERGREENBlendOp[op].blend_cntl & COLOR_SRCBLEND_mask) !=
+- (BLEND_ZERO << COLOR_SRCBLEND_shift)) {
+- RADEON_FALLBACK(("Component alpha not supported with source "
+- "alpha and source value blending.\n"));
++ if (pMaskPicture->componentAlpha) {
++ /* Check if it's component alpha that relies on a source alpha and
++ * on the source value. We can only get one of those into the
++ * single source value that we get to blend with.
++ */
++ if (EVERGREENBlendOp[op].src_alpha &&
++ (EVERGREENBlendOp[op].blend_cntl & COLOR_SRCBLEND_mask) !=
++ (BLEND_ZERO << COLOR_SRCBLEND_shift)) {
++ RADEON_FALLBACK(("Component alpha not supported with source "
++ "alpha and source value blending.\n"));
++ }
+ }
+- }
+
+- if (!EVERGREENCheckCompositeTexture(pMaskPicture, pDstPicture, op, 1))
+- return FALSE;
++ if (!EVERGREENCheckCompositeTexture(pMaskPicture, pDstPicture, op, 1))
++ return FALSE;
++ } else if (pMaskPicture->pSourcePict->type != SourcePictTypeSolidFill)
++ RADEON_FALLBACK(("Gradient pictures not supported yet\n"));
+ }
+
+- if (!EVERGREENCheckCompositeTexture(pSrcPicture, pDstPicture, op, 0))
+- return FALSE;
+-
+ if (!EVERGREENGetDestFormat(pDstPicture, &tmp1))
+ return FALSE;
+
+@@ -1132,7 +1130,8 @@ static Bool EVERGREENPrepareComposite(int op, PicturePtr pSrcPicture,
+ PicturePtr pMaskPicture, PicturePtr pDstPicture,
+ PixmapPtr pSrc, PixmapPtr pMask, PixmapPtr pDst)
+ {
+- ScrnInfoPtr pScrn = xf86Screens[pSrc->drawable.pScreen->myNum];
++ ScreenPtr pScreen = pDst->drawable.pScreen;
++ ScrnInfoPtr pScrn = xf86Screens[pScreen->myNum];
+ RADEONInfoPtr info = RADEONPTR(pScrn);
+ struct radeon_accel_state *accel_state = info->accel_state;
+ uint32_t dst_format;
+@@ -1142,13 +1141,19 @@ static Bool EVERGREENPrepareComposite(int op, PicturePtr pSrcPicture,
+ struct r600_accel_object src_obj, mask_obj, dst_obj;
+ float *cbuf;
+
+- if (pDst->drawable.bitsPerPixel < 8 || pSrc->drawable.bitsPerPixel < 8)
++ if (pDst->drawable.bitsPerPixel < 8 || (pSrc && pSrc->drawable.bitsPerPixel < 8))
+ return FALSE;
+
++ if (!pSrc) {
++ pSrc = RADEONSolidPixmap(pScreen, pSrcPicture->pSourcePict->solidFill.color);
++ if (!pSrc)
++ RADEON_FALLBACK("Failed to create solid scratch pixmap\n");
++ }
++
+ src_obj.offset = 0;
+ dst_obj.offset = 0;
+- src_obj.bo = radeon_get_pixmap_bo(pSrc);
+ dst_obj.bo = radeon_get_pixmap_bo(pDst);
++ src_obj.bo = radeon_get_pixmap_bo(pSrc);
+ dst_obj.surface = radeon_get_pixmap_surface(pDst);
+ src_obj.surface = radeon_get_pixmap_surface(pSrc);
+ dst_obj.tiling_flags = radeon_get_pixmap_tiling(pDst);
+@@ -1166,7 +1171,15 @@ static Bool EVERGREENPrepareComposite(int op, PicturePtr pSrcPicture,
+ dst_obj.bpp = pDst->drawable.bitsPerPixel;
+ dst_obj.domain = RADEON_GEM_DOMAIN_VRAM;
+
+- if (pMask) {
++ if (pMaskPicture) {
++ if (!pMask) {
++ pMask = RADEONSolidPixmap(pScreen, pMaskPicture->pSourcePict->solidFill.color);
++ if (!pMask) {
++ if (!pSrcPicture->pDrawable)
++ pScreen->DestroyPixmap(pSrc);
++ RADEON_FALLBACK("Failed to create solid scratch pixmap\n");
++ }
++ }
+ mask_obj.offset = 0;
+ mask_obj.bo = radeon_get_pixmap_bo(pMask);
+ mask_obj.tiling_flags = radeon_get_pixmap_tiling(pMask);
+@@ -1363,11 +1376,9 @@ static Bool EVERGREENPrepareComposite(int op, PicturePtr pSrcPicture,
+ return TRUE;
+ }
+
+-static void EVERGREENDoneComposite(PixmapPtr pDst)
++static void EVERGREENFinishComposite(ScrnInfoPtr pScrn, PixmapPtr pDst,
++ struct radeon_accel_state *accel_state)
+ {
+- ScrnInfoPtr pScrn = xf86Screens[pDst->drawable.pScreen->myNum];
+- RADEONInfoPtr info = RADEONPTR(pScrn);
+- struct radeon_accel_state *accel_state = info->accel_state;
+ int vtx_size;
+
+ if (accel_state->vsync)
+@@ -1381,6 +1392,22 @@ static void EVERGREENDoneComposite(PixmapPtr pDst)
+ evergreen_finish_op(pScrn, vtx_size);
+ }
+
++static void EVERGREENDoneComposite(PixmapPtr pDst)
++{
++ ScreenPtr pScreen = pDst->drawable.pScreen;
++ ScrnInfoPtr pScrn = xf86Screens[pScreen->myNum];
++ RADEONInfoPtr info = RADEONPTR(pScrn);
++ struct radeon_accel_state *accel_state = info->accel_state;
++
++ EVERGREENFinishComposite(pScrn, pDst, accel_state);
++
++ if (!accel_state->src_pic->pDrawable)
++ pScreen->DestroyPixmap(accel_state->src_pix);
++
++ if (accel_state->msk_pic && !accel_state->msk_pic->pDrawable)
++ pScreen->DestroyPixmap(accel_state->msk_pix);
++}
++
+ static void EVERGREENComposite(PixmapPtr pDst,
+ int srcX, int srcY,
+ int maskX, int maskY,
+@@ -1393,7 +1420,7 @@ static void EVERGREENComposite(PixmapPtr pDst,
+ float *vb;
+
+ if (CS_FULL(info->cs)) {
+- EVERGREENDoneComposite(info->accel_state->dst_pix);
++ EVERGREENFinishComposite(pScrn, pDst, info->accel_state);
+ radeon_cs_flush_indirect(pScrn);
+ EVERGREENPrepareComposite(info->accel_state->composite_op,
+ info->accel_state->src_pic,
+--
+1.7.7.5
+
diff --git a/staging/xf86-video-ati/0002-poor-man-s-solid-picture-support-for-r100.patch b/staging/xf86-video-ati/0002-poor-man-s-solid-picture-support-for-r100.patch
new file mode 100644
index 000000000..3a2779446
--- /dev/null
+++ b/staging/xf86-video-ati/0002-poor-man-s-solid-picture-support-for-r100.patch
@@ -0,0 +1,182 @@
+From f36b911ecc31f689ddceeeb11d10eb7cb4a3428d Mon Sep 17 00:00:00 2001
+From: Alex Deucher <alexander.deucher@amd.com>
+Date: Fri, 13 Apr 2012 13:24:46 -0400
+Subject: [PATCH 2/3] poor man's solid picture support for r100
+
+Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
+---
+ src/radeon_exa_render.c | 101 +++++++++++++++++++++++++++--------------------
+ 1 files changed, 58 insertions(+), 43 deletions(-)
+
+diff --git a/src/radeon_exa_render.c b/src/radeon_exa_render.c
+index b6cc9e4..451a625 100644
+--- a/src/radeon_exa_render.c
++++ b/src/radeon_exa_render.c
+@@ -338,17 +338,8 @@ static Bool R100CheckCompositeTexture(PicturePtr pPict,
+ int unit)
+ {
+ unsigned int repeatType = pPict->repeat ? pPict->repeatType : RepeatNone;
+- int w = pPict->pDrawable->width;
+- int h = pPict->pDrawable->height;
+ int i;
+
+- /* r100 limit should be 2048, there are issues with 2048
+- * see 197a62704742a4a19736c2637ac92d1dc5ab34ed
+- */
+-
+- if ((w > 2047) || (h > 2047))
+- RADEON_FALLBACK(("Picture w/h too large (%dx%d)\n", w, h));
+-
+ for (i = 0; i < sizeof(R100TexFormats) / sizeof(R100TexFormats[0]); i++) {
+ if (R100TexFormats[i].fmt == pPict->format)
+ break;
+@@ -357,7 +348,7 @@ static Bool R100CheckCompositeTexture(PicturePtr pPict,
+ RADEON_FALLBACK(("Unsupported picture format 0x%x\n",
+ (int)pPict->format));
+
+- if (!RADEONCheckTexturePOT(pPict, unit == 0))
++ if (pPict->pDrawable && !RADEONCheckTexturePOT(pPict, unit == 0))
+ return FALSE;
+
+ if (pPict->filter != PictFilterNearest &&
+@@ -392,15 +383,24 @@ static Bool FUNC_NAME(R100TextureSetup)(PicturePtr pPict, PixmapPtr pPix,
+ {
+ RINFO_FROM_SCREEN(pPix->drawable.pScreen);
+ uint32_t txfilter, txformat, txoffset, txpitch;
+- int w = pPict->pDrawable->width;
+- int h = pPict->pDrawable->height;
+- unsigned int repeatType = pPict->repeat ? pPict->repeatType : RepeatNone;
+- Bool repeat = (repeatType == RepeatNormal || repeatType == RepeatReflect) &&
+- !(unit == 0 && (info->accel_state->need_src_tile_x || info->accel_state->need_src_tile_y));
+- int i;
++ unsigned int repeatType;
++ Bool repeat;
++ int i, w, h;
+ struct radeon_exa_pixmap_priv *driver_priv;
+ ACCEL_PREAMBLE();
+
++ if (pPict->pDrawable) {
++ w = pPict->pDrawable->width;
++ h = pPict->pDrawable->height;
++ repeatType = pPict->repeat ? pPict->repeatType : RepeatNone;
++ } else {
++ w = h = 1;
++ repeatType = RepeatNormal;
++ }
++
++ repeat = (repeatType == RepeatNormal || repeatType == RepeatReflect) &&
++ !(unit == 0 && (info->accel_state->need_src_tile_x || info->accel_state->need_src_tile_y));
++
+ txpitch = exaGetPixmapPitch(pPix);
+ txoffset = 0;
+
+@@ -510,22 +510,6 @@ static Bool R100CheckComposite(int op, PicturePtr pSrcPicture,
+ if (op >= sizeof(RadeonBlendOp) / sizeof(RadeonBlendOp[0]))
+ RADEON_FALLBACK(("Unsupported Composite op 0x%x\n", op));
+
+- if (!pSrcPicture->pDrawable)
+- RADEON_FALLBACK(("Solid or gradient pictures not supported yet\n"));
+-
+- /* r100 limit should be 2048, there are issues with 2048
+- * see 197a62704742a4a19736c2637ac92d1dc5ab34ed
+- */
+-
+- pSrcPixmap = RADEONGetDrawablePixmap(pSrcPicture->pDrawable);
+-
+- if (pSrcPixmap->drawable.width > 2047 ||
+- pSrcPixmap->drawable.height > 2047) {
+- RADEON_FALLBACK(("Source w/h too large (%d,%d).\n",
+- pSrcPixmap->drawable.width,
+- pSrcPixmap->drawable.height));
+- }
+-
+ pDstPixmap = RADEONGetDrawablePixmap(pDstPicture->pDrawable);
+
+ if (pDstPixmap->drawable.width > 2047 ||
+@@ -535,20 +519,35 @@ static Bool R100CheckComposite(int op, PicturePtr pSrcPicture,
+ pDstPixmap->drawable.height));
+ }
+
++ if (pSrcPicture->pDrawable) {
++ /* r100 limit should be 2048, there are issues with 2048
++ * see 197a62704742a4a19736c2637ac92d1dc5ab34ed
++ */
++ pSrcPixmap = RADEONGetDrawablePixmap(pSrcPicture->pDrawable);
++
++ if (pSrcPixmap->drawable.width > 2047 ||
++ pSrcPixmap->drawable.height > 2047) {
++ RADEON_FALLBACK(("Source w/h too large (%d,%d).\n",
++ pSrcPixmap->drawable.width,
++ pSrcPixmap->drawable.height));
++ }
++ } else if (pSrcPicture->pSourcePict->type != SourcePictTypeSolidFill)
++ RADEON_FALLBACK(("Gradient pictures not supported yet\n"));
++
+ if (pMaskPicture) {
+ PixmapPtr pMaskPixmap;
+
+- if (!pMaskPicture->pDrawable)
+- RADEON_FALLBACK(("Solid or gradient pictures not supported yet\n"));
+-
+- pMaskPixmap = RADEONGetDrawablePixmap(pMaskPicture->pDrawable);
++ if (pMaskPicture->pDrawable) {
++ pMaskPixmap = RADEONGetDrawablePixmap(pMaskPicture->pDrawable);
+
+- if (pMaskPixmap->drawable.width > 2047 ||
+- pMaskPixmap->drawable.height > 2047) {
+- RADEON_FALLBACK(("Mask w/h too large (%d,%d).\n",
+- pMaskPixmap->drawable.width,
+- pMaskPixmap->drawable.height));
+- }
++ if (pMaskPixmap->drawable.width > 2047 ||
++ pMaskPixmap->drawable.height > 2047) {
++ RADEON_FALLBACK(("Mask w/h too large (%d,%d).\n",
++ pMaskPixmap->drawable.width,
++ pMaskPixmap->drawable.height));
++ }
++ } else if (pMaskPicture->pSourcePict->type != SourcePictTypeSolidFill)
++ RADEON_FALLBACK(("Gradient pictures not supported yet\n"));
+
+ if (pMaskPicture->componentAlpha) {
+ /* Check if it's component alpha that relies on a source alpha and
+@@ -624,7 +623,8 @@ static Bool FUNC_NAME(R100PrepareComposite)(int op,
+ PixmapPtr pMask,
+ PixmapPtr pDst)
+ {
+- RINFO_FROM_SCREEN(pDst->drawable.pScreen);
++ ScreenPtr pScreen = pDst->drawable.pScreen;
++ RINFO_FROM_SCREEN(pScreen);
+ uint32_t dst_format, dst_pitch, colorpitch;
+ uint32_t pp_cntl, blendcntl, cblend, ablend;
+ int pixel_shift;
+@@ -648,12 +648,27 @@ static Bool FUNC_NAME(R100PrepareComposite)(int op,
+
+ CHECK_OFFSET(pDst, 0x0f, "destination");
+
++ if (!pSrc) {
++ pSrc = RADEONSolidPixmap(pScreen, cpu_to_le32(pSrcPicture->pSourcePict->solidFill.color));
++ if (!pSrc)
++ RADEON_FALLBACK("Failed to create solid scratch pixmap\n");
++ }
++
+ if (((dst_pitch >> pixel_shift) & 0x7) != 0)
+ RADEON_FALLBACK(("Bad destination pitch 0x%x\n", (int)dst_pitch));
+
+ if (!RADEONSetupSourceTile(pSrcPicture, pSrc, FALSE, TRUE))
+ return FALSE;
+
++ if (pMaskPicture && !pMask) {
++ pMask = RADEONSolidPixmap(pScreen, cpu_to_le32(pMaskPicture->pSourcePict->solidFill.color));
++ if (!pMask) {
++ if (!pSrcPicture->pDrawable)
++ pScreen->DestroyPixmap(pSrc);
++ RADEON_FALLBACK("Failed to create solid scratch pixmap\n");
++ }
++ }
++
+ RADEONPrepareCompositeCS(op, pSrcPicture, pMaskPicture, pDstPicture,
+ pSrc, pMask, pDst);
+
+--
+1.7.7.5
+
diff --git a/staging/xf86-video-ati/0003-poor-man-s-solid-picture-support-for-r200.patch b/staging/xf86-video-ati/0003-poor-man-s-solid-picture-support-for-r200.patch
new file mode 100644
index 000000000..0a448fc93
--- /dev/null
+++ b/staging/xf86-video-ati/0003-poor-man-s-solid-picture-support-for-r200.patch
@@ -0,0 +1,179 @@
+From c5c8310858f8018a1754f2457d7b102dc7d62b23 Mon Sep 17 00:00:00 2001
+From: Alex Deucher <alexander.deucher@amd.com>
+Date: Fri, 13 Apr 2012 13:28:10 -0400
+Subject: [PATCH 3/3] poor man's solid picture support for r200
+
+Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
+---
+ src/radeon_exa_render.c | 101 +++++++++++++++++++++++++++--------------------
+ 1 files changed, 58 insertions(+), 43 deletions(-)
+
+diff --git a/src/radeon_exa_render.c b/src/radeon_exa_render.c
+index 451a625..7f1a3ff 100644
+--- a/src/radeon_exa_render.c
++++ b/src/radeon_exa_render.c
+@@ -756,17 +756,8 @@ static Bool R200CheckCompositeTexture(PicturePtr pPict,
+ int unit)
+ {
+ unsigned int repeatType = pPict->repeat ? pPict->repeatType : RepeatNone;
+- int w = pPict->pDrawable->width;
+- int h = pPict->pDrawable->height;
+ int i;
+
+- /* r200 limit should be 2048, there are issues with 2048
+- * see bug 19269
+- */
+-
+- if ((w > 2047) || (h > 2047))
+- RADEON_FALLBACK(("Picture w/h too large (%dx%d)\n", w, h));
+-
+ for (i = 0; i < sizeof(R200TexFormats) / sizeof(R200TexFormats[0]); i++)
+ {
+ if (R200TexFormats[i].fmt == pPict->format)
+@@ -776,7 +767,7 @@ static Bool R200CheckCompositeTexture(PicturePtr pPict,
+ RADEON_FALLBACK(("Unsupported picture format 0x%x\n",
+ (int)pPict->format));
+
+- if (!RADEONCheckTexturePOT(pPict, unit == 0))
++ if (pPict->pDrawable && !RADEONCheckTexturePOT(pPict, unit == 0))
+ return FALSE;
+
+ if (pPict->filter != PictFilterNearest &&
+@@ -809,15 +800,24 @@ static Bool FUNC_NAME(R200TextureSetup)(PicturePtr pPict, PixmapPtr pPix,
+ {
+ RINFO_FROM_SCREEN(pPix->drawable.pScreen);
+ uint32_t txfilter, txformat, txoffset, txpitch;
+- int w = pPict->pDrawable->width;
+- int h = pPict->pDrawable->height;
+- unsigned int repeatType = pPict->repeat ? pPict->repeatType : RepeatNone;
+- Bool repeat = (repeatType == RepeatNormal || repeatType == RepeatReflect) &&
+- !(unit == 0 && (info->accel_state->need_src_tile_x || info->accel_state->need_src_tile_y));
+- int i;
++ unsigned int repeatType;
++ Bool repeat;
++ int i, w, h;
+ struct radeon_exa_pixmap_priv *driver_priv;
+ ACCEL_PREAMBLE();
+
++ if (pPict->pDrawable) {
++ w = pPict->pDrawable->width;
++ h = pPict->pDrawable->height;
++ repeatType = pPict->repeat ? pPict->repeatType : RepeatNone;
++ } else {
++ w = h = 1;
++ repeatType = RepeatNormal;
++ }
++
++ repeat = (repeatType == RepeatNormal || repeatType == RepeatReflect) &&
++ !(unit == 0 && (info->accel_state->need_src_tile_x || info->accel_state->need_src_tile_y));
++
+ txpitch = exaGetPixmapPitch(pPix);
+
+ txoffset = 0;
+@@ -926,22 +926,6 @@ static Bool R200CheckComposite(int op, PicturePtr pSrcPicture, PicturePtr pMaskP
+ if (op >= sizeof(RadeonBlendOp) / sizeof(RadeonBlendOp[0]))
+ RADEON_FALLBACK(("Unsupported Composite op 0x%x\n", op));
+
+- if (!pSrcPicture->pDrawable)
+- RADEON_FALLBACK(("Solid or gradient pictures not supported yet\n"));
+-
+- /* r200 limit should be 2048, there are issues with 2048
+- * see bug 19269
+- */
+-
+- pSrcPixmap = RADEONGetDrawablePixmap(pSrcPicture->pDrawable);
+-
+- if (pSrcPixmap->drawable.width > 2047 ||
+- pSrcPixmap->drawable.height > 2047) {
+- RADEON_FALLBACK(("Source w/h too large (%d,%d).\n",
+- pSrcPixmap->drawable.width,
+- pSrcPixmap->drawable.height));
+- }
+-
+ pDstPixmap = RADEONGetDrawablePixmap(pDstPicture->pDrawable);
+
+ if (pDstPixmap->drawable.width > 2047 ||
+@@ -951,20 +935,35 @@ static Bool R200CheckComposite(int op, PicturePtr pSrcPicture, PicturePtr pMaskP
+ pDstPixmap->drawable.height));
+ }
+
++ if (pSrcPicture->pDrawable) {
++ /* r200 limit should be 2048, there are issues with 2048
++ * see 197a62704742a4a19736c2637ac92d1dc5ab34ed
++ */
++ pSrcPixmap = RADEONGetDrawablePixmap(pSrcPicture->pDrawable);
++
++ if (pSrcPixmap->drawable.width > 2047 ||
++ pSrcPixmap->drawable.height > 2047) {
++ RADEON_FALLBACK(("Source w/h too large (%d,%d).\n",
++ pSrcPixmap->drawable.width,
++ pSrcPixmap->drawable.height));
++ }
++ } else if (pSrcPicture->pSourcePict->type != SourcePictTypeSolidFill)
++ RADEON_FALLBACK(("Gradient pictures not supported yet\n"));
++
+ if (pMaskPicture) {
+ PixmapPtr pMaskPixmap;
+
+- if (!pMaskPicture->pDrawable)
+- RADEON_FALLBACK(("Solid or gradient pictures not supported yet\n"));
+-
+- pMaskPixmap = RADEONGetDrawablePixmap(pMaskPicture->pDrawable);
++ if (pMaskPicture->pDrawable) {
++ pMaskPixmap = RADEONGetDrawablePixmap(pMaskPicture->pDrawable);
+
+- if (pMaskPixmap->drawable.width > 2047 ||
+- pMaskPixmap->drawable.height > 2047) {
+- RADEON_FALLBACK(("Mask w/h too large (%d,%d).\n",
+- pMaskPixmap->drawable.width,
+- pMaskPixmap->drawable.height));
+- }
++ if (pMaskPixmap->drawable.width > 2047 ||
++ pMaskPixmap->drawable.height > 2047) {
++ RADEON_FALLBACK(("Mask w/h too large (%d,%d).\n",
++ pMaskPixmap->drawable.width,
++ pMaskPixmap->drawable.height));
++ }
++ } else if (pMaskPicture->pSourcePict->type != SourcePictTypeSolidFill)
++ RADEON_FALLBACK(("Gradient pictures not supported yet\n"));
+
+ if (pMaskPicture->componentAlpha) {
+ /* Check if it's component alpha that relies on a source alpha and
+@@ -997,7 +996,8 @@ static Bool FUNC_NAME(R200PrepareComposite)(int op, PicturePtr pSrcPicture,
+ PicturePtr pMaskPicture, PicturePtr pDstPicture,
+ PixmapPtr pSrc, PixmapPtr pMask, PixmapPtr pDst)
+ {
+- RINFO_FROM_SCREEN(pDst->drawable.pScreen);
++ ScreenPtr pScreen = pDst->drawable.pScreen;
++ RINFO_FROM_SCREEN(pScreen);
+ uint32_t dst_format, dst_pitch;
+ uint32_t pp_cntl, blendcntl, cblend, ablend, colorpitch;
+ int pixel_shift;
+@@ -1024,9 +1024,24 @@ static Bool FUNC_NAME(R200PrepareComposite)(int op, PicturePtr pSrcPicture,
+ if (((dst_pitch >> pixel_shift) & 0x7) != 0)
+ RADEON_FALLBACK(("Bad destination pitch 0x%x\n", (int)dst_pitch));
+
++ if (!pSrc) {
++ pSrc = RADEONSolidPixmap(pScreen, cpu_to_le32(pSrcPicture->pSourcePict->solidFill.color));
++ if (!pSrc)
++ RADEON_FALLBACK("Failed to create solid scratch pixmap\n");
++ }
++
+ if (!RADEONSetupSourceTile(pSrcPicture, pSrc, FALSE, TRUE))
+ return FALSE;
+
++ if (pMaskPicture && !pMask) {
++ pMask = RADEONSolidPixmap(pScreen, cpu_to_le32(pMaskPicture->pSourcePict->solidFill.color));
++ if (!pMask) {
++ if (!pSrcPicture->pDrawable)
++ pScreen->DestroyPixmap(pSrc);
++ RADEON_FALLBACK("Failed to create solid scratch pixmap\n");
++ }
++ }
++
+ RADEONPrepareCompositeCS(op, pSrcPicture, pMaskPicture, pDstPicture,
+ pSrc, pMask, pDst);
+
+--
+1.7.7.5
+
diff --git a/staging/xf86-video-ati/PKGBUILD b/staging/xf86-video-ati/PKGBUILD
new file mode 100644
index 000000000..4b8173027
--- /dev/null
+++ b/staging/xf86-video-ati/PKGBUILD
@@ -0,0 +1,61 @@
+# $Id: PKGBUILD 159723 2012-05-26 09:58:25Z andyrtr $
+# Maintainer: Jan de Groot <jgc@archlinux.org>
+# Contributor: Alexander Baldeck <alexander@archlinux.org>
+
+pkgname=xf86-video-ati
+pkgver=6.14.99
+_gitdate=20120517
+pkgrel=1.${_gitdate} # UMS/EXA: Add reminder for potential solid picture performance issue.
+pkgdesc="X.org ati video driver"
+arch=('i686' 'x86_64')
+url="http://xorg.freedesktop.org/"
+license=('custom')
+depends=('libpciaccess' 'libdrm>=2.4.33' 'udev>=183' 'pixman' 'ati-dri')
+makedepends=('xorg-server-devel>=1.11.99.902' 'xf86driproto' 'mesa' 'glproto')
+conflicts=('xorg-server<1.11.99.902')
+groups=('xorg-drivers' 'xorg')
+options=('!libtool')
+source=(#${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2
+ ${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2::http://cgit.freedesktop.org/xorg/driver/xf86-video-ati/snapshot/xf86-video-ati-3fb694b308ebadd1b849836059b6b56bb19385f7.tar.gz
+ git_fixes.diff
+ 0000-poor-man-s-solid-picture-support-for-r300-r600.patch
+ 0001-poor-man-s-solid-picture-support-for-evergreen.patch
+ 0002-poor-man-s-solid-picture-support-for-r100.patch
+ 0003-poor-man-s-solid-picture-support-for-r200.patch)
+sha1sums=('75ad000bc00599e1797134f2d20d3094cba6af92'
+ '8b774e2f0310075cff2b7d874b0bed38d6245769'
+ '787f88c428f56ca6e96ba5eaf043a30bddfd0e23'
+ '69359a6623fe0f2214790c8ad40cac1a680a3825'
+ 'c0709ab82728e34838a8aeead7d1b79b7faf09bd'
+ '77a519e250c27a9fb94eeb52da655eed7c5f2eca')
+sha1sums=('80c12b88e193354af204b13689b2fae922922c6c'
+ '8b774e2f0310075cff2b7d874b0bed38d6245769'
+ '787f88c428f56ca6e96ba5eaf043a30bddfd0e23'
+ '69359a6623fe0f2214790c8ad40cac1a680a3825'
+ 'c0709ab82728e34838a8aeead7d1b79b7faf09bd'
+ '77a519e250c27a9fb94eeb52da655eed7c5f2eca')
+
+build() {
+ #cd ${srcdir}/${pkgname}-${pkgver}
+ cd ${srcdir}/${pkgname}*
+ #patch -Np1 -i ${srcdir}/git_fixes.diff
+
+ # fix rendering issues with recent cairo - testing attemp taken from https://bugs.freedesktop.org/show_bug.cgi?id=47266
+ # and http://lists.x.org/archives/xorg-driver-ati/2012-April/022724.html
+# patch -Np1 -i ${srcdir}/0000-poor-man-s-solid-picture-support-for-r300-r600.patch
+# patch -Np1 -i ${srcdir}/0001-poor-man-s-solid-picture-support-for-evergreen.patch
+# patch -Np1 -i ${srcdir}/0002-poor-man-s-solid-picture-support-for-r100.patch
+# patch -Np1 -i ${srcdir}/0003-poor-man-s-solid-picture-support-for-r200.patch
+
+ ./autogen.sh --prefix=/usr --enable-dri
+# ./configure --prefix=/usr --enable-dri
+ make
+}
+
+package() {
+ #cd "${srcdir}/${pkgname}-${pkgver}"
+ cd ${srcdir}/${pkgname}*
+ make "DESTDIR=${pkgdir}" install
+ install -m755 -d "${pkgdir}/usr/share/licenses/${pkgname}"
+ install -m644 COPYING "${pkgdir}/usr/share/licenses/${pkgname}/"
+}
diff --git a/staging/xf86-video-ati/git_fixes.diff b/staging/xf86-video-ati/git_fixes.diff
new file mode 100644
index 000000000..0c4518319
--- /dev/null
+++ b/staging/xf86-video-ati/git_fixes.diff
@@ -0,0 +1,33 @@
+From d282719a9c2fb0ee32830aa75b8dfbb9392954ed Mon Sep 17 00:00:00 2001
+From: Jerome Glisse <jglisse@redhat.com>
+Date: Wed, 04 Apr 2012 21:08:30 +0000
+Subject: r6xx-r9xx: force 1D tiling for buffer with height < 64
+
+Due to some old kernel issue, height is 8 aligned insided the ddx
+For buffer with height btw 57 & 63 this lead ddx to believe it can
+allocate a 2D tiled surface while mesa will not align height and
+will assume 1D tiled leading to disagreement and rendering issue.
+This patch force buffer with height < 64 to be 1D tiled.
+
+Signed-off-by: Jerome Glisse <jglisse@redhat.com>
+---
+diff --git a/src/radeon_exa.c b/src/radeon_exa.c
+index 99a5806..270dad4 100644
+--- a/src/radeon_exa.c
++++ b/src/radeon_exa.c
+@@ -511,6 +511,13 @@ void *RADEONEXACreatePixmap2(ScreenPtr pScreen, int width, int height,
+ surface.last_level = 0;
+ surface.bpe = cpp;
+ surface.nsamples = 1;
++ if (height < 64) {
++ /* disable 2d tiling for small surface to work around
++ * the fact that ddx align height to 8 pixel for old
++ * obscure reason i can't remember
++ */
++ tiling &= ~RADEON_TILING_MACRO;
++ }
+ surface.flags = RADEON_SURF_SCANOUT;
+ surface.flags |= RADEON_SURF_SET(RADEON_SURF_TYPE_2D, TYPE);
+ surface.flags |= RADEON_SURF_SET(RADEON_SURF_MODE_LINEAR, MODE);
+--
+cgit v0.9.0.2-2-gbebe
diff --git a/staging/xf86-video-intel/PKGBUILD b/staging/xf86-video-intel/PKGBUILD
new file mode 100644
index 000000000..d57f65c68
--- /dev/null
+++ b/staging/xf86-video-intel/PKGBUILD
@@ -0,0 +1,30 @@
+# $Id: PKGBUILD 159725 2012-05-26 10:02:38Z andyrtr $
+# Maintainer: Jan de Groot <jgc@archlinux.org>
+
+pkgname=xf86-video-intel
+pkgver=2.19.0
+pkgrel=2
+pkgdesc="X.org Intel i810/i830/i915/945G/G965+ video drivers"
+arch=(i686 x86_64)
+url="http://xorg.freedesktop.org/"
+license=('custom')
+depends=('intel-dri' 'libxvmc' 'libpciaccess' 'libdrm' 'xcb-util>=0.3.8' 'libxfixes' 'udev>=183')
+makedepends=('xorg-server-devel>=1.12.0' 'libx11' 'libdrm' 'xf86driproto' 'glproto' 'mesa' 'libxvmc' 'libxrender')
+conflicts=('xorg-server<1.12.0' 'xf86-video-i810' 'xf86-video-intel-legacy')
+options=('!libtool')
+groups=('xorg-drivers' 'xorg')
+source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2)
+sha1sums=('131934cf5e90bd48c883804cc644c4cb8b1de100')
+
+build() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
+ ./configure --prefix=/usr --enable-dri
+ make
+}
+
+package() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
+ make DESTDIR="${pkgdir}" install
+ install -m755 -d "${pkgdir}/usr/share/licenses/${pkgname}"
+ install -m644 COPYING "${pkgdir}/usr/share/licenses/${pkgname}/"
+}
diff --git a/staging/xf86-video-nouveau/PKGBUILD b/staging/xf86-video-nouveau/PKGBUILD
new file mode 100644
index 000000000..6e5c8d562
--- /dev/null
+++ b/staging/xf86-video-nouveau/PKGBUILD
@@ -0,0 +1,41 @@
+# $Id: PKGBUILD 159753 2012-05-26 15:02:22Z ibiru $
+# Maintainer: Andreas Radke <andyrtr@archlinux.org>
+# Contributor: buddabrod <buddabrod@gmail.com>
+
+pkgname=xf86-video-nouveau
+_gitdate=20120512
+pkgver=0.0.16_git${_gitdate} # see configure.ac
+pkgrel=2
+pkgdesc="Open Source 2D acceleration driver for nVidia cards (experimental)"
+arch=('i686' 'x86_64')
+url="http://nouveau.freedesktop.org/wiki/"
+license=('GPL') #and MIT, not yet a license file, see http://nouveau.freedesktop.org/wiki/FAQ#head-09f75d03eb30011c754038a3893119a70745de4e
+depends=('libdrm-nouveau' 'udev')
+optdepends=('nouveau-dri: experimental gallium3d features')
+makedepends=('xorg-server-devel' 'libdrm-new' 'xf86driproto')
+conflicts=('xorg-server<1.11.99.902')
+options=('!libtool')
+install=$pkgname.install
+source=(ftp://ftp.archlinux.org/other/$pkgname/xf86-video-nouveau-${_gitdate}.tar.bz2)
+md5sums=('3e27e283219936d64c194eca24cd81cd')
+
+# source PKGBUILD && mksource
+mksource() {
+ mkdir /tmp/$pkgname-${_gitdate}
+ pushd /tmp/$pkgname-${_gitdate}
+ git clone -v --depth 1 git://anongit.freedesktop.org/nouveau/xf86-video-nouveau
+ cd xf86-video-nouveau
+ git archive --prefix=xf86-video-nouveau-${_gitdate}/ --format=tar HEAD | bzip2 > /tmp/$pkgname-${_gitdate}/$pkgname-${_gitdate}.tar.bz2
+ popd
+}
+
+build() {
+ cd $srcdir/xf86-video-nouveau-${_gitdate}
+ ./autogen.sh --prefix=/usr
+ make
+}
+
+package() {
+ cd $srcdir/xf86-video-nouveau-${_gitdate}
+ make DESTDIR=$pkgdir install
+}
diff --git a/staging/xf86-video-nouveau/xf86-video-nouveau.install b/staging/xf86-video-nouveau/xf86-video-nouveau.install
new file mode 100644
index 000000000..027154ff3
--- /dev/null
+++ b/staging/xf86-video-nouveau/xf86-video-nouveau.install
@@ -0,0 +1,16 @@
+post_install () {
+ cat << _EOF
+ ==> make sure you use KernelModeSetting (KMS)
+ ==> see http://wiki.archlinux.org/index.php/Nouveau#KMS for more
+_EOF
+}
+
+post_upgrade() {
+ if [ "`vercmp $2 0.0.15_git20100117-1`" -lt 0 ]; then
+ cat << _EOF
+ ==> ATTENTION: Usermode support has been dropped
+ ==> make sure you use KernelModeSetting (KMS)
+ ==> see http://wiki.archlinux.org/index.php/Nouveau#KMS for more
+_EOF
+ fi
+}
diff --git a/staging/xfconf/PKGBUILD b/staging/xfconf/PKGBUILD
new file mode 100644
index 000000000..757bcc41d
--- /dev/null
+++ b/staging/xfconf/PKGBUILD
@@ -0,0 +1,49 @@
+# $Id: PKGBUILD 159773 2012-05-26 18:14:15Z foutrelis $
+# Maintainer: Evangelos Foutras <evangelos@foutrelis.com>
+# Contributor: tobias <tobias funnychar archlinux.org>
+
+pkgname=xfconf
+pkgver=4.10.0
+pkgrel=2
+pkgdesc="A simple client-server configuration storage and query system"
+arch=('i686' 'x86_64')
+url="http://www.xfce.org/"
+license=('GPL2')
+groups=('xfce4')
+# http://www.xfce.org/documentation/requirements
+# keep dbus, see also http://bugs.archlinux.org/task/14536
+depends=('libxfce4util' 'dbus-glib' 'dbus')
+makedepends=('pkgconfig' 'perl-extutils-depends' 'perl-extutils-pkgconfig'
+ 'glib-perl' 'intltool' 'gtk-doc' 'chrpath')
+options=('!libtool' '!emptydirs')
+source=(http://archive.xfce.org/src/xfce/$pkgname/4.10/$pkgname-$pkgver.tar.bz2)
+sha256sums=('175219a441cc7d0f210bbd1a3b0abba41598627cd9db27235811400c3e100576')
+
+build() {
+ cd "$srcdir/$pkgname-$pkgver"
+
+ ./configure \
+ --prefix=/usr \
+ --sysconfdir=/etc \
+ --libexecdir=/usr/lib/xfce4 \
+ --localstatedir=/var \
+ --disable-static \
+ --enable-gtk-doc \
+ --with-perl-options=INSTALLDIRS="vendor" \
+ --disable-debug
+ make
+}
+
+package() {
+ cd "$srcdir/$pkgname-$pkgver"
+
+ make DESTDIR="$pkgdir" install
+
+ # remove unneeded dynloader bootstrap file
+ rm "$pkgdir/usr/lib/perl5/vendor_perl/auto/Xfce4/Xfconf/Xfconf.bs"
+
+ # fix insecure rpath, http://bugs.archlinux.org/task/19980
+ chrpath -d "$pkgdir/usr/lib/perl5/vendor_perl/auto/Xfce4/Xfconf/Xfconf.so"
+}
+
+# vim:set ts=2 sw=2 et:
diff --git a/staging/xorg-server/10-quirks.conf b/staging/xorg-server/10-quirks.conf
new file mode 100644
index 000000000..7afad22dc
--- /dev/null
+++ b/staging/xorg-server/10-quirks.conf
@@ -0,0 +1,10 @@
+# Collection of quirks and blacklist/whitelists for specific devices.
+
+
+# Accelerometer device, posts data through ABS_X/ABS_Y, making X unusable
+# http://bugs.freedesktop.org/show_bug.cgi?id=22442
+Section "InputClass"
+ Identifier "ThinkPad HDAPS accelerometer blacklist"
+ MatchProduct "ThinkPad HDAPS accelerometer data"
+ Option "Ignore" "on"
+EndSection
diff --git a/staging/xorg-server/EXA_Fall_back_earlier_and_more_thoroughly_from_exaGlyphsV2.diff b/staging/xorg-server/EXA_Fall_back_earlier_and_more_thoroughly_from_exaGlyphsV2.diff
new file mode 100644
index 000000000..12c110151
--- /dev/null
+++ b/staging/xorg-server/EXA_Fall_back_earlier_and_more_thoroughly_from_exaGlyphsV2.diff
@@ -0,0 +1,116 @@
+--- xorg-server-1.12.1/exa/exa_glyphs.c 2012-03-30 04:57:25.000000000 +0200
++++ xorg-server-1.12.1/exa_glyphs.c.new 2012-04-15 11:48:51.683214230 +0200
+@@ -686,6 +686,7 @@
+ PixmapPtr pMaskPixmap = 0;
+ PicturePtr pMask = NULL;
+ ScreenPtr pScreen = pDst->pDrawable->pScreen;
++ ExaScreenPriv(pScreen);
+ int width = 0, height = 0;
+ int x, y;
+ int first_xOff = list->xOff, first_yOff = list->yOff;
+@@ -697,7 +698,6 @@
+ ExaGlyphBuffer buffer;
+
+ if (maskFormat) {
+- ExaScreenPriv(pScreen);
+ GCPtr pGC;
+ xRectangle rect;
+
+@@ -719,22 +719,20 @@
+ maskFormat->depth,
+ CREATE_PIXMAP_USAGE_SCRATCH);
+ if (!pMaskPixmap)
+- return;
++ goto fallback;
+ component_alpha = NeedsComponent(maskFormat->format);
+ pMask = CreatePicture(0, &pMaskPixmap->drawable,
+ maskFormat, CPComponentAlpha, &component_alpha,
+ serverClient, &error);
+- if (!pMask ||
+- (!component_alpha && pExaScr->info->CheckComposite &&
+- !(*pExaScr->info->CheckComposite) (PictOpAdd, pSrc, NULL, pMask)))
++ (*pScreen->DestroyPixmap) (pMaskPixmap);
++ if (!pMask)
++ goto fallback;
++
++ if (!component_alpha && pExaScr->info->CheckComposite &&
++ !(*pExaScr->info->CheckComposite) (PictOpAdd, pSrc, NULL, pMask))
+ {
+ PictFormatPtr argbFormat;
+
+- (*pScreen->DestroyPixmap) (pMaskPixmap);
+-
+- if (!pMask)
+- return;
+-
+ /* The driver can't seem to composite to a8, let's try argb (but
+ * without component-alpha) */
+ FreePicture((pointer) pMask, (XID) 0);
+@@ -748,15 +746,25 @@
+ maskFormat->depth,
+ CREATE_PIXMAP_USAGE_SCRATCH);
+ if (!pMaskPixmap)
+- return;
++ goto fallback;
+
+ pMask = CreatePicture(0, &pMaskPixmap->drawable, maskFormat, 0, 0,
+ serverClient, &error);
+- if (!pMask) {
+- (*pScreen->DestroyPixmap) (pMaskPixmap);
+- return;
+- }
++ (*pScreen->DestroyPixmap) (pMaskPixmap);
++ if (!pMask)
++ goto fallback;
+ }
++
++ if (pExaScr->info->CheckComposite &&
++ (!(*pExaScr->info->CheckComposite) (PictOpAdd, pSrc, NULL, pMask) ||
++ (!(*pExaScr->info->CheckComposite) (op, pSrc, pMask, pDst) &&
++ (op != PictOpOver ||
++ !(*pExaScr->info->CheckComposite) (PictOpOutReverse, pSrc, pMask, pDst) ||
++ !(*pExaScr->info->CheckComposite) (PictOpOver, pSrc, pMask, pDst))))) {
++ FreePicture ((pointer) pMask, (XID) 0);
++ goto fallback;
++ }
++
+ pGC = GetScratchGC(pMaskPixmap->drawable.depth, pScreen);
+ ValidateGC(&pMaskPixmap->drawable, pGC);
+ rect.x = 0;
+@@ -769,6 +777,13 @@
+ y = -extents.y1;
+ }
+ else {
++ if (pExaScr->info->CheckComposite &&
++ !(*pExaScr->info->CheckComposite) (op, pSrc, NULL, pDst) &&
++ (op != PictOpOver ||
++ !(*pExaScr->info->CheckComposite) (PictOpOutReverse, pSrc, NULL, pDst) ||
++ !(*pExaScr->info->CheckComposite) (PictOpOver, pSrc, NULL, pDst)))
++ goto fallback;
++
+ x = 0;
+ y = 0;
+ }
+@@ -834,6 +849,10 @@
+ xSrc + x - first_xOff,
+ ySrc + y - first_yOff, 0, 0, x, y, width, height);
+ FreePicture((pointer) pMask, (XID) 0);
+- (*pScreen->DestroyPixmap) (pMaskPixmap);
+ }
++
++ return;
++
++fallback:
++ ExaCheckGlyphs(op, pSrc, pDst, maskFormat, xSrc, ySrc, nlist, list, glyphs);
+ }
+--- xorg-server-1.12.1/exa/exa_render.c 2012-03-30 04:57:25.000000000 +0200
++++ xorg-server-1.12.1/exa_render.c.new 2012-04-15 11:50:35.272482047 +0200
+@@ -878,7 +878,7 @@
+ Bool saveMaskRepeat = pMask ? pMask->repeat : 0;
+ RegionRec region;
+
+- if (pExaScr->swappedOut)
++ if (pExaScr->fallback_counter || pExaScr->swappedOut)
+ goto fallback;
+
+ /* Remove repeat in source if useless */
diff --git a/staging/xorg-server/PKGBUILD b/staging/xorg-server/PKGBUILD
new file mode 100644
index 000000000..78b533fe1
--- /dev/null
+++ b/staging/xorg-server/PKGBUILD
@@ -0,0 +1,200 @@
+# $Id: PKGBUILD 159720 2012-05-26 09:47:01Z andyrtr $
+# Maintainer: Jan de Groot <jgc@archlinux.org>
+
+pkgbase=xorg-server
+pkgname=('xorg-server' 'xorg-server-xephyr' 'xorg-server-xdmx' 'xorg-server-xvfb' 'xorg-server-xnest' 'xorg-server-common' 'xorg-server-devel')
+pkgver=1.12.1.902
+pkgrel=2
+arch=('i686' 'x86_64')
+license=('custom')
+url="http://xorg.freedesktop.org"
+makedepends=('pixman' 'libx11' 'mesa' 'libgl' 'xf86driproto' 'xcmiscproto' 'xtrans' 'bigreqsproto' 'randrproto' 'inputproto' 'fontsproto' 'videoproto'
+ 'compositeproto' 'recordproto' 'scrnsaverproto' 'resourceproto' 'xineramaproto' 'libxkbfile' 'libxfont' 'renderproto' 'libpciaccess'
+ 'libxv' 'xf86dgaproto' 'libxmu' 'libxrender' 'libxi' 'dmxproto' 'libxaw' 'libdmx' 'libxtst' 'libxres' 'xorg-xkbcomp' 'xorg-util-macros'
+ 'xorg-font-util' 'glproto' 'dri2proto' 'udev>=183' 'libgcrypt')
+options=('!libtool')
+source=(${url}/releases/individual/xserver/${pkgbase}-${pkgver}.tar.bz2
+ autoconfig-nvidia.patch
+ autoconfig-sis.patch
+ #EXA_Fall_back_earlier_and_more_thoroughly_from_exaGlyphsV2.diff
+ #git-fixes.patch
+ xvfb-run
+ xvfb-run.1
+ 10-quirks.conf)
+sha256sums=('052efb01c47348b4138c89ad5654be022a4d952acc6129b2ad2659bc1ff4d509'
+ '66e25f76a7496c429e0aff4b0670f168719bb0ceaeb88c6f2272f2bf3ed21162'
+ 'd027776fac1f7675b0a9ee817502290b1c45f9c09b0f0a6bb058c35f92361e84'
+ 'ff0156309470fc1d378fd2e104338020a884295e285972cc88e250e031cc35b9'
+ '2460adccd3362fefd4cdc5f1c70f332d7b578091fb9167bf88b5f91265bbd776'
+ '94612f5c0d34a3b7152915c2e285c7b462e9d8e38d3539bd551a339498eac166')
+
+build() {
+ cd "${srcdir}/${pkgbase}-${pkgver}"
+
+ # Use nouveau/nv/nvidia drivers for nvidia devices
+ patch -Np1 -i "${srcdir}/autoconfig-nvidia.patch"
+
+ # Use unofficial imedia SiS driver for supported SiS devices
+ patch -Np0 -i "${srcdir}/autoconfig-sis.patch"
+
+ # fix glitches and crashes with EXA and cairo 1.12
+ # taken from https://bugs.freedesktop.org/show_bug.cgi?id=47266
+ # and reworked for 1.12.1 changes
+# patch -Np1 -i ${srcdir}/EXA_Fall_back_earlier_and_more_thoroughly_from_exaGlyphsV2.diff
+
+ # Add post-release patches from 1.12 branch
+# patch -Np1 -i ${srcdir}/git-fixes.patch
+
+ autoreconf -fi
+ ./configure --prefix=/usr \
+ --enable-ipv6 \
+ --enable-dri \
+ --enable-dmx \
+ --enable-xvfb \
+ --enable-xnest \
+ --enable-composite \
+ --enable-xcsecurity \
+ --enable-xorg \
+ --enable-xephyr \
+ --enable-glx-tls \
+ --enable-kdrive \
+ --enable-kdrive-evdev \
+ --enable-kdrive-kbd \
+ --enable-kdrive-mouse \
+ --enable-install-setuid \
+ --enable-config-udev \
+ --disable-config-dbus \
+ --enable-record \
+ --disable-xfbdev \
+ --disable-xfake \
+ --disable-static \
+ --sysconfdir=/etc/X11 \
+ --localstatedir=/var \
+ --with-xkb-path=/usr/share/X11/xkb \
+ --with-xkb-output=/var/lib/xkb \
+ --with-fontrootdir=/usr/share/fonts
+ make
+
+ # Disable subdirs for make install rule to make splitting easier
+ sed -e 's/^DMX_SUBDIRS =.*/DMX_SUBDIRS =/' \
+ -e 's/^XVFB_SUBDIRS =.*/XVFB_SUBDIRS =/' \
+ -e 's/^XNEST_SUBDIRS =.*/XNEST_SUBDIRS = /' \
+ -e 's/^KDRIVE_SUBDIRS =.*/KDRIVE_SUBDIRS =/' \
+ -i hw/Makefile
+}
+
+package_xorg-server-common() {
+ pkgdesc="Xorg server common files"
+ depends=('xkeyboard-config' 'xorg-xkbcomp' 'xorg-setxkbmap' 'xorg-fonts-misc')
+
+ cd "${srcdir}/${pkgbase}-${pkgver}"
+ install -m755 -d "${pkgdir}/usr/share/licenses/xorg-server-common"
+ install -m644 COPYING "${pkgdir}/usr/share/licenses/xorg-server-common"
+
+ make -C xkb DESTDIR="${pkgdir}" install-data
+
+ install -m755 -d "${pkgdir}/usr/share/man/man1"
+ install -m644 man/Xserver.1 "${pkgdir}/usr/share/man/man1/"
+
+ install -m755 -d "${pkgdir}/usr/lib/xorg"
+ install -m644 dix/protocol.txt "${pkgdir}/usr/lib/xorg/"
+}
+
+package_xorg-server() {
+ pkgdesc="Xorg X server"
+ depends=(libxdmcp libxfont udev libpciaccess libdrm pixman libgcrypt libxau xorg-server-common xf86-input-evdev)
+ backup=('etc/X11/xorg.conf.d/10-evdev.conf' 'etc/X11/xorg.conf.d/10-quirks.conf')
+ provides=('x-server')
+ groups=('xorg')
+ conflicts=('nvidia-utils<=290.10')
+
+ cd "${srcdir}/${pkgbase}-${pkgver}"
+ make DESTDIR="${pkgdir}" install
+
+ install -m755 -d "${pkgdir}/etc/X11"
+ mv "${pkgdir}/usr/share/X11/xorg.conf.d" "${pkgdir}/etc/X11/"
+ install -m644 "${srcdir}/10-quirks.conf" "${pkgdir}/etc/X11/xorg.conf.d/"
+
+ rmdir "${pkgdir}/usr/share/X11"
+
+ # Needed for non-mesa drivers, libgl will restore it
+ mv "${pkgdir}/usr/lib/xorg/modules/extensions/libglx.so" \
+ "${pkgdir}/usr/lib/xorg/modules/extensions/libglx.xorg"
+
+ rm -rf "${pkgdir}/var"
+
+ rm -f "${pkgdir}/usr/share/man/man1/Xserver.1"
+ rm -f "${pkgdir}/usr/lib/xorg/protocol.txt"
+
+ install -m755 -d "${pkgdir}/usr/share/licenses/xorg-server"
+ ln -sf ../xorg-server-common/COPYING "${pkgdir}/usr/share/licenses/xorg-server/COPYING"
+
+ rm -rf "${pkgdir}/usr/lib/pkgconfig"
+ rm -rf "${pkgdir}/usr/include"
+ rm -rf "${pkgdir}/usr/share/aclocal"
+}
+
+package_xorg-server-xephyr() {
+ pkgdesc="A nested X server that runs as an X application"
+ depends=(libxfont libgl libgcrypt libxv pixman xorg-server-common)
+
+ cd "${srcdir}/${pkgbase}-${pkgver}/hw/kdrive"
+ make DESTDIR="${pkgdir}" install
+
+ install -m755 -d "${pkgdir}/usr/share/licenses/xorg-server-xephyr"
+ ln -sf ../xorg-server-common/COPYING "${pkgdir}/usr/share/licenses/xorg-server-xephyr/COPYING"
+}
+
+package_xorg-server-xvfb() {
+ pkgdesc="Virtual framebuffer X server"
+ depends=(libxfont libxdmcp libxau libgcrypt pixman xorg-server-common)
+
+ cd "${srcdir}/${pkgbase}-${pkgver}/hw/vfb"
+ make DESTDIR="${pkgdir}" install
+
+ install -m755 "${srcdir}/xvfb-run" "${pkgdir}/usr/bin/"
+ install -m644 "${srcdir}/xvfb-run.1" "${pkgdir}/usr/share/man/man1/"
+
+ install -m755 -d "${pkgdir}/usr/share/licenses/xorg-server-xvfb"
+ ln -sf ../xorg-server-common/COPYING "${pkgdir}/usr/share/licenses/xorg-server-xvfb/COPYING"
+}
+
+package_xorg-server-xnest() {
+ pkgdesc="A nested X server that runs as an X application"
+ depends=(libxfont libxext libgcrypt pixman xorg-server-common)
+
+ cd "${srcdir}/${pkgbase}-${pkgver}/hw/xnest"
+ make DESTDIR="${pkgdir}" install
+
+ install -m755 -d "${pkgdir}/usr/share/licenses/xorg-server-xnest"
+ ln -sf ../xorg-server-common/COPYING "${pkgdir}/usr/share/licenses/xorg-server-xnest/COPYING"
+}
+
+package_xorg-server-xdmx() {
+ pkgdesc="Distributed Multihead X Server and utilities"
+ depends=(libxfont libxi libgcrypt libxaw libxrender libdmx libxfixes pixman xorg-server-common)
+
+ cd "${srcdir}/${pkgbase}-${pkgver}/hw/dmx"
+ make DESTDIR="${pkgdir}" install
+
+ install -m755 -d "${pkgdir}/usr/share/licenses/xorg-server-xdmx"
+ ln -sf ../xorg-server-common/COPYING "${pkgdir}/usr/share/licenses/xorg-server-xdmx/COPYING"
+}
+
+package_xorg-server-devel() {
+ pkgdesc="Development files for the X.Org X server"
+ depends=(xproto randrproto renderproto xextproto inputproto kbproto fontsproto videoproto dri2proto xineramaproto xorg-util-macros pixman libpciaccess)
+
+ cd "${srcdir}/${pkgbase}-${pkgver}"
+ make DESTDIR="${pkgdir}" install
+
+ rm -rf "${pkgdir}/usr/bin"
+ rm -rf "${pkgdir}/usr/share/man"
+ rm -rf "${pkgdir}/usr/share/doc"
+ rm -rf "${pkgdir}/usr/share/X11"
+ rm -rf "${pkgdir}/usr/lib/xorg"
+ rm -rf "${pkgdir}/var"
+
+ install -m755 -d "${pkgdir}/usr/share/licenses/xorg-server-devel"
+ ln -sf ../xorg-server-common/COPYING "${pkgdir}/usr/share/licenses/xorg-server-devel/COPYING"
+}
diff --git a/staging/xorg-server/autoconfig-nvidia.patch b/staging/xorg-server/autoconfig-nvidia.patch
new file mode 100644
index 000000000..6d5220ac7
--- /dev/null
+++ b/staging/xorg-server/autoconfig-nvidia.patch
@@ -0,0 +1,28 @@
+diff -Nur xorg-server-1.11.99.902.orig/hw/xfree86/common/xf86pciBus.c xorg-server-1.11.99.902/hw/xfree86/common/xf86pciBus.c
+--- xorg-server-1.11.99.902.orig/hw/xfree86/common/xf86pciBus.c 2012-02-10 10:10:37.583014924 +0000
++++ xorg-server-1.11.99.902/hw/xfree86/common/xf86pciBus.c 2012-02-10 11:16:07.148971317 +0000
+@@ -1144,7 +1144,23 @@
+ int idx = 0;
+
+ #ifdef __linux__
+- driverList[idx++] = "nouveau";
++ switch (dev->device_id)
++ {
++ /* NV1 */
++ case 0x0008:
++ case 0x0009:
++ driverList[idx++] = "vesa";
++ break;
++ /* NV3 */
++ case 0x0018:
++ case 0x0019:
++ driverList[idx++] = "nouveau";
++ break;
++ default:
++ driverList[idx++] = "nouveau";
++ driverList[idx++] = "nvidia";
++ break;
++ }
+ #endif
+ driverList[idx++] = "nv";
+ break;
diff --git a/staging/xorg-server/autoconfig-sis.patch b/staging/xorg-server/autoconfig-sis.patch
new file mode 100644
index 000000000..0b50049db
--- /dev/null
+++ b/staging/xorg-server/autoconfig-sis.patch
@@ -0,0 +1,21 @@
+--- hw/xfree86/common/xf86pciBus.c.orig 2011-09-24 10:53:45.421697668 +0000
++++ hw/xfree86/common/xf86pciBus.c 2011-09-24 10:55:56.416250708 +0000
+@@ -1200,9 +1200,15 @@
+ break;
+ }
+ break;
+- case 0x1039:
+- driverList[0] = "sis";
+- break;
++ case 0x1039:
++ switch (dev->device_id)
++ {
++ case 0x6350: case 0x6351:
++ driverList[0] = "sisimedia"; driverList[1] = "sis"; break;
++ default:
++ driverList[0] = "sis"; break;
++ }
++ break;
+ case 0x126f:
+ driverList[0] = "siliconmotion";
+ break;
diff --git a/staging/xorg-server/git-fixes.patch b/staging/xorg-server/git-fixes.patch
new file mode 100644
index 000000000..f6ca2426b
--- /dev/null
+++ b/staging/xorg-server/git-fixes.patch
@@ -0,0 +1,1717 @@
+From b5bf0ac5405eab77f26bb2f8726644232af17178 Mon Sep 17 00:00:00 2001
+From: Keith Packard <keithp@keithp.com>
+Date: Wed, 11 Apr 2012 16:28:21 +0000
+Subject: hw/xfree86: Spurious ');' in xf86vmode.c messed up indentation badly
+
+Inside the unfinished XF86VIDMODE_EVENTS #ifdef block the
+function definition for xf86VidModeNotifyEvent had an extra ');'
+before the prototype argument declarations. This was harmless for the
+compiler as the code never gets used, but completely messed up the
+file re-indentation. This patch removes the spurious characters in
+preparation for re-indenting the file.
+
+Signed-off-by: Keith Packard <keithp@keithp.com>
+(cherry picked from commit 592bd0ae2b60cd6f6afd3efc40f5f659b12900b4)
+---
+diff --git a/hw/xfree86/dixmods/extmod/xf86vmode.c b/hw/xfree86/dixmods/extmod/xf86vmode.c
+index 6e2a8e9..9f64f8e 100644
+--- a/hw/xfree86/dixmods/extmod/xf86vmode.c
++++ b/hw/xfree86/dixmods/extmod/xf86vmode.c
+@@ -75,7 +75,7 @@ static unsigned char XF86VidModeReqCode = 0;
+ #ifdef XF86VIDMODE_EVENTS
+ static int XF86VidModeEventBase = 0;
+
+-static void SXF86VidModeNotifyEvent();
++static void SXF86VidModeNotifyEvent(
+ xXF86VidModeNotifyEvent * /* from */ , xXF86VidModeNotifyEvent * /* to */
+ );
+
+--
+cgit v0.9.0.2-2-gbebe
+From 3ad72a80088fe3236f38bd0696b04f399e24fe3d Mon Sep 17 00:00:00 2001
+From: Keith Packard <keithp@keithp.com>
+Date: Wed, 11 Apr 2012 16:33:54 +0000
+Subject: hw/xfree86: Re-indent xf86vmode.c
+
+This is the result of re-running the 'x-indent.sh' script over
+xf86vmode.c to clean up the disaster caused by broken syntax in the
+file.
+
+Signed-off-by: Keith Packard <keithp@keithp.com>
+(cherry picked from commit 9779b904c7c0b49c74054c22c420012c40595cdc)
+---
+diff --git a/hw/xfree86/dixmods/extmod/xf86vmode.c b/hw/xfree86/dixmods/extmod/xf86vmode.c
+index 9f64f8e..68c4b58 100644
+--- a/hw/xfree86/dixmods/extmod/xf86vmode.c
++++ b/hw/xfree86/dixmods/extmod/xf86vmode.c
+@@ -75,8 +75,7 @@ static unsigned char XF86VidModeReqCode = 0;
+ #ifdef XF86VIDMODE_EVENTS
+ static int XF86VidModeEventBase = 0;
+
+-static void SXF86VidModeNotifyEvent(
+-xXF86VidModeNotifyEvent * /* from */ , xXF86VidModeNotifyEvent * /* to */
++static void SXF86VidModeNotifyEvent(xXF86VidModeNotifyEvent * /* from */ , xXF86VidModeNotifyEvent * /* to */
+ );
+
+ static RESTYPE EventType; /* resource type for event masks */
+@@ -117,20 +116,22 @@ static DevPrivateKeyRec ScreenPrivateKeyRec;
+ #define DEBUG_P(x) /**/
+ #endif
+ static int
+- ClientMajorVersion(ClientPtr client) {
++ClientMajorVersion(ClientPtr client)
++{
+ VidModePrivPtr pPriv;
+
+- pPriv = VM_GETPRIV(client);
++ pPriv = VM_GETPRIV(client);
+ if (!pPriv)
+- return 0;
++ return 0;
+ else
+- return pPriv->major;
++ return pPriv->major;
+ }
++
+ #ifdef XF86VIDMODE_EVENTS
+ static void
+- CheckScreenPrivate(pScreen)
++CheckScreenPrivate(pScreen)
+ ScreenPtr
+- pScreen;
++ pScreen;
+ {
+ SetupScreen(pScreen);
+
+@@ -142,9 +143,10 @@ ScreenPtr
+ }
+ }
+
+-static XF86VidModeScreenPrivatePtr MakeScreenPrivate(pScreen)
++static XF86VidModeScreenPrivatePtr
++MakeScreenPrivate(pScreen)
+ ScreenPtr
+- pScreen;
++ pScreen;
+ {
+ SetupScreen(pScreen);
+
+@@ -160,18 +162,22 @@ ScreenPtr
+ }
+
+ static unsigned long
+- getEventMask(ScreenPtr pScreen, ClientPtr client) {
++getEventMask(ScreenPtr pScreen, ClientPtr client)
++{
+ SetupScreen(pScreen);
+ XF86VidModeEventPtr pEv;
+
+ if (!pPriv)
+- return 0;
++ return 0;
+ for (pEv = pPriv->events; pEv; pEv = pEv->next)
+ if (pEv->client == client)
+ return pEv->mask;
+- return 0;
+-} static Bool
+- setEventMask(ScreenPtr pScreen, ClientPtr client, unsigned long mask) {
++ return 0;
++}
++
++static Bool
++setEventMask(ScreenPtr pScreen, ClientPtr client, unsigned long mask)
++{
+ SetupScreen(pScreen);
+ XF86VidModeEventPtr pEv, *pPrev;
+
+@@ -181,7 +187,8 @@ static unsigned long
+ pPriv = MakeScreenPrivate(pScreen);
+ if (!pPriv)
+ return FALSE;
+- } for (pPrev = &pPriv->events; pEv = *pPrev; pPrev = &pEv->next)
++ }
++ for (pPrev = &pPriv->events; pEv = *pPrev; pPrev = &pEv->next)
+ if (pEv->client == client)
+ break;
+ if (mask == 0) {
+@@ -208,38 +215,43 @@ static unsigned long
+ }
+
+ static int
+- XF86VidModeFreeEvents(pointer value, XID id) {
++XF86VidModeFreeEvents(pointer value, XID id)
++{
+ XF86VidModeEventPtr pOld = (XF86VidModeEventPtr) value;
+ ScreenPtr pScreen = pOld->screen;
+- SetupScreen(pScreen);
++
++ SetupScreen(pScreen);
+ XF86VidModeEventPtr pEv, *pPrev;
+
+ if (!pPriv)
+- return TRUE;
++ return TRUE;
+ for (pPrev = &pPriv->events; pEv = *pPrev; pPrev = &pEv->next)
+ if (pEv == pOld)
+ break;
+ if (!pEv)
+- return TRUE;
++ return TRUE;
+ *pPrev = pEv->next;
+- free(pEv);
+- CheckScreenPrivate(pScreen);
+- return TRUE;
+-} static void
+- SendXF86VidModeNotify(ScreenPtr pScreen, int state, Bool forced) {
++ free(pEv);
++ CheckScreenPrivate(pScreen);
++ return TRUE;
++}
++
++static void
++SendXF86VidModeNotify(ScreenPtr pScreen, int state, Bool forced)
++{
+ XF86VidModeScreenPrivatePtr pPriv;
+ XF86VidModeEventPtr pEv;
+ unsigned long mask;
+ xXF86VidModeNotifyEvent ev;
+ int kind;
+
+- UpdateCurrentTimeIf();
+- mask = XF86VidModeNotifyMask;
+- pScreen = screenInfo.screens[pScreen->myNum];
+- pPriv = GetScreenPrivate(pScreen);
++ UpdateCurrentTimeIf();
++ mask = XF86VidModeNotifyMask;
++ pScreen = screenInfo.screens[pScreen->myNum];
++ pPriv = GetScreenPrivate(pScreen);
+ if (!pPriv)
+- return;
+- kind = XF86VidModeModeChange;
++ return;
++ kind = XF86VidModeModeChange;
+ for (pEv = pPriv->events; pEv; pEv = pEv->next) {
+ if (!(pEv->mask & mask))
+ continue;
+@@ -251,8 +263,10 @@ static int
+ ev.forced = forced;
+ WriteEventsToClient(pEv->client, 1, (xEvent *) &ev);
+ }} static void
+- SXF86VidModeNotifyEvent(xXF86VidModeNotifyEvent * from,
+- xXF86VidModeNotifyEvent * to) {
++
++SXF86VidModeNotifyEvent(xXF86VidModeNotifyEvent * from,
++ xXF86VidModeNotifyEvent * to)
++{
+ to->type = from->type;
+ to->state = from->state;
+ cpswaps(from->sequenceNumber, to->sequenceNumber);
+@@ -264,29 +278,31 @@ static int
+ #endif
+
+ static int
+- ProcXF86VidModeQueryVersion(ClientPtr client) {
++ProcXF86VidModeQueryVersion(ClientPtr client)
++{
+ xXF86VidModeQueryVersionReply rep;
+
+- DEBUG_P("XF86VidModeQueryVersion");
++ DEBUG_P("XF86VidModeQueryVersion");
+
+- REQUEST_SIZE_MATCH(xXF86VidModeQueryVersionReq);
+- rep.type = X_Reply;
+- rep.length = 0;
+- rep.sequenceNumber = client->sequence;
+- rep.majorVersion = SERVER_XF86VIDMODE_MAJOR_VERSION;
+- rep.minorVersion = SERVER_XF86VIDMODE_MINOR_VERSION;
++ REQUEST_SIZE_MATCH(xXF86VidModeQueryVersionReq);
++ rep.type = X_Reply;
++ rep.length = 0;
++ rep.sequenceNumber = client->sequence;
++ rep.majorVersion = SERVER_XF86VIDMODE_MAJOR_VERSION;
++ rep.minorVersion = SERVER_XF86VIDMODE_MINOR_VERSION;
+ if (client->swapped) {
+ swaps(&rep.sequenceNumber);
+ swapl(&rep.length);
+ swaps(&rep.majorVersion);
+ swaps(&rep.minorVersion);
+- } WriteToClient(client, sizeof(xXF86VidModeQueryVersionReply),
+- (char *) &rep);
++ }
++ WriteToClient(client, sizeof(xXF86VidModeQueryVersionReply), (char *) &rep);
+ return Success;
+ }
+
+ static int
+- ProcXF86VidModeGetModeLine(ClientPtr client) {
++ProcXF86VidModeGetModeLine(ClientPtr client)
++{
+ REQUEST(xXF86VidModeGetModeLineReq);
+ xXF86VidModeGetModeLineReply rep;
+ xXF86OldVidModeGetModeLineReply oldrep;
+@@ -294,11 +310,11 @@ static int
+ int dotClock;
+ int ver;
+
+- DEBUG_P("XF86VidModeGetModeline");
++ DEBUG_P("XF86VidModeGetModeline");
+
+- ver = ClientMajorVersion(client);
+- REQUEST_SIZE_MATCH(xXF86VidModeGetModeLineReq);
+- rep.type = X_Reply;
++ ver = ClientMajorVersion(client);
++ REQUEST_SIZE_MATCH(xXF86VidModeGetModeLineReq);
++ rep.type = X_Reply;
+ if (ver < 2) {
+ rep.length = bytes_to_int32(SIZEOF(xXF86OldVidModeGetModeLineReply) -
+ SIZEOF(xGenericReply));
+@@ -386,7 +402,8 @@ static int
+ }
+
+ static int
+- ProcXF86VidModeGetAllModeLines(ClientPtr client) {
++ProcXF86VidModeGetAllModeLines(ClientPtr client)
++{
+ REQUEST(xXF86VidModeGetAllModeLinesReq);
+ xXF86VidModeGetAllModeLinesReply rep;
+ xXF86VidModeModeInfo mdinf;
+@@ -395,38 +412,39 @@ static int
+ int modecount, dotClock;
+ int ver;
+
+- DEBUG_P("XF86VidModeGetAllModelines");
++ DEBUG_P("XF86VidModeGetAllModelines");
+
+- REQUEST_SIZE_MATCH(xXF86VidModeGetAllModeLinesReq);
++ REQUEST_SIZE_MATCH(xXF86VidModeGetAllModeLinesReq);
+
+ if (stuff->screen >= screenInfo.numScreens)
+- return BadValue;
++ return BadValue;
+
+- ver = ClientMajorVersion(client);
++ ver = ClientMajorVersion(client);
+
+- modecount = VidModeGetNumOfModes(stuff->screen);
++ modecount = VidModeGetNumOfModes(stuff->screen);
+ if (modecount < 1)
+- return VidModeErrorBase + XF86VidModeExtensionDisabled;
++ return VidModeErrorBase + XF86VidModeExtensionDisabled;
+
+ if (!VidModeGetFirstModeline(stuff->screen, &mode, &dotClock))
+- return BadValue;
++ return BadValue;
+
+- rep.type = X_Reply;
+- rep.length = SIZEOF(xXF86VidModeGetAllModeLinesReply) -
++ rep.type = X_Reply;
++ rep.length = SIZEOF(xXF86VidModeGetAllModeLinesReply) -
+ SIZEOF(xGenericReply);
+ if (ver < 2)
+- rep.length += modecount * sizeof(xXF86OldVidModeModeInfo);
++ rep.length += modecount * sizeof(xXF86OldVidModeModeInfo);
+ else
+- rep.length += modecount * sizeof(xXF86VidModeModeInfo);
+- rep.length >>= 2;
+- rep.sequenceNumber = client->sequence;
+- rep.modecount = modecount;
++ rep.length += modecount * sizeof(xXF86VidModeModeInfo);
++ rep.length >>= 2;
++ rep.sequenceNumber = client->sequence;
++ rep.modecount = modecount;
+ if (client->swapped) {
+ swaps(&rep.sequenceNumber);
+ swapl(&rep.length);
+ swapl(&rep.modecount);
+- } WriteToClient(client, sizeof(xXF86VidModeGetAllModeLinesReply),
+- (char *) &rep);
++ }
++ WriteToClient(client, sizeof(xXF86VidModeGetAllModeLinesReply),
++ (char *) &rep);
+
+ do {
+ mdinf.dotclock = dotClock;
+@@ -492,7 +510,8 @@ static int
+ && VidModeGetModeValue(mode, VIDMODE_FLAGS) == stuff->flags )
+
+ static int
+- ProcXF86VidModeAddModeLine(ClientPtr client) {
++ProcXF86VidModeAddModeLine(ClientPtr client)
++{
+ REQUEST(xXF86VidModeAddModeLineReq);
+ xXF86OldVidModeAddModeLineReq *oldstuff =
+ (xXF86OldVidModeAddModeLineReq *) client->requestBuffer;
+@@ -502,9 +521,9 @@ static int
+ int dotClock;
+ int ver;
+
+- DEBUG_P("XF86VidModeAddModeline");
++ DEBUG_P("XF86VidModeAddModeline");
+
+- ver = ClientMajorVersion(client);
++ ver = ClientMajorVersion(client);
+ if (ver < 2) {
+ /* convert from old format */
+ stuff = &newstuff;
+@@ -533,7 +552,8 @@ static int
+ stuff->after_vsyncend = oldstuff->after_vsyncend;
+ stuff->after_vtotal = oldstuff->after_vtotal;
+ stuff->after_flags = oldstuff->after_flags;
+- } if (xf86GetVerbosity() > DEFAULT_XF86VIDMODE_VERBOSITY) {
++ }
++ if (xf86GetVerbosity() > DEFAULT_XF86VIDMODE_VERBOSITY) {
+ ErrorF("AddModeLine - scrn: %d clock: %ld\n",
+ (int) stuff->screen, (unsigned long) stuff->dotclock);
+ ErrorF("AddModeLine - hdsp: %d hbeg: %d hend: %d httl: %d\n",
+@@ -654,7 +674,8 @@ static int
+ }
+
+ static int
+- ProcXF86VidModeDeleteModeLine(ClientPtr client) {
++ProcXF86VidModeDeleteModeLine(ClientPtr client)
++{
+ REQUEST(xXF86VidModeDeleteModeLineReq);
+ xXF86OldVidModeDeleteModeLineReq *oldstuff =
+ (xXF86OldVidModeDeleteModeLineReq *) client->requestBuffer;
+@@ -663,9 +684,9 @@ static int
+ int len, dotClock;
+ int ver;
+
+- DEBUG_P("XF86VidModeDeleteModeline");
++ DEBUG_P("XF86VidModeDeleteModeline");
+
+- ver = ClientMajorVersion(client);
++ ver = ClientMajorVersion(client);
+ if (ver < 2) {
+ /* convert from old format */
+ stuff = &newstuff;
+@@ -683,7 +704,8 @@ static int
+ stuff->vtotal = oldstuff->vtotal;
+ stuff->flags = oldstuff->flags;
+ stuff->privsize = oldstuff->privsize;
+- } if (xf86GetVerbosity() > DEFAULT_XF86VIDMODE_VERBOSITY) {
++ }
++ if (xf86GetVerbosity() > DEFAULT_XF86VIDMODE_VERBOSITY) {
+ ErrorF("DeleteModeLine - scrn: %d clock: %ld\n",
+ (int) stuff->screen, (unsigned long) stuff->dotclock);
+ ErrorF(" hdsp: %d hbeg: %d hend: %d httl: %d\n",
+@@ -777,7 +799,8 @@ static int
+ }
+
+ static int
+- ProcXF86VidModeModModeLine(ClientPtr client) {
++ProcXF86VidModeModModeLine(ClientPtr client)
++{
+ REQUEST(xXF86VidModeModModeLineReq);
+ xXF86OldVidModeModModeLineReq *oldstuff =
+ (xXF86OldVidModeModModeLineReq *) client->requestBuffer;
+@@ -786,9 +809,9 @@ static int
+ int len, dotClock;
+ int ver;
+
+- DEBUG_P("XF86VidModeModModeline");
++ DEBUG_P("XF86VidModeModModeline");
+
+- ver = ClientMajorVersion(client);
++ ver = ClientMajorVersion(client);
+ if (ver < 2) {
+ /* convert from old format */
+ stuff = &newstuff;
+@@ -805,7 +828,8 @@ static int
+ stuff->vtotal = oldstuff->vtotal;
+ stuff->flags = oldstuff->flags;
+ stuff->privsize = oldstuff->privsize;
+- } if (xf86GetVerbosity() > DEFAULT_XF86VIDMODE_VERBOSITY) {
++ }
++ if (xf86GetVerbosity() > DEFAULT_XF86VIDMODE_VERBOSITY) {
+ ErrorF("ModModeLine - scrn: %d hdsp: %d hbeg: %d hend: %d httl: %d\n",
+ (int) stuff->screen, stuff->hdisplay, stuff->hsyncstart,
+ stuff->hsyncend, stuff->htotal);
+@@ -903,7 +927,8 @@ static int
+ }
+
+ static int
+- ProcXF86VidModeValidateModeLine(ClientPtr client) {
++ProcXF86VidModeValidateModeLine(ClientPtr client)
++{
+ REQUEST(xXF86VidModeValidateModeLineReq);
+ xXF86OldVidModeValidateModeLineReq *oldstuff =
+ (xXF86OldVidModeValidateModeLineReq *) client->requestBuffer;
+@@ -913,9 +938,9 @@ static int
+ int len, status, dotClock;
+ int ver;
+
+- DEBUG_P("XF86VidModeValidateModeline");
++ DEBUG_P("XF86VidModeValidateModeline");
+
+- ver = ClientMajorVersion(client);
++ ver = ClientMajorVersion(client);
+ if (ver < 2) {
+ /* convert from old format */
+ stuff = &newstuff;
+@@ -933,7 +958,8 @@ static int
+ stuff->vtotal = oldstuff->vtotal;
+ stuff->flags = oldstuff->flags;
+ stuff->privsize = oldstuff->privsize;
+- } if (xf86GetVerbosity() > DEFAULT_XF86VIDMODE_VERBOSITY) {
++ }
++ if (xf86GetVerbosity() > DEFAULT_XF86VIDMODE_VERBOSITY) {
+ ErrorF("ValidateModeLine - scrn: %d clock: %ld\n",
+ (int) stuff->screen, (unsigned long) stuff->dotclock);
+ ErrorF(" hdsp: %d hbeg: %d hend: %d httl: %d\n",
+@@ -1022,7 +1048,8 @@ static int
+ }
+
+ static int
+- ProcXF86VidModeSwitchMode(ClientPtr client) {
++ProcXF86VidModeSwitchMode(ClientPtr client)
++{
+ REQUEST(xXF86VidModeSwitchModeReq);
+
+ DEBUG_P("XF86VidModeSwitchMode");
+@@ -1035,8 +1062,11 @@ static int
+ VidModeZoomViewport(stuff->screen, (short) stuff->zoom);
+
+ return Success;
+-} static int
+- ProcXF86VidModeSwitchToMode(ClientPtr client) {
++}
++
++static int
++ProcXF86VidModeSwitchToMode(ClientPtr client)
++{
+ REQUEST(xXF86VidModeSwitchToModeReq);
+ xXF86OldVidModeSwitchToModeReq *oldstuff =
+ (xXF86OldVidModeSwitchToModeReq *) client->requestBuffer;
+@@ -1045,9 +1075,9 @@ static int
+ int len, dotClock;
+ int ver;
+
+- DEBUG_P("XF86VidModeSwitchToMode");
++ DEBUG_P("XF86VidModeSwitchToMode");
+
+- ver = ClientMajorVersion(client);
++ ver = ClientMajorVersion(client);
+ if (ver < 2) {
+ /* convert from old format */
+ stuff = &newstuff;
+@@ -1065,7 +1095,8 @@ static int
+ stuff->vtotal = oldstuff->vtotal;
+ stuff->flags = oldstuff->flags;
+ stuff->privsize = oldstuff->privsize;
+- } if (xf86GetVerbosity() > DEFAULT_XF86VIDMODE_VERBOSITY) {
++ }
++ if (xf86GetVerbosity() > DEFAULT_XF86VIDMODE_VERBOSITY) {
+ ErrorF("SwitchToMode - scrn: %d clock: %ld\n",
+ (int) stuff->screen, (unsigned long) stuff->dotclock);
+ ErrorF(" hdsp: %d hbeg: %d hend: %d httl: %d\n",
+@@ -1138,7 +1169,8 @@ static int
+ }
+
+ static int
+- ProcXF86VidModeLockModeSwitch(ClientPtr client) {
++ProcXF86VidModeLockModeSwitch(ClientPtr client)
++{
+ REQUEST(xXF86VidModeLockModeSwitchReq);
+
+ REQUEST_SIZE_MATCH(xXF86VidModeLockModeSwitchReq);
+@@ -1152,53 +1184,57 @@ static int
+ return VidModeErrorBase + XF86VidModeZoomLocked;
+
+ return Success;
+-} static int
+- ProcXF86VidModeGetMonitor(ClientPtr client) {
++}
++
++static int
++ProcXF86VidModeGetMonitor(ClientPtr client)
++{
+ REQUEST(xXF86VidModeGetMonitorReq);
+ xXF86VidModeGetMonitorReply rep;
+ CARD32 *hsyncdata, *vsyncdata;
+ int i, nHsync, nVrefresh;
+ pointer monitor;
+
+- DEBUG_P("XF86VidModeGetMonitor");
++ DEBUG_P("XF86VidModeGetMonitor");
+
+- REQUEST_SIZE_MATCH(xXF86VidModeGetMonitorReq);
++ REQUEST_SIZE_MATCH(xXF86VidModeGetMonitorReq);
+
+ if (stuff->screen >= screenInfo.numScreens)
+- return BadValue;
++ return BadValue;
+
+ if (!VidModeGetMonitor(stuff->screen, &monitor))
+- return BadValue;
++ return BadValue;
+
+- nHsync = VidModeGetMonitorValue(monitor, VIDMODE_MON_NHSYNC, 0).i;
+- nVrefresh = VidModeGetMonitorValue(monitor, VIDMODE_MON_NVREFRESH, 0).i;
++ nHsync = VidModeGetMonitorValue(monitor, VIDMODE_MON_NHSYNC, 0).i;
++ nVrefresh = VidModeGetMonitorValue(monitor, VIDMODE_MON_NVREFRESH, 0).i;
+
+- rep.type = X_Reply;
++ rep.type = X_Reply;
+ if ((char *) (VidModeGetMonitorValue(monitor, VIDMODE_MON_VENDOR, 0)).ptr)
+- rep.vendorLength = strlen((char *) (VidModeGetMonitorValue(monitor,
+- VIDMODE_MON_VENDOR,
+- 0)).ptr);
++ rep.vendorLength = strlen((char *) (VidModeGetMonitorValue(monitor,
++ VIDMODE_MON_VENDOR,
++ 0)).ptr);
+ else
+- rep.vendorLength = 0;
++ rep.vendorLength = 0;
+ if ((char *) (VidModeGetMonitorValue(monitor, VIDMODE_MON_MODEL, 0)).ptr)
+- rep.modelLength = strlen((char *) (VidModeGetMonitorValue(monitor,
+- VIDMODE_MON_MODEL,
+- 0)).ptr);
++ rep.modelLength = strlen((char *) (VidModeGetMonitorValue(monitor,
++ VIDMODE_MON_MODEL,
++ 0)).ptr);
+ else
+- rep.modelLength = 0;
+- rep.length =
++ rep.modelLength = 0;
++ rep.length =
+ bytes_to_int32(SIZEOF(xXF86VidModeGetMonitorReply) -
+ SIZEOF(xGenericReply) + (nHsync +
+ nVrefresh) * sizeof(CARD32) +
+ pad_to_int32(rep.vendorLength) +
+ pad_to_int32(rep.modelLength));
+- rep.sequenceNumber = client->sequence;
+- rep.nhsync = nHsync;
+- rep.nvsync = nVrefresh;
+- hsyncdata = malloc(nHsync * sizeof(CARD32));
++ rep.sequenceNumber = client->sequence;
++ rep.nhsync = nHsync;
++ rep.nvsync = nVrefresh;
++ hsyncdata = malloc(nHsync * sizeof(CARD32));
+ if (!hsyncdata) {
+ return BadAlloc;
+- } vsyncdata = malloc(nVrefresh * sizeof(CARD32));
++ }
++ vsyncdata = malloc(nVrefresh * sizeof(CARD32));
+
+ if (!vsyncdata) {
+ free(hsyncdata);
+@@ -1208,19 +1244,18 @@ static int
+ for (i = 0; i < nHsync; i++) {
+ hsyncdata[i] = (unsigned short) (VidModeGetMonitorValue(monitor,
+ VIDMODE_MON_HSYNC_LO,
+- i)).
+- f | (unsigned
+- short) (VidModeGetMonitorValue(monitor, VIDMODE_MON_HSYNC_HI,
+- i)).f << 16;
++ i)).f |
++ (unsigned
++ short) (VidModeGetMonitorValue(monitor, VIDMODE_MON_HSYNC_HI,
++ i)).f << 16;
+ }
+ for (i = 0; i < nVrefresh; i++) {
+ vsyncdata[i] = (unsigned short) (VidModeGetMonitorValue(monitor,
+ VIDMODE_MON_VREFRESH_LO,
+- i)).
+- f | (unsigned
+- short) (VidModeGetMonitorValue(monitor,
+- VIDMODE_MON_VREFRESH_HI,
+- i)).f << 16;
++ i)).f |
++ (unsigned
++ short) (VidModeGetMonitorValue(monitor, VIDMODE_MON_VREFRESH_HI,
++ i)).f << 16;
+ }
+
+ if (client->swapped) {
+@@ -1249,38 +1284,40 @@ static int
+ }
+
+ static int
+- ProcXF86VidModeGetViewPort(ClientPtr client) {
++ProcXF86VidModeGetViewPort(ClientPtr client)
++{
+ REQUEST(xXF86VidModeGetViewPortReq);
+ xXF86VidModeGetViewPortReply rep;
+ int x, y;
+
+- DEBUG_P("XF86VidModeGetViewPort");
++ DEBUG_P("XF86VidModeGetViewPort");
+
+- REQUEST_SIZE_MATCH(xXF86VidModeGetViewPortReq);
++ REQUEST_SIZE_MATCH(xXF86VidModeGetViewPortReq);
+
+ if (stuff->screen >= screenInfo.numScreens)
+- return BadValue;
++ return BadValue;
+
+- rep.type = X_Reply;
+- rep.length = 0;
+- rep.sequenceNumber = client->sequence;
++ rep.type = X_Reply;
++ rep.length = 0;
++ rep.sequenceNumber = client->sequence;
+
+- VidModeGetViewPort(stuff->screen, &x, &y);
+- rep.x = x;
+- rep.y = y;
++ VidModeGetViewPort(stuff->screen, &x, &y);
++ rep.x = x;
++ rep.y = y;
+
+ if (client->swapped) {
+ swaps(&rep.sequenceNumber);
+ swapl(&rep.length);
+ swapl(&rep.x);
+ swapl(&rep.y);
+- } WriteToClient(client, SIZEOF(xXF86VidModeGetViewPortReply),
+- (char *) &rep);
++ }
++ WriteToClient(client, SIZEOF(xXF86VidModeGetViewPortReply), (char *) &rep);
+ return Success;
+ }
+
+ static int
+- ProcXF86VidModeSetViewPort(ClientPtr client) {
++ProcXF86VidModeSetViewPort(ClientPtr client)
++{
+ REQUEST(xXF86VidModeSetViewPortReq);
+
+ DEBUG_P("XF86VidModeSetViewPort");
+@@ -1294,8 +1331,11 @@ static int
+ return BadValue;
+
+ return Success;
+-} static int
+- ProcXF86VidModeGetDotClocks(ClientPtr client) {
++}
++
++static int
++ProcXF86VidModeGetDotClocks(ClientPtr client)
++{
+ REQUEST(xXF86VidModeGetDotClocksReq);
+ xXF86VidModeGetDotClocksReply rep;
+ int n;
+@@ -1304,31 +1344,33 @@ static int
+ int *Clocks = NULL;
+ Bool ClockProg;
+
+- DEBUG_P("XF86VidModeGetDotClocks");
++ DEBUG_P("XF86VidModeGetDotClocks");
+
+- REQUEST_SIZE_MATCH(xXF86VidModeGetDotClocksReq);
++ REQUEST_SIZE_MATCH(xXF86VidModeGetDotClocksReq);
+
+ if (stuff->screen >= screenInfo.numScreens)
+- return BadValue;
++ return BadValue;
+
+- numClocks = VidModeGetNumOfClocks(stuff->screen, &ClockProg);
++ numClocks = VidModeGetNumOfClocks(stuff->screen, &ClockProg);
+
+- rep.type = X_Reply;
+- rep.length = bytes_to_int32(SIZEOF(xXF86VidModeGetDotClocksReply)
+- - SIZEOF(xGenericReply) + numClocks);
+- rep.sequenceNumber = client->sequence;
+- rep.clocks = numClocks;
+- rep.maxclocks = MAXCLOCKS;
+- rep.flags = 0;
++ rep.type = X_Reply;
++ rep.length = bytes_to_int32(SIZEOF(xXF86VidModeGetDotClocksReply)
++ - SIZEOF(xGenericReply) + numClocks);
++ rep.sequenceNumber = client->sequence;
++ rep.clocks = numClocks;
++ rep.maxclocks = MAXCLOCKS;
++ rep.flags = 0;
+
+ if (!ClockProg) {
+ Clocks = malloc(numClocks * sizeof(int));
+ if (!Clocks)
+- return BadValue;
++ return BadValue;
+ if (!VidModeGetClocks(stuff->screen, Clocks)) {
+ free(Clocks);
+ return BadValue;
+- }} if (ClockProg) {
++ }
++ }
++ if (ClockProg) {
+ rep.flags |= CLKFLAG_PROGRAMABLE;
+ }
+ if (client->swapped) {
+@@ -1356,7 +1398,8 @@ static int
+ }
+
+ static int
+- ProcXF86VidModeSetGamma(ClientPtr client) {
++ProcXF86VidModeSetGamma(ClientPtr client)
++{
+ REQUEST(xXF86VidModeSetGammaReq);
+
+ DEBUG_P("XF86VidModeSetGamma");
+@@ -1372,79 +1415,89 @@ static int
+ return BadValue;
+
+ return Success;
+-} static int
+- ProcXF86VidModeGetGamma(ClientPtr client) {
++}
++
++static int
++ProcXF86VidModeGetGamma(ClientPtr client)
++{
+ REQUEST(xXF86VidModeGetGammaReq);
+ xXF86VidModeGetGammaReply rep;
+ float red, green, blue;
+
+- DEBUG_P("XF86VidModeGetGamma");
++ DEBUG_P("XF86VidModeGetGamma");
+
+- REQUEST_SIZE_MATCH(xXF86VidModeGetGammaReq);
++ REQUEST_SIZE_MATCH(xXF86VidModeGetGammaReq);
+
+ if (stuff->screen >= screenInfo.numScreens)
+- return BadValue;
++ return BadValue;
+
+- rep.type = X_Reply;
+- rep.length = 0;
+- rep.sequenceNumber = client->sequence;
++ rep.type = X_Reply;
++ rep.length = 0;
++ rep.sequenceNumber = client->sequence;
+ if (!VidModeGetGamma(stuff->screen, &red, &green, &blue))
+- return BadValue;
+- rep.red = (CARD32) (red * 10000.);
+- rep.green = (CARD32) (green * 10000.);
+- rep.blue = (CARD32) (blue * 10000.);
++ return BadValue;
++ rep.red = (CARD32) (red * 10000.);
++ rep.green = (CARD32) (green * 10000.);
++ rep.blue = (CARD32) (blue * 10000.);
+ if (client->swapped) {
+ swaps(&rep.sequenceNumber);
+ swapl(&rep.length);
+ swapl(&rep.red);
+ swapl(&rep.green);
+ swapl(&rep.blue);
+- } WriteToClient(client, sizeof(xXF86VidModeGetGammaReply), (char *) &rep);
++ }
++ WriteToClient(client, sizeof(xXF86VidModeGetGammaReply), (char *) &rep);
+
+ return Success;
+ }
+
+ static int
+- ProcXF86VidModeSetGammaRamp(ClientPtr client) {
++ProcXF86VidModeSetGammaRamp(ClientPtr client)
++{
+ CARD16 *r, *g, *b;
+ int length;
+- REQUEST(xXF86VidModeSetGammaRampReq);
++
++ REQUEST(xXF86VidModeSetGammaRampReq);
+
+ if (stuff->screen >= screenInfo.numScreens)
+- return BadValue;
++ return BadValue;
+
+ if (stuff->size != VidModeGetGammaRampSize(stuff->screen))
+- return BadValue;
++ return BadValue;
+
+- length = (stuff->size + 1) & ~1;
++ length = (stuff->size + 1) & ~1;
+
+- REQUEST_FIXED_SIZE(xXF86VidModeSetGammaRampReq, length * 6);
++ REQUEST_FIXED_SIZE(xXF86VidModeSetGammaRampReq, length * 6);
+
+- r = (CARD16 *) &stuff[1];
+- g = r + length;
+- b = g + length;
++ r = (CARD16 *) &stuff[1];
++ g = r + length;
++ b = g + length;
+
+ if (!VidModeSetGammaRamp(stuff->screen, stuff->size, r, g, b))
+- return BadValue;
++ return BadValue;
+
+- return Success;
+-} static int
+- ProcXF86VidModeGetGammaRamp(ClientPtr client) {
++ return Success;
++}
++
++static int
++ProcXF86VidModeGetGammaRamp(ClientPtr client)
++{
+ CARD16 *ramp = NULL;
+ int length;
+ size_t ramplen = 0;
+ xXF86VidModeGetGammaRampReply rep;
+- REQUEST(xXF86VidModeGetGammaRampReq);
++
++ REQUEST(xXF86VidModeGetGammaRampReq);
+
+ if (stuff->screen >= screenInfo.numScreens)
+- return BadValue;
++ return BadValue;
+
+ if (stuff->size != VidModeGetGammaRampSize(stuff->screen))
+- return BadValue;
++ return BadValue;
+
+- REQUEST_SIZE_MATCH(xXF86VidModeGetGammaRampReq);
++ REQUEST_SIZE_MATCH(xXF86VidModeGetGammaRampReq);
+
+- length = (stuff->size + 1) & ~1;
++ length = (stuff->size + 1) & ~1;
+
+ if (stuff->size) {
+ ramplen = length * 3 * sizeof(CARD16);
+@@ -1455,7 +1508,9 @@ static int
+ ramp, ramp + length, ramp + (length * 2))) {
+ free(ramp);
+ return BadValue;
+- }} rep.type = X_Reply;
++ }
++ }
++ rep.type = X_Reply;
+ rep.length = (length >> 1) * 3;
+ rep.sequenceNumber = client->sequence;
+ rep.size = stuff->size;
+@@ -1476,47 +1531,53 @@ static int
+ }
+
+ static int
+- ProcXF86VidModeGetGammaRampSize(ClientPtr client) {
++ProcXF86VidModeGetGammaRampSize(ClientPtr client)
++{
+ xXF86VidModeGetGammaRampSizeReply rep;
+- REQUEST(xXF86VidModeGetGammaRampSizeReq);
++
++ REQUEST(xXF86VidModeGetGammaRampSizeReq);
+
+ if (stuff->screen >= screenInfo.numScreens)
+- return BadValue;
++ return BadValue;
+
+- REQUEST_SIZE_MATCH(xXF86VidModeGetGammaRampSizeReq);
++ REQUEST_SIZE_MATCH(xXF86VidModeGetGammaRampSizeReq);
+
+- rep.type = X_Reply;
+- rep.length = 0;
+- rep.sequenceNumber = client->sequence;
+- rep.size = VidModeGetGammaRampSize(stuff->screen);
++ rep.type = X_Reply;
++ rep.length = 0;
++ rep.sequenceNumber = client->sequence;
++ rep.size = VidModeGetGammaRampSize(stuff->screen);
+ if (client->swapped) {
+ swaps(&rep.sequenceNumber);
+ swapl(&rep.length);
+ swaps(&rep.size);
+- } WriteToClient(client, sizeof(xXF86VidModeGetGammaRampSizeReply),
+- (char *) &rep);
++ }
++ WriteToClient(client, sizeof(xXF86VidModeGetGammaRampSizeReply),
++ (char *) &rep);
+
+ return Success;
+ }
+
+ static int
+- ProcXF86VidModeGetPermissions(ClientPtr client) {
++ProcXF86VidModeGetPermissions(ClientPtr client)
++{
+ xXF86VidModeGetPermissionsReply rep;
+- REQUEST(xXF86VidModeGetPermissionsReq);
++
++ REQUEST(xXF86VidModeGetPermissionsReq);
+
+ if (stuff->screen >= screenInfo.numScreens)
+- return BadValue;
++ return BadValue;
+
+- REQUEST_SIZE_MATCH(xXF86VidModeGetPermissionsReq);
++ REQUEST_SIZE_MATCH(xXF86VidModeGetPermissionsReq);
+
+- rep.type = X_Reply;
+- rep.length = 0;
+- rep.sequenceNumber = client->sequence;
+- rep.permissions = XF86VM_READ_PERMISSION;
++ rep.type = X_Reply;
++ rep.length = 0;
++ rep.sequenceNumber = client->sequence;
++ rep.permissions = XF86VM_READ_PERMISSION;
+ if (xf86GetVidModeEnabled() &&
+ (xf86GetVidModeAllowNonLocal() || LocalClient(client))) {
+ rep.permissions |= XF86VM_WRITE_PERMISSION;
+- } if (client->swapped) {
++ }
++ if (client->swapped) {
+ swaps(&rep.sequenceNumber);
+ swapl(&rep.length);
+ swapl(&rep.permissions);
+@@ -1528,21 +1589,23 @@ static int
+ }
+
+ static int
+- ProcXF86VidModeSetClientVersion(ClientPtr client) {
++ProcXF86VidModeSetClientVersion(ClientPtr client)
++{
+ REQUEST(xXF86VidModeSetClientVersionReq);
+
+ VidModePrivPtr pPriv;
+
+- DEBUG_P("XF86VidModeSetClientVersion");
++ DEBUG_P("XF86VidModeSetClientVersion");
+
+- REQUEST_SIZE_MATCH(xXF86VidModeSetClientVersionReq);
++ REQUEST_SIZE_MATCH(xXF86VidModeSetClientVersionReq);
+
+ if ((pPriv = VM_GETPRIV(client)) == NULL) {
+ pPriv = malloc(sizeof(VidModePrivRec));
+ if (!pPriv)
+ return BadAlloc;
+ VM_SETPRIV(client, pPriv);
+- } pPriv->major = stuff->major;
++ }
++ pPriv->major = stuff->major;
+
+ pPriv->minor = stuff->minor;
+
+@@ -1550,85 +1613,103 @@ static int
+ }
+
+ static int
+- ProcXF86VidModeDispatch(ClientPtr client) {
++ProcXF86VidModeDispatch(ClientPtr client)
++{
+ REQUEST(xReq);
+ switch (stuff->data) {
+ case X_XF86VidModeQueryVersion:
+ return ProcXF86VidModeQueryVersion(client);
+- case X_XF86VidModeGetModeLine:return ProcXF86VidModeGetModeLine(client);
+- case X_XF86VidModeGetMonitor:return ProcXF86VidModeGetMonitor(client);
+- case X_XF86VidModeGetAllModeLines:return
+- ProcXF86VidModeGetAllModeLines(client);
+- case X_XF86VidModeValidateModeLine:return
+- ProcXF86VidModeValidateModeLine(client);
+- case X_XF86VidModeGetViewPort:return ProcXF86VidModeGetViewPort(client);
+- case X_XF86VidModeGetDotClocks:return
+- ProcXF86VidModeGetDotClocks(client);
+- case X_XF86VidModeSetClientVersion:return
+- ProcXF86VidModeSetClientVersion(client);
+- case X_XF86VidModeGetGamma:return ProcXF86VidModeGetGamma(client);
+- case X_XF86VidModeGetGammaRamp:return
+- ProcXF86VidModeGetGammaRamp(client);
+- case X_XF86VidModeGetGammaRampSize:return
+- ProcXF86VidModeGetGammaRampSize(client);
+- case X_XF86VidModeGetPermissions:return
+- ProcXF86VidModeGetPermissions(client);
+- default:if (!xf86GetVidModeEnabled())
++ case X_XF86VidModeGetModeLine:
++ return ProcXF86VidModeGetModeLine(client);
++ case X_XF86VidModeGetMonitor:
++ return ProcXF86VidModeGetMonitor(client);
++ case X_XF86VidModeGetAllModeLines:
++ return ProcXF86VidModeGetAllModeLines(client);
++ case X_XF86VidModeValidateModeLine:
++ return ProcXF86VidModeValidateModeLine(client);
++ case X_XF86VidModeGetViewPort:
++ return ProcXF86VidModeGetViewPort(client);
++ case X_XF86VidModeGetDotClocks:
++ return ProcXF86VidModeGetDotClocks(client);
++ case X_XF86VidModeSetClientVersion:
++ return ProcXF86VidModeSetClientVersion(client);
++ case X_XF86VidModeGetGamma:
++ return ProcXF86VidModeGetGamma(client);
++ case X_XF86VidModeGetGammaRamp:
++ return ProcXF86VidModeGetGammaRamp(client);
++ case X_XF86VidModeGetGammaRampSize:
++ return ProcXF86VidModeGetGammaRampSize(client);
++ case X_XF86VidModeGetPermissions:
++ return ProcXF86VidModeGetPermissions(client);
++ default:
++ if (!xf86GetVidModeEnabled())
+ return VidModeErrorBase + XF86VidModeExtensionDisabled;
+ if (xf86GetVidModeAllowNonLocal() || LocalClient(client)) {
+ switch (stuff->data) {
+ case X_XF86VidModeAddModeLine:
+ return ProcXF86VidModeAddModeLine(client);
+- case X_XF86VidModeDeleteModeLine:return
+- ProcXF86VidModeDeleteModeLine(client);
+- case X_XF86VidModeModModeLine:return
+- ProcXF86VidModeModModeLine(client);
+- case X_XF86VidModeSwitchMode:return
+- ProcXF86VidModeSwitchMode(client);
+- case X_XF86VidModeSwitchToMode:return
+- ProcXF86VidModeSwitchToMode(client);
+- case X_XF86VidModeLockModeSwitch:return
+- ProcXF86VidModeLockModeSwitch(client);
+- case X_XF86VidModeSetViewPort:return
+- ProcXF86VidModeSetViewPort(client);
+- case X_XF86VidModeSetGamma:return
+- ProcXF86VidModeSetGamma(client);
+- case X_XF86VidModeSetGammaRamp:return
+- ProcXF86VidModeSetGammaRamp(client);
+- default:return BadRequest;
+- }}
++ case X_XF86VidModeDeleteModeLine:
++ return ProcXF86VidModeDeleteModeLine(client);
++ case X_XF86VidModeModModeLine:
++ return ProcXF86VidModeModModeLine(client);
++ case X_XF86VidModeSwitchMode:
++ return ProcXF86VidModeSwitchMode(client);
++ case X_XF86VidModeSwitchToMode:
++ return ProcXF86VidModeSwitchToMode(client);
++ case X_XF86VidModeLockModeSwitch:
++ return ProcXF86VidModeLockModeSwitch(client);
++ case X_XF86VidModeSetViewPort:
++ return ProcXF86VidModeSetViewPort(client);
++ case X_XF86VidModeSetGamma:
++ return ProcXF86VidModeSetGamma(client);
++ case X_XF86VidModeSetGammaRamp:
++ return ProcXF86VidModeSetGammaRamp(client);
++ default:
++ return BadRequest;
++ }
++ }
+ else
+- return VidModeErrorBase + XF86VidModeClientNotLocal;
++ return VidModeErrorBase + XF86VidModeClientNotLocal;
+ }
+ }
+
+ static int
+- SProcXF86VidModeQueryVersion(ClientPtr client) {
++SProcXF86VidModeQueryVersion(ClientPtr client)
++{
+ REQUEST(xXF86VidModeQueryVersionReq);
+ swaps(&stuff->length);
+ return ProcXF86VidModeQueryVersion(client);
+-} static int
+- SProcXF86VidModeGetModeLine(ClientPtr client) {
++}
++
++static int
++SProcXF86VidModeGetModeLine(ClientPtr client)
++{
+ REQUEST(xXF86VidModeGetModeLineReq);
+ swaps(&stuff->length);
+ REQUEST_SIZE_MATCH(xXF86VidModeGetModeLineReq);
+ swaps(&stuff->screen);
+ return ProcXF86VidModeGetModeLine(client);
+-} static int
+- SProcXF86VidModeGetAllModeLines(ClientPtr client) {
++}
++
++static int
++SProcXF86VidModeGetAllModeLines(ClientPtr client)
++{
+ REQUEST(xXF86VidModeGetAllModeLinesReq);
+ swaps(&stuff->length);
+ REQUEST_SIZE_MATCH(xXF86VidModeGetAllModeLinesReq);
+ swaps(&stuff->screen);
+ return ProcXF86VidModeGetAllModeLines(client);
+-} static int
+- SProcXF86VidModeAddModeLine(ClientPtr client) {
++}
++
++static int
++SProcXF86VidModeAddModeLine(ClientPtr client)
++{
+ xXF86OldVidModeAddModeLineReq *oldstuff =
+ (xXF86OldVidModeAddModeLineReq *) client->requestBuffer;
+ int ver;
+
+- REQUEST(xXF86VidModeAddModeLineReq);
+- ver = ClientMajorVersion(client);
++ REQUEST(xXF86VidModeAddModeLineReq);
++ ver = ClientMajorVersion(client);
+ if (ver < 2) {
+ swaps(&oldstuff->length);
+ REQUEST_AT_LEAST_SIZE(xXF86OldVidModeAddModeLineReq);
+@@ -1666,13 +1747,14 @@ static int
+ }
+
+ static int
+- SProcXF86VidModeDeleteModeLine(ClientPtr client) {
++SProcXF86VidModeDeleteModeLine(ClientPtr client)
++{
+ xXF86OldVidModeDeleteModeLineReq *oldstuff =
+ (xXF86OldVidModeDeleteModeLineReq *) client->requestBuffer;
+ int ver;
+
+- REQUEST(xXF86VidModeDeleteModeLineReq);
+- ver = ClientMajorVersion(client);
++ REQUEST(xXF86VidModeDeleteModeLineReq);
++ ver = ClientMajorVersion(client);
+ if (ver < 2) {
+ swaps(&oldstuff->length);
+ REQUEST_AT_LEAST_SIZE(xXF86OldVidModeDeleteModeLineReq);
+@@ -1710,13 +1792,14 @@ static int
+ }
+
+ static int
+- SProcXF86VidModeModModeLine(ClientPtr client) {
++SProcXF86VidModeModModeLine(ClientPtr client)
++{
+ xXF86OldVidModeModModeLineReq *oldstuff =
+ (xXF86OldVidModeModModeLineReq *) client->requestBuffer;
+ int ver;
+
+- REQUEST(xXF86VidModeModModeLineReq);
+- ver = ClientMajorVersion(client);
++ REQUEST(xXF86VidModeModModeLineReq);
++ ver = ClientMajorVersion(client);
+ if (ver < 2) {
+ swaps(&oldstuff->length);
+ REQUEST_AT_LEAST_SIZE(xXF86OldVidModeModModeLineReq);
+@@ -1754,13 +1837,14 @@ static int
+ }
+
+ static int
+- SProcXF86VidModeValidateModeLine(ClientPtr client) {
++SProcXF86VidModeValidateModeLine(ClientPtr client)
++{
+ xXF86OldVidModeValidateModeLineReq *oldstuff =
+ (xXF86OldVidModeValidateModeLineReq *) client->requestBuffer;
+ int ver;
+
+- REQUEST(xXF86VidModeValidateModeLineReq);
+- ver = ClientMajorVersion(client);
++ REQUEST(xXF86VidModeValidateModeLineReq);
++ ver = ClientMajorVersion(client);
+ if (ver < 2) {
+ swaps(&oldstuff->length);
+ REQUEST_AT_LEAST_SIZE(xXF86OldVidModeValidateModeLineReq);
+@@ -1798,44 +1882,60 @@ static int
+ }
+
+ static int
+- SProcXF86VidModeSwitchMode(ClientPtr client) {
++SProcXF86VidModeSwitchMode(ClientPtr client)
++{
+ REQUEST(xXF86VidModeSwitchModeReq);
+ swaps(&stuff->length);
+ REQUEST_SIZE_MATCH(xXF86VidModeSwitchModeReq);
+ swaps(&stuff->screen);
+ swaps(&stuff->zoom);
+ return ProcXF86VidModeSwitchMode(client);
+-} static int
+- SProcXF86VidModeSwitchToMode(ClientPtr client) {
++}
++
++static int
++SProcXF86VidModeSwitchToMode(ClientPtr client)
++{
+ REQUEST(xXF86VidModeSwitchToModeReq);
+ swaps(&stuff->length);
+ REQUEST_SIZE_MATCH(xXF86VidModeSwitchToModeReq);
+ swapl(&stuff->screen);
+ return ProcXF86VidModeSwitchToMode(client);
+-} static int
+- SProcXF86VidModeLockModeSwitch(ClientPtr client) {
++}
++
++static int
++SProcXF86VidModeLockModeSwitch(ClientPtr client)
++{
+ REQUEST(xXF86VidModeLockModeSwitchReq);
+ swaps(&stuff->length);
+ REQUEST_SIZE_MATCH(xXF86VidModeLockModeSwitchReq);
+ swaps(&stuff->screen);
+ swaps(&stuff->lock);
+ return ProcXF86VidModeLockModeSwitch(client);
+-} static int
+- SProcXF86VidModeGetMonitor(ClientPtr client) {
++}
++
++static int
++SProcXF86VidModeGetMonitor(ClientPtr client)
++{
+ REQUEST(xXF86VidModeGetMonitorReq);
+ swaps(&stuff->length);
+ REQUEST_SIZE_MATCH(xXF86VidModeGetMonitorReq);
+ swaps(&stuff->screen);
+ return ProcXF86VidModeGetMonitor(client);
+-} static int
+- SProcXF86VidModeGetViewPort(ClientPtr client) {
++}
++
++static int
++SProcXF86VidModeGetViewPort(ClientPtr client)
++{
+ REQUEST(xXF86VidModeGetViewPortReq);
+ swaps(&stuff->length);
+ REQUEST_SIZE_MATCH(xXF86VidModeGetViewPortReq);
+ swaps(&stuff->screen);
+ return ProcXF86VidModeGetViewPort(client);
+-} static int
+- SProcXF86VidModeSetViewPort(ClientPtr client) {
++}
++
++static int
++SProcXF86VidModeSetViewPort(ClientPtr client)
++{
+ REQUEST(xXF86VidModeSetViewPortReq);
+ swaps(&stuff->length);
+ REQUEST_SIZE_MATCH(xXF86VidModeSetViewPortReq);
+@@ -1843,23 +1943,32 @@ static int
+ swapl(&stuff->x);
+ swapl(&stuff->y);
+ return ProcXF86VidModeSetViewPort(client);
+-} static int
+- SProcXF86VidModeGetDotClocks(ClientPtr client) {
++}
++
++static int
++SProcXF86VidModeGetDotClocks(ClientPtr client)
++{
+ REQUEST(xXF86VidModeGetDotClocksReq);
+ swaps(&stuff->length);
+ REQUEST_SIZE_MATCH(xXF86VidModeGetDotClocksReq);
+ swaps(&stuff->screen);
+ return ProcXF86VidModeGetDotClocks(client);
+-} static int
+- SProcXF86VidModeSetClientVersion(ClientPtr client) {
++}
++
++static int
++SProcXF86VidModeSetClientVersion(ClientPtr client)
++{
+ REQUEST(xXF86VidModeSetClientVersionReq);
+ swaps(&stuff->length);
+ REQUEST_SIZE_MATCH(xXF86VidModeSetClientVersionReq);
+ swaps(&stuff->major);
+ swaps(&stuff->minor);
+ return ProcXF86VidModeSetClientVersion(client);
+-} static int
+- SProcXF86VidModeSetGamma(ClientPtr client) {
++}
++
++static int
++SProcXF86VidModeSetGamma(ClientPtr client)
++{
+ REQUEST(xXF86VidModeSetGammaReq);
+ swaps(&stuff->length);
+ REQUEST_SIZE_MATCH(xXF86VidModeSetGammaReq);
+@@ -1868,120 +1977,145 @@ static int
+ swapl(&stuff->green);
+ swapl(&stuff->blue);
+ return ProcXF86VidModeSetGamma(client);
+-} static int
+- SProcXF86VidModeGetGamma(ClientPtr client) {
++}
++
++static int
++SProcXF86VidModeGetGamma(ClientPtr client)
++{
+ REQUEST(xXF86VidModeGetGammaReq);
+ swaps(&stuff->length);
+ REQUEST_SIZE_MATCH(xXF86VidModeGetGammaReq);
+ swaps(&stuff->screen);
+ return ProcXF86VidModeGetGamma(client);
+-} static int
+- SProcXF86VidModeSetGammaRamp(ClientPtr client) {
++}
++
++static int
++SProcXF86VidModeSetGammaRamp(ClientPtr client)
++{
+ int length;
+- REQUEST(xXF86VidModeSetGammaRampReq);
+- swaps(&stuff->length);
+- REQUEST_AT_LEAST_SIZE(xXF86VidModeSetGammaRampReq);
+- swaps(&stuff->size);
+- swaps(&stuff->screen);
+- length = ((stuff->size + 1) & ~1) * 6;
+- REQUEST_FIXED_SIZE(xXF86VidModeSetGammaRampReq, length);
+- SwapRestS(stuff);
+- return ProcXF86VidModeSetGammaRamp(client);
+-} static int
+- SProcXF86VidModeGetGammaRamp(ClientPtr client) {
++
++ REQUEST(xXF86VidModeSetGammaRampReq);
++ swaps(&stuff->length);
++ REQUEST_AT_LEAST_SIZE(xXF86VidModeSetGammaRampReq);
++ swaps(&stuff->size);
++ swaps(&stuff->screen);
++ length = ((stuff->size + 1) & ~1) * 6;
++ REQUEST_FIXED_SIZE(xXF86VidModeSetGammaRampReq, length);
++ SwapRestS(stuff);
++ return ProcXF86VidModeSetGammaRamp(client);
++}
++
++static int
++SProcXF86VidModeGetGammaRamp(ClientPtr client)
++{
+ REQUEST(xXF86VidModeGetGammaRampReq);
+ swaps(&stuff->length);
+ REQUEST_SIZE_MATCH(xXF86VidModeGetGammaRampReq);
+ swaps(&stuff->size);
+ swaps(&stuff->screen);
+ return ProcXF86VidModeGetGammaRamp(client);
+-} static int
+- SProcXF86VidModeGetGammaRampSize(ClientPtr client) {
++}
++
++static int
++SProcXF86VidModeGetGammaRampSize(ClientPtr client)
++{
+ REQUEST(xXF86VidModeGetGammaRampSizeReq);
+ swaps(&stuff->length);
+ REQUEST_SIZE_MATCH(xXF86VidModeGetGammaRampSizeReq);
+ swaps(&stuff->screen);
+ return ProcXF86VidModeGetGammaRampSize(client);
+-} static int
+- SProcXF86VidModeGetPermissions(ClientPtr client) {
++}
++
++static int
++SProcXF86VidModeGetPermissions(ClientPtr client)
++{
+ REQUEST(xXF86VidModeGetPermissionsReq);
+ swaps(&stuff->length);
+ REQUEST_SIZE_MATCH(xXF86VidModeGetPermissionsReq);
+ swaps(&stuff->screen);
+ return ProcXF86VidModeGetPermissions(client);
+-} static int
+- SProcXF86VidModeDispatch(ClientPtr client) {
++}
++
++static int
++SProcXF86VidModeDispatch(ClientPtr client)
++{
+ REQUEST(xReq);
+ switch (stuff->data) {
+ case X_XF86VidModeQueryVersion:
+ return SProcXF86VidModeQueryVersion(client);
+- case X_XF86VidModeGetModeLine:return
+- SProcXF86VidModeGetModeLine(client);
+- case X_XF86VidModeGetMonitor:return SProcXF86VidModeGetMonitor(client);
+- case X_XF86VidModeGetAllModeLines:return
+- SProcXF86VidModeGetAllModeLines(client);
+- case X_XF86VidModeGetViewPort:return
+- SProcXF86VidModeGetViewPort(client);
+- case X_XF86VidModeValidateModeLine:return
+- SProcXF86VidModeValidateModeLine(client);
+- case X_XF86VidModeGetDotClocks:return
+- SProcXF86VidModeGetDotClocks(client);
+- case X_XF86VidModeSetClientVersion:return
+- SProcXF86VidModeSetClientVersion(client);
+- case X_XF86VidModeGetGamma:return SProcXF86VidModeGetGamma(client);
+- case X_XF86VidModeGetGammaRamp:return
+- SProcXF86VidModeGetGammaRamp(client);
+- case X_XF86VidModeGetGammaRampSize:return
+- SProcXF86VidModeGetGammaRampSize(client);
+- case X_XF86VidModeGetPermissions:return
+- SProcXF86VidModeGetPermissions(client);
+- default:if (!xf86GetVidModeEnabled())
++ case X_XF86VidModeGetModeLine:
++ return SProcXF86VidModeGetModeLine(client);
++ case X_XF86VidModeGetMonitor:
++ return SProcXF86VidModeGetMonitor(client);
++ case X_XF86VidModeGetAllModeLines:
++ return SProcXF86VidModeGetAllModeLines(client);
++ case X_XF86VidModeGetViewPort:
++ return SProcXF86VidModeGetViewPort(client);
++ case X_XF86VidModeValidateModeLine:
++ return SProcXF86VidModeValidateModeLine(client);
++ case X_XF86VidModeGetDotClocks:
++ return SProcXF86VidModeGetDotClocks(client);
++ case X_XF86VidModeSetClientVersion:
++ return SProcXF86VidModeSetClientVersion(client);
++ case X_XF86VidModeGetGamma:
++ return SProcXF86VidModeGetGamma(client);
++ case X_XF86VidModeGetGammaRamp:
++ return SProcXF86VidModeGetGammaRamp(client);
++ case X_XF86VidModeGetGammaRampSize:
++ return SProcXF86VidModeGetGammaRampSize(client);
++ case X_XF86VidModeGetPermissions:
++ return SProcXF86VidModeGetPermissions(client);
++ default:
++ if (!xf86GetVidModeEnabled())
+ return VidModeErrorBase + XF86VidModeExtensionDisabled;
+ if (xf86GetVidModeAllowNonLocal() || LocalClient(client)) {
+ switch (stuff->data) {
+ case X_XF86VidModeAddModeLine:
+ return SProcXF86VidModeAddModeLine(client);
+- case X_XF86VidModeDeleteModeLine:return
+- SProcXF86VidModeDeleteModeLine(client);
+- case X_XF86VidModeModModeLine:return
+- SProcXF86VidModeModModeLine(client);
+- case X_XF86VidModeSwitchMode:return
+- SProcXF86VidModeSwitchMode(client);
+- case X_XF86VidModeSwitchToMode:return
+- SProcXF86VidModeSwitchToMode(client);
+- case X_XF86VidModeLockModeSwitch:return
+- SProcXF86VidModeLockModeSwitch(client);
+- case X_XF86VidModeSetViewPort:return
+- SProcXF86VidModeSetViewPort(client);
+- case X_XF86VidModeSetGamma:return
+- SProcXF86VidModeSetGamma(client);
+- case X_XF86VidModeSetGammaRamp:return
+- SProcXF86VidModeSetGammaRamp(client);
+- default:return BadRequest;
+- }}
++ case X_XF86VidModeDeleteModeLine:
++ return SProcXF86VidModeDeleteModeLine(client);
++ case X_XF86VidModeModModeLine:
++ return SProcXF86VidModeModModeLine(client);
++ case X_XF86VidModeSwitchMode:
++ return SProcXF86VidModeSwitchMode(client);
++ case X_XF86VidModeSwitchToMode:
++ return SProcXF86VidModeSwitchToMode(client);
++ case X_XF86VidModeLockModeSwitch:
++ return SProcXF86VidModeLockModeSwitch(client);
++ case X_XF86VidModeSetViewPort:
++ return SProcXF86VidModeSetViewPort(client);
++ case X_XF86VidModeSetGamma:
++ return SProcXF86VidModeSetGamma(client);
++ case X_XF86VidModeSetGammaRamp:
++ return SProcXF86VidModeSetGammaRamp(client);
++ default:
++ return BadRequest;
++ }
++ }
+ else
+- return VidModeErrorBase + XF86VidModeClientNotLocal;
++ return VidModeErrorBase + XF86VidModeClientNotLocal;
+ }
+ }
+
+ void
+- XFree86VidModeExtensionInit(void) {
++XFree86VidModeExtensionInit(void)
++{
+ ExtensionEntry *extEntry;
+ ScreenPtr pScreen;
+ int i;
+ Bool enabled = FALSE;
+
+- DEBUG_P("XFree86VidModeExtensionInit");
++ DEBUG_P("XFree86VidModeExtensionInit");
+
+ if (!dixRegisterPrivateKey(&VidModeClientPrivateKeyRec, PRIVATE_CLIENT, 0))
+- return;
++ return;
+ #ifdef XF86VIDMODE_EVENTS
+ if (!dixRegisterPrivateKey(&ScreenPrivateKeyRec, PRIVATE_SCREEN, 0))
+- return;
++ return;
+ #endif
+
+ #ifdef XF86VIDMODE_EVENTS
+- EventType = CreateNewResourceType(XF86VidModeFreeEvents, "VidModeEvent");
++ EventType = CreateNewResourceType(XF86VidModeFreeEvents, "VidModeEvent");
+ #endif
+
+ for (i = 0; i < screenInfo.numScreens; i++) {
+@@ -1990,8 +2124,8 @@ void
+ enabled = TRUE;
+ }
+ /* This means that the DDX doesn't want the vidmode extension enabled */
+- if (!enabled)
+- return;
++ if (!enabled)
++ return;
+
+ if (
+ #ifdef XF86VIDMODE_EVENTS
+--
+cgit v0.9.0.2-2-gbebe
+From 15607cf2dc87405606b20113011f1ebd97637d32 Mon Sep 17 00:00:00 2001
+From: Daniel Kurtz <djkurtz@chromium.org>
+Date: Thu, 12 Apr 2012 00:11:10 +0000
+Subject: dix: don't BUG_WARN for button events from button-only device
+
+Events from button-only devices still need coordinates, and they get them
+from scale_to_desktop(). Therefore, a dev without valuators is not a bug.
+However, a dev with valuators, but less than two of them still is a bug.
+
+This was noticed when unplugging a "Creative Technology SB Arena Headset",
+which has some BTNs and some KEYs, but no REL or ABS valuators.
+It emits [BTN_3] = 0 on unplug, which would trigger the BUG_WARN.
+
+Signed-off-by: Daniel Kurtz <djkurtz@chromium.org>
+Reviewed-by: Chase Douglas <chase.douglas@canonical.com>
+Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
+(cherry picked from commit c5a45b0f7658c77725adce2b64a0fbd62f208328)
+---
+diff --git a/dix/getevents.c b/dix/getevents.c
+index 4e0af45..9dc9617 100644
+--- a/dix/getevents.c
++++ b/dix/getevents.c
+@@ -842,7 +842,7 @@ scale_to_desktop(DeviceIntPtr dev, ValuatorMask *mask,
+ ScreenPtr scr = miPointerGetScreen(dev);
+ double x, y;
+
+- BUG_WARN(!dev->valuator || dev->valuator->numAxes < 2);
++ BUG_WARN(dev->valuator && dev->valuator->numAxes < 2);
+ if (!dev->valuator || dev->valuator->numAxes < 2) {
+ /* if we have no axes, last.valuators must be in screen coords
+ * anyway */
+--
+cgit v0.9.0.2-2-gbebe
+From f8d2ca759ad37d5e99d462f21a2259ce17bb1a00 Mon Sep 17 00:00:00 2001
+From: Peter Hutterer <peter.hutterer@who-t.net>
+Date: Wed, 18 Apr 2012 05:56:37 +0000
+Subject: dix: indentation fix
+
+Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
+(cherry picked from commit ebf214876a4885a98ded4f5525925b69005fae05)
+---
+diff --git a/dix/dispatch.c b/dix/dispatch.c
+index 9a2e22f..d971805 100644
+--- a/dix/dispatch.c
++++ b/dix/dispatch.c
+@@ -416,8 +416,8 @@ Dispatch(void)
+ if (XSERVER_REQUEST_START_ENABLED())
+ XSERVER_REQUEST_START(LookupMajorName(client->majorOp),
+ client->majorOp,
+- ((xReq *) client->requestBuffer)->
+- length, client->index,
++ ((xReq *) client->requestBuffer)->length,
++ client->index,
+ client->requestBuffer);
+ #endif
+ if (result > (maxBigRequestSize << 2))
+--
+cgit v0.9.0.2-2-gbebe
+From f012f0c48dedba4df69cc1a1ecdf8ee5d37daca9 Mon Sep 17 00:00:00 2001
+From: Michal Suchanek <hramrach@gmail.com>
+Date: Thu, 26 Apr 2012 13:11:20 +0000
+Subject: dmx: Annotate dmxlog.c with _X_ATTRIBUTE_PRINTF and _X_NORETURN
+
+and fix resulting printf warning in dmxLogVisual
+
+Signed-off-by: Michal Suchanek <hramrach@gmail.com>
+Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
+Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
+(cherry picked from commit d662fa2450856777b59c4b62b912395a8bfd52fd)
+---
+diff --git a/hw/dmx/dmxlog.c b/hw/dmx/dmxlog.c
+index b56bb93..151f672 100644
+--- a/hw/dmx/dmxlog.c
++++ b/hw/dmx/dmxlog.c
+@@ -86,6 +86,8 @@ ErrorF(const char *format, ...)
+
+ /** Provide an VFatalError function when used stand-alone. */
+ static void
++VFatalError(const char *format, va_list args) _X_ATTRIBUTE_PRINTF(1, 0) _X_NORETURN;
++static void
+ VFatalError(const char *format, va_list args)
+ {
+ vfprintf(stderr, format, args); /* RATS: We assume the format string
+@@ -104,7 +106,9 @@ VErrorF(const char *format, va_list args)
+ }
+ #else
+ /** This function was removed between XFree86 4.3.0 and XFree86 4.4.0. */
+-extern void AbortServer(void);
++extern void AbortServer(void) _X_NORETURN;
++static void
++VFatalError(const char *format, va_list args) _X_ATTRIBUTE_PRINTF(1, 0) _X_NORETURN;
+ static void
+ VFatalError(const char *format, va_list args)
+ {
+@@ -166,6 +170,8 @@ dmxHeader(dmxLogLevel logLevel, DMXInputInfo * dmxInput,
+ /* Prints the error message with the appropriate low-level X output
+ * routine. */
+ static void
++dmxMessage(dmxLogLevel logLevel, const char *format, va_list args) _X_ATTRIBUTE_PRINTF(2, 0);
++static void
+ dmxMessage(dmxLogLevel logLevel, const char *format, va_list args)
+ {
+ if (logLevel == dmxFatal || logLevel >= dmxCurrentLogLevel) {
+@@ -303,10 +309,11 @@ dmxLogVisual(DMXScreenInfo * dmxScreen, XVisualInfo * vi, int defaultVisual)
+ class = "DirectColor";
+ break;
+ }
++#define VisualLogFormat "0x%02lx %s %2db %db/rgb %3d 0x%04lx 0x%04lx 0x%04lx%s\n"
+
+ if (dmxScreen) {
+ dmxLogOutput(dmxScreen,
+- "0x%02x %s %2db %db/rgb %3d 0x%04x 0x%04x 0x%04x%s\n",
++ VisualLogFormat,
+ vi->visualid, class, vi->depth, vi->bits_per_rgb,
+ vi->colormap_size,
+ vi->red_mask, vi->green_mask, vi->blue_mask,
+@@ -314,7 +321,7 @@ dmxLogVisual(DMXScreenInfo * dmxScreen, XVisualInfo * vi, int defaultVisual)
+ }
+ else {
+ dmxLog(dmxInfo,
+- " 0x%02x %s %2db %db/rgb %3d 0x%04x 0x%04x 0x%04x%s\n",
++ " " VisualLogFormat,
+ vi->visualid, class, vi->depth, vi->bits_per_rgb,
+ vi->colormap_size,
+ vi->red_mask, vi->green_mask, vi->blue_mask,
+diff --git a/hw/dmx/dmxlog.h b/hw/dmx/dmxlog.h
+index 4d4cd26..162484b 100644
+--- a/hw/dmx/dmxlog.h
++++ b/hw/dmx/dmxlog.h
+@@ -55,18 +55,23 @@ typedef enum {
+ /* Logging functions used by Xserver/hw/dmx routines. */
+ extern dmxLogLevel dmxSetLogLevel(dmxLogLevel newLevel);
+ extern dmxLogLevel dmxGetLogLevel(void);
+-extern void dmxLog(dmxLogLevel logLevel, const char *format, ...);
+-extern void dmxLogCont(dmxLogLevel logLevel, const char *format, ...);
++extern void dmxLog(dmxLogLevel logLevel, const char *format,
++ ...) _X_ATTRIBUTE_PRINTF(2, 3);
++extern void dmxLogCont(dmxLogLevel logLevel, const char *format,
++ ...) _X_ATTRIBUTE_PRINTF(2, 3);
+ extern const char *dmxEventName(int type);
+
+ #ifndef DMX_LOG_STANDALONE
+-extern void dmxLogOutput(DMXScreenInfo * dmxScreen, const char *format, ...);
++extern void dmxLogOutput(DMXScreenInfo * dmxScreen, const char *format,
++ ...) _X_ATTRIBUTE_PRINTF(2, 3);
+ extern void dmxLogOutputCont(DMXScreenInfo * dmxScreen, const char *format,
+- ...);
++ ...) _X_ATTRIBUTE_PRINTF(2, 3);
+ extern void dmxLogOutputWarning(DMXScreenInfo * dmxScreen, const char *format,
+- ...);
+-extern void dmxLogInput(DMXInputInfo * dmxInput, const char *format, ...);
+-extern void dmxLogInputCont(DMXInputInfo * dmxInput, const char *format, ...);
++ ...) _X_ATTRIBUTE_PRINTF(2, 3);
++extern void dmxLogInput(DMXInputInfo * dmxInput, const char *format,
++ ...) _X_ATTRIBUTE_PRINTF(2, 3);
++extern void dmxLogInputCont(DMXInputInfo * dmxInput, const char *format,
++ ...) _X_ATTRIBUTE_PRINTF(2, 3);
+ extern void dmxLogArgs(dmxLogLevel logLevel, int argc, char **argv);
+ extern void dmxLogVisual(DMXScreenInfo * dmxScreen, XVisualInfo * vi,
+ int defaultVisual);
+--
+cgit v0.9.0.2-2-gbebe
+From 58dfb13953af71021317b9d85230b1163198f031 Mon Sep 17 00:00:00 2001
+From: Jeremy Huddleston <jeremyhu@apple.com>
+Date: Thu, 10 May 2012 07:53:20 +0000
+Subject: Revert "dix: when disabling a device, release all buttons and keys"
+
+This reverts commit 90299556db24543bb7365e8c2897deca3aa219e7.
+
+The commit being reverted triggered a segfault on server shutdown when a
+device posts raw events after the root windows are forced to NULL.
+
+https://lists.debian.org/debian-x/2012/05/msg00240.html
+
+Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
+---
+diff --git a/dix/devices.c b/dix/devices.c
+index d0e99bd..0125504 100644
+--- a/dix/devices.c
++++ b/dix/devices.c
+@@ -432,8 +432,6 @@ DisableDevice(DeviceIntPtr dev, BOOL sendevent)
+ if (*prev != dev)
+ return FALSE;
+
+- ReleaseButtonsAndKeys(dev);
+-
+ /* float attached devices */
+ if (IsMaster(dev)) {
+ for (other = inputInfo.devices; other; other = other->next) {
+--
+cgit v0.9.0.2-2-gbebe
diff --git a/staging/xorg-server/xvfb-run b/staging/xorg-server/xvfb-run
new file mode 100644
index 000000000..4c2f4e0d3
--- /dev/null
+++ b/staging/xorg-server/xvfb-run
@@ -0,0 +1,180 @@
+#!/bin/sh
+
+# $Id: xvfb-run 2027 2004-11-16 14:54:16Z branden $
+
+# This script starts an instance of Xvfb, the "fake" X server, runs a command
+# with that server available, and kills the X server when done. The return
+# value of the command becomes the return value of this script.
+#
+# If anyone is using this to build a Debian package, make sure the package
+# Build-Depends on xvfb, xbase-clients, and xfonts-base.
+
+set -e
+
+PROGNAME=xvfb-run
+SERVERNUM=99
+AUTHFILE=
+ERRORFILE=/dev/null
+STARTWAIT=3
+XVFBARGS="-screen 0 640x480x8"
+LISTENTCP="-nolisten tcp"
+XAUTHPROTO=.
+
+# 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
+
+# Display a message, wrapping lines at the terminal width.
+message () {
+ echo "$PROGNAME: $*" | fmt -t -w ${COLUMNS:-$DEFCOLUMNS}
+}
+
+# Display an error message.
+error () {
+ message "error: $*" >&2
+}
+
+# Display a usage message.
+usage () {
+ if [ -n "$*" ]; then
+ message "usage error: $*"
+ fi
+ cat <<EOF
+Usage: $PROGNAME [OPTION ...] COMMAND
+Run COMMAND (usually an X client) in a virtual X server environment.
+Options:
+-a --auto-servernum try to get a free server number, starting at
+ --server-num
+-e FILE --error-file=FILE file used to store xauth errors and Xvfb
+ output (default: $ERRORFILE)
+-f FILE --auth-file=FILE file used to store auth cookie
+ (default: ./.Xauthority)
+-h --help display this usage message and exit
+-n NUM --server-num=NUM server number to use (default: $SERVERNUM)
+-l --listen-tcp enable TCP port listening in the X server
+-p PROTO --xauth-protocol=PROTO X authority protocol name to use
+ (default: xauth command's default)
+-s ARGS --server-args=ARGS arguments (other than server number and
+ "-nolisten tcp") to pass to the Xvfb server
+ (default: "$XVFBARGS")
+-w DELAY --wait=DELAY delay in seconds to wait for Xvfb to start
+ before running COMMAND (default: $STARTWAIT)
+EOF
+}
+
+# Find a free server number by looking at .X*-lock files in /tmp.
+find_free_servernum() {
+ # Sadly, the "local" keyword is not POSIX. Leave the next line commented in
+ # the hope Debian Policy eventually changes to allow it in /bin/sh scripts
+ # anyway.
+ #local i
+
+ i=$SERVERNUM
+ while [ -f /tmp/.X$i-lock ]; do
+ i=$(($i + 1))
+ done
+ echo $i
+}
+
+# Clean up files
+clean_up() {
+ if [ -e "$AUTHFILE" ]; then
+ XAUTHORITY=$AUTHFILE xauth remove ":$SERVERNUM" >>"$ERRORFILE" 2>&1
+ fi
+ if [ -n "$XVFB_RUN_TMPDIR" ]; then
+ if ! rm -r "$XVFB_RUN_TMPDIR"; then
+ error "problem while cleaning up temporary directory"
+ exit 5
+ fi
+ fi
+}
+
+# Parse the command line.
+ARGS=$(getopt --options +ae:f:hn:lp:s:w: \
+ --long auto-servernum,error-file:,auth-file:,help,server-num:,listen-tcp,xauth-protocol:,server-args:,wait: \
+ --name "$PROGNAME" -- "$@")
+GETOPT_STATUS=$?
+
+if [ $GETOPT_STATUS -ne 0 ]; then
+ error "internal error; getopt exited with status $GETOPT_STATUS"
+ exit 6
+fi
+
+eval set -- "$ARGS"
+
+while :; do
+ case "$1" in
+ -a|--auto-servernum) SERVERNUM=$(find_free_servernum) ;;
+ -e|--error-file) ERRORFILE="$2"; shift ;;
+ -f|--auth-file) AUTHFILE="$2"; shift ;;
+ -h|--help) SHOWHELP="yes" ;;
+ -n|--server-num) SERVERNUM="$2"; shift ;;
+ -l|--listen-tcp) LISTENTCP="" ;;
+ -p|--xauth-protocol) XAUTHPROTO="$2"; shift ;;
+ -s|--server-args) XVFBARGS="$2"; shift ;;
+ -w|--wait) STARTWAIT="$2"; shift ;;
+ --) shift; break ;;
+ *) error "internal error; getopt permitted \"$1\" unexpectedly"
+ exit 6
+ ;;
+ esac
+ shift
+done
+
+if [ "$SHOWHELP" ]; then
+ usage
+ exit 0
+fi
+
+if [ -z "$*" ]; then
+ usage "need a command to run" >&2
+ exit 2
+fi
+
+if ! which xauth >/dev/null; then
+ error "xauth command not found"
+ exit 3
+fi
+
+# tidy up after ourselves
+trap clean_up EXIT
+
+# If the user did not specify an X authorization file to use, set up a temporary
+# directory to house one.
+if [ -z "$AUTHFILE" ]; then
+ XVFB_RUN_TMPDIR="$(mktemp -d -t $PROGNAME.XXXXXX)"
+ AUTHFILE="$XVFB_RUN_TMPDIR/Xauthority"
+fi
+
+# Start Xvfb.
+MCOOKIE=$(mcookie)
+XAUTHORITY=$AUTHFILE xauth source - << EOF >>"$ERRORFILE" 2>&1
+add :$SERVERNUM $XAUTHPROTO $MCOOKIE
+EOF
+XAUTHORITY=$AUTHFILE Xvfb ":$SERVERNUM" $XVFBARGS $LISTENTCP >>"$ERRORFILE" \
+ 2>&1 &
+XVFBPID=$!
+sleep "$STARTWAIT"
+if ! kill -0 $XVFBPID 2>/dev/null; then
+ echo "Xvfb failed to start" >&2
+ exit 1
+fi
+
+# Start the command and save its exit status.
+set +e
+DISPLAY=:$SERVERNUM XAUTHORITY=$AUTHFILE "$@" 2>&1
+RETVAL=$?
+set -e
+
+# Kill Xvfb now that the command has exited.
+kill $XVFBPID
+
+# Return the executed command's exit status.
+exit $RETVAL
+
+# vim:set ai et sts=4 sw=4 tw=80:
diff --git a/staging/xorg-server/xvfb-run.1 b/staging/xorg-server/xvfb-run.1
new file mode 100644
index 000000000..137d3a196
--- /dev/null
+++ b/staging/xorg-server/xvfb-run.1
@@ -0,0 +1,282 @@
+.\" $Id: xvfb-run.1 2138 2005-01-17 23:40:27Z branden $
+.\"
+.\" Copyright 1998-2004 Branden Robinson <branden@debian.org>.
+.\"
+.\" This is free software; you may redistribute it and/or modify
+.\" it under the terms of the GNU General Public License as
+.\" published by the Free Software Foundation; either version 2,
+.\" or (at your option) any later version.
+.\"
+.\" This is distributed in the hope that it will be useful, but
+.\" WITHOUT ANY WARRANTY; without even the implied warranty of
+.\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+.\" GNU General Public License for more details.
+.\"
+.\" You should have received a copy of the GNU General Public License with
+.\" the Debian operating system, in /usr/share/common-licenses/GPL; if
+.\" not, write to the Free Software Foundation, Inc., 59 Temple Place,
+.\" Suite 330, Boston, MA 02111-1307 USA
+.\"
+.\" We need the URL macro from groff's www macro package, but also want
+.\" things to work all right for people who don't have it. So we define
+.\" our own URL macro and let the www macro package override it if it's
+.\" available.
+.de URL
+\\$2 \(laURL: \\$1 \(ra\\$3
+..
+.if \n[.g] .mso www.tmac
+.TH xvfb\-run 1 "2004\-11\-12" "Debian Project"
+.SH NAME
+xvfb\-run \- run specified X client or command in a virtual X server environment
+.SH SYNOPSIS
+.B xvfb\-run
+[
+.I options
+]
+.I command
+.SH DESCRIPTION
+.B xvfb\-run
+is a wrapper for the
+.BR Xvfb (1x)
+command which simplifies the task of running commands (typically an X
+client, or a script containing a list of clients to be run) within a virtual
+X server environment.
+.PP
+.B xvfb\-run
+sets up an X authority file (or uses an existing user\-specified one),
+writes a cookie to it (see
+.BR xauth (1x))
+and then starts the
+.B Xvfb
+X server as a background process.
+The process ID of
+.B Xvfb
+is stored for later use.
+The specified
+.I command
+is then run using the X display corresponding to the
+.B Xvfb
+server
+just started and the X authority file created earlier.
+.PP
+When the
+.I command
+exits, its status is saved, the
+.B Xvfb
+server is killed (using the process ID stored earlier), the X authority
+cookie removed, and the authority file deleted (if the user did not specify
+one to use).
+.B xvfb\-run
+then exits with the exit status of
+.IR command .
+.PP
+.B xvfb\-run
+requires the
+.B xauth
+command to function.
+.SH OPTIONS
+.TP
+.B \-a\fR,\fB \-\-auto\-servernum
+Try to get a free server number, starting at 99, or the argument to
+.BR \-\-server\-num .
+.TP
+.BI \-e\ file \fR,\fB\ \-\-error\-file= file
+Store output from
+.B xauth
+and
+.B Xvfb
+in
+.IR file .
+The default is
+.IR /dev/null .
+.TP
+.BI \-f\ file \fR,\fB\ \-\-auth\-file= file
+Store X authentication data in
+.IR file .
+By default, a temporary directory called
+.IR xvfb\-run. PID
+(where PID is the process ID of
+.B xvfb\-run
+itself) is created in the directory specified by the environment variable
+.B TMPDIR
+(or
+.I /tmp
+if that variable is null or unset), and the
+.BR tempfile (1)
+command is used to create a file in that temporary directory called
+.IR Xauthority .
+.TP
+.B \-h\fR,\fB \-\-help
+Display a usage message and exit.
+.TP
+.BI \-n\ servernumber \fR,\fB\ \-\-server\-num= servernumber
+Use
+.I servernumber
+as the server number (but see the
+.B \-a\fR,\fB \-\-auto\-servernum
+option above).
+The default is 99.
+.TP
+.B \-l\fR,\fB \-\-listen\-tcp
+Enable TCP port listening in the X server.
+For security reasons (to avoid denial\-of\-service attacks or exploits),
+TCP port listening is disabled by default.
+.TP
+.BI \-p\ protocolname \fR,\fB\ \-\-xauth\-protocol= protocolname
+Use
+.I protocolname
+as the X authority protocol to use.
+The default is \(oq.\(cq, which
+.B xauth
+interprets as its own default protocol, which is MIT\-MAGIC\-COOKIE\-1.
+.TP
+.BI \-s\ arguments \fR,\fB\ \-\-server\-args= arguments
+Pass
+.I arguments
+to the
+.B Xvfb
+server.
+Be careful to quote any whitespace characters that may occur within
+.I arguments
+to prevent them from regarded as separators for
+.BR xvfb\-run 's
+own arguments.
+Also, note that specification of \(oq\-nolisten tcp\(cq in
+.I arguments
+may override the function of
+.BR xvfb\-run 's
+own
+.B \-l\fR,\fB \-\-listen\-tcp
+option, and that specification of the server number (e.g., \(oq:1\(cq) may
+be ignored because of the way the X server parses its argument list.
+Use the
+.B xvfb\-run
+option
+.BI \-n\ servernumber \fR,\fB\ \-\-server\-num= servernumber
+to achieve the latter function.
+The default is \(oq\-screen 0 640x480x8\(cq.
+.TP
+.BI \-w\ delay \fR,\fB\ \-\-wait= delay
+Wait
+.I delay
+seconds after launching
+.B Xvfb
+before attempting to start the specified command.
+The default is 3.
+.SH ENVIRONMENT
+.TP
+.B COLUMNS
+indicates the width of the terminal device in character cells.
+This value is used for formatting diagnostic messages.
+If not set, the terminal is queried using
+.BR stty (1)
+to determine its width.
+If that fails, a value of \(oq80\(cq is assumed.
+.TP
+.B TMPDIR
+specifies the directory in which to place
+.BR xvfb\-run 's
+temporary directory for storage of the X authority file; only used if the
+.B \-f
+or
+.B \-\-auth\-file
+options are not specified.
+.SH "OUTPUT FILES"
+.PP
+Unless the
+.B \-f
+or
+.B \-\-auth\-file
+options are specified, a temporary
+directory and file within it are created (and deleted) to store the X
+authority cookies used by the
+.B Xvfb
+server and client(s) run under it.
+See
+.BR tempfile (1).
+If \-f or \-\-auth\-file are used, then the specified X authority file is
+only written to, not created or deleted (though
+.B xauth
+creates an authority file itself if told to use use that does not already
+exist).
+.PP
+An error file with a user\-specified name is also created if the
+.B \-e
+or
+.B \-\-error\-file
+options are specifed; see above.
+.SH "EXIT STATUS"
+.B xvfb\-run
+uses its exit status as well as output to standard error to communicate
+diagnostics.
+The exit status of \(oq1\(cq is not used, and should be interpreted as failure
+of the specified command.
+.TP
+0
+.B xvfb\-run
+only uses this exit status if the
+.B \-h\fR,\fB \-\-help
+option is given.
+In all other situations, this may be interpreted as success of the specified
+command.
+.TP
+2
+No command to run was specified.
+.TP
+3
+The
+.B xauth
+command is not available.
+.TP
+4
+The temporary directory that was going to be used already exists; since
+.B xvfb\-run
+produces a uniquely named directory, this may indicate an attempt by another
+process on the system to exploit a temporary file race condition.
+.TP
+5
+A problem was encountered while cleaning up the temporary directory.
+.TP
+6
+A problem was encountered while using
+.BR getopt (1)
+to parse the command\-line arguments.
+.SH EXAMPLES
+.TP
+.B xvfb\-run \-\-auto\-servernum \-\-server\-num=1 xlogo
+runs the
+.BR xlogo (1x)
+demonstration client inside the
+.B Xvfb
+X server on the first available server number greater than or equal to 1.
+.TP
+.B xvfb\-run \-\-server\-args="\-screen 0 1024x768x24" ico \-faces
+runs the
+.BR ico (1x)
+demonstration client (and passes it the
+.B \-faces
+argument) inside the
+.B Xvfb
+X server, configured with a root window of 1024 by 768 pixels and a color
+depth of 24 bits.
+.PP
+Note that the demo X clients used in the above examples will not exit on
+their own, so they will have to be killed before
+.B xvfb\-run
+will exit.
+.SH BUGS
+See
+.URL "http://bugs.debian.org/xvfb" "the Debian Bug Tracking System" .
+If you wish to report a bug in
+.BR xvfb\-run ,
+please use the
+.BR reportbug (1)
+command.
+.SH AUTHOR
+.B xfvb\-run
+was written by Branden Robinson and Jeff Licquia with sponsorship from
+Progeny Linux Systems.
+.SH "SEE ALSO"
+.BR Xvfb (1x),
+.BR xauth (1x)
+.\" vim:set et tw=80: