summaryrefslogtreecommitdiff
path: root/extra
diff options
context:
space:
mode:
authorroot <root@rshg054.dnsready.net>2012-03-14 00:01:30 +0000
committerroot <root@rshg054.dnsready.net>2012-03-14 00:01:30 +0000
commit01a0c4bc740842efa3bf1a7e1d6c8be5656e4e2a (patch)
treec9cf79fb6311cbb2a890419e0a382aa211fb3010 /extra
parentca06c41d7d8e5d38284de9048372ab45dcd8b2fb (diff)
Wed Mar 14 00:01:29 UTC 2012
Diffstat (limited to 'extra')
-rw-r--r--extra/freetype2/PKGBUILD6
-rw-r--r--extra/git/PKGBUILD8
-rw-r--r--extra/gstreamer0.10-base/PKGBUILD23
-rw-r--r--extra/gstreamer0.10-good/PKGBUILD15
-rw-r--r--extra/gstreamer0.10-ugly/PKGBUILD22
-rw-r--r--extra/gstreamer0.10-ugly/opencore-amr.patch35
-rw-r--r--extra/gstreamer0.10/PKGBUILD8
-rw-r--r--extra/icedtea-web-java7/PKGBUILD8
-rw-r--r--extra/icedtea-web/PKGBUILD10
-rw-r--r--extra/kactivities/PKGBUILD4
-rw-r--r--extra/kdeaccessibility-jovie/PKGBUILD4
-rw-r--r--extra/kdeaccessibility-kaccessible/PKGBUILD4
-rw-r--r--extra/kdeaccessibility-kmag/PKGBUILD4
-rw-r--r--extra/kdeaccessibility-kmousetool/PKGBUILD4
-rw-r--r--extra/kdeaccessibility-kmouth/PKGBUILD4
-rw-r--r--extra/kdeadmin/PKGBUILD4
-rw-r--r--extra/kdeartwork/PKGBUILD4
-rw-r--r--extra/kdebase-konsole/PKGBUILD4
-rw-r--r--extra/kdebase-runtime/PKGBUILD16
-rw-r--r--extra/kdebase-workspace/PKGBUILD8
-rw-r--r--extra/kdebase-workspace/kde-np.pam1
-rw-r--r--extra/kdebase-workspace/kde.pam1
-rw-r--r--extra/kdebase/PKGBUILD4
-rw-r--r--extra/kdebindings-kimono/PKGBUILD4
-rw-r--r--extra/kdebindings-korundum/PKGBUILD4
-rw-r--r--extra/kdebindings-kross/PKGBUILD4
-rw-r--r--extra/kdebindings-perlkde/PKGBUILD4
-rw-r--r--extra/kdebindings-perlqt/PKGBUILD4
-rw-r--r--extra/kdebindings-python/PKGBUILD4
-rw-r--r--extra/kdebindings-qtruby/PKGBUILD4
-rw-r--r--extra/kdebindings-qyoto/PKGBUILD4
-rw-r--r--extra/kdebindings-smokegen/PKGBUILD4
-rw-r--r--extra/kdebindings-smokekde/PKGBUILD4
-rw-r--r--extra/kdebindings-smokeqt/PKGBUILD4
-rw-r--r--extra/kdeedu-analitza/PKGBUILD4
-rw-r--r--extra/kdeedu-blinken/PKGBUILD4
-rw-r--r--extra/kdeedu-cantor/PKGBUILD4
-rw-r--r--extra/kdeedu-kalgebra/PKGBUILD4
-rw-r--r--extra/kdeedu-kalzium/PKGBUILD4
-rw-r--r--extra/kdeedu-kanagram/PKGBUILD4
-rw-r--r--extra/kdeedu-kbruch/PKGBUILD4
-rw-r--r--extra/kdeedu-kgeography/PKGBUILD4
-rw-r--r--extra/kdeedu-khangman/PKGBUILD4
-rw-r--r--extra/kdeedu-kig/PKGBUILD2
-rw-r--r--extra/kdeedu-kiten/PKGBUILD4
-rw-r--r--extra/kdeedu-klettres/PKGBUILD4
-rw-r--r--extra/kdeedu-kmplot/PKGBUILD4
-rw-r--r--extra/kdeedu-kstars/PKGBUILD4
-rw-r--r--extra/kdeedu-ktouch/PKGBUILD4
-rw-r--r--extra/kdeedu-kturtle/PKGBUILD4
-rw-r--r--extra/kdeedu-kwordquiz/PKGBUILD4
-rw-r--r--extra/kdeedu-marble/PKGBUILD4
-rw-r--r--extra/kdeedu-parley/PKGBUILD4
-rw-r--r--extra/kdeedu-rocs/PKGBUILD2
-rw-r--r--extra/kdeedu-step/PKGBUILD4
-rw-r--r--extra/kdegames/PKGBUILD4
-rw-r--r--extra/kdegraphics-gwenview/PKGBUILD4
-rw-r--r--extra/kdegraphics-kamera/PKGBUILD4
-rw-r--r--extra/kdegraphics-kcolorchooser/PKGBUILD4
-rw-r--r--extra/kdegraphics-kgamma/PKGBUILD4
-rw-r--r--extra/kdegraphics-kolourpaint/PKGBUILD4
-rw-r--r--extra/kdegraphics-kruler/PKGBUILD4
-rw-r--r--extra/kdegraphics-ksaneplugin/PKGBUILD4
-rw-r--r--extra/kdegraphics-ksnapshot/PKGBUILD4
-rw-r--r--extra/kdegraphics-mobipocket/PKGBUILD4
-rw-r--r--extra/kdegraphics-okular/PKGBUILD4
-rw-r--r--extra/kdegraphics-strigi-analyzer/PKGBUILD4
-rw-r--r--extra/kdegraphics-svgpart/PKGBUILD4
-rw-r--r--extra/kdegraphics-thumbnailers/PKGBUILD4
-rw-r--r--extra/kdemultimedia/PKGBUILD4
-rw-r--r--extra/kdenetwork/PKGBUILD2
-rw-r--r--extra/kdepim-runtime/PKGBUILD4
-rw-r--r--extra/kdepim/PKGBUILD2
-rw-r--r--extra/kdepimlibs/PKGBUILD4
-rw-r--r--extra/kdeplasma-addons/PKGBUILD4
-rw-r--r--extra/kdesdk-kate/PKGBUILD4
-rw-r--r--extra/kdesdk/PKGBUILD4
-rw-r--r--extra/kdetoys/PKGBUILD4
-rw-r--r--extra/kdeutils-filelight/PKGBUILD4
-rw-r--r--extra/kdeutils-kcalc/PKGBUILD4
-rw-r--r--extra/kdeutils-kcharselect/PKGBUILD4
-rw-r--r--extra/kdeutils-kdf/PKGBUILD4
-rw-r--r--extra/kdeutils-kfloppy/PKGBUILD4
-rw-r--r--extra/kdeutils-kgpg/PKGBUILD4
-rw-r--r--extra/kdeutils-kremotecontrol/PKGBUILD2
-rw-r--r--extra/kdeutils-ksecrets/PKGBUILD4
-rw-r--r--extra/kdeutils-ktimer/PKGBUILD4
-rw-r--r--extra/kdeutils-kwallet/PKGBUILD4
-rw-r--r--extra/kdeutils-printer-applet/PKGBUILD4
-rw-r--r--extra/kdeutils-superkaramba/PKGBUILD4
-rw-r--r--extra/kdeutils-sweeper/PKGBUILD4
-rw-r--r--extra/kdewebdev/PKGBUILD4
-rw-r--r--extra/libkdcraw/PKGBUILD4
-rw-r--r--extra/libkdeedu/PKGBUILD4
-rw-r--r--extra/libkexiv2/PKGBUILD4
-rw-r--r--extra/libkipi/PKGBUILD2
-rw-r--r--extra/libksane/PKGBUILD4
-rw-r--r--extra/libmpdclient/PKGBUILD6
-rw-r--r--extra/libpciaccess/PKGBUILD8
-rw-r--r--extra/libx11/PKGBUILD10
-rw-r--r--extra/libxcb/PKGBUILD38
-rw-r--r--extra/libxcb/libxcb-1.1-no-pthread-stubs.patch9
-rw-r--r--extra/libxft/PKGBUILD12
-rw-r--r--extra/libxft/git_fixes.diff43
-rw-r--r--extra/libxi/PKGBUILD6
-rw-r--r--extra/libxt/PKGBUILD12
-rw-r--r--extra/libxt/Revert_treat_unexpected_returned_events_from_poll_as_errors.diff40
-rw-r--r--extra/mesa/PKGBUILD134
-rw-r--r--extra/mpc/PKGBUILD32
-rw-r--r--extra/oxygen-gtk2/PKGBUILD6
-rw-r--r--extra/oxygen-gtk3/PKGBUILD6
-rw-r--r--extra/poppler/PKGBUILD15
-rw-r--r--extra/ruby/PKGBUILD4
-rw-r--r--extra/smb4k/PKGBUILD6
-rw-r--r--extra/thunar/PKGBUILD22
-rw-r--r--extra/thunar/fix-crash-8168.patch32
-rw-r--r--extra/thunar/fix-launching-multiple-files-7456.patch53
-rw-r--r--extra/thunar/fix-segfault-on-rename.patch27
-rw-r--r--extra/thunar/fix-sorting-of-large-numbers-5356.patch32
-rw-r--r--extra/xf86-input-acecad/PKGBUILD8
-rw-r--r--extra/xf86-input-aiptek/PKGBUILD8
-rw-r--r--extra/xf86-input-evdev/PKGBUILD12
-rw-r--r--extra/xf86-input-joystick/PKGBUILD17
-rw-r--r--extra/xf86-input-keyboard/PKGBUILD8
-rw-r--r--extra/xf86-input-mouse/PKGBUILD8
-rw-r--r--extra/xf86-input-synaptics/PKGBUILD25
-rw-r--r--extra/xf86-input-void/PKGBUILD8
-rw-r--r--extra/xf86-input-wacom/PKGBUILD10
-rw-r--r--extra/xf86-video-apm/PKGBUILD19
-rw-r--r--extra/xf86-video-apm/apm-1.2.3-git.patch34
-rw-r--r--extra/xf86-video-ark/PKGBUILD22
-rw-r--r--extra/xf86-video-ast/PKGBUILD19
-rw-r--r--extra/xf86-video-ast/ast-0.93.9-vga.patch38
-rw-r--r--extra/xf86-video-ati/PKGBUILD8
-rw-r--r--extra/xf86-video-chips/PKGBUILD18
-rw-r--r--extra/xf86-video-chips/chips-1.2.4-git.patch912
-rw-r--r--extra/xf86-video-cirrus/PKGBUILD19
-rw-r--r--extra/xf86-video-cirrus/cirrus-1.3.2-git.patch846
-rw-r--r--extra/xf86-video-dummy/PKGBUILD16
-rw-r--r--extra/xf86-video-fbdev/PKGBUILD12
-rw-r--r--extra/xf86-video-glint/PKGBUILD14
-rw-r--r--extra/xf86-video-i128/PKGBUILD19
-rw-r--r--extra/xf86-video-i128/i128-1.3.4-git.patch173
-rw-r--r--extra/xf86-video-i740/PKGBUILD12
-rw-r--r--extra/xf86-video-intel/PKGBUILD13
-rw-r--r--extra/xf86-video-mach64/PKGBUILD12
-rw-r--r--extra/xf86-video-mga/PKGBUILD16
-rw-r--r--extra/xf86-video-mga/git-fixes.patch800
-rw-r--r--extra/xf86-video-neomagic/PKGBUILD12
-rw-r--r--extra/xf86-video-nouveau/PKGBUILD8
-rw-r--r--extra/xf86-video-nv/PKGBUILD12
-rw-r--r--extra/xf86-video-openchrome/PKGBUILD25
-rw-r--r--extra/xf86-video-r128/PKGBUILD16
-rw-r--r--extra/xf86-video-rendition/PKGBUILD19
-rw-r--r--extra/xf86-video-rendition/rendition-4.2.4-git.patch809
-rw-r--r--extra/xf86-video-s3/PKGBUILD12
-rw-r--r--extra/xf86-video-s3virge/PKGBUILD19
-rw-r--r--extra/xf86-video-s3virge/copyright.patch82
-rw-r--r--extra/xf86-video-s3virge/s3virge-1.10.4-vga.patch76
-rw-r--r--extra/xf86-video-savage/PKGBUILD28
-rw-r--r--extra/xf86-video-siliconmotion/PKGBUILD19
-rw-r--r--extra/xf86-video-siliconmotion/smi-1.7.5-vga.patch25
-rw-r--r--extra/xf86-video-sis/PKGBUILD28
-rw-r--r--extra/xf86-video-sis/git-f5dafa24.patch1654
-rw-r--r--extra/xf86-video-sisusb/PKGBUILD19
-rw-r--r--extra/xf86-video-sisusb/sisusb-0.9.4-git.patch794
-rw-r--r--extra/xf86-video-tdfx/PKGBUILD30
-rw-r--r--extra/xf86-video-trident/PKGBUILD19
-rw-r--r--extra/xf86-video-trident/trident-1.3.4-git.patch523
-rw-r--r--extra/xf86-video-tseng/PKGBUILD18
-rw-r--r--extra/xf86-video-tseng/tseng-1.2.4-git.patch317
-rw-r--r--extra/xf86-video-unichrome/PKGBUILD16
-rw-r--r--extra/xf86-video-v4l/PKGBUILD12
-rw-r--r--extra/xf86-video-v4l/git-fixes.patch4362
-rw-r--r--extra/xf86-video-vesa/PKGBUILD27
-rw-r--r--extra/xf86-video-voodoo/PKGBUILD12
-rw-r--r--extra/xf86-video-xgixp/PKGBUILD12
-rw-r--r--extra/xorg-server/PKGBUILD30
-rw-r--r--extra/xorg-server/autoconfig-nvidia.patch55
-rw-r--r--extra/xorg-xinput/PKGBUILD14
180 files changed, 12563 insertions, 705 deletions
diff --git a/extra/freetype2/PKGBUILD b/extra/freetype2/PKGBUILD
index 66b741634..6cbf66f72 100644
--- a/extra/freetype2/PKGBUILD
+++ b/extra/freetype2/PKGBUILD
@@ -1,8 +1,8 @@
-# $Id: PKGBUILD 142921 2011-11-18 09:26:09Z andyrtr $
+# $Id: PKGBUILD 153269 2012-03-12 19:00:15Z jgc $
# Maintainer: Jan de Groot <jgc@archlinux.org>
pkgname=freetype2
-pkgver=2.4.8
+pkgver=2.4.9
pkgrel=1
pkgdesc="TrueType font rendering library"
arch=(i686 x86_64)
@@ -13,7 +13,7 @@ options=('!libtool')
source=(http://downloads.sourceforge.net/sourceforge/freetype/freetype-${pkgver}.tar.bz2
freetype-2.3.0-enable-spr.patch
freetype-2.2.1-enable-valid.patch)
-md5sums=('dbf2caca1d3afd410a29217a9809d397'
+md5sums=('77a893dae81fd5b896632715ca041179'
'816dc8619a6904a7385769433c0a8653'
'214119610444c9b02766ccee5e220680')
diff --git a/extra/git/PKGBUILD b/extra/git/PKGBUILD
index 224afafab..6419aeede 100644
--- a/extra/git/PKGBUILD
+++ b/extra/git/PKGBUILD
@@ -1,8 +1,8 @@
-# $Id: PKGBUILD 152269 2012-03-06 12:08:41Z dan $
+# $Id: PKGBUILD 153414 2012-03-13 02:15:42Z dan $
# Maintainer: Dan McGee <dan@archlinux.org>
pkgname=git
-pkgver=1.7.9.3
+pkgver=1.7.9.4
pkgrel=1
pkgdesc="the fast distributed version control system"
arch=(i686 x86_64)
@@ -92,7 +92,7 @@ package() {
install -D -m644 "$srcdir"/git-daemon.conf "$pkgdir"/etc/conf.d/git-daemon.conf
}
-sha1sums=('6216153da1139c25cb96cfb4441eff327013ec4f'
- '223daa871a64facc60bdf643c50c78eac21c88f4'
+sha1sums=('05d2ff75ffd3356516d096f992b4fb3b8b6c0079'
+ '833dc143d2d296754d681c57b41a008ff433b225'
'f2b41828bd912b72e2cb3e14677739c4f370de66'
'149e2da1ecb48872ddb31c0945afeaad1f9653d7')
diff --git a/extra/gstreamer0.10-base/PKGBUILD b/extra/gstreamer0.10-base/PKGBUILD
index ad59c539c..5bfea48f6 100644
--- a/extra/gstreamer0.10-base/PKGBUILD
+++ b/extra/gstreamer0.10-base/PKGBUILD
@@ -1,28 +1,20 @@
-# $Id: PKGBUILD 135097 2011-08-10 09:35:11Z jgc $
+# $Id: PKGBUILD 153257 2012-03-12 15:48:41Z jgc $
# Maintainer: Jan de Groot <jgc@archlinux.org>
pkgbase=('gstreamer0.10-base')
pkgname=('gstreamer0.10-base' 'gstreamer0.10-base-plugins')
-pkgver=0.10.35
+pkgver=0.10.36
pkgrel=1
arch=('i686' 'x86_64')
license=('LGPL')
makedepends=('pkgconfig' 'gstreamer0.10>=0.10.35' 'orc' 'libxv' 'alsa-lib' 'cdparanoia' 'libvisual' 'libvorbis' 'libtheora' 'pango' 'gobject-introspection')
options=(!libtool !emptydirs)
url="http://gstreamer.freedesktop.org/"
-source=(${url}/src/gst-plugins-base/gst-plugins-base-${pkgver}.tar.bz2
- oggstream-fix-crashes-with-0-byte-vorbis-packets.patch
- theoradec-segfault-on-0-byte-ogg_packet-in-_chain_reverse.patch)
-sha256sums=('cd24f01bb5258a1f400bc4f2c212bb7cee9ee23c9ffb80d537a24ef366d17103'
- '2e9d001dbe0ed598c8e86b0081c6ecdf28a1a6b45ffafc639f5cf52fdf0d467f'
- '8da16aed8c098251903208cc7ac233b7a9df3f024f78c6970e71f3c2e2bdaa17')
+source=(${url}/src/gst-plugins-base/gst-plugins-base-${pkgver}.tar.xz)
+sha256sums=('1fe45c3894903001d4d008b0713dab089f53726dcb5842d5b40c2595a984e64a')
build() {
cd "${srcdir}/gst-plugins-base-${pkgver}"
-
- patch -Np1 -i "${srcdir}/oggstream-fix-crashes-with-0-byte-vorbis-packets.patch"
- patch -Np1 -i "${srcdir}/theoradec-segfault-on-0-byte-ogg_packet-in-_chain_reverse.patch"
-
sed -i '/AC_PATH_XTRA/d' configure.ac
autoreconf
./configure --prefix=/usr --sysconfdir=/etc --localstatedir=/var \
@@ -30,10 +22,15 @@ build() {
--with-package-name="GStreamer Base Plugins (Archlinux)" \
--with-package-origin="http://www.archlinux.org/"
- make || return 1
+ make
sed -e 's/^SUBDIRS_EXT =.*/SUBDIRS_EXT =/' -i Makefile
}
+check() {
+ cd "${srcdir}/gst-plugins-base-${pkgver}"
+ make check
+}
+
package_gstreamer0.10-base() {
pkgdesc="GStreamer Multimedia Framework Base plugin libraries"
depends=('gstreamer0.10>=0.10.35' 'orc' 'libxv')
diff --git a/extra/gstreamer0.10-good/PKGBUILD b/extra/gstreamer0.10-good/PKGBUILD
index 9eb5c7629..3d0b13a61 100644
--- a/extra/gstreamer0.10-good/PKGBUILD
+++ b/extra/gstreamer0.10-good/PKGBUILD
@@ -1,17 +1,17 @@
-# $Id: PKGBUILD 148764 2012-02-05 11:49:36Z ibiru $
+# $Id: PKGBUILD 153259 2012-03-12 16:05:31Z jgc $
# Maintainer: Jan de Groot <jgc@archlinux.org>
pkgbase=gstreamer0.10-good
pkgname=('gstreamer0.10-good' 'gstreamer0.10-good-plugins')
-pkgver=0.10.30
-pkgrel=2
+pkgver=0.10.31
+pkgrel=1
arch=('i686' 'x86_64')
license=('LGPL')
makedepends=('intltool' 'pkgconfig' 'gstreamer0.10-base>=0.10.34' 'libavc1394' 'libiec61883' 'aalib' 'libshout' 'libdv' 'flac' 'gconf' 'wavpack' 'taglib' 'libsoup-gnome' 'v4l-utils' 'libcaca' 'bzip2' 'gdk-pixbuf2' 'libpulse' 'jack' 'udev')
url="http://gstreamer.freedesktop.org/"
options=(!libtool !emptydirs)
-source=(${url}/src/gst-plugins-good/gst-plugins-good-${pkgver}.tar.bz2)
-sha256sums=('b12cba90b27d8423cd0a808939098d19db3996cfb9bf528507c6321782e095f6')
+source=(${url}/src/gst-plugins-good/gst-plugins-good-${pkgver}.tar.xz)
+sha256sums=('77a8436a7c0a15f876bad29616835046890df2bcaf72da02151bd91e3d292b64')
build() {
cd "${srcdir}/gst-plugins-good-${pkgver}"
@@ -29,6 +29,11 @@ build() {
sed -e 's/gst sys ext/gst/' -i Makefile
}
+check() {
+ cd "${srcdir}/gst-plugins-good-${pkgver}"
+ make check
+}
+
package_gstreamer0.10-good() {
depends=('gstreamer0.10-base>=0.10.34' 'bzip2')
pkgdesc="GStreamer Multimedia Framework Good plugin libraries"
diff --git a/extra/gstreamer0.10-ugly/PKGBUILD b/extra/gstreamer0.10-ugly/PKGBUILD
index 7889cc845..974e0fc4a 100644
--- a/extra/gstreamer0.10-ugly/PKGBUILD
+++ b/extra/gstreamer0.10-ugly/PKGBUILD
@@ -1,20 +1,23 @@
-# $Id: PKGBUILD 150876 2012-02-23 13:48:00Z allan $
+# $Id: PKGBUILD 153261 2012-03-12 17:04:34Z jgc $
# Maintainer: Jan de Groot <jgc@archlinux.org>
pkgbase=gstreamer0.10-ugly
pkgname=('gstreamer0.10-ugly' 'gstreamer0.10-ugly-plugins')
-pkgver=0.10.18
-pkgrel=6
+pkgver=0.10.19
+pkgrel=1
arch=('i686' 'x86_64')
license=('LGPL')
-makedepends=('pkgconfig' 'gstreamer0.10-base>=0.10.34' 'libdvdread' 'lame' 'libmpeg2' 'a52dec' 'libid3tag' 'libmad' 'libsidplay' 'libcdio' 'x264' 'opencore-amr')
+makedepends=('pkgconfig' 'gstreamer0.10-base>=0.10.34' 'libdvdread' 'lame' 'libmpeg2' 'a52dec' 'libmad' 'libsidplay' 'libcdio' 'x264' 'opencore-amr')
url="http://gstreamer.freedesktop.org/"
options=(!libtool)
-source=(${url}/src/gst-plugins-ugly/gst-plugins-ugly-${pkgver}.tar.bz2)
-md5sums=('04a7009a4efea2844075949c111f5e4d')
+source=(${url}/src/gst-plugins-ugly/gst-plugins-ugly-${pkgver}.tar.xz
+ opencore-amr.patch)
+md5sums=('ba26045c8c8c91f0d48d327ccf53ac0c'
+ 'd8feb6c99bfaff8be6b2c48ea4e98e47')
build() {
cd "${srcdir}/gst-plugins-ugly-${pkgver}"
+ patch -Np0 -i "${srcdir}/opencore-amr.patch"
./configure --prefix=/usr --sysconfdir=/etc --localstatedir=/var \
--disable-static --enable-experimental \
--with-package-name="GStreamer Ugly Plugins (Archlinux)" \
@@ -23,6 +26,11 @@ build() {
sed -e 's/gst-libs gst ext/gst-libs gst/' -i Makefile
}
+check() {
+ cd "${srcdir}/gst-plugins-ugly-${pkgver}"
+ make check
+}
+
package_gstreamer0.10-ugly() {
pkgdesc="GStreamer Multimedia Framework Ugly plugin libraries"
depends=('gstreamer0.10-base>=0.10.34')
@@ -33,7 +41,7 @@ package_gstreamer0.10-ugly() {
package_gstreamer0.10-ugly-plugins() {
pkgdesc="GStreamer Multimedia Framework Ugly Plugins (gst-plugins-ugly)"
- depends=("gstreamer0.10-ugly=${pkgver}" 'libdvdread' 'lame' 'libmpeg2' 'a52dec' 'libid3tag' 'libmad' 'libsidplay' 'libcdio' 'x264' 'opencore-amr')
+ depends=("gstreamer0.10-ugly=${pkgver}" 'libdvdread' 'lame' 'libmpeg2' 'a52dec' 'libmad' 'libsidplay' 'libcdio' 'x264' 'opencore-amr')
groups=('gstreamer0.10-plugins')
replaces=('gstreamer0.10-dvdread' 'gstreamer0.10-mpeg2dec' 'gstreamer0.10-mad' 'gstreamer0.10-lame' 'gstreamer0.10-sidplay' 'gstreamer0.10-a52dec')
conflicts=('gstreamer0.10-dvdread' 'gstreamer0.10-mpeg2dec' 'gstreamer0.10-mad' 'gstreamer0.10-lame' 'gstreamer0.10-sidplay' 'gstreamer0.10-a52dec')
diff --git a/extra/gstreamer0.10-ugly/opencore-amr.patch b/extra/gstreamer0.10-ugly/opencore-amr.patch
new file mode 100644
index 000000000..0a350dc46
--- /dev/null
+++ b/extra/gstreamer0.10-ugly/opencore-amr.patch
@@ -0,0 +1,35 @@
+--- ext/amrnb/amrnbdec.h.orig 2012-03-12 16:49:14.417405139 +0000
++++ ext/amrnb/amrnbdec.h 2012-03-12 16:49:35.393899419 +0000
+@@ -22,7 +22,7 @@
+
+ #include <gst/gst.h>
+ #include <gst/audio/gstaudiodecoder.h>
+-#include <interf_dec.h>
++#include <opencore-amrnb/interf_dec.h>
+
+ G_BEGIN_DECLS
+
+--- ext/amrnb/amrnbenc.h.orig 2012-03-12 16:49:23.833996062 +0000
++++ ext/amrnb/amrnbenc.h 2012-03-12 16:49:46.597141876 +0000
+@@ -21,7 +21,7 @@
+ #define __GST_AMRNBENC_H__
+
+ #include <gst/gst.h>
+-#include <interf_enc.h>
++#include <opencore-amrnb/interf_enc.h>
+ #include <gst/audio/gstaudioencoder.h>
+
+ G_BEGIN_DECLS
+--- ext/amrwbdec/amrwbdec.h.orig 2012-03-12 16:47:48.658100992 +0000
++++ ext/amrwbdec/amrwbdec.h 2012-03-12 16:48:12.177910733 +0000
+@@ -22,8 +22,8 @@
+
+ #include <gst/gst.h>
+ #include <gst/audio/gstaudiodecoder.h>
+-#include <dec_if.h>
+-#include <if_rom.h>
++#include <opencore-amrwb/dec_if.h>
++#include <opencore-amrwb/if_rom.h>
+
+ G_BEGIN_DECLS
+
diff --git a/extra/gstreamer0.10/PKGBUILD b/extra/gstreamer0.10/PKGBUILD
index bde26b026..07299a4d7 100644
--- a/extra/gstreamer0.10/PKGBUILD
+++ b/extra/gstreamer0.10/PKGBUILD
@@ -1,8 +1,8 @@
-# $Id: PKGBUILD 134230 2011-08-02 16:10:38Z jgc $
+# $Id: PKGBUILD 153252 2012-03-12 14:53:39Z jgc $
# Maintainer: Jan de Groot <jgc@archlinux.org>
pkgname=gstreamer0.10
-pkgver=0.10.35
+pkgver=0.10.36
pkgrel=1
pkgdesc="GStreamer Multimedia Framework"
arch=('i686' 'x86_64')
@@ -12,8 +12,8 @@ depends=('libxml2' 'glib2')
optdepends=('sh: feedback script')
makedepends=('intltool' 'pkgconfig' 'gtk-doc' 'gobject-introspection')
options=('!libtool')
-source=(${url}/src/gstreamer/gstreamer-${pkgver}.tar.bz2)
-sha256sums=('817bfea2cd46e2487b97e2ed9218f0299b32a3de1e5e80b4c7868d17e9089786')
+source=(${url}/src/gstreamer/gstreamer-${pkgver}.tar.xz)
+md5sums=('15389c73e091b1dda915279c388b9cb2')
build() {
cd "${srcdir}/gstreamer-${pkgver}"
diff --git a/extra/icedtea-web-java7/PKGBUILD b/extra/icedtea-web-java7/PKGBUILD
index 31c0e9566..b12233bbb 100644
--- a/extra/icedtea-web-java7/PKGBUILD
+++ b/extra/icedtea-web-java7/PKGBUILD
@@ -3,14 +3,14 @@
pkgbase=icedtea-web-java7
pkgname=('icedtea-web-java7' 'icedtea-web-java7-doc')
-pkgver=1.1.5
+pkgver=1.2
pkgrel=1
arch=('i686' 'x86_64')
url="http://icedtea.classpath.org/wiki/IcedTea-Web"
license=('GPL2')
makedepends=('jdk7-openjdk' 'zip' 'gtk2' 'libxtst' 'npapi-sdk' 'rhino' 'junit')
source=(http://icedtea.classpath.org/download/source/${pkgbase/-java7/}-$pkgver.tar.gz)
-sha256sums=('ab5c34a9dc6bff48baf1f1d1a34bf54bfb954ad93ee9e7e44d642fa991bcc919')
+sha256sums=('3f8d22b655df207409dd3451ba02907f61a12ac051e4df4d44bb5ed47c4f778d')
_javaver=7
_jvmdir=/usr/lib/jvm/java-${_javaver}-openjdk
@@ -29,7 +29,9 @@ build() {
check() {
cd "${srcdir}"/icedtea-web*
- make -k check
+ # as more tests have been added some are expectged to fail
+ # see http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2012-March/017566.html
+ make -k check || /bin/true
}
diff --git a/extra/icedtea-web/PKGBUILD b/extra/icedtea-web/PKGBUILD
index fed422199..b9884b410 100644
--- a/extra/icedtea-web/PKGBUILD
+++ b/extra/icedtea-web/PKGBUILD
@@ -1,16 +1,16 @@
-# $Id: PKGBUILD 152259 2012-03-06 05:29:22Z andyrtr $
+# $Id: PKGBUILD 153280 2012-03-12 20:33:58Z andyrtr $
# Maintainer: Andreas Radke <andyrtr@archlinux.org>
pkgbase=icedtea-web
pkgname=('icedtea-web' 'icedtea-web-doc')
-pkgver=1.1.5
+pkgver=1.2
pkgrel=1
arch=('i686' 'x86_64')
url="http://icedtea.classpath.org/wiki/IcedTea-Web"
license=('GPL2')
makedepends=('openjdk6' 'zip' 'gtk2' 'npapi-sdk' 'rhino' 'junit')
source=(http://icedtea.classpath.org/download/source/$pkgname-$pkgver.tar.gz)
-sha256sums=('ab5c34a9dc6bff48baf1f1d1a34bf54bfb954ad93ee9e7e44d642fa991bcc919')
+sha256sums=('3f8d22b655df207409dd3451ba02907f61a12ac051e4df4d44bb5ed47c4f778d')
_javaver=6
_jvmdir=/usr/lib/jvm/java-${_javaver}-openjdk
@@ -24,7 +24,9 @@ build() {
check() {
cd "$srcdir/$pkgname-$pkgver"
- make -k check
+ # as more tests have been added some are expectged to fail
+ # see http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2012-March/017566.html
+ make -k check || /bin/true
}
diff --git a/extra/kactivities/PKGBUILD b/extra/kactivities/PKGBUILD
index 76d22ab0f..ae6b79549 100644
--- a/extra/kactivities/PKGBUILD
+++ b/extra/kactivities/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152486 2012-03-07 16:12:35Z andrea $
+# $Id: PKGBUILD 153087 2012-03-12 09:08:04Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kactivities
@@ -10,7 +10,7 @@ url='http://kde.org/'
license=('GPL' 'FDL')
depends=('kdelibs')
makedepends=('cmake' 'automoc4')
-source=("http://download.kde.org/stable/${pkgver}/src/xz/${pkgname}-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/${pkgname}-${pkgver}.tar.xz")
sha1sums=('29979514848633da71780b342e7328063bd47d07')
build() {
diff --git a/extra/kdeaccessibility-jovie/PKGBUILD b/extra/kdeaccessibility-jovie/PKGBUILD
index bef6a0495..b65b9d2bf 100644
--- a/extra/kdeaccessibility-jovie/PKGBUILD
+++ b/extra/kdeaccessibility-jovie/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152506 2012-03-07 16:13:18Z andrea $
+# $Id: PKGBUILD 153104 2012-03-12 09:12:14Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdeaccessibility-jovie
@@ -13,7 +13,7 @@ depends=('kdebase-runtime' 'speech-dispatcher')
makedepends=('cmake' 'automoc4')
replaces=('kdeaccessibility-kttsd')
install=${pkgname}.install
-source=("http://download.kde.org/stable/${pkgver}/src/xz/jovie-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/jovie-${pkgver}.tar.xz")
sha1sums=('4ac647ac3823b6a4f01f839f3e11bca09d6353ee')
build() {
diff --git a/extra/kdeaccessibility-kaccessible/PKGBUILD b/extra/kdeaccessibility-kaccessible/PKGBUILD
index f09974e94..b3fb8d850 100644
--- a/extra/kdeaccessibility-kaccessible/PKGBUILD
+++ b/extra/kdeaccessibility-kaccessible/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152508 2012-03-07 16:13:20Z andrea $
+# $Id: PKGBUILD 153106 2012-03-12 09:12:46Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdeaccessibility-kaccessible
@@ -11,7 +11,7 @@ license=('GPL' 'FDL')
groups=('kde' 'kdeaccessibility')
depends=('kdelibs' 'speech-dispatcher')
makedepends=('cmake' 'automoc4')
-source=("http://download.kde.org/stable/${pkgver}/src/xz/kaccessible-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/kaccessible-${pkgver}.tar.xz")
sha1sums=('da137f22a8de55858a3ae80f4e95d89c18b50257')
build() {
diff --git a/extra/kdeaccessibility-kmag/PKGBUILD b/extra/kdeaccessibility-kmag/PKGBUILD
index 1445c60a0..65b8b6166 100644
--- a/extra/kdeaccessibility-kmag/PKGBUILD
+++ b/extra/kdeaccessibility-kmag/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152510 2012-03-07 16:13:23Z andrea $
+# $Id: PKGBUILD 153108 2012-03-12 09:13:16Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdeaccessibility-kmag
@@ -12,7 +12,7 @@ groups=('kde' 'kdeaccessibility')
depends=('kdebase-runtime')
makedepends=('cmake' 'automoc4')
install=${pkgname}.install
-source=("http://download.kde.org/stable/${pkgver}/src/xz/kmag-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/kmag-${pkgver}.tar.xz")
sha1sums=('35686d11ecf5e2783b7518499300a715ef27108d')
build() {
diff --git a/extra/kdeaccessibility-kmousetool/PKGBUILD b/extra/kdeaccessibility-kmousetool/PKGBUILD
index 8c8992204..6cd9d2254 100644
--- a/extra/kdeaccessibility-kmousetool/PKGBUILD
+++ b/extra/kdeaccessibility-kmousetool/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152512 2012-03-07 16:13:27Z andrea $
+# $Id: PKGBUILD 153110 2012-03-12 09:13:45Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdeaccessibility-kmousetool
@@ -12,7 +12,7 @@ groups=('kde' 'kdeaccessibility')
depends=('kdebase-runtime')
makedepends=('cmake' 'automoc4')
install=${pkgname}.install
-source=("http://download.kde.org/stable/${pkgver}/src/xz/kmousetool-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/kmousetool-${pkgver}.tar.xz")
sha1sums=('8b3f0323602ab33a5749c7e5c75d50b62c352786')
build() {
diff --git a/extra/kdeaccessibility-kmouth/PKGBUILD b/extra/kdeaccessibility-kmouth/PKGBUILD
index add86d95b..36ba23a37 100644
--- a/extra/kdeaccessibility-kmouth/PKGBUILD
+++ b/extra/kdeaccessibility-kmouth/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152514 2012-03-07 16:13:31Z andrea $
+# $Id: PKGBUILD 153112 2012-03-12 09:14:16Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdeaccessibility-kmouth
@@ -12,7 +12,7 @@ groups=('kde' 'kdeaccessibility')
depends=('kdebase-runtime')
makedepends=('cmake' 'automoc4')
install=${pkgname}.install
-source=("http://download.kde.org/stable/${pkgver}/src/xz/kmouth-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/kmouth-${pkgver}.tar.xz")
sha1sums=('b4cecf89eea96892608fd125635ea9f9f7fee8be')
build() {
diff --git a/extra/kdeadmin/PKGBUILD b/extra/kdeadmin/PKGBUILD
index ef7319c44..a8cdfe6c8 100644
--- a/extra/kdeadmin/PKGBUILD
+++ b/extra/kdeadmin/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152516 2012-03-07 16:13:38Z andrea $
+# $Id: PKGBUILD 153114 2012-03-12 09:14:51Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
# Contributor: Pierre Schmitz <pierre@archlinux.de>
@@ -14,7 +14,7 @@ url='http://www.kde.org'
license=('GPL' 'LGPL' 'FDL')
groups=('kde' 'kdeadmin')
makedepends=('cmake' 'automoc4' 'kdebindings-python' 'system-config-printer-common')
-source=("http://download.kde.org/stable/${pkgver}/src/xz/${pkgbase}-${pkgver}.tar.xz"
+source=("http://download.kde.org/stable/${pkgver}/src/${pkgbase}-${pkgver}.tar.xz"
'syslog-path.patch')
sha1sums=('0ee44575bfb45159ced6d4d046b07323ebab00e7'
'20095ce6e0f3e5b6800a7c6e52de6fddba62c031')
diff --git a/extra/kdeartwork/PKGBUILD b/extra/kdeartwork/PKGBUILD
index 36ab0e29f..c946c6f79 100644
--- a/extra/kdeartwork/PKGBUILD
+++ b/extra/kdeartwork/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152518 2012-03-07 16:13:43Z andrea $
+# $Id: PKGBUILD 153116 2012-03-12 09:15:24Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
# Contributor: Pierre Schmitz <pierre@archlinux.de>
@@ -21,7 +21,7 @@ license=('GPL' 'LGPL' 'FDL')
groups=('kde' 'kdeartwork')
makedepends=('cmake' 'automoc4' 'xscreensaver' 'eigen' 'kdebase-workspace'
'libkexiv2')
-source=("http://download.kde.org/stable/${pkgver}/src/xz/${pkgbase}-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/${pkgbase}-${pkgver}.tar.xz")
sha1sums=('31215ff41d01c8bf680578abe57b65648441a135')
build() {
diff --git a/extra/kdebase-konsole/PKGBUILD b/extra/kdebase-konsole/PKGBUILD
index 5988a276e..ac470be3e 100644
--- a/extra/kdebase-konsole/PKGBUILD
+++ b/extra/kdebase-konsole/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152520 2012-03-07 16:13:46Z andrea $
+# $Id: PKGBUILD 153118 2012-03-12 09:15:57Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdebase-konsole
@@ -11,7 +11,7 @@ license=('GPL' 'LGPL' 'FDL')
groups=('kde' 'kdebase')
depends=('kdebase-runtime' 'kdebase-lib')
makedepends=('cmake' 'automoc4')
-source=("http://download.kde.org/stable/${pkgver}/src/xz/konsole-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/konsole-${pkgver}.tar.xz")
sha1sums=('23490d929c6c3a56485e4c6585a1d10af9810651')
build() {
diff --git a/extra/kdebase-runtime/PKGBUILD b/extra/kdebase-runtime/PKGBUILD
index bfec466b7..37c135c51 100644
--- a/extra/kdebase-runtime/PKGBUILD
+++ b/extra/kdebase-runtime/PKGBUILD
@@ -1,23 +1,21 @@
-# $Id: PKGBUILD 152464 2012-03-07 16:11:58Z andrea $
+# $Id: PKGBUILD 153395 2012-03-12 20:57:08Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
# Contributor: Pierre Schmitz <pierre@archlinux.de>
pkgname=kdebase-runtime
pkgver=4.8.1
-pkgrel=1
+pkgrel=2
pkgdesc="KDE Base Runtime Environment"
arch=('i686' 'x86_64')
url='http://www.kde.org'
license=('GPL' 'LGPL')
-depends=('kdelibs' 'ntrack' 'smbclient' 'libssh' 'libcanberra' 'oxygen-icons'
- 'xorg-xauth')
-makedepends=('pkg-config' 'cmake' 'automoc4' 'kdepimlibs' 'openslp' 'doxygen'
- 'xine-lib')
+depends=('kdelibs' 'smbclient' 'libssh' 'libcanberra' 'oxygen-icons' 'xorg-xauth')
+makedepends=('pkg-config' 'cmake' 'automoc4' 'kdepimlibs' 'openslp' 'doxygen')
optdepends=('htdig: to build the search index in khelpcenter'
'rarian: needed by khelpcenter'
'gdb: drkonq crash handler')
install="${pkgname}.install"
-source=("http://download.kde.org/stable/${pkgver}/src/xz/kde-runtime-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/kde-runtime-${pkgver}.tar.xz")
sha1sums=('82b57dc38335716fb382a665b536a9aece4684d6')
build() {
@@ -27,7 +25,9 @@ build() {
cmake ../kde-runtime-${pkgver} \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_SKIP_RPATH=ON \
- -DCMAKE_INSTALL_PREFIX=/usr
+ -DCMAKE_INSTALL_PREFIX=/usr \
+ -DWITH_QNtrack=OFF \
+ -DWITH_Xine=OFF
make
}
diff --git a/extra/kdebase-workspace/PKGBUILD b/extra/kdebase-workspace/PKGBUILD
index 734b298ab..5f8cb0768 100644
--- a/extra/kdebase-workspace/PKGBUILD
+++ b/extra/kdebase-workspace/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152488 2012-03-07 16:12:41Z andrea $
+# $Id: PKGBUILD 153084 2012-03-12 09:07:28Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
# Contributor: Pierre Schmitz <pierre@archlinux.de>
@@ -31,13 +31,13 @@ backup=('usr/share/config/kdm/kdmrc'
'etc/pam.d/kde-np'
'etc/pam.d/kscreensaver')
options=('emptydirs')
-source=("http://download.kde.org/stable/${pkgver}/src/xz/${_pkgname}-${pkgver}.tar.xz"
+source=("http://download.kde.org/stable/${pkgver}/src/${_pkgname}-${pkgver}.tar.xz"
'kdm' 'kde.pam' 'kde-np.pam' 'kscreensaver.pam'
'fixpath.patch' 'terminate-server.patch' 'kdm-xinitrd.patch')
sha1sums=('675df4befd736e770e3029af8d38800c9018e888'
'5db3a245201bd4a50e65aa2ef583cf5490e4f646'
- 'e4198a443703f749b58a4fec88362fced1b45789'
- '264e395c2c44cdda5a242c6dee649afab44cd6e5'
+ '712a90999bd429883dcef5dcaf288aace332ced8'
+ 'b321b5e613b60231330e606fdf1e124646148388'
'106635aa1aae51d6f0668b1853f6c49a4fe9d3d8'
'd7b5883f7e65c6839b1f65f94d58026673dd0226'
'ac7bc292c865bc1ab8c02e6341aa7aeaf1a3eeee'
diff --git a/extra/kdebase-workspace/kde-np.pam b/extra/kdebase-workspace/kde-np.pam
index dfedb8edf..7d60cc35c 100644
--- a/extra/kdebase-workspace/kde-np.pam
+++ b/extra/kdebase-workspace/kde-np.pam
@@ -1,6 +1,7 @@
#%PAM-1.0
auth required pam_nologin.so
auth required pam_permit.so
+auth required pam_env.so
account required pam_unix.so
password required pam_unix.so
session required pam_unix.so
diff --git a/extra/kdebase-workspace/kde.pam b/extra/kdebase-workspace/kde.pam
index 9ec074d06..ec1d8277f 100644
--- a/extra/kdebase-workspace/kde.pam
+++ b/extra/kdebase-workspace/kde.pam
@@ -1,6 +1,7 @@
#%PAM-1.0
auth required pam_unix.so
auth required pam_nologin.so
+auth required pam_env.so
account required pam_unix.so
password required pam_unix.so
session required pam_unix.so
diff --git a/extra/kdebase/PKGBUILD b/extra/kdebase/PKGBUILD
index 59f5ca09e..bc0fa6c28 100644
--- a/extra/kdebase/PKGBUILD
+++ b/extra/kdebase/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152490 2012-03-07 16:12:45Z andrea $
+# $Id: PKGBUILD 153088 2012-03-12 09:08:09Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
# Contributor: Pierre Schmitz <pierre@archlinux.de>
@@ -19,7 +19,7 @@ url='http://www.kde.org'
license=('GPL' 'LGPL' 'FDL')
groups=('kde' 'kdebase')
makedepends=('kdelibs' 'cmake' 'automoc4' 'tidyhtml')
-source=("http://download.kde.org/stable/${pkgver}/src/xz/kde-baseapps-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/kde-baseapps-${pkgver}.tar.xz")
sha1sums=('bfbc51930a81ea272ddbb1fc9a9cefb9cf9a81d6')
build() {
diff --git a/extra/kdebindings-kimono/PKGBUILD b/extra/kdebindings-kimono/PKGBUILD
index f2f347521..b5ad96bc7 100644
--- a/extra/kdebindings-kimono/PKGBUILD
+++ b/extra/kdebindings-kimono/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152522 2012-03-07 16:13:49Z andrea $
+# $Id: PKGBUILD 153120 2012-03-12 09:16:29Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdebindings-kimono
@@ -12,7 +12,7 @@ groups=('kdebindings')
depends=('kdebindings-qyoto' 'kdebindings-smokekde')
makedepends=('cmake' 'automoc4' 'kdebindings-smokegen' 'boost' 'kdepimlibs')
conflicts=('kdebindings-csharp')
-source=("http://download.kde.org/stable/${pkgver}/src/xz/kimono-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/kimono-${pkgver}.tar.xz")
sha1sums=('cecf979d52091a2baaabb7334750f8376d835b0a')
build() {
diff --git a/extra/kdebindings-korundum/PKGBUILD b/extra/kdebindings-korundum/PKGBUILD
index b30a52aa0..9a9875ea7 100644
--- a/extra/kdebindings-korundum/PKGBUILD
+++ b/extra/kdebindings-korundum/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152524 2012-03-07 16:13:52Z andrea $
+# $Id: PKGBUILD 153122 2012-03-12 09:16:59Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdebindings-korundum
@@ -14,7 +14,7 @@ makedepends=('cmake' 'automoc4' 'kdebindings-smokegen' 'boost'
'kdepimlibs' 'kdegraphics-okular' 'kdesdk-kate')
conflicts=('kdebindings-ruby')
options=('!makeflags')
-source=("http://download.kde.org/stable/${pkgver}/src/xz/korundum-${pkgver}.tar.xz"
+source=("http://download.kde.org/stable/${pkgver}/src/korundum-${pkgver}.tar.xz"
'korundum-4.8.0-ruby19.patch')
sha1sums=('10788c362d209785ce800d70c3b8823af49cf16c'
'73299f56a891d8a5475ac07dd485619859312f70')
diff --git a/extra/kdebindings-kross/PKGBUILD b/extra/kdebindings-kross/PKGBUILD
index fdd9847ab..cae462e88 100644
--- a/extra/kdebindings-kross/PKGBUILD
+++ b/extra/kdebindings-kross/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152526 2012-03-07 16:13:57Z andrea $
+# $Id: PKGBUILD 153124 2012-03-12 09:17:31Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgbase=kdebindings-kross
@@ -12,7 +12,7 @@ arch=('i686' 'x86_64')
license=('GPL' 'LGPL' 'FDL')
groups=('kdebindings')
makedepends=('kdelibs' 'cmake' 'automoc4' 'python2' 'java-environment')
-source=("http://download.kde.org/stable/${pkgver}/src/xz/kross-interpreters-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/kross-interpreters-${pkgver}.tar.xz")
sha1sums=('28a20608fedf726615fc6b97664a30a350e58540')
build() {
diff --git a/extra/kdebindings-perlkde/PKGBUILD b/extra/kdebindings-perlkde/PKGBUILD
index eb4f60281..5b32ef867 100644
--- a/extra/kdebindings-perlkde/PKGBUILD
+++ b/extra/kdebindings-perlkde/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152528 2012-03-07 16:14:02Z andrea $
+# $Id: PKGBUILD 153126 2012-03-12 09:18:04Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdebindings-perlkde
@@ -12,7 +12,7 @@ groups=('kdebindings')
depends=('kdebindings-perlqt' 'kdebindings-smokekde')
makedepends=('cmake' 'automoc4' 'kdebindings-smokegen' 'kdepimlibs'
'kdegraphics-okular' 'kdesdk-kate')
-source=("http://download.kde.org/stable/${pkgver}/src/xz/perlkde-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/perlkde-${pkgver}.tar.xz")
sha1sums=('93e3b009c972a697aebf0450c4c07ff87a5c0461')
build() {
diff --git a/extra/kdebindings-perlqt/PKGBUILD b/extra/kdebindings-perlqt/PKGBUILD
index b01ee7eb9..42cb9d1de 100644
--- a/extra/kdebindings-perlqt/PKGBUILD
+++ b/extra/kdebindings-perlqt/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152478 2012-03-07 16:12:22Z andrea $
+# $Id: PKGBUILD 153076 2012-03-12 09:04:09Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdebindings-perlqt
@@ -11,7 +11,7 @@ license=('GPL' 'LGPL' 'FDL')
groups=('kdebindings')
depends=('kdebindings-smokeqt' 'perl-list-moreutils')
makedepends=('cmake' 'automoc4' 'kdebindings-smokegen')
-source=("http://download.kde.org/stable/${pkgver}/src/xz/perlqt-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/perlqt-${pkgver}.tar.xz")
sha1sums=('119bbce5e82a47c8f70a8a124b73aa1cacf646ff')
build() {
diff --git a/extra/kdebindings-python/PKGBUILD b/extra/kdebindings-python/PKGBUILD
index 6df77cad7..5389b88a7 100644
--- a/extra/kdebindings-python/PKGBUILD
+++ b/extra/kdebindings-python/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152480 2012-03-07 16:12:27Z andrea $
+# $Id: PKGBUILD 153078 2012-03-12 09:04:41Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdebindings-python
@@ -11,7 +11,7 @@ license=('GPL' 'LGPL' 'FDL')
groups=('kdebindings')
depends=('kdepim-runtime' 'python2-pyqt' 'qscintilla')
makedepends=('cmake' 'automoc4' 'boost')
-source=("http://download.kde.org/stable/${pkgver}/src/xz/pykde4-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/pykde4-${pkgver}.tar.xz")
sha1sums=('b9ef35269d2e08578ba20d01822dbdbed72bffb8')
build() {
diff --git a/extra/kdebindings-qtruby/PKGBUILD b/extra/kdebindings-qtruby/PKGBUILD
index 0ff402521..c591969ea 100644
--- a/extra/kdebindings-qtruby/PKGBUILD
+++ b/extra/kdebindings-qtruby/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152484 2012-03-07 16:12:33Z andrea $
+# $Id: PKGBUILD 153082 2012-03-12 09:05:48Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdebindings-qtruby
@@ -12,7 +12,7 @@ groups=('kdebindings')
depends=('kdebindings-smokeqt' 'ruby')
makedepends=('cmake' 'automoc4' 'kdebindings-smokegen')
conflicts=('kdebindings-ruby')
-source=("http://download.kde.org/stable/${pkgver}/src/xz/qtruby-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/qtruby-${pkgver}.tar.xz")
sha1sums=('b2532f9e9e04760fce5d9ac87768e6085f0c231b')
build() {
diff --git a/extra/kdebindings-qyoto/PKGBUILD b/extra/kdebindings-qyoto/PKGBUILD
index 05742c189..091cba8d2 100644
--- a/extra/kdebindings-qyoto/PKGBUILD
+++ b/extra/kdebindings-qyoto/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152482 2012-03-07 16:12:30Z andrea $
+# $Id: PKGBUILD 153080 2012-03-12 09:05:15Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdebindings-qyoto
@@ -12,7 +12,7 @@ groups=('kdebindings')
depends=('kdebindings-smokeqt' 'mono')
makedepends=('cmake' 'automoc4' 'kdebindings-smokegen')
conflicts=('kdebindings-csharp')
-source=("http://download.kde.org/stable/${pkgver}/src/xz/qyoto-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/qyoto-${pkgver}.tar.xz")
sha1sums=('32ad56ce6189ce691ed46b8494c4cb446dda6016')
build() {
diff --git a/extra/kdebindings-smokegen/PKGBUILD b/extra/kdebindings-smokegen/PKGBUILD
index c68a05bde..c711b780e 100644
--- a/extra/kdebindings-smokegen/PKGBUILD
+++ b/extra/kdebindings-smokegen/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152468 2012-03-07 16:12:03Z andrea $
+# $Id: PKGBUILD 153065 2012-03-12 09:01:20Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdebindings-smokegen
@@ -11,7 +11,7 @@ license=('GPL' 'LGPL' 'FDL')
depends=('kdebase-runtime')
makedepends=('cmake' 'automoc4')
conflicts=('kdebindings-smoke')
-source=("http://download.kde.org/stable/${pkgver}/src/xz/smokegen-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/smokegen-${pkgver}.tar.xz")
sha1sums=('6d43ed064730ff81e1844d0634c1b574bd4ffdb2')
build() {
diff --git a/extra/kdebindings-smokekde/PKGBUILD b/extra/kdebindings-smokekde/PKGBUILD
index 9d7222399..101cf6775 100644
--- a/extra/kdebindings-smokekde/PKGBUILD
+++ b/extra/kdebindings-smokekde/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152476 2012-03-07 16:12:17Z andrea $
+# $Id: PKGBUILD 153074 2012-03-12 09:03:36Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdebindings-smokekde
@@ -13,7 +13,7 @@ depends=('kdebindings-smokeqt')
makedepends=('cmake' 'automoc4' 'kdebindings-smokegen' 'boost'
'kdepimlibs' 'kdegraphics-okular' 'kdesdk-kate')
conflicts=('kdebindings-smoke')
-source=("http://download.kde.org/stable/${pkgver}/src/xz/smokekde-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/smokekde-${pkgver}.tar.xz")
sha1sums=('680a29725c4b04629befafcd6c74dbc8cc6238f6')
build() {
diff --git a/extra/kdebindings-smokeqt/PKGBUILD b/extra/kdebindings-smokeqt/PKGBUILD
index 1f56b0d1e..0a52750bc 100644
--- a/extra/kdebindings-smokeqt/PKGBUILD
+++ b/extra/kdebindings-smokeqt/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152470 2012-03-07 16:12:08Z andrea $
+# $Id: PKGBUILD 153068 2012-03-12 09:01:53Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdebindings-smokeqt
@@ -12,7 +12,7 @@ groups=('kdebindings')
depends=('kdebase-runtime' 'qimageblitz' 'qscintilla' 'kdebindings-smokegen')
makedepends=('cmake' 'automoc4')
conflicts=('kdebindings-smoke')
-source=("http://download.kde.org/stable/${pkgver}/src/xz/smokeqt-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/smokeqt-${pkgver}.tar.xz")
sha1sums=('7af6089df0ffefe7a88600e43641dfd18da8e3e8')
build() {
diff --git a/extra/kdeedu-analitza/PKGBUILD b/extra/kdeedu-analitza/PKGBUILD
index 1f5f7e677..2c9cf9c1f 100644
--- a/extra/kdeedu-analitza/PKGBUILD
+++ b/extra/kdeedu-analitza/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152504 2012-03-07 16:13:15Z andrea $
+# $Id: PKGBUILD 153102 2012-03-12 09:11:44Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdeedu-analitza
@@ -11,7 +11,7 @@ license=('GPL' 'LGPL' 'FDL')
groups=('kde' 'kdeedu')
depends=('kdelibs')
makedepends=('cmake' 'automoc4')
-source=("http://download.kde.org/stable/${pkgver}/src/xz/analitza-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/analitza-${pkgver}.tar.xz")
sha1sums=('94c175417126c578c38f29c348a8bb8f54cdfb45')
build() {
diff --git a/extra/kdeedu-blinken/PKGBUILD b/extra/kdeedu-blinken/PKGBUILD
index 4f5f534af..65de66711 100644
--- a/extra/kdeedu-blinken/PKGBUILD
+++ b/extra/kdeedu-blinken/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152530 2012-03-07 16:14:06Z andrea $
+# $Id: PKGBUILD 153128 2012-03-12 09:18:34Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdeedu-blinken
@@ -12,7 +12,7 @@ groups=('kde' 'kdeedu')
depends=('kdebase-runtime')
makedepends=('cmake' 'automoc4')
install=${pkgname}.install
-source=("http://download.kde.org/stable/${pkgver}/src/xz/blinken-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/blinken-${pkgver}.tar.xz")
sha1sums=('ff9f07ee59145a9993604fdef7f301c09c095775')
build() {
diff --git a/extra/kdeedu-cantor/PKGBUILD b/extra/kdeedu-cantor/PKGBUILD
index c21c1b404..3ee9c8408 100644
--- a/extra/kdeedu-cantor/PKGBUILD
+++ b/extra/kdeedu-cantor/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152532 2012-03-07 16:14:09Z andrea $
+# $Id: PKGBUILD 153130 2012-03-12 09:19:04Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdeedu-cantor
@@ -15,7 +15,7 @@ optdepends=('maxima: Maxima backend'
'octave: Octave backend'
'r: R backend')
install=${pkgname}.install
-source=("http://download.kde.org/stable/${pkgver}/src/xz/cantor-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/cantor-${pkgver}.tar.xz")
sha1sums=('bc98d41262454de5aee65b124e7f93041ad639af')
build() {
diff --git a/extra/kdeedu-kalgebra/PKGBUILD b/extra/kdeedu-kalgebra/PKGBUILD
index f8360a81f..87672c664 100644
--- a/extra/kdeedu-kalgebra/PKGBUILD
+++ b/extra/kdeedu-kalgebra/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152534 2012-03-07 16:14:13Z andrea $
+# $Id: PKGBUILD 153132 2012-03-12 09:19:34Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdeedu-kalgebra
@@ -12,7 +12,7 @@ groups=('kde' 'kdeedu')
depends=('kdebase-runtime' 'libkdeedu' 'kdeedu-analitza')
makedepends=('cmake' 'automoc4')
install=${pkgname}.install
-source=("http://download.kde.org/stable/${pkgver}/src/xz/kalgebra-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/kalgebra-${pkgver}.tar.xz")
sha1sums=('79f4c85e93a1d270d9d7ba648b86d49fca42d6fb')
build() {
diff --git a/extra/kdeedu-kalzium/PKGBUILD b/extra/kdeedu-kalzium/PKGBUILD
index e88490663..88fee129f 100644
--- a/extra/kdeedu-kalzium/PKGBUILD
+++ b/extra/kdeedu-kalzium/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152536 2012-03-07 16:14:18Z andrea $
+# $Id: PKGBUILD 153134 2012-03-12 09:20:04Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdeedu-kalzium
@@ -12,7 +12,7 @@ groups=('kde' 'kdeedu')
depends=('kdelibs' 'avogadro' 'ocaml' 'facile')
makedepends=('cmake' 'automoc4')
install=${pkgname}.install
-source=("http://download.kde.org/stable/${pkgver}/src/xz/kalzium-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/kalzium-${pkgver}.tar.xz")
sha1sums=('914072b8a324e6966528e0047ea50c2a52736051')
build() {
diff --git a/extra/kdeedu-kanagram/PKGBUILD b/extra/kdeedu-kanagram/PKGBUILD
index 27a571bb4..5641fcc9a 100644
--- a/extra/kdeedu-kanagram/PKGBUILD
+++ b/extra/kdeedu-kanagram/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152538 2012-03-07 16:14:25Z andrea $
+# $Id: PKGBUILD 153136 2012-03-12 09:20:34Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdeedu-kanagram
@@ -12,7 +12,7 @@ groups=('kde' 'kdeedu')
depends=('kdebase-runtime' 'libkdeedu')
makedepends=('cmake' 'automoc4')
install=${pkgname}.install
-source=("http://download.kde.org/stable/${pkgver}/src/xz/kanagram-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/kanagram-${pkgver}.tar.xz")
sha1sums=('d41fa85f894fb0ada8757e4282a57102fda32006')
build() {
diff --git a/extra/kdeedu-kbruch/PKGBUILD b/extra/kdeedu-kbruch/PKGBUILD
index 1f9012107..1e3174aab 100644
--- a/extra/kdeedu-kbruch/PKGBUILD
+++ b/extra/kdeedu-kbruch/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152540 2012-03-07 16:14:32Z andrea $
+# $Id: PKGBUILD 153138 2012-03-12 09:21:03Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdeedu-kbruch
@@ -12,7 +12,7 @@ groups=('kde' 'kdeedu')
depends=('kdebase-runtime')
makedepends=('cmake' 'automoc4')
install=${pkgname}.install
-source=("http://download.kde.org/stable/${pkgver}/src/xz/kbruch-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/kbruch-${pkgver}.tar.xz")
sha1sums=('477e508294b097d8367f80a65b1be7c60b1f3211')
build() {
diff --git a/extra/kdeedu-kgeography/PKGBUILD b/extra/kdeedu-kgeography/PKGBUILD
index bef245768..4d302023b 100644
--- a/extra/kdeedu-kgeography/PKGBUILD
+++ b/extra/kdeedu-kgeography/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152542 2012-03-07 16:14:39Z andrea $
+# $Id: PKGBUILD 153140 2012-03-12 09:21:32Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdeedu-kgeography
@@ -12,7 +12,7 @@ groups=('kde' 'kdeedu')
depends=('kdebase-runtime')
makedepends=('cmake' 'automoc4')
install=${pkgname}.install
-source=("http://download.kde.org/stable/${pkgver}/src/xz/kgeography-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/kgeography-${pkgver}.tar.xz")
sha1sums=('58b526d3a597cc2afff49f431a78864d36842ef2')
build() {
diff --git a/extra/kdeedu-khangman/PKGBUILD b/extra/kdeedu-khangman/PKGBUILD
index 4d33fbb6b..ad233acfe 100644
--- a/extra/kdeedu-khangman/PKGBUILD
+++ b/extra/kdeedu-khangman/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152544 2012-03-07 16:14:46Z andrea $
+# $Id: PKGBUILD 153142 2012-03-12 09:22:03Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdeedu-khangman
@@ -12,7 +12,7 @@ groups=('kde' 'kdeedu')
depends=('kdebase-runtime' 'libkdeedu')
makedepends=('cmake' 'automoc4')
install=${pkgname}.install
-source=("http://download.kde.org/stable/${pkgver}/src/xz/khangman-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/khangman-${pkgver}.tar.xz")
sha1sums=('102eb6edec5f2c6f6f9086c6fb2136a6550cdef1')
build() {
diff --git a/extra/kdeedu-kig/PKGBUILD b/extra/kdeedu-kig/PKGBUILD
index 2e5ad0f1a..d3b652be1 100644
--- a/extra/kdeedu-kig/PKGBUILD
+++ b/extra/kdeedu-kig/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152853 2012-03-10 09:36:12Z andrea $
+# $Id: PKGBUILD 153144 2012-03-12 09:22:32Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdeedu-kig
diff --git a/extra/kdeedu-kiten/PKGBUILD b/extra/kdeedu-kiten/PKGBUILD
index c1ffd6cf8..3df55f152 100644
--- a/extra/kdeedu-kiten/PKGBUILD
+++ b/extra/kdeedu-kiten/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152548 2012-03-07 16:15:00Z andrea $
+# $Id: PKGBUILD 153146 2012-03-12 09:23:02Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdeedu-kiten
@@ -12,7 +12,7 @@ groups=('kde' 'kdeedu')
depends=('kdebase-runtime')
makedepends=('cmake' 'automoc4')
install=${pkgname}.install
-source=("http://download.kde.org/stable/${pkgver}/src/xz/kiten-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/kiten-${pkgver}.tar.xz")
sha1sums=('c2c165f4bc89bcbe3a6b49eb06231d4bf85132f0')
build() {
diff --git a/extra/kdeedu-klettres/PKGBUILD b/extra/kdeedu-klettres/PKGBUILD
index d2669f697..730758457 100644
--- a/extra/kdeedu-klettres/PKGBUILD
+++ b/extra/kdeedu-klettres/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152550 2012-03-07 16:15:06Z andrea $
+# $Id: PKGBUILD 153148 2012-03-12 09:23:31Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdeedu-klettres
@@ -12,7 +12,7 @@ groups=('kde' 'kdeedu')
depends=('kdebase-runtime')
makedepends=('cmake' 'automoc4')
install=${pkgname}.install
-source=("http://download.kde.org/stable/${pkgver}/src/xz/klettres-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/klettres-${pkgver}.tar.xz")
sha1sums=('d26ced07799a849d42e0865c143515934bfb9446')
build() {
diff --git a/extra/kdeedu-kmplot/PKGBUILD b/extra/kdeedu-kmplot/PKGBUILD
index 812d5077d..c7cd50139 100644
--- a/extra/kdeedu-kmplot/PKGBUILD
+++ b/extra/kdeedu-kmplot/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152552 2012-03-07 16:15:10Z andrea $
+# $Id: PKGBUILD 153150 2012-03-12 09:24:01Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdeedu-kmplot
@@ -12,7 +12,7 @@ groups=('kde' 'kdeedu')
depends=('kdebase-runtime')
makedepends=('cmake' 'automoc4')
install=${pkgname}.install
-source=("http://download.kde.org/stable/${pkgver}/src/xz/kmplot-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/kmplot-${pkgver}.tar.xz")
sha1sums=('04eadb4a030e594c9ea09b55142640345b1c36c4')
build() {
diff --git a/extra/kdeedu-kstars/PKGBUILD b/extra/kdeedu-kstars/PKGBUILD
index 05f79bb72..5fa518198 100644
--- a/extra/kdeedu-kstars/PKGBUILD
+++ b/extra/kdeedu-kstars/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152554 2012-03-07 16:15:13Z andrea $
+# $Id: PKGBUILD 153152 2012-03-12 09:24:33Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdeedu-kstars
@@ -12,7 +12,7 @@ groups=('kde' 'kdeedu')
depends=('kdebase-runtime' 'eigen' 'cfitsio' 'libindi')
makedepends=('cmake' 'automoc4')
install=${pkgname}.install
-source=("http://download.kde.org/stable/${pkgver}/src/xz/kstars-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/kstars-${pkgver}.tar.xz")
sha1sums=('5453568396529c4767fb5485e1493d86bd0e6177')
build() {
diff --git a/extra/kdeedu-ktouch/PKGBUILD b/extra/kdeedu-ktouch/PKGBUILD
index ce4c27f83..8eb295d99 100644
--- a/extra/kdeedu-ktouch/PKGBUILD
+++ b/extra/kdeedu-ktouch/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152556 2012-03-07 16:15:16Z andrea $
+# $Id: PKGBUILD 153154 2012-03-12 09:25:04Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdeedu-ktouch
@@ -12,7 +12,7 @@ groups=('kde' 'kdeedu')
depends=('kdebase-runtime')
makedepends=('cmake' 'automoc4')
install=${pkgname}.install
-source=("http://download.kde.org/stable/${pkgver}/src/xz/ktouch-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/ktouch-${pkgver}.tar.xz")
sha1sums=('42598cddc04de3d7ec64ea88068b2313333e02fd')
build() {
diff --git a/extra/kdeedu-kturtle/PKGBUILD b/extra/kdeedu-kturtle/PKGBUILD
index 629f95c4f..e9a813833 100644
--- a/extra/kdeedu-kturtle/PKGBUILD
+++ b/extra/kdeedu-kturtle/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152559 2012-03-07 16:15:18Z andrea $
+# $Id: PKGBUILD 153156 2012-03-12 09:25:34Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdeedu-kturtle
@@ -12,7 +12,7 @@ groups=('kde' 'kdeedu')
depends=('kdebase-runtime')
makedepends=('cmake' 'automoc4')
install=${pkgname}.install
-source=("http://download.kde.org/stable/${pkgver}/src/xz/kturtle-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/kturtle-${pkgver}.tar.xz")
sha1sums=('3a6a3828c44957644716608234a3813690d0c503')
build() {
diff --git a/extra/kdeedu-kwordquiz/PKGBUILD b/extra/kdeedu-kwordquiz/PKGBUILD
index 9b7827b4e..ec59c20ae 100644
--- a/extra/kdeedu-kwordquiz/PKGBUILD
+++ b/extra/kdeedu-kwordquiz/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152561 2012-03-07 16:15:21Z andrea $
+# $Id: PKGBUILD 153158 2012-03-12 09:26:05Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdeedu-kwordquiz
@@ -12,7 +12,7 @@ groups=('kde' 'kdeedu')
depends=('kdebase-runtime' 'libkdeedu')
makedepends=('cmake' 'automoc4')
install=${pkgname}.install
-source=("http://download.kde.org/stable/${pkgver}/src/xz/kwordquiz-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/kwordquiz-${pkgver}.tar.xz")
sha1sums=('954e49b9dea8e486f8316b9215e12d736e9b1448')
build() {
diff --git a/extra/kdeedu-marble/PKGBUILD b/extra/kdeedu-marble/PKGBUILD
index 28b705d44..238ce851f 100644
--- a/extra/kdeedu-marble/PKGBUILD
+++ b/extra/kdeedu-marble/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152494 2012-03-07 16:12:57Z andrea $
+# $Id: PKGBUILD 153092 2012-03-12 09:09:09Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdeedu-marble
@@ -13,7 +13,7 @@ depends=('kdebase-runtime')
makedepends=('cmake' 'automoc4' 'gpsd')
optdepends=('gpsd: gps support')
install=${pkgname}.install
-source=("http://download.kde.org/stable/${pkgver}/src/xz/marble-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/marble-${pkgver}.tar.xz")
sha1sums=('542da37f6ea2df21b331aea28cab810eb6802b78')
build() {
diff --git a/extra/kdeedu-parley/PKGBUILD b/extra/kdeedu-parley/PKGBUILD
index c2e4ac6cb..3dda88390 100644
--- a/extra/kdeedu-parley/PKGBUILD
+++ b/extra/kdeedu-parley/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152563 2012-03-07 16:15:25Z andrea $
+# $Id: PKGBUILD 153160 2012-03-12 09:26:36Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdeedu-parley
@@ -12,7 +12,7 @@ groups=('kde' 'kdeedu')
depends=('kdebase-runtime' 'libkdeedu')
makedepends=('cmake' 'automoc4')
install=${pkgname}.install
-source=("http://download.kde.org/stable/${pkgver}/src/xz/parley-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/parley-${pkgver}.tar.xz")
sha1sums=('65cb2a02e5da3d9f1f9bb5a2017743b116bce1cb')
build() {
diff --git a/extra/kdeedu-rocs/PKGBUILD b/extra/kdeedu-rocs/PKGBUILD
index 5a7a200eb..6b3fa3e97 100644
--- a/extra/kdeedu-rocs/PKGBUILD
+++ b/extra/kdeedu-rocs/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152855 2012-03-10 09:48:31Z andrea $
+# $Id: PKGBUILD 153162 2012-03-12 09:27:09Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdeedu-rocs
diff --git a/extra/kdeedu-step/PKGBUILD b/extra/kdeedu-step/PKGBUILD
index 56878a614..1217a5e96 100644
--- a/extra/kdeedu-step/PKGBUILD
+++ b/extra/kdeedu-step/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152567 2012-03-07 16:15:32Z andrea $
+# $Id: PKGBUILD 153164 2012-03-12 09:27:39Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdeedu-step
@@ -12,7 +12,7 @@ groups=('kde' 'kdeedu')
depends=('kdebase-runtime' 'libqalculate' 'gsl' 'eigen')
makedepends=('cmake' 'automoc4')
install=${pkgname}.install
-source=("http://download.kde.org/stable/${pkgver}/src/xz/step-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/step-${pkgver}.tar.xz")
sha1sums=('5b8da2e1efe783e46042603d9ba87f1f464ba105')
build() {
diff --git a/extra/kdegames/PKGBUILD b/extra/kdegames/PKGBUILD
index 487c63080..d28f5d297 100644
--- a/extra/kdegames/PKGBUILD
+++ b/extra/kdegames/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152569 2012-03-07 16:15:42Z andrea $
+# $Id: PKGBUILD 153166 2012-03-12 09:29:12Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
# Contributor: Pierre Schmitz <pierre@archlinux.de>
@@ -51,7 +51,7 @@ license=('GPL' 'LGPL' 'FDL')
groups=('kde' 'kdegames')
makedepends=('cmake' 'automoc4' 'ggz-client-libs' 'twisted' 'kdebindings-python'
'openal')
-source=("http://download.kde.org/stable/${pkgver}/src/xz/${pkgbase}-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/${pkgbase}-${pkgver}.tar.xz")
sha1sums=('bcf764fd1f2f8083c388c17f26b83eeac568b1d5')
build() {
diff --git a/extra/kdegraphics-gwenview/PKGBUILD b/extra/kdegraphics-gwenview/PKGBUILD
index 3a412f9ea..7ca2620c2 100644
--- a/extra/kdegraphics-gwenview/PKGBUILD
+++ b/extra/kdegraphics-gwenview/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152572 2012-03-07 16:15:47Z andrea $
+# $Id: PKGBUILD 153168 2012-03-12 09:29:42Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdegraphics-gwenview
@@ -13,7 +13,7 @@ depends=('kdebase-lib' 'libkipi')
makedepends=('cmake' 'automoc4')
optdepends=('kipi-plugins: extra plugins to share photos')
install=$pkgname.install
-source=("http://download.kde.org/stable/${pkgver}/src/xz/gwenview-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/gwenview-${pkgver}.tar.xz")
sha1sums=('c549b0256140c6c466e3279cf12bdc6e6ee82960')
build() {
diff --git a/extra/kdegraphics-kamera/PKGBUILD b/extra/kdegraphics-kamera/PKGBUILD
index a9bc20469..b44b8bc50 100644
--- a/extra/kdegraphics-kamera/PKGBUILD
+++ b/extra/kdegraphics-kamera/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152574 2012-03-07 16:15:51Z andrea $
+# $Id: PKGBUILD 153170 2012-03-12 09:30:19Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdegraphics-kamera
@@ -11,7 +11,7 @@ license=('GPL' 'LGPL' 'FDL')
groups=('kde' 'kdegraphics')
depends=('kdebase-runtime' 'gphoto2')
makedepends=('cmake' 'automoc4')
-source=("http://download.kde.org/stable/${pkgver}/src/xz/kamera-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/kamera-${pkgver}.tar.xz")
sha1sums=('98a54976430aa3061d14f5b71c6d5d896abc9baf')
build() {
diff --git a/extra/kdegraphics-kcolorchooser/PKGBUILD b/extra/kdegraphics-kcolorchooser/PKGBUILD
index 6ec26e1c5..83d343699 100644
--- a/extra/kdegraphics-kcolorchooser/PKGBUILD
+++ b/extra/kdegraphics-kcolorchooser/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152576 2012-03-07 16:15:54Z andrea $
+# $Id: PKGBUILD 153172 2012-03-12 09:30:49Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdegraphics-kcolorchooser
@@ -12,7 +12,7 @@ groups=('kde' 'kdegraphics')
depends=('kdebase-runtime')
makedepends=('cmake' 'automoc4')
install=${pkgname}.install
-source=("http://download.kde.org/stable/${pkgver}/src/xz/kcolorchooser-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/kcolorchooser-${pkgver}.tar.xz")
sha1sums=('b82a86ac95ca9b4c1dbd66b8164ce855232fec69')
build() {
diff --git a/extra/kdegraphics-kgamma/PKGBUILD b/extra/kdegraphics-kgamma/PKGBUILD
index dab1badbf..0ecb98d99 100644
--- a/extra/kdegraphics-kgamma/PKGBUILD
+++ b/extra/kdegraphics-kgamma/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152578 2012-03-07 16:15:56Z andrea $
+# $Id: PKGBUILD 153174 2012-03-12 09:31:22Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdegraphics-kgamma
@@ -14,7 +14,7 @@ groups=('kde' 'kdegraphics')
# but nvidia providing libgl does not depend on libxxf86vm
depends=('kdebase-runtime' 'libxxf86vm')
makedepends=('cmake' 'automoc4')
-source=("http://download.kde.org/stable/${pkgver}/src/xz/kgamma-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/kgamma-${pkgver}.tar.xz")
sha1sums=('9829ed03f9faac64afafe83bb84eae0048929dfe')
build() {
diff --git a/extra/kdegraphics-kolourpaint/PKGBUILD b/extra/kdegraphics-kolourpaint/PKGBUILD
index 512a5f350..cbd5d7f21 100644
--- a/extra/kdegraphics-kolourpaint/PKGBUILD
+++ b/extra/kdegraphics-kolourpaint/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152580 2012-03-07 16:15:59Z andrea $
+# $Id: PKGBUILD 153176 2012-03-12 09:31:52Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdegraphics-kolourpaint
@@ -12,7 +12,7 @@ groups=('kde' 'kdegraphics')
depends=('kdebase-runtime' 'qimageblitz')
makedepends=('cmake' 'automoc4')
install=${pkgname}.install
-source=("http://download.kde.org/stable/${pkgver}/src/xz/kolourpaint-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/kolourpaint-${pkgver}.tar.xz")
sha1sums=('7a6404f573671b8407a2cf4ec3543ab0883a7af2')
build() {
diff --git a/extra/kdegraphics-kruler/PKGBUILD b/extra/kdegraphics-kruler/PKGBUILD
index 4f3af8fff..08641cebe 100644
--- a/extra/kdegraphics-kruler/PKGBUILD
+++ b/extra/kdegraphics-kruler/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152582 2012-03-07 16:16:03Z andrea $
+# $Id: PKGBUILD 153178 2012-03-12 09:32:22Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdegraphics-kruler
@@ -12,7 +12,7 @@ groups=('kde' 'kdegraphics')
depends=('kdebase-runtime')
makedepends=('cmake' 'automoc4')
install=${pkgname}.install
-source=("http://download.kde.org/stable/${pkgver}/src/xz/kruler-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/kruler-${pkgver}.tar.xz")
sha1sums=('e551744f2e3f772450eb6fe21358067e9448799e')
build() {
diff --git a/extra/kdegraphics-ksaneplugin/PKGBUILD b/extra/kdegraphics-ksaneplugin/PKGBUILD
index d9631b9b5..5dc589577 100644
--- a/extra/kdegraphics-ksaneplugin/PKGBUILD
+++ b/extra/kdegraphics-ksaneplugin/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152584 2012-03-07 16:16:05Z andrea $
+# $Id: PKGBUILD 153180 2012-03-12 09:32:55Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdegraphics-ksaneplugin
@@ -12,7 +12,7 @@ depends=('libksane')
makedepends=('cmake' 'automoc4')
replaces=('kdegraphics-libs')
conflicts=('kdegraphics-libs')
-source=("http://download.kde.org/stable/${pkgver}/src/xz/ksaneplugin-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/ksaneplugin-${pkgver}.tar.xz")
sha1sums=('6f59ab3630850d9ceee15e9d01cb1b6b6dedc9e9')
build() {
diff --git a/extra/kdegraphics-ksnapshot/PKGBUILD b/extra/kdegraphics-ksnapshot/PKGBUILD
index f9415043b..fc7058317 100644
--- a/extra/kdegraphics-ksnapshot/PKGBUILD
+++ b/extra/kdegraphics-ksnapshot/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152586 2012-03-07 16:16:08Z andrea $
+# $Id: PKGBUILD 153182 2012-03-12 09:33:25Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdegraphics-ksnapshot
@@ -13,7 +13,7 @@ depends=('kdelibs' 'libkipi')
makedepends=('cmake' 'automoc4')
optdepends=('kipi-plugins')
install=${pkgname}.install
-source=("http://download.kde.org/stable/${pkgver}/src/xz/ksnapshot-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/ksnapshot-${pkgver}.tar.xz")
sha1sums=('3e8f0842d06d0fbb98dcebeba684847552fc02a9')
build() {
diff --git a/extra/kdegraphics-mobipocket/PKGBUILD b/extra/kdegraphics-mobipocket/PKGBUILD
index 1a0f5e9d6..6cce5063d 100644
--- a/extra/kdegraphics-mobipocket/PKGBUILD
+++ b/extra/kdegraphics-mobipocket/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152588 2012-03-07 16:16:11Z andrea $
+# $Id: PKGBUILD 153184 2012-03-12 09:33:54Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdegraphics-mobipocket
@@ -13,7 +13,7 @@ makedepends=('cmake' 'automoc4' 'kdegraphics-okular')
replaces=('kdegraphics-libs')
conflicts=('kdegraphics-libs')
install=${pkgname}.install
-source=("http://download.kde.org/stable/${pkgver}/src/xz/${pkgname}-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/${pkgname}-${pkgver}.tar.xz")
sha1sums=('6ffef4612619ac433addee9fae7f49c05455863b')
build() {
diff --git a/extra/kdegraphics-okular/PKGBUILD b/extra/kdegraphics-okular/PKGBUILD
index cb404a54e..f0d3a6f94 100644
--- a/extra/kdegraphics-okular/PKGBUILD
+++ b/extra/kdegraphics-okular/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152472 2012-03-07 16:12:11Z andrea $
+# $Id: PKGBUILD 153070 2012-03-12 09:02:23Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdegraphics-okular
@@ -14,7 +14,7 @@ depends=('kdebase-runtime' 'qimageblitz' 'poppler-qt' 'chmlib' 'djvulibre'
makedepends=('cmake' 'automoc4')
optdepends=('kdegraphics-mobipocket: mobipocket support')
install=${pkgname}.install
-source=("http://download.kde.org/stable/${pkgver}/src/xz/okular-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/okular-${pkgver}.tar.xz")
sha1sums=('ddf676820acf3615d1996bf40e82ebd5c9aa41d8')
build() {
diff --git a/extra/kdegraphics-strigi-analyzer/PKGBUILD b/extra/kdegraphics-strigi-analyzer/PKGBUILD
index f058a25dc..b9c9ae2a2 100644
--- a/extra/kdegraphics-strigi-analyzer/PKGBUILD
+++ b/extra/kdegraphics-strigi-analyzer/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152590 2012-03-07 16:16:16Z andrea $
+# $Id: PKGBUILD 153186 2012-03-12 09:34:28Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdegraphics-strigi-analyzer
@@ -12,7 +12,7 @@ depends=('kdelibs')
makedepends=('cmake' 'automoc4')
replaces=('kdegraphics-libs')
conflicts=('kdegraphics-libs')
-source=("http://download.kde.org/stable/${pkgver}/src/xz/${pkgname}-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/${pkgname}-${pkgver}.tar.xz")
sha1sums=('2e951029c3874cd5f10a75dc4d88b653b76a3121')
build() {
diff --git a/extra/kdegraphics-svgpart/PKGBUILD b/extra/kdegraphics-svgpart/PKGBUILD
index a6090150a..859380342 100644
--- a/extra/kdegraphics-svgpart/PKGBUILD
+++ b/extra/kdegraphics-svgpart/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152592 2012-03-07 16:16:21Z andrea $
+# $Id: PKGBUILD 153188 2012-03-12 09:35:01Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdegraphics-svgpart
@@ -12,7 +12,7 @@ depends=('kdelibs')
makedepends=('cmake' 'automoc4')
replaces=('kdegraphics-libs')
conflicts=('kdegraphics-libs')
-source=("http://download.kde.org/stable/${pkgver}/src/xz/svgpart-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/svgpart-${pkgver}.tar.xz")
sha1sums=('2332156b52c9f1a33cc0f0cb9d64f01aaf38f9bc')
build() {
diff --git a/extra/kdegraphics-thumbnailers/PKGBUILD b/extra/kdegraphics-thumbnailers/PKGBUILD
index 6200281ef..3dde950d3 100644
--- a/extra/kdegraphics-thumbnailers/PKGBUILD
+++ b/extra/kdegraphics-thumbnailers/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152594 2012-03-07 16:16:27Z andrea $
+# $Id: PKGBUILD 153190 2012-03-12 09:35:34Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdegraphics-thumbnailers
@@ -12,7 +12,7 @@ depends=('libkexiv2' 'libkdcraw')
makedepends=('cmake' 'automoc4')
replaces=('kdegraphics-libs')
conflicts=('kdegraphics-libs')
-source=("http://download.kde.org/stable/${pkgver}/src/xz/${pkgname}-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/${pkgname}-${pkgver}.tar.xz")
sha1sums=('a714f485f68202c8b6e2716cf426abd6d82c0dc7')
build() {
diff --git a/extra/kdemultimedia/PKGBUILD b/extra/kdemultimedia/PKGBUILD
index b6761d7c2..9e320eb0a 100644
--- a/extra/kdemultimedia/PKGBUILD
+++ b/extra/kdemultimedia/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152596 2012-03-07 16:16:34Z andrea $
+# $Id: PKGBUILD 153192 2012-03-12 09:36:16Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
# Contributor: Pierre Schmitz <pierre@archlinux.de>
@@ -18,7 +18,7 @@ license=('GPL' 'LGPL' 'FDL')
groups=('kde' 'kdemultimedia')
makedepends=('cmake' 'automoc4' 'kdelibs' 'tunepimp' 'ffmpeg' 'mplayer'
'pulseaudio' 'libmusicbrainz3')
-source=("http://download.kde.org/stable/${pkgver}/src/xz/${pkgbase}-${pkgver}.tar.xz"
+source=("http://download.kde.org/stable/${pkgver}/src/${pkgbase}-${pkgver}.tar.xz"
'mplayerthumbs.config')
sha1sums=('9de14f08c7f1649201be029b8e683a296cc75f52'
'ba016fa2563c14ffcba852c62506b66bfc6ee683')
diff --git a/extra/kdenetwork/PKGBUILD b/extra/kdenetwork/PKGBUILD
index e12663c2d..53e7bfcc5 100644
--- a/extra/kdenetwork/PKGBUILD
+++ b/extra/kdenetwork/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152598 2012-03-07 16:16:41Z andrea $
+# $Id: PKGBUILD 153194 2012-03-12 09:37:02Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
# Contributor: Pierre Schmitz <pierre@archlinux.de>
diff --git a/extra/kdepim-runtime/PKGBUILD b/extra/kdepim-runtime/PKGBUILD
index d34ea527c..2c28e4d91 100644
--- a/extra/kdepim-runtime/PKGBUILD
+++ b/extra/kdepim-runtime/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152466 2012-03-07 16:12:01Z andrea $
+# $Id: PKGBUILD 153062 2012-03-12 09:00:47Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
# Contributor: Pierre Schmitz <pierre@archlinux.de>
@@ -12,7 +12,7 @@ license=('GPL' 'LGPL' 'FDL')
depends=('kdepimlibs' 'kdebase-runtime')
makedepends=('cmake' 'automoc4' 'boost')
install=${pkgname}.install
-source=("http://download.kde.org/stable/${pkgver}/src/xz/${pkgname}-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/${pkgname}-${pkgver}.tar.xz")
sha1sums=('2e2e5f1dbfd1b54f0e2b71f9f23be2cfa94348f2')
build() {
diff --git a/extra/kdepim/PKGBUILD b/extra/kdepim/PKGBUILD
index 8ec4e8559..cb4720e8e 100644
--- a/extra/kdepim/PKGBUILD
+++ b/extra/kdepim/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152600 2012-03-07 16:16:49Z andrea $
+# $Id: PKGBUILD 153196 2012-03-12 09:37:49Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
# Contributor: Pierre Schmitz <pierre@archlinux.de>
diff --git a/extra/kdepimlibs/PKGBUILD b/extra/kdepimlibs/PKGBUILD
index 33b5ea612..82787b3b1 100644
--- a/extra/kdepimlibs/PKGBUILD
+++ b/extra/kdepimlibs/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152461 2012-03-07 16:11:52Z andrea $
+# $Id: PKGBUILD 153055 2012-03-12 08:59:19Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
# Contributor: Pierre Schmitz <pierre@archlinux.de>
@@ -12,7 +12,7 @@ license=('GPL' 'LGPL')
depends=('kdelibs' 'gpgme' 'akonadi' 'libical' 'prison')
makedepends=('cmake' 'automoc4' 'boost' 'cyrus-sasl' 'openldap')
install='kdepimlibs.install'
-source=("http://download.kde.org/stable/${pkgver}/src/xz/${pkgname}-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/${pkgname}-${pkgver}.tar.xz")
sha1sums=('ccc653df34fd8f5f8eddac9a9e14f0fa1ea82839')
build() {
diff --git a/extra/kdeplasma-addons/PKGBUILD b/extra/kdeplasma-addons/PKGBUILD
index 6892de569..26636f0b3 100644
--- a/extra/kdeplasma-addons/PKGBUILD
+++ b/extra/kdeplasma-addons/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152602 2012-03-07 16:17:00Z andrea $
+# $Id: PKGBUILD 153198 2012-03-12 09:38:25Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
# Contributor: Pierre Schmitz <pierre@archlinux.de>
@@ -82,7 +82,7 @@ license=('GPL' 'LGPL')
groups=('kde' 'kdeplasma-addons')
makedepends=('cmake' 'automoc4' 'kdebase-workspace' 'kdeedu-marble' 'eigen'
'scim' 'qwt' 'boost' 'libkexiv2' 'ibus')
-source=("http://download.kde.org/stable/${pkgver}/src/xz/${pkgbase}-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/${pkgbase}-${pkgver}.tar.xz")
sha1sums=('dad77ee1f6ab341a327d694f670e15f160d77d7c')
build() {
diff --git a/extra/kdesdk-kate/PKGBUILD b/extra/kdesdk-kate/PKGBUILD
index 2d9eeede3..3a332b7df 100644
--- a/extra/kdesdk-kate/PKGBUILD
+++ b/extra/kdesdk-kate/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152474 2012-03-07 16:12:14Z andrea $
+# $Id: PKGBUILD 153072 2012-03-12 09:03:04Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgbase=kdesdk-kate
@@ -9,7 +9,7 @@ pkgrel=1
arch=('i686' 'x86_64')
license=('GPL' 'LGPL' 'FDL')
makedepends=('kdelibs ''cmake' 'automoc4')
-source=("http://download.kde.org/stable/${pkgver}/src/xz/kate-${pkgver}.tar.xz"
+source=("http://download.kde.org/stable/${pkgver}/src/kate-${pkgver}.tar.xz"
'pkgbuild-syntax-highlight.patch')
sha1sums=('d5bd513cd2bfefc2d345547115d0cb0a9d3e6143'
'0a928253bd2077f0264d96a6c8823c69c47b6a8d')
diff --git a/extra/kdesdk/PKGBUILD b/extra/kdesdk/PKGBUILD
index 08a3cb9cc..f207de92e 100644
--- a/extra/kdesdk/PKGBUILD
+++ b/extra/kdesdk/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152604 2012-03-07 16:17:09Z andrea $
+# $Id: PKGBUILD 153200 2012-03-12 09:39:38Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
# Contributor: Pierre Schmitz <pierre@archlinux.de>
@@ -30,7 +30,7 @@ license=('GPL' 'LGPL' 'FDL')
groups=('kde' 'kdesdk')
makedepends=('cmake' 'automoc4' 'boost' 'subversion' 'antlr2' 'kdepimlibs'
'kdebase-lib')
-source=("http://download.kde.org/stable/${pkgver}/src/xz/${pkgbase}-${pkgver}.tar.xz"
+source=("http://download.kde.org/stable/${pkgver}/src/${pkgbase}-${pkgver}.tar.xz"
'fix-python2-path.patch')
sha1sums=('5104445024047ae01099e7baa8e5b47a63b76198'
'923cabd7a877cf9a68efeb24fbf3d5827e1d949e')
diff --git a/extra/kdetoys/PKGBUILD b/extra/kdetoys/PKGBUILD
index ff1480eb4..f9938dd35 100644
--- a/extra/kdetoys/PKGBUILD
+++ b/extra/kdetoys/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152606 2012-03-07 16:17:12Z andrea $
+# $Id: PKGBUILD 153202 2012-03-12 09:40:10Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
# Contributor: Pierre Schmitz <pierre@archlinux.de>
@@ -13,7 +13,7 @@ url='http://www.kde.org'
license=('GPL' 'LGPL' 'FDL')
groups=('kde' 'kdetoys')
makedepends=('cmake' 'automoc4' 'kdebase-workspace')
-source=("http://download.kde.org/stable/${pkgver}/src/xz/${pkgbase}-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/${pkgbase}-${pkgver}.tar.xz")
sha1sums=('b0a1c26fa00795767c0d73ff3d25cc339cb005b8')
build() {
diff --git a/extra/kdeutils-filelight/PKGBUILD b/extra/kdeutils-filelight/PKGBUILD
index 337fa0593..de14f23f4 100644
--- a/extra/kdeutils-filelight/PKGBUILD
+++ b/extra/kdeutils-filelight/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152610 2012-03-07 16:17:18Z andrea $
+# $Id: PKGBUILD 153206 2012-03-12 09:41:09Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdeutils-filelight
@@ -14,7 +14,7 @@ groups=('kde' 'kdeutils')
replaces=('filelight')
conflicts=('filelight')
install=${pkgname}.install
-source=("http://download.kde.org/stable/${pkgver}/src/xz/filelight-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/filelight-${pkgver}.tar.xz")
sha1sums=('24cd19b927221de2dafd2a1c3d5e8a72a41ec4b5')
build() {
diff --git a/extra/kdeutils-kcalc/PKGBUILD b/extra/kdeutils-kcalc/PKGBUILD
index 0f20833a2..211c9736e 100644
--- a/extra/kdeutils-kcalc/PKGBUILD
+++ b/extra/kdeutils-kcalc/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152612 2012-03-07 16:17:20Z andrea $
+# $Id: PKGBUILD 153208 2012-03-12 09:41:38Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdeutils-kcalc
@@ -12,7 +12,7 @@ depends=('kdebase-runtime')
makedepends=('cmake' 'automoc4')
groups=('kde' 'kdeutils')
install=${pkgname}.install
-source=("http://download.kde.org/stable/${pkgver}/src/xz/kcalc-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/kcalc-${pkgver}.tar.xz")
sha1sums=('f119707ece800a2102eb881402a5bc289b2a55ea')
build() {
diff --git a/extra/kdeutils-kcharselect/PKGBUILD b/extra/kdeutils-kcharselect/PKGBUILD
index 5c95a44dd..534f25137 100644
--- a/extra/kdeutils-kcharselect/PKGBUILD
+++ b/extra/kdeutils-kcharselect/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152614 2012-03-07 16:17:23Z andrea $
+# $Id: PKGBUILD 153210 2012-03-12 09:42:11Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdeutils-kcharselect
@@ -11,7 +11,7 @@ license=('GPL' 'LGPL' 'FDL')
depends=('kdebase-runtime')
makedepends=('cmake' 'automoc4')
groups=('kde' 'kdeutils')
-source=("http://download.kde.org/stable/${pkgver}/src/xz/kcharselect-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/kcharselect-${pkgver}.tar.xz")
sha1sums=('06888b54f8c139966f327dd1955c25c967d437fb')
build() {
diff --git a/extra/kdeutils-kdf/PKGBUILD b/extra/kdeutils-kdf/PKGBUILD
index 317f9f41d..c588ec8e2 100644
--- a/extra/kdeutils-kdf/PKGBUILD
+++ b/extra/kdeutils-kdf/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152616 2012-03-07 16:17:25Z andrea $
+# $Id: PKGBUILD 153212 2012-03-12 09:42:40Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdeutils-kdf
@@ -12,7 +12,7 @@ depends=('kdebase-runtime')
makedepends=('cmake' 'automoc4')
groups=('kde' 'kdeutils')
install=${pkgname}.install
-source=("http://download.kde.org/stable/${pkgver}/src/xz/kdf-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/kdf-${pkgver}.tar.xz")
sha1sums=('fb28f99b23819f3618a8857affdaad1957f8bd68')
build() {
diff --git a/extra/kdeutils-kfloppy/PKGBUILD b/extra/kdeutils-kfloppy/PKGBUILD
index 0c5f26d1d..67710ea86 100644
--- a/extra/kdeutils-kfloppy/PKGBUILD
+++ b/extra/kdeutils-kfloppy/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152618 2012-03-07 16:17:28Z andrea $
+# $Id: PKGBUILD 153214 2012-03-12 09:43:11Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdeutils-kfloppy
@@ -12,7 +12,7 @@ depends=('kdebase-runtime')
makedepends=('cmake' 'automoc4')
groups=('kde' 'kdeutils')
install=${pkgname}.install
-source=("http://download.kde.org/stable/${pkgver}/src/xz/kfloppy-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/kfloppy-${pkgver}.tar.xz")
sha1sums=('78c5dfa1198d9c215ff2a22b82c4e3db2b7c0485')
build() {
diff --git a/extra/kdeutils-kgpg/PKGBUILD b/extra/kdeutils-kgpg/PKGBUILD
index 4f99c67ea..32a373d88 100644
--- a/extra/kdeutils-kgpg/PKGBUILD
+++ b/extra/kdeutils-kgpg/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152620 2012-03-07 16:17:30Z andrea $
+# $Id: PKGBUILD 153216 2012-03-12 09:43:41Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdeutils-kgpg
@@ -12,7 +12,7 @@ depends=('kdepim-runtime' 'kde-agent')
makedepends=('cmake' 'automoc4')
groups=('kde' 'kdeutils')
install=${pkgname}.install
-source=("http://download.kde.org/stable/${pkgver}/src/xz/kgpg-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/kgpg-${pkgver}.tar.xz")
sha1sums=('40f5bd3f2d4bfeed56e519194c41049e14899e36')
build() {
diff --git a/extra/kdeutils-kremotecontrol/PKGBUILD b/extra/kdeutils-kremotecontrol/PKGBUILD
index 2360606b4..965cf16eb 100644
--- a/extra/kdeutils-kremotecontrol/PKGBUILD
+++ b/extra/kdeutils-kremotecontrol/PKGBUILD
@@ -14,7 +14,7 @@ groups=('kde' 'kdeutils')
replaces=('kdeutils-kdelirc')
conflicts=('kdeutils-kdelirc')
install=${pkgname}.install
-source=("http://download.kde.org/stable/${pkgver}/src/xz/kremotecontrol-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/kremotecontrol-${pkgver}.tar.xz")
sha1sums=('684ad9b0393081a39b2c6badb2f411846e582bb2')
build() {
diff --git a/extra/kdeutils-ksecrets/PKGBUILD b/extra/kdeutils-ksecrets/PKGBUILD
index ed8bd60a2..78fad0deb 100644
--- a/extra/kdeutils-ksecrets/PKGBUILD
+++ b/extra/kdeutils-ksecrets/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152624 2012-03-07 16:17:35Z andrea $
+# $Id: PKGBUILD 153220 2012-03-12 09:44:43Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdeutils-ksecrets
@@ -12,7 +12,7 @@ depends=('kdebase-workspace' 'qca-ossl')
makedepends=('cmake' 'automoc4')
groups=('kde' 'kdeutils')
install=${pkgname}.install
-source=("http://download.kde.org/stable/${pkgver}/src/xz/ksecrets-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/ksecrets-${pkgver}.tar.xz")
sha1sums=('7ff7889da899dbac86ae63b0e25c2a8cde59fc32')
build() {
diff --git a/extra/kdeutils-ktimer/PKGBUILD b/extra/kdeutils-ktimer/PKGBUILD
index a4a20efc6..cbdaff575 100644
--- a/extra/kdeutils-ktimer/PKGBUILD
+++ b/extra/kdeutils-ktimer/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152626 2012-03-07 16:17:38Z andrea $
+# $Id: PKGBUILD 153222 2012-03-12 09:45:12Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdeutils-ktimer
@@ -12,7 +12,7 @@ depends=('kdebase-runtime')
makedepends=('cmake' 'automoc4')
groups=('kde' 'kdeutils')
install=${pkgname}.install
-source=("http://download.kde.org/stable/${pkgver}/src/xz/ktimer-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/ktimer-${pkgver}.tar.xz")
sha1sums=('c16ace45eefe9d495086a08fb1c0144baec9572f')
build() {
diff --git a/extra/kdeutils-kwallet/PKGBUILD b/extra/kdeutils-kwallet/PKGBUILD
index 7431d0af7..c4c370976 100644
--- a/extra/kdeutils-kwallet/PKGBUILD
+++ b/extra/kdeutils-kwallet/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152628 2012-03-07 16:17:41Z andrea $
+# $Id: PKGBUILD 153224 2012-03-12 09:45:42Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdeutils-kwallet
@@ -12,7 +12,7 @@ depends=('kdebase-runtime')
makedepends=('cmake' 'automoc4')
groups=('kde' 'kdeutils')
install=${pkgname}.install
-source=("http://download.kde.org/stable/${pkgver}/src/xz/kwallet-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/kwallet-${pkgver}.tar.xz")
sha1sums=('39c1d6720cd486e86179468b5606923bab73cb9e')
build() {
diff --git a/extra/kdeutils-printer-applet/PKGBUILD b/extra/kdeutils-printer-applet/PKGBUILD
index 844fa55cf..c80b49411 100644
--- a/extra/kdeutils-printer-applet/PKGBUILD
+++ b/extra/kdeutils-printer-applet/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152630 2012-03-07 16:17:43Z andrea $
+# $Id: PKGBUILD 153227 2012-03-12 09:46:15Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdeutils-printer-applet
@@ -12,7 +12,7 @@ license=('GPL' 'LGPL' 'FDL')
depends=('kdebase-runtime' 'kdebindings-python' 'system-config-printer-common')
makedepends=('cmake' 'automoc4')
groups=('kde' 'kdeutils')
-source=("http://download.kde.org/stable/${pkgver}/src/xz/printer-applet-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/printer-applet-${pkgver}.tar.xz")
sha1sums=('c3002fea0382386256c3acaebd907a41db0ccc4e')
build() {
diff --git a/extra/kdeutils-superkaramba/PKGBUILD b/extra/kdeutils-superkaramba/PKGBUILD
index 20f418fb5..251879e9d 100644
--- a/extra/kdeutils-superkaramba/PKGBUILD
+++ b/extra/kdeutils-superkaramba/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152632 2012-03-07 16:17:46Z andrea $
+# $Id: PKGBUILD 153229 2012-03-12 09:46:45Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdeutils-superkaramba
@@ -12,7 +12,7 @@ depends=('kdebase-runtime' 'qimageblitz')
makedepends=('cmake' 'automoc4')
groups=('kde' 'kdeutils')
install=${pkgname}.install
-source=("http://download.kde.org/stable/${pkgver}/src/xz/superkaramba-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/superkaramba-${pkgver}.tar.xz")
sha1sums=('934a62e3d82e92a99b9d070a2dd39634b7351cea')
build() {
diff --git a/extra/kdeutils-sweeper/PKGBUILD b/extra/kdeutils-sweeper/PKGBUILD
index eb24923da..1d6f068a1 100644
--- a/extra/kdeutils-sweeper/PKGBUILD
+++ b/extra/kdeutils-sweeper/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152634 2012-03-07 16:17:48Z andrea $
+# $Id: PKGBUILD 153231 2012-03-12 09:47:17Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=kdeutils-sweeper
@@ -12,7 +12,7 @@ license=('GPL' 'LGPL' 'FDL')
depends=('kdebase-runtime')
makedepends=('cmake' 'automoc4')
groups=('kde' 'kdeutils')
-source=("http://download.kde.org/stable/${pkgver}/src/xz/sweeper-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/sweeper-${pkgver}.tar.xz")
sha1sums=('7a11a22397bbe5106118ed94942f27f546fad80b')
build() {
diff --git a/extra/kdewebdev/PKGBUILD b/extra/kdewebdev/PKGBUILD
index b00c0a02c..0eec1a823 100644
--- a/extra/kdewebdev/PKGBUILD
+++ b/extra/kdewebdev/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152636 2012-03-07 16:17:51Z andrea $
+# $Id: PKGBUILD 153233 2012-03-12 09:47:53Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
# Contributor: Pierre Schmitz <pierre@archlinux.de>
@@ -14,7 +14,7 @@ url='http://www.kde.org'
license=('GPL' 'LGPL' 'FDL')
groups=('kde' 'kdewebdev')
makedepends=('cmake' 'automoc4' 'ruby' 'tidyhtml' 'kdepim-runtime' 'boost')
-source=("http://download.kde.org/stable/${pkgver}/src/xz/${pkgbase}-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/${pkgbase}-${pkgver}.tar.xz")
sha1sums=('c707886d79d9ba150c408326efccf24847d5dc38')
build() {
diff --git a/extra/libkdcraw/PKGBUILD b/extra/libkdcraw/PKGBUILD
index c36b9864c..007ec0f38 100644
--- a/extra/libkdcraw/PKGBUILD
+++ b/extra/libkdcraw/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152496 2012-03-07 16:13:01Z andrea $
+# $Id: PKGBUILD 153094 2012-03-12 09:09:38Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=libkdcraw
@@ -13,7 +13,7 @@ makedepends=('cmake' 'automoc4')
replaces=('kdegraphics-libs')
conflicts=('kdegraphics-libs')
install=${pkgname}.install
-source=("http://download.kde.org/stable/${pkgver}/src/xz/${pkgname}-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/${pkgname}-${pkgver}.tar.xz")
sha1sums=('80dd47457b9803240a3002ef42d96e201d9face8')
build() {
diff --git a/extra/libkdeedu/PKGBUILD b/extra/libkdeedu/PKGBUILD
index 084ff7430..a9939d35b 100644
--- a/extra/libkdeedu/PKGBUILD
+++ b/extra/libkdeedu/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152492 2012-03-07 16:12:51Z andrea $
+# $Id: PKGBUILD 153090 2012-03-12 09:08:39Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=libkdeedu
@@ -12,7 +12,7 @@ depends=('kdelibs')
makedepends=('cmake' 'automoc4')
install=${pkgname}.install
replaces=('kdeedu-libkdeedu' 'kdeedu-data')
-source=("http://download.kde.org/stable/${pkgver}/src/xz/${pkgname}-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/${pkgname}-${pkgver}.tar.xz")
sha1sums=('ab9ed54dcb99f7cfe98623aa47434841f372a5a7')
build() {
diff --git a/extra/libkexiv2/PKGBUILD b/extra/libkexiv2/PKGBUILD
index 8e98c7dd2..9229bf059 100644
--- a/extra/libkexiv2/PKGBUILD
+++ b/extra/libkexiv2/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152498 2012-03-07 16:13:04Z andrea $
+# $Id: PKGBUILD 153096 2012-03-12 09:10:12Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=libkexiv2
@@ -12,7 +12,7 @@ depends=('kdelibs')
makedepends=('cmake' 'automoc4')
replaces=('kdegraphics-libs')
conflicts=('kdegraphics-libs')
-source=("http://download.kde.org/stable/${pkgver}/src/xz/${pkgname}-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/${pkgname}-${pkgver}.tar.xz")
sha1sums=('273d76f2414c2dc442ab8f9dc72578977aba0f0c')
build() {
diff --git a/extra/libkipi/PKGBUILD b/extra/libkipi/PKGBUILD
index d4332a378..53dfafca9 100644
--- a/extra/libkipi/PKGBUILD
+++ b/extra/libkipi/PKGBUILD
@@ -13,7 +13,7 @@ makedepends=('cmake' 'automoc4')
replaces=('kdegraphics-libs')
conflicts=('kdegraphics-libs')
install=${pkgname}.install
-source=("http://download.kde.org/stable/${pkgver}/src/xz/${pkgname}-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/${pkgname}-${pkgver}.tar.xz")
sha1sums=('bc290e3354c206d7852433aac704fc96b3a55700')
build() {
diff --git a/extra/libksane/PKGBUILD b/extra/libksane/PKGBUILD
index 422b55b51..e894f474d 100644
--- a/extra/libksane/PKGBUILD
+++ b/extra/libksane/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 152502 2012-03-07 16:13:11Z andrea $
+# $Id: PKGBUILD 153100 2012-03-12 09:11:12Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=libksane
@@ -13,7 +13,7 @@ makedepends=('cmake' 'automoc4')
replaces=('kdegraphics-libs')
conflicts=('kdegraphics-libs')
install=${pkgname}.install
-source=("http://download.kde.org/stable/${pkgver}/src/xz/${pkgname}-${pkgver}.tar.xz")
+source=("http://download.kde.org/stable/${pkgver}/src/${pkgname}-${pkgver}.tar.xz")
sha1sums=('20631624185f8bf26d7a8c2e7222731513e8a2ec')
build() {
diff --git a/extra/libmpdclient/PKGBUILD b/extra/libmpdclient/PKGBUILD
index 277358431..91f6eb78e 100644
--- a/extra/libmpdclient/PKGBUILD
+++ b/extra/libmpdclient/PKGBUILD
@@ -1,9 +1,9 @@
-# $Id: PKGBUILD 141673 2011-11-02 05:35:47Z bisson $
+# $Id: PKGBUILD 153242 2012-03-12 13:45:57Z bisson $
# Contributor: Andrea Scarpino <andrea@archlinux.org>
# Maintainer: Gaetan Bisson <bisson@archlinux.org>
pkgname=libmpdclient
-pkgver=2.6
+pkgver=2.7
pkgrel=1
pkgdesc='Asynchronous API library for interfacing MPD in the C, C++ & Objective C languages'
url='http://mpd.wikia.com/wiki/ClientLib:libmpdclient'
@@ -11,7 +11,7 @@ license=('custom:BSD')
arch=('i686' 'x86_64')
options=('!libtool')
source=("http://downloads.sourceforge.net/project/musicpd/${pkgname}/${pkgver}/${pkgname}-${pkgver}.tar.gz")
-sha1sums=('39bdcf5399fb98e34b8b6110057b64f4d1945333')
+sha1sums=('f97e35525851eb192d3799f0dabe32915c56b96b')
build() {
cd "${srcdir}/${pkgname}-${pkgver}"
diff --git a/extra/libpciaccess/PKGBUILD b/extra/libpciaccess/PKGBUILD
index 8302ea92a..3d396d2bb 100644
--- a/extra/libpciaccess/PKGBUILD
+++ b/extra/libpciaccess/PKGBUILD
@@ -1,8 +1,9 @@
# $Id: PKGBUILD 356 2008-04-18 22:56:27Z aaron $
# Maintainer: Jan de Groot <jgc@archlinux.org>
# Contributor: Alexander Baldeck <alexander@archlinux.org>
+
pkgname=libpciaccess
-pkgver=0.12.1
+pkgver=0.13
pkgrel=1
pkgdesc="X11 PCI access library"
arch=(i686 x86_64)
@@ -12,12 +13,15 @@ depends=('glibc')
makedepends=('pkgconfig' 'xorg-util-macros')
options=('!libtool')
source=(${url}/releases/individual/lib/${pkgname}-${pkgver}.tar.bz2)
-sha1sums=('4933bda545df37395e57ff6b4bd61e17a5431770')
+sha1sums=('7ddd8e1de27326f6f4a3ac6b4d2241fe77ef5353')
build() {
cd "${srcdir}/${pkgname}-${pkgver}"
./configure --prefix=/usr --sysconfdir=/etc
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/extra/libx11/PKGBUILD b/extra/libx11/PKGBUILD
index da81d3904..fc3fd1d0b 100644
--- a/extra/libx11/PKGBUILD
+++ b/extra/libx11/PKGBUILD
@@ -1,8 +1,8 @@
-# $Id: PKGBUILD 134215 2011-08-02 15:15:42Z jgc $
+# $Id: PKGBUILD 153292 2012-03-12 20:52:22Z andyrtr $
# Maintainer: Jan de Groot <jgc@archlinux.org>
pkgname=libx11
-pkgver=1.4.4
+pkgver=1.4.99.1
pkgrel=1
pkgdesc="X11 client-side library"
arch=(i686 x86_64)
@@ -14,7 +14,7 @@ license=('custom')
source=(${url}/releases/individual/lib/libX11-${pkgver}.tar.bz2
xorg.sh
xorg.csh)
-sha1sums=('2d9d38bfd7003ec60eea0b1999ab72cfd5fa3b90'
+sha1sums=('317e0112926926a52c13f56f71c1ec9e4540cf4d '
'4b756387426afb2a5bb7a155631ec42348abf5c1'
'45b0b310776cf5d9a94b4a18a5c63ddad9de6ba8')
@@ -22,6 +22,10 @@ build() {
cd "${srcdir}/libX11-${pkgver}"
./configure --prefix=/usr --disable-static --disable-xf86bigfont
make
+}
+
+package() {
+ cd "${srcdir}/libX11-${pkgver}"
make check
}
diff --git a/extra/libxcb/PKGBUILD b/extra/libxcb/PKGBUILD
index 31a5183f5..2bbe1b908 100644
--- a/extra/libxcb/PKGBUILD
+++ b/extra/libxcb/PKGBUILD
@@ -1,36 +1,32 @@
-# $Id: PKGBUILD 122471 2011-05-04 08:36:03Z jgc $
+# $Id: PKGBUILD 153294 2012-03-12 20:52:27Z andyrtr $
# Maintainer: Jan de Groot <jgc@archlinux.org>
# Contributor: Alexander Baldeck <alexander@archlinux.org>
pkgname=libxcb
-pkgver=1.7
-pkgrel=2
+pkgver=1.8.1
+pkgrel=1
pkgdesc="X11 client-side library"
arch=(i686 x86_64)
url="http://xcb.freedesktop.org/"
-depends=('xcb-proto>=1.6' 'libxdmcp' 'libxau')
+depends=('xcb-proto>=1.7' 'libxdmcp' 'libxau')
makedepends=('pkgconfig' 'libxslt' 'python2')
-conflicts=('libx11<1.1.99.2')
options=('!libtool')
license=('custom')
-source=(${url}/dist/${pkgname}-${pkgver}.tar.bz2
- xcb_auth-fix-memory-leak.patch
+source=($url/dist/$pkgname-$pkgver.tar.bz2
libxcb-1.1-no-pthread-stubs.patch)
-sha1sums=('7540f0587907bce421914f0ddb813810cb2f36f8'
- '0c9246fd2ea270bfa06cb8ef93df2f8227d83c2a'
- '3455e84642283bc91c8313af319002a20bbcbdf4')
+sha1sums=('98199b6054750a06cddd4e77baa4354af547ce6f'
+ 'd2df03ddf3e949c10c2c185256b0eb7fa02837ab')
build() {
- cd "${srcdir}/${pkgname}-${pkgver}"
- patch -Np1 -i "${srcdir}/libxcb-1.1-no-pthread-stubs.patch"
- patch -Np1 -i "${srcdir}/xcb_auth-fix-memory-leak.patch"
- libtoolize --force --copy
- aclocal
- autoconf
- automake --add-missing
- PYTHON=python2 ./configure --prefix=/usr --enable-xinput
+ cd "$srcdir/$pkgname-$pkgver"
+ patch -Np1 -i "$srcdir/libxcb-1.1-no-pthread-stubs.patch"
+ PYTHON=/usr/bin/python2 ./autogen.sh --prefix=/usr --enable-xinput
make
- make DESTDIR="${pkgdir}" install
- install -m755 -d "${pkgdir}/usr/share/licenses/${pkgname}"
- install -m644 COPYING "${pkgdir}/usr/share/licenses/${pkgname}/"
+}
+
+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/extra/libxcb/libxcb-1.1-no-pthread-stubs.patch b/extra/libxcb/libxcb-1.1-no-pthread-stubs.patch
index f17de1b1d..8e8162f0a 100644
--- a/extra/libxcb/libxcb-1.1-no-pthread-stubs.patch
+++ b/extra/libxcb/libxcb-1.1-no-pthread-stubs.patch
@@ -1,10 +1,9 @@
-diff -up libxcb-1.1/configure.ac.pthread-stubs libxcb-1.1/configure.ac
---- libxcb-1.1/configure.ac.pthread-stubs 2007-11-04 18:17:11.000000000 -0500
-+++ libxcb-1.1/configure.ac 2007-11-12 10:27:06.000000000 -0500
-@@ -31,7 +31,7 @@ AC_SUBST(HTML_CHECK_RESULT)
+--- libxcb-1.8.1/configure.ac 2012-03-09 15:38:38.000000000 +0100
++++ libxcb-1.8.1/configure.ac.new 2012-03-09 16:50:40.107109896 +0100
+@@ -35,7 +35,7 @@
# Checks for pkg-config packages
- PKG_CHECK_MODULES(XCBPROTO, xcb-proto >= 1.6)
+ PKG_CHECK_MODULES(XCBPROTO, xcb-proto >= 1.7)
-NEEDED="pthread-stubs xau >= 0.99.2"
+NEEDED="xau >= 0.99.2"
PKG_CHECK_MODULES(NEEDED, $NEEDED)
diff --git a/extra/libxft/PKGBUILD b/extra/libxft/PKGBUILD
index 709f6b6e9..e15cb95bc 100644
--- a/extra/libxft/PKGBUILD
+++ b/extra/libxft/PKGBUILD
@@ -1,9 +1,9 @@
-# $Id: PKGBUILD 152776 2012-03-09 16:13:37Z andyrtr $
+# $Id: PKGBUILD 153277 2012-03-12 20:25:11Z andyrtr $
# Maintainer: Jan de Groot <jgc@archlinux.org>
pkgname=libxft
pkgver=2.3.0
-pkgrel=1
+pkgrel=2
pkgdesc="FreeType-based font drawing library for X"
arch=('i686' 'x86_64')
license=('custom')
@@ -11,11 +11,15 @@ url="http://xorg.freedesktop.org/"
depends=('fontconfig' 'libxrender')
makedepends=('pkgconfig')
options=('!libtool')
-source=("${url}/releases/individual/lib/libXft-${pkgver}.tar.bz2")
-sha1sums=('687f38a810b9ae58e1169c295d9d438370235e23')
+source=("${url}/releases/individual/lib/libXft-${pkgver}.tar.bz2"
+ git_fixes.diff)
+sha1sums=('687f38a810b9ae58e1169c295d9d438370235e23'
+ 'a87a56f62905bfcd85469caf349d07f37f84a989')
build() {
cd "${srcdir}/libXft-${pkgver}"
+ # fix broken bold fonts in urxvt terinals - https://bugs.freedesktop.org/show_bug.cgi?id=47178 + https://bugs.freedesktop.org/show_bug.cgi?id=47196
+ patch -Np1 -i ${srcdir}/git_fixes.diff
./configure --prefix=/usr --sysconfdir=/etc --disable-static
make
}
diff --git a/extra/libxft/git_fixes.diff b/extra/libxft/git_fixes.diff
new file mode 100644
index 000000000..3a7155271
--- /dev/null
+++ b/extra/libxft/git_fixes.diff
@@ -0,0 +1,43 @@
+From 84b8b5b46773f9b686d57f28092824b86bffed9d Mon Sep 17 00:00:00 2001
+From: Mikael Magnusson <mikachu@gmail.com>
+Date: Sun, 11 Mar 2012 01:41:55 +0000
+Subject: Fixup for 550b2f76401c2 which broke bold fonts
+
+The commit removed the line
+AC_CHECK_FUNCS(FT_Get_Next_Char FT_Get_BDF_Property FT_Get_PS_Font_Info FT_Has_PS_Glyph_Names FT_GlyphSlot_Embolden)
+but failed to remove the #if lines that this commit removes, resulting
+in that code never being executed.
+
+Fixes: https://bugs.freedesktop.org/attachment.cgi?id=58280
+
+Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
+---
+diff --git a/src/xftglyphs.c b/src/xftglyphs.c
+index 4a3b9d6..2f3dc5a 100644
+--- a/src/xftglyphs.c
++++ b/src/xftglyphs.c
+@@ -24,9 +24,7 @@
+ #include <freetype/ftoutln.h>
+ #include <freetype/ftlcdfil.h>
+
+-#if HAVE_FT_GLYPHSLOT_EMBOLDEN
+ #include <freetype/ftsynth.h>
+-#endif
+
+ /*
+ * Validate the memory info for a font
+@@ -434,12 +432,10 @@ XftFontLoadGlyphs (Display *dpy,
+
+ glyphslot = face->glyph;
+
+-#if HAVE_FT_GLYPHSLOT_EMBOLDEN
+ /*
+ * Embolden if required
+ */
+ if (font->info.embolden) FT_GlyphSlot_Embolden(glyphslot);
+-#endif
+
+ /*
+ * Compute glyph metrics from FreeType information
+--
+cgit v0.9.0.2-2-gbebe
diff --git a/extra/libxi/PKGBUILD b/extra/libxi/PKGBUILD
index b195dfce8..e242b28ab 100644
--- a/extra/libxi/PKGBUILD
+++ b/extra/libxi/PKGBUILD
@@ -1,8 +1,8 @@
-# $Id: PKGBUILD 145628 2011-12-24 14:44:56Z andyrtr $
+# $Id: PKGBUILD 153296 2012-03-12 20:52:30Z andyrtr $
# Maintainer: Jan de Groot <jgc@archlinux.org>
pkgname=libxi
-pkgver=1.4.5
+pkgver=1.6.0
pkgrel=1
pkgdesc="X11 Input extension library"
arch=('i686' 'x86_64')
@@ -12,7 +12,7 @@ makedepends=('pkgconfig' 'xorg-util-macros')
options=(!libtool)
license=('custom')
source=(${url}/releases/individual/lib/libXi-${pkgver}.tar.bz2)
-sha1sums=('8ac24dec8e488f49fd6a6b256c815da9ceec9737')
+sha1sums=('b7edf48f93e8abd13ca688fa7f597452c4b74346')
build() {
cd "${srcdir}/libXi-${pkgver}"
diff --git a/extra/libxt/PKGBUILD b/extra/libxt/PKGBUILD
index 264f85673..21c48820f 100644
--- a/extra/libxt/PKGBUILD
+++ b/extra/libxt/PKGBUILD
@@ -1,9 +1,9 @@
-# $Id: PKGBUILD 152767 2012-03-09 16:01:47Z andyrtr $
+# $Id: PKGBUILD 153273 2012-03-12 20:17:00Z andyrtr $
#Maintainer: Jan de Groot <jgc@archlinux.org>
pkgname=libxt
pkgver=1.1.2
-pkgrel=1
+pkgrel=2
pkgdesc="X11 toolkit intrinsics library"
arch=('i686' 'x86_64')
url="http://xorg.freedesktop.org/"
@@ -11,11 +11,15 @@ license=('custom')
depends=('libsm' 'libx11')
makedepends=('xorg-util-macros')
options=('!libtool')
-source=("${url}/releases/individual/lib/libXt-${pkgver}.tar.bz2")
-sha1sums=('9e84b807419d78bda4acbd7aea05aed2ab0556cf')
+source=("${url}/releases/individual/lib/libXt-${pkgver}.tar.bz2"
+ Revert_treat_unexpected_returned_events_from_poll_as_errors.diff)
+sha1sums=('9e84b807419d78bda4acbd7aea05aed2ab0556cf'
+ 'bebadf4b90f6a49530b5600a12a9385253e0daa6')
build() {
cd "${srcdir}/libXt-${pkgver}"
+ # revert broken commit, see https://bugs.archlinux.org/task/28844 + https://bugs.archlinux.org/task/28875 + https://bugs.freedesktop.org/show_bug.cgi?id=47203
+ patch -Np1 -R -i ${srcdir}/Revert_treat_unexpected_returned_events_from_poll_as_errors.diff
./configure --prefix=/usr --sysconfdir=/etc --disable-static
make
}
diff --git a/extra/libxt/Revert_treat_unexpected_returned_events_from_poll_as_errors.diff b/extra/libxt/Revert_treat_unexpected_returned_events_from_poll_as_errors.diff
new file mode 100644
index 000000000..b3f708292
--- /dev/null
+++ b/extra/libxt/Revert_treat_unexpected_returned_events_from_poll_as_errors.diff
@@ -0,0 +1,40 @@
+From 70bb9e28d37fff4ead4d0a2c672af77059765fa4 Mon Sep 17 00:00:00 2001
+From: Jeremy Huddleston <jeremyhu@apple.com>
+Date: Wed, 04 Jan 2012 18:33:29 +0000
+Subject: Treat unexpected returned events from poll as errors
+
+Inspired by libxcb's f0565e8f06aadf760a9065a97b8cf5ab9cbd18de
+
+Resolves https://bugs.freedesktop.org/show_bug.cgi?id=20048
+
+Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
+---
+diff --git a/src/NextEvent.c b/src/NextEvent.c
+index b1f7bc7..c8c9dd5 100644
+--- a/src/NextEvent.c
++++ b/src/NextEvent.c
+@@ -356,7 +356,21 @@ static int IoWait (
+ return Select (wf->nfds, &wf->rmask, &wf->wmask, &wf->emask,
+ wt->wait_time_ptr);
+ #else
+- return poll (wf->fdlist, wf->fdlistlen, wt->poll_wait);
++ int ret = poll (wf->fdlist, wf->fdlistlen, wt->poll_wait);
++ /* If poll() returns an event we didn't expect, such as POLLNVAL, treat
++ * it as if it failed. */
++ if(ret >= 0) {
++ nfds_t i;
++ for (i=0; i < wf->fdlistlen; i++) {
++ struct pollfd *fd = &wf->fdlist[i];
++ if (fd->revents & ~fd->events) {
++ ret = -1;
++ errno = EIO;
++ break;
++ }
++ }
++ }
++ return ret;
+ #endif
+ }
+
+--
+cgit v0.9.0.2-2-gbebe
diff --git a/extra/mesa/PKGBUILD b/extra/mesa/PKGBUILD
index e1f0df20b..5528b2dd5 100644
--- a/extra/mesa/PKGBUILD
+++ b/extra/mesa/PKGBUILD
@@ -1,25 +1,23 @@
-# $Id: PKGBUILD 143633 2011-11-27 22:29:58Z andyrtr $
+# $Id: PKGBUILD 153288 2012-03-12 20:52:15Z andyrtr $
# Maintainer: Jan de Groot <jgc@archlinux.org>
# Maintainer: Andreas Radke <andyrtr@archlinux.org>
pkgbase=mesa
-pkgname=('mesa' 'libgl' 'libglapi' 'libgles' 'libegl' 'khrplatform-devel' 'ati-dri' 'intel-dri' 'unichrome-dri' 'mach64-dri' 'mga-dri' 'r128-dri' 'savage-dri' 'sis-dri' 'tdfx-dri' 'nouveau-dri') # 'llvm-dri')
-# prepare 7.12/8.0
-#pkgname=('mesa' 'libgl' 'libglapi' 'libgles' 'libegl' 'ati-dri' 'intel-dri' 'nouveau-dri') # 'llvm-dri')
+pkgname=('mesa' 'libgl' 'osmesa' 'libglapi' '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
+ pkgver=7.10.99.git20110709
+ #pkgver=7.11
else
- pkgver=7.11.2
+ pkgver=8.0.1
fi
-pkgrel=1
+pkgrel=2
arch=('i686' 'x86_64')
-makedepends=('glproto>=1.4.14' 'libdrm>=2.4.26' 'libxxf86vm>=1.1.1' 'libxdamage>=1.1.3' 'expat>=2.0.1' 'libx11>=1.4.3' 'libxt>=1.1.1'
+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')
url="http://mesa3d.sourceforge.net"
license=('custom')
@@ -30,11 +28,12 @@ if [ "${_git}" = "true" ]; then
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'
- '0837c52698fe3252369c3fdb5195afcc')
+ '24eeebf66971809d8f40775a379b36c9')
build() {
cd ${srcdir}/?esa-*
@@ -43,17 +42,18 @@ if [ "${_git}" = "true" ]; then
autoreconf -vfi
./autogen.sh --prefix=/usr \
--with-dri-driverdir=/usr/lib/xorg/modules/dri \
- --with-gallium-drivers=r300,r600,nouveau,swrast \
+ --with-gallium-drivers=r300,r600,nouveau,svga,swrast \
--enable-gallium-llvm \
--enable-gallium-egl --enable-shared-glapi\
--enable-glx-tls \
- --with-driver=dri \
- --enable-xcb \
- --disable-glut \
+ --enable-dri \
+ --enable-glx \
+ --enable-osmesa \
--enable-gles1 \
--enable-gles2 \
--enable-egl \
--enable-texture-float \
+ --enable-xa \
--enable-shared-dricore
# --enable-gallium-svga \
@@ -62,17 +62,18 @@ if [ "${_git}" = "true" ]; then
autoreconf -vfi
./configure --prefix=/usr \
--with-dri-driverdir=/usr/lib/xorg/modules/dri \
- --with-gallium-drivers=r300,r600,nouveau,swrast \
+ --with-gallium-drivers=r300,r600,nouveau,svga,swrast \
--enable-gallium-llvm \
--enable-gallium-egl --enable-shared-glapi\
--enable-glx-tls \
- --with-driver=dri \
- --enable-xcb \
- --disable-glut \
+ --enable-dri \
+ --enable-glx \
+ --enable-osmesa \
--enable-gles1 \
--enable-gles2 \
--enable-egl \
--enable-texture-float \
+ --enable-xa \
--enable-shared-dricore
fi
@@ -80,8 +81,9 @@ fi
}
package_libgl() {
- depends=('libdrm>=2.4.26' 'libxxf86vm>=1.1.1' 'libxdamage>=1.1.3' 'expat>=2.0.1' 'libglapi' 'gcc-libs')
+ 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"
@@ -94,13 +96,20 @@ package_libgl() {
cd src/mesa/drivers/dri
make -C ${srcdir}/?esa-*/src/gallium/targets/dri-swrast DESTDIR="${pkgdir}" install
- ln -s swrastg_dri.so "${pkgdir}/usr/lib/xorg/modules/dri/swrast_dri.so"
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"
@@ -160,7 +169,7 @@ package_libegl() {
}
package_khrplatform-devel() {
- depends=('')
+ #depends=('')
pkgdesc="Khronos platform development package"
cd ${srcdir}/?esa-*
@@ -184,7 +193,8 @@ package_mesa() {
rm -f "${pkgdir}/usr/lib/libGLESv"*
rm -f "${pkgdir}/usr/lib/libEGL"*
rm -rf "${pkgdir}/usr/lib/egl"
- rm -f ${pkgdir}/usr/lib/pkgconfig/{glesv1_cm.pc,glesv2.pc,egl.pc}
+ rm -f "${pkgdir}/usr/lib/libOSMesa"*
+ rm -f ${pkgdir}/usr/lib/pkgconfig/{glesv1_cm.pc,glesv2.pc,egl.pc,osmesa.pc}
rm -rf "${pkgdir}/usr/lib/xorg"
rm -f "${pkgdir}/usr/include/GL/glew.h"
rm -f "${pkgdir}/usr/include/GL/glxew.h"
@@ -213,66 +223,10 @@ package_intel-dri() {
depends=("libgl=${pkgver}")
pkgdesc="Mesa DRI drivers for Intel"
- make -C ${srcdir}/?esa-*/src/mesa/drivers/dri/i810 DESTDIR="${pkgdir}" install # dead in 7.12
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_unichrome-dri() {
- depends=("libgl=${pkgver}")
- pkgdesc="Mesa DRI drivers for S3 Graphics/VIA Unichrome"
-
- make -C ${srcdir}/?esa-*/src/mesa/drivers/dri/unichrome DESTDIR="${pkgdir}" install
-}
-
-package_mach64-dri() {
- depends=("libgl=${pkgver}")
- pkgdesc="Mesa DRI drivers for ATI Mach64"
- conflicts=('xf86-video-mach64<6.8.2')
-
- make -C ${srcdir}/?esa-*/src/mesa/drivers/dri/mach64 DESTDIR="${pkgdir}" install
-}
-
-package_mga-dri() {
- depends=("libgl=${pkgver}")
- pkgdesc="Mesa DRI drivers for Matrox"
- conflicts=('xf86-video-mga<1.4.11')
-
- make -C ${srcdir}/?esa-*/src/mesa/drivers/dri/mga DESTDIR="${pkgdir}" install
-}
-
-package_r128-dri() {
- depends=("libgl=${pkgver}")
- pkgdesc="Mesa DRI drivers for ATI Rage128"
- conflicts=('xf86-video-r128<6.8.1')
-
- make -C ${srcdir}/?esa-*/src/mesa/drivers/dri/r128 DESTDIR="${pkgdir}" install
-}
-
-package_savage-dri() {
- depends=("libgl=${pkgver}")
- pkgdesc="Mesa DRI drivers for S3 Sraphics/VIA Savage"
- conflicts=('xf86-video-savage<2.3.1')
-
- make -C ${srcdir}/?esa-*/src/mesa/drivers/dri/savage DESTDIR="${pkgdir}" install
-}
-
-package_sis-dri() {
- depends=("libgl=${pkgver}")
- pkgdesc="Mesa DRI drivers for SiS"
- conflicts=('xf86-video-sis<0.10.2')
-
- make -C ${srcdir}/?esa-*/src/mesa/drivers/dri/sis DESTDIR="${pkgdir}" install
-}
-
-package_tdfx-dri() {
- depends=("libgl=${pkgver}")
- pkgdesc="Mesa DRI drivers for 3dfx"
- conflicts=('xf86-video-tdfx<1.4.3')
-
- make -C ${srcdir}/?esa-*/src/mesa/drivers/dri/tdfx DESTDIR="${pkgdir}" install
-}
-
package_nouveau-dri() {
depends=("libgl=${pkgver}")
pkgdesc="Mesa classic DRI + Gallium3D drivers for Nouveau"
@@ -283,21 +237,9 @@ package_nouveau-dri() {
make -C ${srcdir}/?esa-*/src/gallium/targets/dri-nouveau DESTDIR="${pkgdir}" install
}
-#package_llvm-dri() {
-# depends=("libgl=${pkgver}")
-# pkgdesc="Mesa common LLVM support"
-
-#if [ "${_git}" = "true" ]; then
-# cd ${srcdir}/mesa-*/src/gallium
-# else
-# cd "${srcdir}/Mesa-${pkgver}/src/gallium"
-#fi
-
- # gallium llvmpipe
-#if [ "${_git}" = "true" ]; then
-# make -C drivers/llvmpipe DESTDIR="${pkgdir}" install
-# #make -C targets/dri-swrast DESTDIR="${pkgdir}" install
-# else
-# make -C ${srcdir}/Mesa-${pkgver}/src/gallium/targets/dri-nouveau DESTDIR="${pkgdir}" install
-#fi
-#}
+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/extra/mpc/PKGBUILD b/extra/mpc/PKGBUILD
index 65575e75a..ad489d325 100644
--- a/extra/mpc/PKGBUILD
+++ b/extra/mpc/PKGBUILD
@@ -1,30 +1,30 @@
-# $Id: PKGBUILD 132481 2011-07-24 21:57:50Z angvp $
-# Maintainer: Angel Velasquez <angvp@archlinux.org>
+# $Id: PKGBUILD 153244 2012-03-12 13:46:46Z bisson $
+# Maintainer: Gaetan Bisson <bisson@archlinux.org>
+# Contributor: Angel Velasquez <angvp@archlinux.org>
# Contributor: Andrea Scarpino <andrea@archlinux.org>
# Contributor: Alexander Fehr <pizzapunk gmail com>
# Contributor: Link Dupont <link@subpop.net>
pkgname=mpc
-pkgver=0.21
+pkgver=0.22
pkgrel=1
-pkgdesc="Minimalist command line interface to MPD"
-arch=('i686' 'x86_64')
-url="http://mpd.wikia.com/wiki/Client:Mpc"
+pkgdesc='Minimalist command line interface to MPD'
+url='http://mpd.wikia.com/wiki/Client:Mpc'
license=('GPL2')
-depends=('libmpdclient')
+arch=('i686' 'x86_64')
options=('!emptydirs')
-source=(http://downloads.sourceforge.net/musicpd/${pkgname}-$pkgver.tar.bz2)
-md5sums=('d8f88aad5fa7ed4c6e7005c5ec1ba7c5')
+depends=('libmpdclient')
+source=("http://downloads.sourceforge.net/musicpd/${pkgname}-${pkgver}.tar.gz")
+sha1sums=('e35414c1f5b25f4e500ceae125adb5bb9063b029')
build() {
- cd "$srcdir/$pkgname-$pkgver"
- ./configure --prefix=/usr
- make
+ cd "${srcdir}/${pkgname}-${pkgver}"
+ ./configure --prefix=/usr
+ make
}
package() {
- cd "$srcdir/$pkgname-$pkgver"
- make DESTDIR="$pkgdir" install
- # Install bash completion file
- install -D -m644 doc/mpc-completion.bash "$pkgdir/etc/bash_completion.d/mpc"
+ cd "${srcdir}/${pkgname}-${pkgver}"
+ make DESTDIR="${pkgdir}" install
+ install -Dm644 doc/mpc-completion.bash "${pkgdir}/etc/bash_completion.d/mpc"
}
diff --git a/extra/oxygen-gtk2/PKGBUILD b/extra/oxygen-gtk2/PKGBUILD
index c7886480a..4173fb9d6 100644
--- a/extra/oxygen-gtk2/PKGBUILD
+++ b/extra/oxygen-gtk2/PKGBUILD
@@ -1,9 +1,9 @@
-# $Id: PKGBUILD 150269 2012-02-16 07:56:45Z andrea $
+# $Id: PKGBUILD 153265 2012-03-12 17:50:21Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
# Contributor: birdflesh <antkoul at gmail dot com>
pkgname=oxygen-gtk2
-pkgver=1.2.1
+pkgver=1.2.2
pkgrel=1
pkgdesc="Port of the default KDE widget theme (Oxygen) to GTK2"
arch=('i686' 'x86_64')
@@ -14,7 +14,7 @@ conflicts=('oxygen-gtk')
replaces=('oxygen-gtk')
makedepends=('cmake')
source=("http://download.kde.org/stable/${pkgname}/${pkgver}/src/${pkgname}-${pkgver}.tar.bz2")
-md5sums=('4a0a98a3499a9357d0f83191b48900ad')
+md5sums=('88cc3da77fec3802564b6d16b4268300')
build() {
cd "${srcdir}"
diff --git a/extra/oxygen-gtk3/PKGBUILD b/extra/oxygen-gtk3/PKGBUILD
index 4788efdfc..5e8587085 100644
--- a/extra/oxygen-gtk3/PKGBUILD
+++ b/extra/oxygen-gtk3/PKGBUILD
@@ -1,8 +1,8 @@
-# $Id: PKGBUILD 150271 2012-02-16 07:57:57Z andrea $
+# $Id: PKGBUILD 153267 2012-03-12 17:51:08Z andrea $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
pkgname=oxygen-gtk3
-pkgver=1.0.1
+pkgver=1.0.2
pkgrel=1
pkgdesc="Port of the default KDE widget theme (Oxygen) to GTK3"
arch=('i686' 'x86_64')
@@ -11,7 +11,7 @@ license=('LGPL')
depends=('gtk3' 'dbus-glib')
makedepends=('cmake')
source=("http://download.kde.org/stable/${pkgname}/${pkgver}/src/${pkgname}-${pkgver}.tar.bz2")
-md5sums=('5ecdac1dca4307d369b04db9a9e4e3af')
+md5sums=('3e884df6afe8a549063748ff12b5065c')
build() {
cd "${srcdir}"
diff --git a/extra/poppler/PKGBUILD b/extra/poppler/PKGBUILD
index 5a79cd246..f8fa182f3 100644
--- a/extra/poppler/PKGBUILD
+++ b/extra/poppler/PKGBUILD
@@ -1,10 +1,10 @@
-# $Id: PKGBUILD 148882 2012-02-05 11:54:01Z ibiru $
+# $Id: PKGBUILD 153271 2012-03-12 19:10:06Z jgc $
# Maintainer: Jan de Groot <jgc@archlinux.org>
pkgbase=poppler
pkgname=('poppler' 'poppler-glib' 'poppler-qt')
-pkgver=0.18.3
-pkgrel=2
+pkgver=0.18.4
+pkgrel=1
arch=(i686 x86_64)
license=('GPL')
makedepends=('libjpeg' 'gcc-libs' 'cairo' 'fontconfig' 'openjpeg' 'gtk2' 'qt' 'pkgconfig' 'lcms' 'gobject-introspection')
@@ -12,16 +12,13 @@ options=('!libtool' '!emptydirs')
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
- git-fixes.patch)
-md5sums=('d70d2d63d8acd29c97185f7e5f09c9b4'
- '9dc64c254a31e570507bdd4ad4ba629a'
- 'af56b7b1b24a08f7498a0c7f5e862b93')
+ http://cgit.freedesktop.org/poppler/test/snapshot/test-${_testtag}.tar.bz2)
+md5sums=('12658f3308597e57f3faff538cc73baf'
+ '9dc64c254a31e570507bdd4ad4ba629a')
build() {
cd "${srcdir}/${pkgbase}-${pkgver}"
sed -i -e '/AC_PATH_XTRA/d' configure.ac
- #patch -Np1 -i "${srcdir}/git-fixes.patch"
autoreconf -fi
diff --git a/extra/ruby/PKGBUILD b/extra/ruby/PKGBUILD
index 8ceaba4b4..5abe3aa7a 100644
--- a/extra/ruby/PKGBUILD
+++ b/extra/ruby/PKGBUILD
@@ -5,7 +5,7 @@
pkgname=ruby
pkgver=1.9.3_p125
-pkgrel=1
+pkgrel=2
pkgdesc='An object-oriented language for quick and easy programming'
arch=('i686' 'x86_64')
url='http://www.ruby-lang.org/en/'
@@ -21,7 +21,7 @@ options=('!emptydirs' '!makeflags')
install='ruby.install'
source=("ftp://ftp.ruby-lang.org/pub/ruby/${pkgver%.*}/ruby-${pkgver//_/-}.tar.bz2"
'gemrc')
-md5sums=('341b8fc42aa18bd668314199f219db14'
+md5sums=('702529a7f8417ed79f628b77d8061aa5'
'6fb8e7a09955e0f64be3158fb4a27e7a')
build() {
diff --git a/extra/smb4k/PKGBUILD b/extra/smb4k/PKGBUILD
index 7f7f32897..09fcb9679 100644
--- a/extra/smb4k/PKGBUILD
+++ b/extra/smb4k/PKGBUILD
@@ -1,9 +1,9 @@
-# $Id: PKGBUILD 148642 2012-02-04 23:32:14Z giovanni $
+# $Id: PKGBUILD 153239 2012-03-12 11:49:26Z giovanni $
# Maintainer: Giovanni Scafora <giovanni@archlinux.org>
# Contributor: Emanuele Rampichini <emanuele.rampichini@gmail.com>
pkgname=smb4k
-pkgver=1.0.0
+pkgver=1.0.1
pkgrel=1
pkgdesc="A KDE program that browses samba shares"
arch=('i686' 'x86_64')
@@ -13,7 +13,7 @@ depends=('kdebase-runtime')
makedepends=('cmake' 'automoc4' 'docbook-xsl')
install=smb4k.install
source=("http://downloads.sourceforge.net/project/${pkgname}/Smb4K%20%28stable%20releases%29/${pkgver}/${pkgname}-${pkgver}.tar.bz2")
-md5sums=('d00b71aac63aa9c68e68e5980c07a01b')
+md5sums=('c4b515e482ef7a7a834a3b660e1ee4d0')
build() {
cd "${srcdir}/${pkgname}-${pkgver}"
diff --git a/extra/thunar/PKGBUILD b/extra/thunar/PKGBUILD
index 000a5136e..04f37604d 100644
--- a/extra/thunar/PKGBUILD
+++ b/extra/thunar/PKGBUILD
@@ -1,10 +1,10 @@
-# $Id: PKGBUILD 149974 2012-02-11 23:31:34Z allan $
+# $Id: PKGBUILD 153248 2012-03-12 14:40:08Z tpowa $
# Maintainer: Evangelos Foutras <evangelos@foutrelis.com>
# Contributor: Andrew Simmons <andrew.simmons@gmail.com>
pkgname=thunar
pkgver=1.2.3
-pkgrel=4
+pkgrel=5
pkgdesc="Modern file manager for Xfce"
arch=('i686' 'x86_64')
url="http://thunar.xfce.org"
@@ -22,12 +22,24 @@ 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.2/Thunar-$pkgver.tar.bz2)
-sha256sums=('e66aa9ad61a9202e15cc7c5fffc7b961da9ab3b4428f874c1ec8e46eb4ffaca6')
+source=(http://archive.xfce.org/src/xfce/${pkgname}/1.2/Thunar-$pkgver.tar.bz2
+ fix-segfault-on-rename.patch
+ fix-sorting-of-large-numbers-5356.patch
+ fix-launching-multiple-files-7456.patch
+ fix-crash-8168.patch)
+md5sums=('0a2c36cdd3cb3a2ab52cbf6055415b85'
+ '07e568a84f3a24e32d9d37803a250099'
+ '926dbefb639c429c8acf064922b4fbe0'
+ '7ef67fa9faa414ba03053dc69f4cdebc'
+ '54a88687621bcbd5ab7d951a952d3558')
build() {
cd "$srcdir/Thunar-$pkgver"
-
+ # add fixes from git tree
+ patch -Np1 -i ../fix-sorting-of-large-numbers-5356.patch
+ patch -Np1 -i ../fix-launching-multiple-files-7456.patch
+ patch -Np1 -i ../fix-crash-8168.patch
+ patch -Np1 -i ../fix-segfault-on-rename.patch
./configure --prefix=/usr \
--sysconfdir=/etc \
--libexecdir=/usr/lib \
diff --git a/extra/thunar/fix-crash-8168.patch b/extra/thunar/fix-crash-8168.patch
new file mode 100644
index 000000000..4300c81c6
--- /dev/null
+++ b/extra/thunar/fix-crash-8168.patch
@@ -0,0 +1,32 @@
+From 71f6f207cfd0194a3f3db83cb5fab694a5036e22 Mon Sep 17 00:00:00 2001
+From: Jannis Pohlmann <jannis@xfce.org>
+Date: Sun, 26 Feb 2012 17:38:50 +0000
+Subject: Fix crash when removing an ancestor of the current folder (bug #8168).
+
+Whenever we release the GFileMonitor of a ThunarFolder, we also need to
+disconnect from its signals. Otherwise one of the signal handlers might
+still be called, potentially with corrupted user data (which was the
+case here).
+---
+diff --git a/thunar/thunar-folder.c b/thunar/thunar-folder.c
+index 62015fe..4076b8d 100644
+--- a/thunar/thunar-folder.c
++++ b/thunar/thunar-folder.c
+@@ -236,6 +236,7 @@ thunar_folder_finalize (GObject *object)
+ /* disconnect from the file alteration monitor */
+ if (G_LIKELY (folder->monitor != NULL))
+ {
++ g_signal_handlers_disconnect_matched (folder->monitor, G_SIGNAL_MATCH_DATA, 0, 0, NULL, NULL, folder);
+ g_file_monitor_cancel (folder->monitor);
+ g_object_unref (folder->monitor);
+ }
+@@ -705,6 +706,7 @@ thunar_folder_reload (ThunarFolder *folder)
+ /* disconnect from the file alteration monitor */
+ if (G_UNLIKELY (folder->monitor != NULL))
+ {
++ g_signal_handlers_disconnect_matched (folder->monitor, G_SIGNAL_MATCH_DATA, 0, 0, NULL, NULL, folder);
+ g_file_monitor_cancel (folder->monitor);
+ g_object_unref (folder->monitor);
+ folder->monitor = NULL;
+--
+cgit v0.9.0.2
diff --git a/extra/thunar/fix-launching-multiple-files-7456.patch b/extra/thunar/fix-launching-multiple-files-7456.patch
new file mode 100644
index 000000000..40d581553
--- /dev/null
+++ b/extra/thunar/fix-launching-multiple-files-7456.patch
@@ -0,0 +1,53 @@
+From 379b8b9f350cb362735eb0e2a0e9471a898f2664 Mon Sep 17 00:00:00 2001
+From: John Lindgren <john.lindgren@aol.com>
+Date: Sun, 26 Feb 2012 18:52:24 +0000
+Subject: Fix handling %U when launching multiple files with an app (bug #7456).
+
+GIO returns a newly allocated GAppInfo every time
+g_app_info_get_default_for_type() is called. This means that if we use a
+GHashTable and g_direct_hash() to associate GAppInfos with files to be
+launched with each of them, we will actually end up with multiple
+GAppInfos that are the same, and each of them will only have a single
+file associated.
+
+To fix this, we now use a fake hash function that causes GHashTable to
+always search the GAppInfo in the collision list.
+---
+diff --git a/thunar/thunar-launcher.c b/thunar/thunar-launcher.c
+index f479cf9..9f96b87 100644
+--- a/thunar/thunar-launcher.c
++++ b/thunar/thunar-launcher.c
+@@ -546,17 +546,28 @@ thunar_launcher_execute_files (ThunarLauncher *launcher,
+
+
+
++static guint
++thunar_launcher_g_app_info_hash (gconstpointer app_info)
++{
++ return 0;
++}
++
++
++
+ static void
+ thunar_launcher_open_files (ThunarLauncher *launcher,
+ GList *files)
+ {
+- GAppInfo *app_info;
+ GHashTable *applications;
++ GAppInfo *app_info;
+ GList *file_list;
+ GList *lp;
+
+- /* allocate a hash table to associate applications to URIs */
+- applications = g_hash_table_new_full (g_direct_hash,
++ /* allocate a hash table to associate applications to URIs. since GIO allocates
++ * new GAppInfo objects every time, g_direct_hash does not work. we therefor use
++ * a fake hash function to always hit the collision list of the hash table and
++ * avoid storing multiple equal GAppInfos by means of g_app_info_equal(). */
++ applications = g_hash_table_new_full (thunar_launcher_g_app_info_hash,
+ (GEqualFunc) g_app_info_equal,
+ (GDestroyNotify) g_object_unref,
+ (GDestroyNotify) thunar_g_file_list_free);
+--
+cgit v0.9.0.2
diff --git a/extra/thunar/fix-segfault-on-rename.patch b/extra/thunar/fix-segfault-on-rename.patch
new file mode 100644
index 000000000..b64a91e08
--- /dev/null
+++ b/extra/thunar/fix-segfault-on-rename.patch
@@ -0,0 +1,27 @@
+From fb7e7a602473fe2f11c78baacacaad1aea8c9dc6 Mon Sep 17 00:00:00 2001
+From: Nick Schermer <nick@xfce.org>
+Date: Wed, 30 Nov 2011 17:45:57 +0000
+Subject: Fix segfault when plugin returns a NULL suffix.
+
+(cherry picked from commit 6f813ba48553e5b95a83bfa8463b20b8ee4607c4)
+---
+diff --git a/thunar/thunar-renamer-model.c b/thunar/thunar-renamer-model.c
+index 1aa7b77..91a47e1 100644
+--- a/thunar/thunar-renamer-model.c
++++ b/thunar/thunar-renamer-model.c
+@@ -823,10 +823,9 @@ thunar_renamer_model_process_item (ThunarRenamerModel *renamer_model,
+ /* determine the new suffix */
+ suffix = thunarx_renamer_process (renamer_model->renamer, THUNARX_FILE_INFO (item->file), dot + 1, idx);
+
+- /* generate the new file name */
+- name = g_new (gchar, (dot - display_name) + 1 + strlen (suffix) + 1);
+- memcpy (name, display_name, (dot - display_name) + 1);
+- memcpy (name + (dot - display_name) + 1, suffix, strlen (suffix) + 1);
++ prefix = g_strndup (display_name, (dot - display_name) + 1);
++ name = g_strconcat (prefix, suffix, NULL);
++ g_free (prefix);
+
+ /* release the suffix */
+ g_free (suffix);
+--
+cgit v0.9.0.2
diff --git a/extra/thunar/fix-sorting-of-large-numbers-5356.patch b/extra/thunar/fix-sorting-of-large-numbers-5356.patch
new file mode 100644
index 000000000..1105eea83
--- /dev/null
+++ b/extra/thunar/fix-sorting-of-large-numbers-5356.patch
@@ -0,0 +1,32 @@
+From 493db02bdbc6ec667cd04e75a77dff8366ec1bc0 Mon Sep 17 00:00:00 2001
+From: Eric Koegel <eric.koegel@gmail.com>
+Date: Sun, 06 Nov 2011 13:58:33 +0000
+Subject: Fix sorting of filenames with large numbers (bug #5356).
+
+Change compare_by_name_using_number() to use guint64.
+
+Signed-off-by: Jannis Pohlmann <jannis@xfce.org>
+---
+diff --git a/thunar/thunar-file.c b/thunar/thunar-file.c
+index 909da25..44cdb31 100644
+--- a/thunar/thunar-file.c
++++ b/thunar/thunar-file.c
+@@ -3168,12 +3168,12 @@ static gint
+ compare_by_name_using_number (const gchar *ap,
+ const gchar *bp)
+ {
+- guint anum;
+- guint bnum;
++ guint64 anum;
++ guint64 bnum;
+
+ /* determine the numbers in ap and bp */
+- anum = strtoul (ap, NULL, 10);
+- bnum = strtoul (bp, NULL, 10);
++ anum = strtouq (ap, NULL, 10);
++ bnum = strtouq (bp, NULL, 10);
+
+ /* compare the numbers */
+ if (anum < bnum)
+--
+cgit v0.9.0.2
diff --git a/extra/xf86-input-acecad/PKGBUILD b/extra/xf86-input-acecad/PKGBUILD
index 49eb109fe..dad6302b5 100644
--- a/extra/xf86-input-acecad/PKGBUILD
+++ b/extra/xf86-input-acecad/PKGBUILD
@@ -1,16 +1,16 @@
-# $Id: PKGBUILD 140352 2011-10-11 21:29:41Z jgc $
+# $Id: PKGBUILD 153299 2012-03-12 20:52:33Z andyrtr $
# Maintainer: Jan de Groot <jgc@archlinux.org>
pkgname=xf86-input-acecad
pkgver=1.5.0
-pkgrel=2
+pkgrel=3
pkgdesc="X.Org acecad tablet input driver"
arch=(i686 x86_64)
url="http://xorg.freedesktop.org/"
license=('custom')
depends=('sysfsutils')
-makedepends=('xorg-server-devel>=1.10.99.902')
-conflicts=('xorg-server<1.10.99.902')
+makedepends=('xorg-server-devel>=1.11.99.902')
+conflicts=('xorg-server<1.11.99.902')
options=('!libtool')
groups=('xorg-drivers' 'xorg')
source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2
diff --git a/extra/xf86-input-aiptek/PKGBUILD b/extra/xf86-input-aiptek/PKGBUILD
index dd0075860..615b04a5e 100644
--- a/extra/xf86-input-aiptek/PKGBUILD
+++ b/extra/xf86-input-aiptek/PKGBUILD
@@ -1,16 +1,16 @@
-# $Id: PKGBUILD 140354 2011-10-11 21:29:43Z jgc $
+# $Id: PKGBUILD 153301 2012-03-12 20:52:36Z andyrtr $
#Maintainer: Jan de Groot <jgc@archlinux.org>
pkgname=xf86-input-aiptek
pkgver=1.4.1
-pkgrel=2
+pkgrel=3
pkgdesc="X.Org Aiptek USB Digital Tablet input driver"
arch=(i686 x86_64)
url="http://xorg.freedesktop.org/"
license=('custom')
depends=('glibc')
-makedepends=('pkgconfig' 'xorg-server-devel>=1.10.99.902')
-conflicts=('xorg-server<1.10.99.902')
+makedepends=('pkgconfig' 'xorg-server-devel>=1.11.99.902')
+conflicts=('xorg-server<1.11.99.902')
options=('!libtool')
groups=('xorg-drivers' 'xorg')
source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2)
diff --git a/extra/xf86-input-evdev/PKGBUILD b/extra/xf86-input-evdev/PKGBUILD
index 47296c598..a0299099f 100644
--- a/extra/xf86-input-evdev/PKGBUILD
+++ b/extra/xf86-input-evdev/PKGBUILD
@@ -1,21 +1,21 @@
-# $Id: PKGBUILD 140356 2011-10-11 21:29:45Z jgc $
+# $Id: PKGBUILD 153303 2012-03-12 20:52:38Z andyrtr $
# Maintainer: Jan de Groot <jgc@archlinux.org>
# Contributor: Alexander Baldeck <Alexander@archlinux.org
pkgname=xf86-input-evdev
-pkgver=2.6.0
-pkgrel=4
+pkgver=2.7.0
+pkgrel=1
pkgdesc="X.org evdev input driver"
arch=(i686 x86_64)
url="http://xorg.freedesktop.org/"
license=('custom')
depends=('glibc')
-makedepends=('xorg-server-devel>=1.10.99.902')
-conflicts=('xorg-server<1.10.99.902')
+makedepends=('xorg-server-devel>=1.11.99.902')
+conflicts=('xorg-server<1.11.99.902')
options=('!libtool' '!makeflags')
groups=('xorg-drivers' 'xorg')
source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2)
-sha1sums=('fb6f7a6f5168ae07efe890e4ace9fb8af1d4e1e0')
+sha1sums=('f0cb2d8400c33e8e83b538b53512e77ba73367fa')
build() {
cd "${srcdir}/${pkgname}-${pkgver}"
diff --git a/extra/xf86-input-joystick/PKGBUILD b/extra/xf86-input-joystick/PKGBUILD
index 7badf2933..27e57bdde 100644
--- a/extra/xf86-input-joystick/PKGBUILD
+++ b/extra/xf86-input-joystick/PKGBUILD
@@ -1,28 +1,27 @@
-# $Id: PKGBUILD 142923 2011-11-18 09:36:49Z jgc $
+# $Id: PKGBUILD 153305 2012-03-12 20:52:42Z andyrtr $
# Maintainer: Jan de Groot <jgc@archlinux.org>
pkgname=xf86-input-joystick
-pkgver=1.6.0
-pkgrel=3
+pkgver=1.6.1
+pkgrel=1
pkgdesc="X.Org Joystick input driver"
arch=(i686 x86_64)
url="http://xorg.freedesktop.org/"
license=('custom')
depends=('glibc')
-makedepends=('xorg-server-devel>=1.11.0')
-conflicts=('xorg-server<1.11.0')
+makedepends=('xorg-server-devel>=1.11.99.902')
+conflicts=('xorg-server<1.11.99.902')
groups=('xorg-drivers' 'xorg')
options=('!libtool')
source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2
- git-fixes.patch
+ #git-fixes.patch
50-joystick.conf)
-sha1sums=('3b9aed1b8128e1fbd947fdcdd5e16efccad1c780'
- '7812a34013a2333641bd7c5d044c46179490cb32'
+sha1sums=('0712652ec6cdb2fca6ad888548b232a4de9cf580'
'e1ff3699a0470c6bb78a53f718df9d8521621e11')
build() {
cd "${srcdir}/${pkgname}-${pkgver}"
- patch -Np1 -i "${srcdir}/git-fixes.patch"
+ #patch -Np1 -i "${srcdir}/git-fixes.patch"
./configure --prefix=/usr
make
}
diff --git a/extra/xf86-input-keyboard/PKGBUILD b/extra/xf86-input-keyboard/PKGBUILD
index 41a732f15..a84212019 100644
--- a/extra/xf86-input-keyboard/PKGBUILD
+++ b/extra/xf86-input-keyboard/PKGBUILD
@@ -1,16 +1,16 @@
-# $Id: PKGBUILD 148598 2012-02-04 10:16:48Z andyrtr $
+# $Id: PKGBUILD 153307 2012-03-12 20:52:44Z andyrtr $
# Maintainer: Jan de Groot <jgc@archlinux.org>
pkgname=xf86-input-keyboard
pkgver=1.6.1
-pkgrel=1
+pkgrel=2
pkgdesc="X.Org keyboard input driver"
arch=(i686 x86_64)
license=('custom')
url="http://xorg.freedesktop.org/"
depends=('glibc')
-makedepends=('xorg-server-devel>=1.10.99.902')
-conflicts=('xorg-server<1.10.99.902')
+makedepends=('xorg-server-devel>=1.11.99.902')
+conflicts=('xorg-server<1.11.99.902')
options=('!libtool')
groups=('xorg-drivers' 'xorg')
source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2)
diff --git a/extra/xf86-input-mouse/PKGBUILD b/extra/xf86-input-mouse/PKGBUILD
index 56f28ff52..f7f68e5f9 100644
--- a/extra/xf86-input-mouse/PKGBUILD
+++ b/extra/xf86-input-mouse/PKGBUILD
@@ -1,16 +1,16 @@
-# $Id: PKGBUILD 140362 2011-10-11 21:29:54Z jgc $
+# $Id: PKGBUILD 153309 2012-03-12 20:52:47Z andyrtr $
# Maintainer: Jan de Groot <jgc@archlinux.org>
pkgname=xf86-input-mouse
pkgver=1.7.1
-pkgrel=2
+pkgrel=3
pkgdesc="X.org mouse input driver"
arch=(i686 x86_64)
license=('custom')
url="http://xorg.freedesktop.org/"
depends=('glibc')
-makedepends=('xorg-server-devel>=1.10.99.902')
-conflicts=('xorg-server<1.10.99.902')
+makedepends=('xorg-server-devel>=1.11.99.902')
+conflicts=('xorg-server<1.11.99.902')
options=('!libtool')
groups=('xorg-drivers' 'xorg')
source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2)
diff --git a/extra/xf86-input-synaptics/PKGBUILD b/extra/xf86-input-synaptics/PKGBUILD
index 327a31176..a3da84b14 100644
--- a/extra/xf86-input-synaptics/PKGBUILD
+++ b/extra/xf86-input-synaptics/PKGBUILD
@@ -1,38 +1,43 @@
-# $Id: PKGBUILD 140364 2011-10-11 21:29:57Z jgc $
+# $Id: PKGBUILD 153311 2012-03-12 20:52:51Z andyrtr $
# Maintainer: Jan de Groot <jgc@archlinux.org>
# Contributor: Tobias Powalowski <tpowa@archlinux.org>
# Contributor: Thomas Bächler <thomas@archlinux.org>
# Contributor: Alexander Baldeck <alexander@archlinux.org>
pkgname=xf86-input-synaptics
-pkgver=1.5.0
-pkgrel=1
+pkgver=1.5.99
+pkgrel=0.2
+_gitver=dfc3a8ed713c2878407c6443c4d3092da3125e0c
pkgdesc="Synaptics driver for notebook touchpads"
arch=('i686' 'x86_64')
license=('custom')
url="http://xorg.freedesktop.org/"
depends=('libxtst')
-makedepends=('xorg-server-devel>=1.10.99.902' 'libxi' 'libx11')
-conflicts=('xorg-server<1.10.99.902')
+makedepends=('xorg-server-devel>=1.11.99.902' 'libxi' 'libx11')
+conflicts=('xorg-server<1.11.99.902')
replaces=('synaptics')
provides=('synaptics')
conflicts=('synaptics')
groups=('xorg-drivers' 'xorg')
options=(!libtool)
backup=('etc/X11/xorg.conf.d/10-synaptics.conf')
-source=(http://xorg.freedesktop.org/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2
+source=(#http://xorg.freedesktop.org/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2
+ http://cgit.freedesktop.org/xorg/driver/xf86-input-synaptics/snapshot/xf86-input-synaptics-${_gitver}.tar.gz
10-synaptics.conf)
-sha1sums=('7373c1e3f02bf7e18f71b65762a982d907b4a053'
- '68e1f4ef5e1038231d210eb422fa4d18c5922f0f')
+md5sums=('5e21cc5c7f61802ac340968caf9db7de'
+ '3b81a81b958dfe3cac3cdef7ee85f1ce')
build() {
- cd "${srcdir}/${pkgname}-${pkgver}"
+# cd "${srcdir}/${pkgname}-${pkgver}"
+ cd ${srcdir}/${pkgname}*
+ autoreconf -fi
./configure --prefix=/usr
make
}
package() {
- cd "${srcdir}/${pkgname}-${pkgver}"
+ #cd "${srcdir}/${pkgname}-${pkgver}"
+ cd ${srcdir}/${pkgname}*
make DESTDIR="${pkgdir}" install
install -m755 -d "${pkgdir}/etc/X11/xorg.conf.d"
install -m644 "${srcdir}/10-synaptics.conf" "${pkgdir}/etc/X11/xorg.conf.d/"
diff --git a/extra/xf86-input-void/PKGBUILD b/extra/xf86-input-void/PKGBUILD
index 312657dc5..4ab21391f 100644
--- a/extra/xf86-input-void/PKGBUILD
+++ b/extra/xf86-input-void/PKGBUILD
@@ -1,16 +1,16 @@
-# $Id: PKGBUILD 140368 2011-10-11 21:30:01Z jgc $
+# $Id: PKGBUILD 153315 2012-03-12 20:53:00Z andyrtr $
#Maintainer: Jan de Groot <jgc@archlinux.org>
pkgname=xf86-input-void
pkgver=1.4.0
-pkgrel=2
+pkgrel=3
pkgdesc="X.org void input driver"
arch=(i686 x86_64)
license=('custom')
url="http://xorg.freedesktop.org/"
depends=('glibc')
-makedepends=('xorg-server-devel>=1.10.99.902')
-conflicts=('xorg-server<1.10.99.902')
+makedepends=('xorg-server-devel>=1.11.99.902')
+conflicts=('xorg-server<1.11.99.902')
groups=('xorg-drivers' 'xorg')
options=('!libtool')
source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2)
diff --git a/extra/xf86-input-wacom/PKGBUILD b/extra/xf86-input-wacom/PKGBUILD
index 559e63924..fcf0ea299 100644
--- a/extra/xf86-input-wacom/PKGBUILD
+++ b/extra/xf86-input-wacom/PKGBUILD
@@ -1,10 +1,10 @@
-# $Id: PKGBUILD 146763 2012-01-17 05:32:23Z heftig $
+# $Id: PKGBUILD 153317 2012-03-12 20:53:04Z andyrtr $
# Maintainer: Jan Alexander Steffens (heftig) <jan.steffens@gmail.com>
# Contributor: Jan de Groot <jgc@archlinux.org>
# Contributor: M Rawash <mrawash@gmail.com>
pkgname=xf86-input-wacom
-pkgver=0.13.0
+pkgver=0.14.0
pkgrel=1
pkgdesc="X.Org Wacom tablet driver"
arch=('i686' 'x86_64')
@@ -12,12 +12,12 @@ url="http://linuxwacom.sourceforge.net/"
license=('GPL')
backup=('etc/X11/xorg.conf.d/50-wacom.conf')
depends=('libxi' 'libxrandr' 'libxinerama')
-makedepends=('xorg-server-devel>=1.11.0' 'libxext')
-conflicts=('xorg-server<1.11.0')
+makedepends=('xorg-server-devel>=1.12.0' 'libxext')
+conflicts=('xorg-server<1.12.0')
options=(!libtool)
source=(http://downloads.sourceforge.net/project/linuxwacom/${pkgname}/${pkgname}-${pkgver}.tar.bz2
70-wacom.rules)
-md5sums=('4a426535989e84c4161e3607ea851654'
+md5sums=('23d19a2b50a86b848df17297c745144f'
'10db4f8272286690255c1bcc18bfdd92')
build() {
diff --git a/extra/xf86-video-apm/PKGBUILD b/extra/xf86-video-apm/PKGBUILD
index c15e421d8..3cf6acff0 100644
--- a/extra/xf86-video-apm/PKGBUILD
+++ b/extra/xf86-video-apm/PKGBUILD
@@ -1,25 +1,32 @@
-# $Id: PKGBUILD 140350 2011-10-11 21:29:39Z jgc $
+# $Id: PKGBUILD 153319 2012-03-12 20:53:08Z andyrtr $
# Maintainer: Jan de Groot <jgc@archlinux.org>
pkgname=xf86-video-apm
pkgver=1.2.3
-pkgrel=4
+pkgrel=5
pkgdesc="X.org Alliance ProMotion video driver"
arch=(i686 x86_64)
url="http://xorg.freedesktop.org/"
license=('custom')
depends=('glibc')
-makedepends=('xorg-server-devel>=1.11.0')
-conflicts=('xorg-server<1.11.0')
+makedepends=('xorg-server-devel>=1.11.99.902')
+conflicts=('xorg-server<1.11.99.902')
groups=('xorg-drivers' 'xorg')
options=('!libtool')
-source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2)
-sha1sums=('1fa7180cf985a74132f8d5b39a0bf9df08713fac')
+source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2
+ apm-1.2.3-git.patch)
+sha1sums=('1fa7180cf985a74132f8d5b39a0bf9df08713fac'
+ 'ad9468519eb959bb879ba4e4993d6a83848d5c6f')
build() {
cd "${srcdir}/${pkgname}-${pkgver}"
+ patch -Np1 -i ${srcdir}/apm-1.2.3-git.patch
./configure --prefix=/usr
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/extra/xf86-video-apm/apm-1.2.3-git.patch b/extra/xf86-video-apm/apm-1.2.3-git.patch
new file mode 100644
index 000000000..1c6afb29d
--- /dev/null
+++ b/extra/xf86-video-apm/apm-1.2.3-git.patch
@@ -0,0 +1,34 @@
+diff --git a/src/apm.h b/src/apm.h
+index bc66714..86c7663 100644
+--- a/src/apm.h
++++ b/src/apm.h
+@@ -109,7 +109,7 @@ typedef struct {
+ char *MemMap;
+ pointer BltMap;
+ Bool UnlockCalled;
+- IOADDRESS iobase, xport, xbase;
++ unsigned long iobase, xport, xbase;
+ unsigned char savedSR10;
+ CARD8 MiscOut;
+ CARD8 c9, d9, db, Rush;
+diff --git a/src/apm_driver.c b/src/apm_driver.c
+index f172bab..f77bb2b 100644
+--- a/src/apm_driver.c
++++ b/src/apm_driver.c
+@@ -418,8 +418,14 @@ ApmPreInit(ScrnInfoPtr pScrn, int flags)
+
+ hwp = VGAHWPTR(pScrn);
+ vgaHWGetIOBase(hwp);
+- pApm->iobase = hwp->PIOOffset;
+- pApm->xport = hwp->PIOOffset + 0x3C4;
++#if ABI_VIDEODRV_VERSION < 12
++#define PIOOFFSET hwp->PIOOffset
++#else
++/* FIXME reintroduce domain support */
++#define PIOOFFSET 0
++#endif
++ pApm->iobase = PIOOFFSET;
++ pApm->xport = PIOOFFSET + 0x3C4;
+
+ /* Set pScrn->monitor */
+ pScrn->monitor = pScrn->confScreen->monitor;
diff --git a/extra/xf86-video-ark/PKGBUILD b/extra/xf86-video-ark/PKGBUILD
index 9f07d6a0c..ac5b44dff 100644
--- a/extra/xf86-video-ark/PKGBUILD
+++ b/extra/xf86-video-ark/PKGBUILD
@@ -1,28 +1,32 @@
-# $Id: PKGBUILD 140348 2011-10-11 21:29:38Z jgc $
+# $Id: PKGBUILD 153321 2012-03-12 20:53:11Z andyrtr $
# Maintainer: Jan de Groot <jgc@archlinux.org>
pkgname=xf86-video-ark
-pkgver=0.7.3
-pkgrel=4
+pkgver=0.7.4
+pkgrel=1
pkgdesc="X.org ark video driver"
arch=(i686 x86_64)
url="http://xorg.freedesktop.org/"
license=('custom')
depends=('glibc')
-makedepends=('xorg-server-devel>=1.11.0')
-conflicts=('xorg-server<1.11.0')
+makedepends=('xorg-server-devel>=1.11.99.902')
+conflicts=('xorg-server<1.11.99.902')
options=('!libtool')
groups=('xorg-drivers' 'xorg')
source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2
- git-fixes.patch)
-sha1sums=('56901ec6097a83433689f208268281f9c98c238b'
- 'f62cdc7995e9b64c9105382ccfa842732fa81309')
+ #git-fixes.patch
+ )
+sha1sums=('d95cb9aa56e7db542b3ac8fed9cb519b11f77556')
build() {
cd "${srcdir}/${pkgname}-${pkgver}"
- patch -Np1 -i "${srcdir}/git-fixes.patch"
+ #patch -Np1 -i "${srcdir}/git-fixes.patch"
./configure --prefix=/usr
make
+}
+
+package() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
make DESTDIR="${pkgdir}" install
install -m755 -d "${pkgdir}/usr/share/licenses/${pkgname}"
diff --git a/extra/xf86-video-ast/PKGBUILD b/extra/xf86-video-ast/PKGBUILD
index a51fd704b..20537ce70 100644
--- a/extra/xf86-video-ast/PKGBUILD
+++ b/extra/xf86-video-ast/PKGBUILD
@@ -1,25 +1,32 @@
-# $Id: PKGBUILD 140346 2011-10-11 21:29:36Z jgc $
+# $Id: PKGBUILD 153323 2012-03-12 20:53:14Z andyrtr $
# Maintainer: Jan de Groot <jgc@archlinux.org>
pkgname=xf86-video-ast
pkgver=0.93.9
-pkgrel=1
+pkgrel=2
pkgdesc="X.org ASPEED AST Graphics video driver"
arch=(i686 x86_64)
url="http://xorg.freedesktop.org/"
license=('custom')
depends=('glibc')
-makedepends=('xorg-server-devel>=1.11.0')
-conflicts=('xorg-server<1.11.0')
+makedepends=('xorg-server-devel>=1.11.99.902')
+conflicts=('xorg-server<1.11.99.902')
options=('!libtool')
groups=('xorg-drivers' 'xorg')
-source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2)
-sha1sums=('424cc93d0300e49a882199c0546425f223b3b4bd')
+source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2
+ ast-0.93.9-vga.patch)
+md5sums=('e25c6a55e9d07cc6054d6affc1231296'
+ '9aa9ea4c568b6563389fa634cb0f7cf0')
build() {
cd "${srcdir}/${pkgname}-${pkgver}"
+ patch -Np1 -i ${srcdir}/ast-0.93.9-vga.patch
./configure --prefix=/usr
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/extra/xf86-video-ast/ast-0.93.9-vga.patch b/extra/xf86-video-ast/ast-0.93.9-vga.patch
new file mode 100644
index 000000000..e05a78f56
--- /dev/null
+++ b/extra/xf86-video-ast/ast-0.93.9-vga.patch
@@ -0,0 +1,38 @@
+From 4a7eda24050b42072c77d527257609e743e8dc78 Mon Sep 17 00:00:00 2001
+From: Adam Jackson <ajax@redhat.com>
+Date: Wed, 16 Nov 2011 20:09:40 +0000
+Subject: Adapt to domain changes in videoabi 12
+
+This is a blind change, I don't have this hardware handy to test with.
+It probably wants the same new API that tdfx wants.
+
+Signed-off-by: Adam Jackson <ajax@redhat.com>
+---
+diff --git a/src/ast_driver.c b/src/ast_driver.c
+index bd3d338..128538f 100644
+--- a/src/ast_driver.c
++++ b/src/ast_driver.c
+@@ -498,11 +498,20 @@ ASTPreInit(ScrnInfoPtr pScrn, int flags)
+ (pScrn->chipset != NULL) ? pScrn->chipset : "Unknown ast");
+
+ /* Resource Allocation */
++#if ABI_VIDEODRV_VERSION < 12
+ pAST->IODBase = pScrn->domainIOBase;
++#else
++ pAST->IODBase = 0;
++#endif
+ /* "Patch" the PIOOffset inside vgaHW in order to force
+ * the vgaHW module to use our relocated i/o ports.
+ */
+- VGAHWPTR(pScrn)->PIOOffset = pAST->PIOOffset = pAST->IODBase + PCI_REGION_BASE(pAST->PciInfo, 2, REGION_IO) - 0x380;
++
++#if ABI_VIDEODRV_VERSION < 12
++ VGAHWPTR(pScrn)->PIOOffset = /* ... */
++#endif
++ pAST->PIOOffset =
++ pAST->IODBase + PCI_REGION_BASE(pAST->PciInfo, 2, REGION_IO) - 0x380;
+
+ pAST->RelocateIO = (IOADDRESS)(PCI_REGION_BASE(pAST->PciInfo, 2, REGION_IO) + pAST->IODBase);
+
+--
+cgit v0.9.0.2-2-gbebe
diff --git a/extra/xf86-video-ati/PKGBUILD b/extra/xf86-video-ati/PKGBUILD
index 2aff325a5..5cce5b37c 100644
--- a/extra/xf86-video-ati/PKGBUILD
+++ b/extra/xf86-video-ati/PKGBUILD
@@ -1,17 +1,17 @@
-# $Id: PKGBUILD 141740 2011-11-02 16:51:06Z andyrtr $
+# $Id: PKGBUILD 153325 2012-03-12 20:53:16Z andyrtr $
# Maintainer: Jan de Groot <jgc@archlinux.org>
# Contributor: Alexander Baldeck <alexander@archlinux.org>
pkgname=xf86-video-ati
pkgver=6.14.3
-pkgrel=1
+pkgrel=2
pkgdesc="X.org ati video driver"
arch=('i686' 'x86_64')
url="http://xorg.freedesktop.org/"
license=('custom')
depends=(libpciaccess libdrm udev pixman ati-dri)
-makedepends=('xorg-server-devel>=1.11.0' 'libdrm' 'xf86driproto' 'mesa' 'glproto')
-conflicts=('xorg-server<1.11.0')
+makedepends=('xorg-server-devel>=1.11.99.902' 'libdrm' '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)
diff --git a/extra/xf86-video-chips/PKGBUILD b/extra/xf86-video-chips/PKGBUILD
index f558899d2..aea1d769a 100644
--- a/extra/xf86-video-chips/PKGBUILD
+++ b/extra/xf86-video-chips/PKGBUILD
@@ -1,29 +1,33 @@
-# $Id: PKGBUILD 140342 2011-10-11 21:29:31Z jgc $
+# $Id: PKGBUILD 153327 2012-03-12 20:53:18Z andyrtr $
# Maintainer: Jan de Groot <jgc@archlinux.org>
# Contributor: Alexander Baldeck <alexander@archlinux.org>
pkgname=xf86-video-chips
pkgver=1.2.4
-pkgrel=3
+pkgrel=4
pkgdesc="X.org Chips and Technologies video driver"
arch=(i686 x86_64)
url="http://xorg.freedesktop.org/"
license=('custom')
depends=(glibc)
-makedepends=('xorg-server-devel>=1.11.0')
-conflicts=('xorg-server<1.11.0')
+makedepends=('xorg-server-devel>=1.11.99.902')
+conflicts=('xorg-server<1.11.99.902')
groups=('xorg-drivers' 'xorg')
options=('!libtool')
source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2
- gut-overlay-8-16-support-from-driver.patch)
+ chips-1.2.4-git.patch)
sha1sums=('71f474335d05f93b2451a7a0750c4409669641a4'
- 'f6a635196118dacb73fad980571b390849963b3d')
+ 'b13ff000e3f6f06c1a7fd55e9e0ad6078f1b4e5b')
build() {
cd "${srcdir}/${pkgname}-${pkgver}"
- patch -Np1 -i "${srcdir}/gut-overlay-8-16-support-from-driver.patch"
+ patch -Np1 -i ${srcdir}/chips-1.2.4-git.patch
./configure --prefix=/usr
make
+}
+
+package() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
make DESTDIR="${pkgdir}" install
install -m755 -d "${pkgdir}/usr/share/licenses/${pkgname}"
diff --git a/extra/xf86-video-chips/chips-1.2.4-git.patch b/extra/xf86-video-chips/chips-1.2.4-git.patch
new file mode 100644
index 000000000..9d8e856a3
--- /dev/null
+++ b/extra/xf86-video-chips/chips-1.2.4-git.patch
@@ -0,0 +1,912 @@
+diff --git a/configure.ac b/configure.ac
+index 225e516..c0ed508 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -44,9 +44,6 @@ XORG_DEFAULT_OPTIONS
+ AC_DISABLE_STATIC
+ AC_PROG_LIBTOOL
+
+-# Checks for programs.
+-AM_PROG_CC_C_O
+-
+ AH_TOP([#include "xorg-server.h"])
+
+ # Define a configure option for an alternate module directory
+diff --git a/man/chips.man b/man/chips.man
+index 740af38..0c022ee 100644
+--- a/man/chips.man
++++ b/man/chips.man
+@@ -165,9 +165,6 @@ Force the use of memory mapped IO where it can be used. Default: off
+ Force driver to leave centering and stretching registers alone. This
+ can fix some laptop suspend/resume problems. Default: off
+ .TP
+-.BI "Option \*qOverlay\*q"
+-Enable 8+24 overlay mode. Only appropriate for depth 24. Default: off.
+-.TP
+ .BI "Option \*qColorKey\*q \*q" integer \*q
+ Set the colormap index used for the transparency key for the depth 8 plane
+ when operating in 8+16 overlay mode. The value must be in the range
+diff --git a/src/ct_accel.c b/src/ct_accel.c
+index 3920b0a..4b5776a 100644
+--- a/src/ct_accel.c
++++ b/src/ct_accel.c
+@@ -428,19 +428,7 @@ chips_imagewrite:
+ infoPtr->ImageWriteFlags |= NO_PLANEMASK;
+ #endif
+
+-
+-#ifdef CHIPS_HIQV
+- if (XAAInit(pScreen, infoPtr)) {
+- if (cPtr->Flags & ChipsOverlay8plus16)
+- return(XAAInitDualFramebufferOverlay(pScreen,
+- CTNAME(DepthChange)));
+- else
+- return TRUE;
+- } else
+- return FALSE;
+-#else
+ return(XAAInit(pScreen, infoPtr));
+-#endif
+ }
+
+ #ifdef CHIPS_HIQV
+@@ -1243,11 +1231,6 @@ CTNAME(SubsequentScreenToScreenColorExpandFill)(ScrnInfoPtr pScrn,
+ #endif
+ w *= cAcl->BytesPerPixel;
+ ctBLTWAIT;
+-#ifdef CHIPS_HIQV
+- if ((y >= pScrn->virtualY) && (cPtr->Flags & ChipsOverlay8plus16) &&
+- (pScrn->depth == 8))
+- ctSETPITCH(cAcl->PitchInBytes << 1, cAcl->PitchInBytes);
+-#endif
+ ctSETSRCADDR(srcaddr);
+ ctSETDSTADDR(destaddr);
+ #ifdef CHIPS_HIQV
+@@ -1271,10 +1254,6 @@ CTNAME(SetupForColor8x8PatternFill)(ScrnInfoPtr pScrn, int patx, int paty,
+ patternaddr = (paty * pScrn->displayWidth +
+ (patx & ~0x3F)) * cAcl->BytesPerPixel;
+ cAcl->patternyrot = (patx & 0x3F) >> 3;
+-#ifdef CHIPS_HIQV
+- if (cPtr->Flags & ChipsOverlay8plus16)
+- patternaddr += cPtr->FbOffset16;
+-#endif
+
+ ctBLTWAIT;
+ ctSETPATSRCADDR(patternaddr);
+@@ -1338,10 +1317,7 @@ CTNAME(SetupForMono8x8PatternFill)(ScrnInfoPtr pScrn, int patx, int paty,
+
+ #ifdef CHIPS_HIQV
+ patternaddr = paty * pScrn->displayWidth + patx;
+- if (cPtr->Flags & ChipsOverlay8plus16)
+- patternaddr = patternaddr * 2 + cPtr->FbOffset16;
+- else
+- patternaddr *= cAcl->BytesPerPixel;
++ patternaddr *= cAcl->BytesPerPixel;
+ #else
+ patternaddr = (paty * pScrn->displayWidth + patx) * cAcl->BytesPerPixel;
+ #endif
+@@ -1593,10 +1569,7 @@ CTNAME(WritePixmap)(ScrnInfoPtr pScrn, int x, int y, int w, int h,
+ dwords = (((skipleft + bytesPerLine + 0x7) & ~0x7)) >> 2;
+ destaddr = (y * pScrn->displayWidth + x) * (bpp >> 3);
+ destpitch = pScrn->displayWidth * (bpp >> 3);
+- if ((y >= pScrn->virtualY) && (cPtr->Flags & ChipsOverlay8plus16))
+- destaddr += cPtr->FbOffset16;
+- else
+- destaddr += cAcl->FbOffset;
++ destaddr += cAcl->FbOffset;
+
+ ctBLTWAIT;
+
+@@ -1681,10 +1654,7 @@ CTNAME(WritePixmap)(ScrnInfoPtr pScrn, int x, int y, int w, int h,
+ y++;
+
+ destaddr = (y * pScrn->displayWidth + x) * (bpp >> 3);
+- if ((y >= pScrn->virtualY) && (cPtr->Flags & ChipsOverlay8plus16))
+- destaddr += cPtr->FbOffset16;
+- else
+- destaddr += cAcl->FbOffset;
++ destaddr += cAcl->FbOffset;
+
+ ctBLTWAIT;
+ ctSETDSTADDR(destaddr);
+@@ -1717,10 +1687,7 @@ CTNAME(ReadPixmap)(ScrnInfoPtr pScrn, int x, int y, int w, int h,
+ dwords = (((bytesPerLine + 0x7) & ~0x7)) >> 2;
+ srcaddr = (y * pScrn->displayWidth + x) * (bpp >> 3);
+ srcpitch = pScrn->displayWidth * (bpp >> 3);
+- if ((y >= pScrn->virtualY) && (cPtr->Flags & ChipsOverlay8plus16))
+- srcaddr += cPtr->FbOffset16;
+- else
+- srcaddr += cAcl->FbOffset;
++ srcaddr += cAcl->FbOffset;
+
+ ctBLTWAIT;
+ ctSETROP( ctDSTSYSTEM | ctLEFT2RIGHT | ctTOP2BOTTOM |
+@@ -1755,10 +1722,7 @@ CTNAME(ReadPixmap)(ScrnInfoPtr pScrn, int x, int y, int w, int h,
+ dst += dstwidth;
+ y++;
+ srcaddr = (y * pScrn->displayWidth + x) * (bpp >> 3);
+- if ((y >= pScrn->virtualY) && (cPtr->Flags & ChipsOverlay8plus16))
+- srcaddr += cPtr->FbOffset16;
+- else
+- srcaddr += cAcl->FbOffset;
++ srcaddr += cAcl->FbOffset;
+ ctBLTWAIT;
+ ctSETSRCADDR(srcaddr);
+ ctSETHEIGHTWIDTHGO(h, bytesPerLine);
+diff --git a/src/ct_driver.c b/src/ct_driver.c
+index 6624b79..a2e5c94 100644
+--- a/src/ct_driver.c
++++ b/src/ct_driver.c
+@@ -949,7 +949,7 @@ CHIPSProbe(DriverPtr drv, int flags)
+ }
+
+ }
+- xfree(usedChips);
++ free(usedChips);
+ }
+ }
+
+@@ -981,12 +981,12 @@ CHIPSProbe(DriverPtr drv, int flags)
+ pScrn->ValidMode = CHIPSValidMode;
+ foundScreen = TRUE;
+ }
+- xfree(usedChips);
++ free(usedChips);
+ }
+ }
+ #endif
+
+- xfree(devSections);
++ free(devSections);
+ return foundScreen;
+ }
+ #endif
+@@ -1446,7 +1446,12 @@ chipsPreInitHiQV(ScrnInfoPtr pScrn, int flags)
+
+ hwp = VGAHWPTR(pScrn);
+ vgaHWGetIOBase(hwp);
++#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 12
+ cPtr->PIOBase = hwp->PIOOffset;
++#else
++ cPtr->PIOBase = 0;
++#endif
++
+ /*
+ * Must allow ensure that storage for the 2nd set of vga registers is
+ * allocated for dual channel cards
+@@ -1639,55 +1644,15 @@ chipsPreInitHiQV(ScrnInfoPtr pScrn, int flags)
+ }
+ }
+
+- if ((s = xf86GetOptValString(cPtr->Options, OPTION_OVERLAY))) {
+- if (!*s || !xf86NameCmp(s, "8,16") || !xf86NameCmp(s, "16,8")) {
+- if (pScrn->bitsPerPixel == 16) {
+- if (cPtr->Flags & ChipsLinearSupport) {
+- cPtr->Flags |= ChipsOverlay8plus16;
+- if(!xf86GetOptValInteger(
+- cPtr->Options, OPTION_COLOR_KEY, &(pScrn->colorKey)))
+- pScrn->colorKey = TRANSPARENCY_KEY;
+- pScrn->overlayFlags = OVERLAY_8_16_DUALFB;
+- xf86DrvMsg(pScrn->scrnIndex, X_CONFIG,
+- "PseudoColor overlay enabled.\n");
+- if (!xf86IsOptionSet(cPtr->Options, OPTION_LCD_STRETCH))
+- xf86DrvMsg(pScrn->scrnIndex, X_WARNING,
+- " - Forcing option \"Stretch\" \"ON\".\n");
+- if (!xf86IsOptionSet(cPtr->Options, OPTION_LCD_CENTER))
+- xf86DrvMsg(pScrn->scrnIndex, X_WARNING,
+- " - Forcing option \"LcdCenter\" \"OFF\".\n");
+- if (cPtr->Flags & ChipsShadowFB) {
+- xf86DrvMsg(pScrn->scrnIndex, X_WARNING,
+- " - Disabling \"Shadow Framebuffer\".\n");
+- xf86DrvMsg(pScrn->scrnIndex, X_WARNING,
+- " Not support with option \"8Plus16\".\n");
+- cPtr->Flags &= ~ChipsShadowFB;
+- cPtr->Rotate = 0;
+- }
+- } else {
+- xf86DrvMsg(pScrn->scrnIndex, X_WARNING, "Option \"Overlay\" ignored. Not supported without linear addressing\n");
+- }
+- } else {
+- xf86DrvMsg(pScrn->scrnIndex, X_WARNING,
+- "Option \"Overlay\" is not supported in this configuration\n");
+- }
+- } else {
+- xf86DrvMsg(pScrn->scrnIndex, X_WARNING,
+- "\"%s\" is not a valid value for Option \"Overlay\"\n", s);
+- }
+- }
+-
+- if (!(cPtr->Flags & ChipsOverlay8plus16)) {
+- if(xf86GetOptValInteger(cPtr->Options, OPTION_VIDEO_KEY,
+- &(cPtr->videoKey))) {
+- xf86DrvMsg(pScrn->scrnIndex, X_CONFIG, "video key set to 0x%x\n",
++ if(xf86GetOptValInteger(cPtr->Options, OPTION_VIDEO_KEY,
++ &(cPtr->videoKey))) {
++ xf86DrvMsg(pScrn->scrnIndex, X_CONFIG, "video key set to 0x%x\n",
+ cPtr->videoKey);
+- } else {
+- cPtr->videoKey = (1 << pScrn->offset.red) |
++ } else {
++ cPtr->videoKey = (1 << pScrn->offset.red) |
+ (1 << pScrn->offset.green) |
+ (((pScrn->mask.blue >> pScrn->offset.blue) - 1)
+ << pScrn->offset.blue);
+- }
+ }
+
+ if (cPtr->Flags & ChipsShadowFB) {
+@@ -2335,28 +2300,16 @@ chipsPreInitHiQV(ScrnInfoPtr pScrn, int flags)
+ /* and 32bits on the others. Thus multiply by a suitable factor */
+ if (cPtr->Flags & Chips64BitMemory) {
+ if (cPtr->FrameBufferSize && (cPtr->PanelType & ChipsLCD))
+- if (cPtr->Flags & ChipsOverlay8plus16 )
+- cPtr->MaxClock = min(cPtr->MaxClock, MemClk->Clk * 8 * 0.7 / 4);
+- else
+ cPtr->MaxClock = min(cPtr->MaxClock,
+ MemClk->Clk * 8 * 0.7 / (bytesPerPixel + 1));
+ else
+- if (cPtr->Flags & ChipsOverlay8plus16)
+- cPtr->MaxClock = min(cPtr->MaxClock, MemClk->Clk * 8 * 0.7 / 3);
+- else
+ cPtr->MaxClock = min(cPtr->MaxClock,
+ MemClk->Clk * 8 * 0.7 / bytesPerPixel);
+ } else {
+ if (cPtr->FrameBufferSize && (cPtr->PanelType & ChipsLCD))
+- if (cPtr->Flags & ChipsOverlay8plus16 )
+- cPtr->MaxClock = min(cPtr->MaxClock, MemClk->Clk * 4 * 0.7 / 4);
+- else
+ cPtr->MaxClock = min(cPtr->MaxClock,
+ MemClk->Clk * 4 * 0.7 / (bytesPerPixel + 1));
+ else
+- if (cPtr->Flags & ChipsOverlay8plus16)
+- cPtr->MaxClock = min(cPtr->MaxClock, MemClk->Clk * 4 * 0.7 / 3);
+- else
+ cPtr->MaxClock = min(cPtr->MaxClock,
+ MemClk->Clk * 4 * 0.7 / bytesPerPixel);
+ }
+@@ -3736,8 +3689,7 @@ CHIPSEnterVT(int scrnIndex, int flags)
+ /* Should we re-save the text mode on each VT enter? */
+ if(!chipsModeInit(pScrn, pScrn->currentMode))
+ return FALSE;
+- if ((!(cPtr->Flags & ChipsOverlay8plus16))
+- && (cPtr->Flags & ChipsVideoSupport)
++ if ((cPtr->Flags & ChipsVideoSupport)
+ && (cPtr->Flags & ChipsLinearSupport))
+ CHIPSResetVideo(pScrn);
+
+@@ -3788,8 +3740,7 @@ chipsLoadPalette(ScrnInfoPtr pScrn, int numColors, int *indices, LOCO *colors,
+ int i, index, shift ;
+ CHIPSEntPtr cPtrEnt;
+
+- shift = ((pScrn->depth == 15) &&
+- (!(cPtr->Flags & ChipsOverlay8plus16))) ? 3 : 0;
++ shift = (pScrn->depth == 15) ? 3 : 0;
+
+ if (cPtr->UseDualChannel) {
+ cPtrEnt = xf86GetEntityPrivate(pScrn->entityList[0],
+@@ -3895,18 +3846,6 @@ chipsLoadPalette16(ScrnInfoPtr pScrn, int numColors, int *indices,
+ hwp->disablePalette(hwp);
+ }
+
+-static Bool
+-cfb8_16ScreenInit(ScreenPtr pScreen, pointer pbits16, pointer pbits8,
+- int xsize, int ysize, int dpix, int dpiy,
+- int width16, int width8)
+-{
+- return
+- (fbOverlaySetupScreen(pScreen, pbits16, pbits8, xsize, ysize,
+- dpix, dpiy, width16, width8, 16, 8) &&
+- fbOverlayFinishScreenInit(pScreen, pbits16, pbits8, xsize, ysize,
+- dpix, dpiy, width16, width8, 16, 8, 16, 8));
+-}
+-
+ /* Mandatory */
+ static Bool
+ CHIPSScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
+@@ -3947,22 +3886,6 @@ CHIPSScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
+ if (!chipsMapMem(pScrn))
+ return FALSE;
+
+- /* Setup a pointer to the overlay if needed */
+- if (cPtr->Flags & ChipsOverlay8plus16) {
+- cPtr->FbOffset16 = pScrn->displayWidth * pScrn->virtualY;
+- cPtr->FbSize16 = (pScrn->displayWidth << 1) * pScrn->virtualY;
+- if (cPtr->FbSize16 > (cPtr->FbMapSize - cPtr->FrameBufferSize)) {
+- xf86DrvMsg(pScrn->scrnIndex, X_CONFIG,
+- "Too little memory for overlay. Disabling.\n");
+- cPtr->Flags &= ~ChipsOverlay8plus16;
+- }
+- if ((pScrn->displayWidth > 1024) || (pScrn->virtualY > 1024)) {
+- xf86DrvMsg(pScrn->scrnIndex, X_CONFIG,
+- "Max overlay Width/Height 1024 pixels. Disabling.\n");
+- cPtr->Flags &= ~ChipsOverlay8plus16;
+- }
+- }
+-
+ /* Setup the MMIO register access functions if need */
+ if (cPtr->UseFullMMIO && cPtr->MMIOBaseVGA) {
+ CHIPSSetMmioExtFuncs(cPtr);
+@@ -4035,18 +3958,10 @@ CHIPSScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
+ miClearVisualTypes();
+
+ /* Setup the visuals we support. */
+- if ((pScrn->bitsPerPixel == 16) && (cPtr->Flags & ChipsOverlay8plus16)){
+- if (!miSetVisualTypes(8, PseudoColorMask | GrayScaleMask,
+- pScrn->rgbBits, PseudoColor))
+- return FALSE;
+- if (!miSetVisualTypes(16, TrueColorMask, pScrn->rgbBits, TrueColor))
+- return FALSE;
+- } else {
+- if (!miSetVisualTypes(pScrn->depth,
++ if (!miSetVisualTypes(pScrn->depth,
+ miGetDefaultVisualMask(pScrn->depth),
+ pScrn->rgbBits, pScrn->defaultVisual))
+- return FALSE;
+- }
++ return FALSE;
+ miSetPixmapDepths ();
+
+ /*
+@@ -4090,13 +4005,6 @@ CHIPSScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
+ break;
+ #endif
+ case 16:
+- if (cPtr->Flags & ChipsOverlay8plus16) {
+- ret = cfb8_16ScreenInit(pScreen, (unsigned char *)FBStart +
+- cPtr->FbOffset16, FBStart, width,
+- height, pScrn->xDpi, pScrn->yDpi,
+- displayWidth, displayWidth);
+- break;
+- }
+ default:
+ ret = fbScreenInit(pScreen, FBStart,
+ width,height,
+@@ -4223,7 +4131,7 @@ CHIPSScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
+ }
+ if (!miInitializeBanking(pScreen, pScrn->virtualX, pScrn->virtualY,
+ pScrn->displayWidth, pBankInfo)) {
+- xfree(pBankInfo);
++ free(pBankInfo);
+ pBankInfo = NULL;
+ return FALSE;
+ }
+@@ -4244,9 +4152,6 @@ CHIPSScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
+ if (pScrn->bitsPerPixel < 8)
+ freespace = allocatebase - pScrn->displayWidth *
+ pScrn->virtualY / 2;
+- else if ((pScrn->bitsPerPixel == 16) && (cPtr->Flags & ChipsOverlay8plus16))
+- freespace = allocatebase - pScrn->displayWidth *
+- pScrn->virtualY - cPtr->FbSize16;
+ else
+ freespace = allocatebase - pScrn->displayWidth *
+ pScrn->virtualY * (pScrn->bitsPerPixel >> 3);
+@@ -4369,9 +4274,7 @@ CHIPSScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
+ AvailFBArea.y2 = cAcl->CacheEnd /
+ (pScrn->displayWidth * (pScrn->bitsPerPixel >> 3));
+
+- if (!(cPtr->Flags & ChipsOverlay8plus16)) {
+- xf86InitFBManager(pScreen, &AvailFBArea);
+- }
++ xf86InitFBManager(pScreen, &AvailFBArea);
+ }
+ if (cPtr->Flags & ChipsAccelSupport) {
+ if (IS_HiQV(cPtr)) {
+@@ -4425,16 +4328,10 @@ CHIPSScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
+ if (!miCreateDefColormap(pScreen))
+ return FALSE;
+
+- if ((cPtr->Flags & ChipsOverlay8plus16) && (pScrn->bitsPerPixel == 16)) {
+- if(!xf86HandleColormaps(pScreen, 256, pScrn->rgbBits, chipsLoadPalette,
+- NULL, CMAP_RELOAD_ON_MODE_SWITCH))
+- return FALSE;
+- } else {
+- if(!xf86HandleColormaps(pScreen, 256, pScrn->rgbBits,
++ if(!xf86HandleColormaps(pScreen, 256, pScrn->rgbBits,
+ (pScrn->depth == 16 ? chipsLoadPalette16 : chipsLoadPalette),
+ NULL, CMAP_RELOAD_ON_MODE_SWITCH | CMAP_PALETTED_TRUECOLOR))
+- return FALSE;
+- }
++ return FALSE;
+
+ #ifndef XSERVER_LIBPCIACCESS
+ racflag = RAC_COLORMAP;
+@@ -4448,8 +4345,7 @@ CHIPSScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
+ xf86SetSilkenMouse(pScreen);
+ #endif
+
+- if ((!(cPtr->Flags & ChipsOverlay8plus16))
+- && (cPtr->Flags & ChipsVideoSupport)
++ if ((cPtr->Flags & ChipsVideoSupport)
+ && (cPtr->Flags & ChipsLinearSupport)) {
+ CHIPSInitVideo(pScreen);
+ }
+@@ -4522,10 +4418,7 @@ CHIPSAdjustFrame(int scrnIndex, int x, int y, int flags)
+ Base >>= 3;
+ break;
+ case 16:
+- if (!(cPtr->Flags & ChipsOverlay8plus16))
+- Base >>= 1;
+- else
+- Base >>= 2;
++ Base >>= 1;
+ break;
+ case 24:
+ if (!IS_HiQV(cPtr))
+@@ -4581,14 +4474,6 @@ CHIPSAdjustFrame(int scrnIndex, int x, int y, int flags)
+ cPtr->writeMSS(cPtr, hwp, MSS);
+ }
+
+- if (cPtr->Flags & ChipsOverlay8plus16) {
+- Base = (Base << 3) & ~(unsigned long)0xF;
+-
+- cPtr->writeMR(cPtr, 0x22, (cPtr->FbOffset16 + Base) & 0xF8);
+- cPtr->writeMR(cPtr, 0x23, ((cPtr->FbOffset16 + Base) >> 8) & 0xFF);
+- cPtr->writeMR(cPtr, 0x24, ((cPtr->FbOffset16 + Base) >> 16) & 0xFF);
+- }
+-
+ }
+
+ /* Mandatory */
+@@ -4652,13 +4537,6 @@ CHIPSValidMode(int scrnIndex, DisplayModePtr mode, Bool verbose, int flags)
+ ScrnInfoPtr pScrn = xf86Screens[scrnIndex];
+ CHIPSPtr cPtr = CHIPSPTR(pScrn);
+
+- if (flags & MODECHECK_FINAL) {
+- /* Don't subtract FrambufferSize here as it should be subtracted already */
+- if ((cPtr->Flags & ChipsOverlay8plus16)
+- && ((pScrn->videoRam<<10) - pScrn->displayWidth * 3 * pScrn->virtualY
+- < 0))
+- return MODE_MEM;
+- }
+ /* The tests here need to be expanded */
+ if ((mode->Flags & V_INTERLACE) && (cPtr->PanelType & ChipsLCD))
+ return MODE_NO_INTERLACE;
+@@ -5544,12 +5422,7 @@ chipsModeInitHiQV(ScrnInfoPtr pScrn, DisplayModePtr mode)
+ } else {
+ ChipsStd->Attribute[0x10] = 0x01; /* mode */
+ }
+- if ((pScrn->bitsPerPixel == 16) && (cPtr->Flags & ChipsOverlay8plus16)) {
+- /* Make sure that the overlay isn't visible in the overscan region */
+- if (ChipsStd->Attribute[0x11] == pScrn->colorKey)
+- ChipsStd->Attribute[0x11] = pScrn->colorKey - 1;
+- } else
+- ChipsStd->Attribute[0x11] = 0x00; /* overscan (border) color */
++ ChipsStd->Attribute[0x11] = 0x00; /* overscan (border) color */
+ ChipsStd->Attribute[0x12] = 0x0F; /* enable all color planes */
+ ChipsStd->Attribute[0x13] = 0x00; /* horiz pixel panning 0 */
+
+@@ -5558,8 +5431,7 @@ chipsModeInitHiQV(ScrnInfoPtr pScrn, DisplayModePtr mode)
+ /* set virtual screen width */
+ tmp = pScrn->displayWidth >> 3;
+ if (pScrn->bitsPerPixel == 16) {
+- if (!(cPtr->Flags & ChipsOverlay8plus16))
+- tmp <<= 1; /* double the width of the buffer */
++ tmp <<= 1; /* double the width of the buffer */
+ } else if (pScrn->bitsPerPixel == 24) {
+ tmp += tmp << 1;
+ } else if (pScrn->bitsPerPixel == 32) {
+@@ -5688,8 +5560,7 @@ chipsModeInitHiQV(ScrnInfoPtr pScrn, DisplayModePtr mode)
+
+ /* centering/stretching */
+ if (!xf86ReturnOptValBool(cPtr->Options, OPTION_SUSPEND_HACK, FALSE)) {
+- if (!xf86ReturnOptValBool(cPtr->Options, OPTION_LCD_STRETCH, FALSE) ||
+- (cPtr->Flags & ChipsOverlay8plus16)) {
++ if (!xf86ReturnOptValBool(cPtr->Options, OPTION_LCD_STRETCH, FALSE)) {
+ ChipsNew->FR[0x40] &= 0xDF; /* Disable Horizontal stretching */
+ ChipsNew->FR[0x48] &= 0xFB; /* Disable vertical stretching */
+ ChipsNew->XR[0xA0] = 0x10; /* Disable cursor stretching */
+@@ -5709,8 +5580,7 @@ chipsModeInitHiQV(ScrnInfoPtr pScrn, DisplayModePtr mode)
+ }
+ }
+
+- if ((xf86ReturnOptValBool(cPtr->Options, OPTION_LCD_CENTER, TRUE))
+- || (cPtr->Flags & ChipsOverlay8plus16)) {
++ if (xf86ReturnOptValBool(cPtr->Options, OPTION_LCD_CENTER, TRUE)) {
+ ChipsNew->FR[0x40] |= 0x3; /* Enable Horizontal centering */
+ ChipsNew->FR[0x48] |= 0x3; /* Enable Vertical centering */
+ } else {
+@@ -5723,8 +5593,7 @@ chipsModeInitHiQV(ScrnInfoPtr pScrn, DisplayModePtr mode)
+ ChipsNew->XR[0x82] |=0x02;
+
+ /* software mode flag */
+- ChipsNew->XR[0xE2] = chipsVideoMode(((cPtr->Flags & ChipsOverlay8plus16) ?
+- 8 : pScrn->depth), (cPtr->PanelType & ChipsLCD) ?
++ ChipsNew->XR[0xE2] = chipsVideoMode((pScrn->depth), (cPtr->PanelType & ChipsLCD) ?
+ min(mode->CrtcHDisplay, cPtr->PanelSize.HDisplay) :
+ mode->CrtcHDisplay, mode->CrtcVDisplay);
+ #ifdef DEBUG
+@@ -5762,7 +5631,7 @@ chipsModeInitHiQV(ScrnInfoPtr pScrn, DisplayModePtr mode)
+ }
+ }
+ /* bpp depend */
+- if ((pScrn->bitsPerPixel == 16) && (!(cPtr->Flags & ChipsOverlay8plus16))) {
++ if (pScrn->bitsPerPixel == 16) {
+ ChipsNew->XR[0x81] = (ChipsNew->XR[0x81] & 0xF0) | 0x4;
+ if (cPtr->Flags & ChipsGammaSupport)
+ ChipsNew->XR[0x82] |= 0x0C;
+@@ -5915,60 +5784,7 @@ chipsModeInitHiQV(ScrnInfoPtr pScrn, DisplayModePtr mode)
+ /* Turn off multimedia by default as it degrades performance */
+ ChipsNew->XR[0xD0] &= 0x0f;
+
+- /* Setup the video/overlay */
+- if (cPtr->Flags & ChipsOverlay8plus16) {
+- ChipsNew->XR[0xD0] |= 0x10; /* Force the Multimedia engine on */
+-#ifdef SAR04
+- ChipsNew->XR[0x4F] = 0x2A; /* SAR04 >352 pixel overlay width */
+-#endif
+- ChipsNew->MR[0x1E] &= 0xE0; /* Set Zoom and Direction */
+- if ((!(cPtr->PanelType & ChipsLCD)) && (mode->Flags & V_INTERLACE))
+- ChipsNew->MR[0x1E] |= 0x10; /* Interlace */
+- ChipsNew->MR[0x1F] &= 0x14; /* Mask reserved bits */
+- ChipsNew->MR[0x1F] |= 0x08; /* RGB 16bpp */
+- if (pScrn->weight.green == 5)
+- ChipsNew->MR[0x1F] |= 0x01; /* RGB 15bpp */
+-
+- ChipsNew->MR[0x20] &= 0x03; /* Mask reserved bits */
+- ChipsNew->MR[0x20] |= 0x80; /* Auto Centre, Use mem ptr1 */
+- ChipsNew->MR[0x22] = cPtr->FbOffset16 & 0xF8; /* Setup Pointer 1 */
+- ChipsNew->MR[0x23] = (cPtr->FbOffset16 >> 8) & 0xFF;
+- ChipsNew->MR[0x24] = (cPtr->FbOffset16 >> 16) & 0xFF;
+- ChipsNew->MR[0x25] = cPtr->FbOffset16 & 0xF8; /* Setup Pointer 2 */
+- ChipsNew->MR[0x26] = (cPtr->FbOffset16 >> 8) & 0xFF;
+- ChipsNew->MR[0x27] = (cPtr->FbOffset16 >> 16) & 0xFF;
+- ChipsNew->MR[0x28] = (pScrn->displayWidth >> 2) - 1; /* Width */
+- ChipsNew->MR[0x34] = (pScrn->displayWidth >> 2) - 1;
+-
+- /* Left Edge of Overlay */
+- ChipsNew->MR[0x2A] = cPtr->OverlaySkewX;
+- ChipsNew->MR[0x2B] &= 0xF8; /* Mask reserved bits */
+- ChipsNew->MR[0x2B] |= ((cPtr->OverlaySkewX >> 8) & 0x7);
+- /* Right Edge of Overlay */
+- ChipsNew->MR[0x2C] = (cPtr->OverlaySkewX + pScrn->displayWidth -
+- 1) & 0xFF;
+- ChipsNew->MR[0x2D] &= 0xF8; /* Mask reserved bits */
+- ChipsNew->MR[0x2D] |= ((cPtr->OverlaySkewX + pScrn->displayWidth -
+- 1) >> 8) & 0x07;
+- /* Top Edge of Overlay */
+- ChipsNew->MR[0x2E] = cPtr->OverlaySkewY;
+- ChipsNew->MR[0x2F] &= 0xF8;
+- ChipsNew->MR[0x2F] |= ((cPtr->OverlaySkewY >> 8) & 0x7);
+- /* Bottom Edge of Overlay*/
+- ChipsNew->MR[0x30] = (cPtr->OverlaySkewY + pScrn->virtualY - 1 )& 0xFF;
+- ChipsNew->MR[0x31] &= 0xF8; /* Mask reserved bits */
+- ChipsNew->MR[0x31] |= ((cPtr->OverlaySkewY + pScrn->virtualY -
+- 1 ) >> 8) & 0x07;
+-
+- ChipsNew->MR[0x3C] &= 0x18; /* Mask reserved bits */
+- ChipsNew->MR[0x3C] |= 0x07; /* Enable keyed overlay window */
+- ChipsNew->MR[0x3D] = 0x00;
+- ChipsNew->MR[0x3E] = 0x00;
+- ChipsNew->MR[0x3F] = pScrn->colorKey; /* 8bpp transparency key */
+- ChipsNew->MR[0x40] = 0xFF;
+- ChipsNew->MR[0x41] = 0xFF;
+- ChipsNew->MR[0x42] = 0x00;
+- } else if (cPtr->Flags & ChipsVideoSupport) {
++ if (cPtr->Flags & ChipsVideoSupport) {
+ #if 0 /* if we do this even though video isn't playing we kill performance */
+ ChipsNew->XR[0xD0] |= 0x10; /* Force the Multimedia engine on */
+ #endif
+@@ -6877,8 +6693,7 @@ chipsRestoreExtendedRegs(ScrnInfoPtr pScrn, CHIPSRegPtr Regs)
+ }
+
+ /* Set SAR04 multimedia register correctly */
+- if ((cPtr->Flags & ChipsOverlay8plus16)
+- || (cPtr->Flags & ChipsVideoSupport)) {
++ if ((cPtr->Flags & ChipsVideoSupport)) {
+ #ifdef SAR04
+ cPtr->writeXR(cPtr, 0x4E, 0x04);
+ if (cPtr->readXR(cPtr, 0x4F) != Regs->XR[0x4F])
+diff --git a/src/ct_driver.h b/src/ct_driver.h
+index d8ce228..9033867 100644
+--- a/src/ct_driver.h
++++ b/src/ct_driver.h
+@@ -114,7 +114,6 @@ typedef struct {
+ /* Options flags for the C&T chipsets */
+ #define ChipsHWCursor 0x00001000
+ #define ChipsShadowFB 0x00002000
+-#define ChipsOverlay8plus16 0x00004000
+ #define ChipsUseNewFB 0x00008000
+
+ /* Architecture type flags */
+@@ -272,11 +271,13 @@ typedef struct {
+
+ typedef struct _CHIPSRec {
+ pciVideoPtr PciInfo;
++#ifndef XSERVER_LIBPCIACCESS
+ PCITAG PciTag;
++#endif
+ int Chipset;
+ EntityInfoPtr pEnt;
+- IOADDRESS PIOBase;
+- CARD32 IOAddress;
++ unsigned long PIOBase;
++ unsigned long IOAddress;
+ unsigned long FbAddress;
+ unsigned int IOBase;
+ unsigned char * FbBase;
+diff --git a/src/ct_video.c b/src/ct_video.c
+index a68acb9..c9e5bb4 100644
+--- a/src/ct_video.c
++++ b/src/ct_video.c
+@@ -56,8 +56,7 @@ CHIPSInitVideo(ScreenPtr pScreen)
+ CHIPSPtr cPtr = CHIPSPTR(pScrn);
+ int num_adaptors;
+
+- if (!(cPtr->Flags & ChipsOverlay8plus16) &&
+- (cPtr->Flags & ChipsVideoSupport)) {
++ if ((cPtr->Flags & ChipsVideoSupport)) {
+ newAdaptor = CHIPSSetupImageVideo(pScreen);
+ CHIPSInitOffscreenImages(pScreen);
+ }
+diff --git a/util/dRegs.c b/util/dRegs.c
+index b7edc8f..0d2f0cb 100644
+--- a/util/dRegs.c
++++ b/util/dRegs.c
+@@ -1,63 +1,8 @@
+-
+-
+-
+-
+-
+-
+-#ifdef __NetBSD__
+-# include <sys/types.h>
+-# include <machine/pio.h>
+-# include <machine/sysarch.h>
+-#else
+-# if defined(SVR4) && defined(i386)
+-# include <sys/types.h>
+-# ifdef NCR
+- /* broken NCR <sys/sysi86.h> */
+-# define __STDC
+-# include <sys/sysi86.h>
+-# undef __STDC
+-# else
+-# include <sys/sysi86.h>
+-# endif
+-# ifdef SVR4
+-# if !defined(sun)
+-# include <sys/seg.h>
+-# endif
+-# endif
+-# include <sys/v86.h>
+-# if defined(sun)
+-# include <sys/psw.h>
+-# endif
+-# endif
+-# include "AsmMacros.h"
+-#endif /* NetBSD */
+-
+ #include <unistd.h>
+ #include <stdio.h>
+ #include <stdlib.h>
+
+-#ifdef __NetBSD__
+-# define SET_IOPL() i386_iopl(3)
+-# define RESET_IOPL() i386_iopl(0)
+-#else
+-# if defined(SVR4) && defined(i386)
+-# ifndef SI86IOPL
+-# define SET_IOPL() sysi86(SI86V86,V86SC_IOPL,PS_IOPL)
+-# define RESET_IOPL() sysi86(SI86V86,V86SC_IOPL,0)
+-# else
+-# define SET_IOPL() sysi86(SI86IOPL,3)
+-# define RESET_IOPL() sysi86(SI86IOPL,0)
+-# endif
+-# else
+-# ifdef linux
+-# define SET_IOPL() iopl(3)
+-# define RESET_IOPL() iopl(0)
+-# else
+-# define SET_IOPL() (void)0
+-# define RESET_IOPL() (void)0
+-# endif
+-# endif
+-#endif
++#include "iopl.h"
+
+ int main(void)
+ {
+diff --git a/util/iopl.h b/util/iopl.h
+new file mode 100644
+index 0000000..e08207c
+--- /dev/null
++++ b/util/iopl.h
+@@ -0,0 +1,60 @@
++#ifdef __NetBSD__
++# include <sys/types.h>
++# include <machine/pio.h>
++# include <machine/sysarch.h>
++#else
++# if defined(__linux__)
++/* Can't because <sys/iopl.h> provides conflicting inb, outb, etc
++ * # include <sys/io.h>
++ */
++int iopl(int level);
++# endif
++# if defined(SVR4) && defined(i386)
++# include <sys/types.h>
++# ifdef NCR
++ /* broken NCR <sys/sysi86.h> */
++# define __STDC
++# include <sys/sysi86.h>
++# undef __STDC
++# else
++# include <sys/sysi86.h>
++# endif
++# ifdef SVR4
++# if !defined(sun)
++# include <sys/seg.h>
++# endif
++# endif
++# include <sys/v86.h>
++# if defined(sun)
++# include <sys/psw.h>
++# endif
++# endif
++# include "AsmMacros.h"
++#endif /* NetBSD */
++
++#include <unistd.h>
++#include <stdio.h>
++#include <stdlib.h>
++
++#ifdef __NetBSD__
++# define SET_IOPL() i386_iopl(3)
++# define RESET_IOPL() i386_iopl(0)
++#else
++# if defined(SVR4) && defined(i386)
++# ifndef SI86IOPL
++# define SET_IOPL() sysi86(SI86V86,V86SC_IOPL,PS_IOPL)
++# define RESET_IOPL() sysi86(SI86V86,V86SC_IOPL,0)
++# else
++# define SET_IOPL() sysi86(SI86IOPL,3)
++# define RESET_IOPL() sysi86(SI86IOPL,0)
++# endif
++# else
++# ifdef linux
++# define SET_IOPL() iopl(3)
++# define RESET_IOPL() iopl(0)
++# else
++# define SET_IOPL() (void)0
++# define RESET_IOPL() (void)0
++# endif
++# endif
++#endif
+diff --git a/util/mRegs.c b/util/mRegs.c
+index f359738..843d01d 100644
+--- a/util/mRegs.c
++++ b/util/mRegs.c
+@@ -1,63 +1,8 @@
+-
+-
+-
+-
+-
+-
+-#ifdef __NetBSD__
+-# include <sys/types.h>
+-# include <machine/pio.h>
+-# include <machine/sysarch.h>
+-#else
+-# if defined(SVR4) && defined(i386)
+-# include <sys/types.h>
+-# ifdef NCR
+- /* broken NCR <sys/sysi86.h> */
+-# define __STDC
+-# include <sys/sysi86.h>
+-# undef __STDC
+-# else
+-# include <sys/sysi86.h>
+-# endif
+-# ifdef SVR4
+-# if !defined(sun)
+-# include <sys/seg.h>
+-# endif
+-# endif
+-# include <sys/v86.h>
+-# if defined(sun)
+-# include <sys/psw.h>
+-# endif
+-# endif
+-# include "AsmMacros.h"
+-#endif /* NetBSD */
+-
+ #include <unistd.h>
+ #include <stdio.h>
+ #include <stdlib.h>
+
+-#ifdef __NetBSD__
+-# define SET_IOPL() i386_iopl(3)
+-# define RESET_IOPL() i386_iopl(0)
+-#else
+-# if defined(SVR4) && defined(i386)
+-# ifndef SI86IOPL
+-# define SET_IOPL() sysi86(SI86V86,V86SC_IOPL,PS_IOPL)
+-# define RESET_IOPL() sysi86(SI86V86,V86SC_IOPL,0)
+-# else
+-# define SET_IOPL() sysi86(SI86IOPL,3)
+-# define RESET_IOPL() sysi86(SI86IOPL,0)
+-# endif
+-# else
+-# ifdef linux
+-# define SET_IOPL() iopl(3)
+-# define RESET_IOPL() iopl(0)
+-# else
+-# define SET_IOPL() (void)0
+-# define RESET_IOPL() (void)0
+-# endif
+-# endif
+-#endif
++#include "iopl.h"
+
+ int hex2int(char* str);
+
+diff --git a/util/modClock.c b/util/modClock.c
+index 89a291a..45af19b 100644
+--- a/util/modClock.c
++++ b/util/modClock.c
+@@ -1,61 +1,12 @@
+-
+-#ifdef __NetBSD__
+-# include <sys/types.h>
+-# include <machine/pio.h>
+-# include <machine/sysarch.h>
+-#else
+-# if defined(SVR4) && defined(i386)
+-# include <sys/types.h>
+-# ifdef NCR
+- /* broken NCR <sys/sysi86.h> */
+-# define __STDC
+-# include <sys/sysi86.h>
+-# undef __STDC
+-# else
+-# include <sys/sysi86.h>
+-# endif
+-# ifdef SVR4
+-# if !defined(sun)
+-# include <sys/seg.h>
+-# endif
+-# endif
+-# include <sys/v86.h>
+-# if defined(sun)
+-# include <sys/psw.h>
+-# endif
+-# endif
+-# include "AsmMacros.h"
+-#endif /* NetBSD */
+-
+ #include <unistd.h>
+ #include <stdio.h>
+ #include <stdlib.h>
++
+ #ifndef Lynx
+ #include <fnmatch.h>
+ #endif
+
+-#ifdef __NetBSD__
+-# define SET_IOPL() i386_iopl(3)
+-# define RESET_IOPL() i386_iopl(0)
+-#else
+-# if defined(SVR4) && defined(i386)
+-# ifndef SI86IOPL
+-# define SET_IOPL() sysi86(SI86V86,V86SC_IOPL,PS_IOPL)
+-# define RESET_IOPL() sysi86(SI86V86,V86SC_IOPL,0)
+-# else
+-# define SET_IOPL() sysi86(SI86IOPL,3)
+-# define RESET_IOPL() sysi86(SI86IOPL,0)
+-# endif
+-# else
+-# ifdef linux
+-# define SET_IOPL() iopl(3)
+-# define RESET_IOPL() iopl(0)
+-# else
+-# define SET_IOPL() (void)0
+-# define RESET_IOPL() (void)0
+-# endif
+-# endif
+-#endif
++#include "iopl.h"
+
+ #define tolerance 0.01 /* +/- 1% */
+
diff --git a/extra/xf86-video-cirrus/PKGBUILD b/extra/xf86-video-cirrus/PKGBUILD
index a2b46e91e..8f03c11d3 100644
--- a/extra/xf86-video-cirrus/PKGBUILD
+++ b/extra/xf86-video-cirrus/PKGBUILD
@@ -1,25 +1,32 @@
-# $Id: PKGBUILD 140340 2011-10-11 21:29:29Z jgc $
+# $Id: PKGBUILD 153329 2012-03-12 20:53:21Z andyrtr $
#Maintainer: Jan de Groot <jgc@archlinux.org>
pkgname=xf86-video-cirrus
pkgver=1.3.2
-pkgrel=7
+pkgrel=8
pkgdesc="X.org Cirrus Logic video driver"
arch=(i686 x86_64)
url="http://xorg.freedesktop.org/"
license=('custom')
depends=('glibc')
-makedepends=('xorg-server-devel>=1.10.99.902')
-conflicts=('xorg-server<1.10.99.902')
+makedepends=('xorg-server-devel>=1.11.99.903')
+conflicts=('xorg-server<1.11.99.903')
groups=('xorg-drivers' 'xorg')
options=('!libtool')
-source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2)
-md5sums=('8195d03ed0be0975c03441e66a9f53b3')
+source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2
+ cirrus-1.3.2-git.patch)
+md5sums=('8195d03ed0be0975c03441e66a9f53b3'
+ '3e3677f330f1c24ce0f570c81f2b9de2')
build() {
cd "${srcdir}/${pkgname}-${pkgver}"
+ patch -Np1 -i ${srcdir}/cirrus-1.3.2-git.patch
./configure --prefix=/usr
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/extra/xf86-video-cirrus/cirrus-1.3.2-git.patch b/extra/xf86-video-cirrus/cirrus-1.3.2-git.patch
new file mode 100644
index 000000000..5701a8473
--- /dev/null
+++ b/extra/xf86-video-cirrus/cirrus-1.3.2-git.patch
@@ -0,0 +1,846 @@
+diff --git a/Makefile.am b/Makefile.am
+index aa89732..7bd8873 100644
+--- a/Makefile.am
++++ b/Makefile.am
+@@ -18,17 +18,18 @@
+ # 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.
+
+-AUTOMAKE_OPTIONS = foreign
+ SUBDIRS = src man
++MAINTAINERCLEANFILES = ChangeLog INSTALL
+
+-EXTRA_DIST = README.multihead ChangeLog
++EXTRA_DIST = README.multihead
+
+-MAINTAINERCLEANFILES=ChangeLog
++.PHONY: ChangeLog INSTALL
+
+-.PHONY: ChangeLog
++INSTALL:
++ $(INSTALL_CMD)
+
+ ChangeLog:
+ $(CHANGELOG_CMD)
+
+-dist-hook: ChangeLog
++dist-hook: ChangeLog INSTALL
+
+diff --git a/configure.ac b/configure.ac
+index d205eb3..68c3eb3 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -20,47 +20,47 @@
+ #
+ # Process this file with autoconf to produce a configure script
+
+-AC_PREREQ(2.57)
++# Initialize Autoconf
++AC_PREREQ([2.60])
+ AC_INIT([xf86-video-cirrus],
+- 1.3.2,
++ [1.3.2],
+ [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg],
+- xf86-video-cirrus)
+-
++ [xf86-video-cirrus])
+ AC_CONFIG_SRCDIR([Makefile.am])
+-AM_CONFIG_HEADER([config.h])
++AC_CONFIG_HEADERS([config.h])
+ AC_CONFIG_AUX_DIR(.)
+
+-AM_INIT_AUTOMAKE([dist-bzip2])
+-
++# Initialize Automake
++AM_INIT_AUTOMAKE([foreign dist-bzip2])
+ AM_MAINTAINER_MODE
+
+-# Require xorg-macros: XORG_CWARNFLAGS, XORG_CHANGELOG
+-m4_ifndef([XORG_MACROS_VERSION], [AC_FATAL([must install xorg-macros 1.2 or later before running autoconf/autogen])])
+-XORG_MACROS_VERSION(1.2)
++# Require X.Org macros 1.8 or later for MAN_SUBSTS set by XORG_MANPAGE_SECTIONS
++m4_ifndef([XORG_MACROS_VERSION],
++ [m4_fatal([must install xorg-macros 1.8 or later before running autoconf/autogen])])
++XORG_MACROS_VERSION(1.8)
++XORG_DEFAULT_OPTIONS
+
+-# Checks for programs.
++# Initialize libtool
+ AC_DISABLE_STATIC
+ AC_PROG_LIBTOOL
+-AC_PROG_CC
+-XORG_CWARNFLAGS
+
+ AH_TOP([#include "xorg-server.h"])
+
++# Define a configure option for an alternate module directory
+ AC_ARG_WITH(xorg-module-dir,
+- AC_HELP_STRING([--with-xorg-module-dir=DIR],
++ AS_HELP_STRING([--with-xorg-module-dir=DIR],
+ [Default xorg module directory [[default=$libdir/xorg/modules]]]),
+ [moduledir="$withval"],
+ [moduledir="$libdir/xorg/modules"])
+
+-# Checks for extensions
++# Store the list of server defined optional extensions in REQUIRED_MODULES
+ XORG_DRIVER_CHECK_EXT(RANDR, randrproto)
+ XORG_DRIVER_CHECK_EXT(RENDER, renderproto)
+ XORG_DRIVER_CHECK_EXT(XV, videoproto)
+ XORG_DRIVER_CHECK_EXT(DPMSExtension, xextproto)
+
+-# Checks for pkg-config packages
++# Obtain compiler/linker options for the driver dependencies
+ PKG_CHECK_MODULES(XORG, [xorg-server >= 1.4 xproto fontsproto $REQUIRED_MODULES])
+-sdkdir=$(pkg-config --variable=sdkdir xorg-server)
+
+ # Checks for libraries.
+ SAVE_CPPFLAGS="$CPPFLAGS"
+@@ -78,21 +78,15 @@ if test "x$XSERVER_LIBPCIACCESS" = xyes; then
+ fi
+ AM_CONDITIONAL(XSERVER_LIBPCIACCESS, test "x$XSERVER_LIBPCIACCESS" = xyes)
+
+-# Checks for header files.
+-AC_HEADER_STDC
+
+-AC_SUBST([XORG_CFLAGS])
+ AC_SUBST([moduledir])
+
+ DRIVER_NAME=cirrus
+ AC_SUBST([DRIVER_NAME])
+
+-XORG_MANPAGE_SECTIONS
+-XORG_RELEASE_VERSION
+-XORG_CHANGELOG
+-
+-AC_OUTPUT([
+- Makefile
+- src/Makefile
+- man/Makefile
++AC_CONFIG_FILES([
++ Makefile
++ src/Makefile
++ man/Makefile
+ ])
++AC_OUTPUT
+diff --git a/man/Makefile.am b/man/Makefile.am
+index f0eb29b..1ea26b3 100644
+--- a/man/Makefile.am
++++ b/man/Makefile.am
+@@ -1,28 +1,25 @@
+ #
+-# Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+-#
+-# Permission to use, copy, modify, distribute, and sell this software and its
+-# documentation for any purpose is hereby granted without fee, provided that
+-# the above copyright notice appear in all copies and that both that
+-# copyright notice and this permission notice appear in supporting
+-# documentation.
+-#
+-# 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 THE OPEN GROUP 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.
+-#
+-# Except as contained in this notice, the name of the copyright holders shall
+-# not be used in advertising or otherwise to promote the sale, use or
+-# other dealings in this Software without prior written authorization
+-# from the copyright holders.
+-#
++# Copyright (c) 2005, Oracle and/or its affiliates. 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 (including the next
++# paragraph) 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
++# THE AUTHORS OR COPYRIGHT HOLDERS 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.
++#
+
+ drivermandir = $(DRIVER_MAN_DIR)
+
+@@ -34,25 +31,11 @@ EXTRA_DIST = @DRIVER_NAME@.man
+
+ CLEANFILES = $(driverman_DATA)
+
+-SED = sed
+
+-# Strings to replace in man pages
+-XORGRELSTRING = @PACKAGE_STRING@
+- XORGMANNAME = X Version 11
++# String replacements in MAN_SUBSTS now come from xorg-macros.m4 via configure
+
+-MAN_SUBSTS = \
+- -e 's|__vendorversion__|"$(XORGRELSTRING)" "$(XORGMANNAME)"|' \
+- -e 's|__xorgversion__|"$(XORGRELSTRING)" "$(XORGMANNAME)"|' \
+- -e 's|__xservername__|Xorg|g' \
+- -e 's|__xconfigfile__|xorg.conf|g' \
+- -e 's|__projectroot__|$(prefix)|g' \
+- -e 's|__appmansuffix__|$(APP_MAN_SUFFIX)|g' \
+- -e 's|__drivermansuffix__|$(DRIVER_MAN_SUFFIX)|g' \
+- -e 's|__adminmansuffix__|$(ADMIN_MAN_SUFFIX)|g' \
+- -e 's|__miscmansuffix__|$(MISC_MAN_SUFFIX)|g' \
+- -e 's|__filemansuffix__|$(FILE_MAN_SUFFIX)|g'
+
+ SUFFIXES = .$(DRIVER_MAN_SUFFIX) .man
+
+ .man.$(DRIVER_MAN_SUFFIX):
+- sed $(MAN_SUBSTS) < $< > $@
++ $(AM_V_GEN)$(SED) $(MAN_SUBSTS) < $< > $@
+diff --git a/man/cirrus.man b/man/cirrus.man
+index 009011e..af46248 100644
+--- a/man/cirrus.man
++++ b/man/cirrus.man
+@@ -1,4 +1,3 @@
+-.\" $XFree86: xc/programs/Xserver/hw/xfree86/drivers/cirrus/cirrus.man,v 1.2 2001/01/27 18:20:47 dawes Exp $
+ .\" shorthand for double quote that works everywhere.
+ .ds q \N'34'
+ .TH CIRRUS __drivermansuffix__ __vendorversion__
+diff --git a/src/CirrusClk.c b/src/CirrusClk.c
+index a3590c9..6fd6270 100644
+--- a/src/CirrusClk.c
++++ b/src/CirrusClk.c
+@@ -1,5 +1,3 @@
+-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/cirrus/CirrusClk.c,v 1.8 1998/12/06 06:08:28 dawes Exp $ */
+-
+ #ifdef HAVE_CONFIG_H
+ #include "config.h"
+ #endif
+diff --git a/src/alp.h b/src/alp.h
+index 01c5301..a182d0c 100644
+--- a/src/alp.h
++++ b/src/alp.h
+@@ -1,5 +1,3 @@
+-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/cirrus/alp.h,v 1.8 2001/10/01 13:44:05 eich Exp $ */
+-
+ /* (c) Itai Nahshon */
+
+ #ifndef ALP_H
+diff --git a/src/alp_driver.c b/src/alp_driver.c
+index fe81757..d3d8e4f 100644
+--- a/src/alp_driver.c
++++ b/src/alp_driver.c
+@@ -15,8 +15,6 @@
+ #include "config.h"
+ #endif
+
+-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/cirrus/alp_driver.c,v 1.35 2003/11/03 05:11:09 tsi Exp $ */
+-
+ /* All drivers should typically include these */
+ #include "xf86.h"
+ #include "xf86_OSproc.h"
+@@ -29,6 +27,10 @@
+ /* Drivers for PCI hardware need this */
+ #include "xf86PciInfo.h"
+
++#ifndef PCI_CHIP_GD7556 /* for old xf86PciInfo.h */
++#define PCI_CHIP_GD7556 0x004C
++#endif
++
+ /* Drivers that need to access the PCI config space directly need this */
+ #include "xf86Pci.h"
+
+@@ -119,6 +121,11 @@ static void AlpOffscreenAccelInit(ScrnInfoPtr pScrn);
+ static void AlpDisplayPowerManagementSet(ScrnInfoPtr pScrn,
+ int PowerManagementMode, int flags);
+
++#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 12
++static void PC98CIRRUS755xEnable(ScrnInfoPtr pScrn);
++static void PC98CIRRUS755xDisable(ScrnInfoPtr pScrn);
++#endif
++
+ /*
+ * This is intentionally screen-independent. It indicates the binding
+ * choice made in the first PreInit.
+@@ -153,6 +160,8 @@ static int gd5430_MaxClocks[] = { 85500, 85500, 50000, 28500, 0 };
+ static int gd5446_MaxClocks[] = { 135100, 135100, 85500, 85500, 0 };
+ static int gd5480_MaxClocks[] = { 135100, 200000, 200000, 135100, 135100 };
+ static int gd7548_MaxClocks[] = { 80100, 80100, 80100, 80100, 80100 };
++static int gd7555_MaxClocks[] = { 80100, 80100, 80100, 80100, 80100 };
++static int gd7556_MaxClocks[] = { 80100, 80100, 80100, 80100, 80100 };
+
+ #ifdef XFree86LOADER
+
+@@ -248,7 +257,7 @@ AlpFreeRec(ScrnInfoPtr pScrn)
+ {
+ if (pScrn->driverPrivate == NULL)
+ return;
+- xfree(pScrn->driverPrivate);
++ free(pScrn->driverPrivate);
+ pScrn->driverPrivate = NULL;
+ }
+
+@@ -385,6 +394,11 @@ AlpCountRam(ScrnInfoPtr pScrn)
+ break;
+ }
+ break;
++
++ case PCI_CHIP_GD7555:
++ case PCI_CHIP_GD7556:
++ videoram = 2048; /* for PC-9821 La13 etc. */
++ break;
+ }
+
+ /* UNMap the Alp memory and MMIO areas */
+@@ -407,6 +421,8 @@ GetAccelPitchValues(ScrnInfoPtr pScrn)
+ {
+ int *linePitches = NULL;
+ int i, n = 0;
++ int max_pitch;
++
+ CirPtr pCir = CIRPTR(pScrn);
+
+ /* XXX ajv - 512, 576, and 1536 may not be supported
+@@ -423,8 +439,21 @@ GetAccelPitchValues(ScrnInfoPtr pScrn)
+ 1280, 1536, 1600, 1920, 2048, 0 };
+ #endif
+
++ switch (pCir->Chipset) {
++ case PCI_CHIP_GD5436:
++ case PCI_CHIP_GD5446:
++ max_pitch = 0x1ff << 3;
++ break;
++
++ default:
++ /* FIXME max_pitch for other chipsets? */
++ max_pitch = (pScrn->bitsPerPixel / 8) * 2048;
++ break;
++ }
++
+ for (i = 0; accelWidths[i] != 0; i++) {
+- if (accelWidths[i] % pCir->Rounding == 0) {
++ if ((accelWidths[i] % pCir->Rounding == 0)
++ && ((accelWidths[i] * pScrn->bitsPerPixel / 8) <= max_pitch)) {
+ n++;
+ linePitches = xnfrealloc(linePitches, n * sizeof(int));
+ linePitches[n - 1] = accelWidths[i];
+@@ -482,12 +511,17 @@ AlpPreInit(ScrnInfoPtr pScrn, int flags)
+
+ pCir = CIRPTR(pScrn);
+ pCir->pScrn = pScrn;
++
++#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 12
+ pCir->PIOReg = hwp->PIOOffset + 0x3CE;
++#else
++ pCir->PIOReg = 0x3CE;
++#endif
+
+ /* Get the entity, and make sure it is PCI. */
+ pCir->pEnt = xf86GetEntityInfo(pScrn->entityList[0]);
+ if (pCir->pEnt->location.type != BUS_PCI) {
+- xfree(pCir->pEnt);
++ free(pCir->pEnt);
+ return FALSE;
+ }
+
+@@ -498,7 +532,8 @@ AlpPreInit(ScrnInfoPtr pScrn, int flags)
+ PCI_DEV_DEV(pCir->PciInfo),
+ PCI_DEV_FUNC(pCir->PciInfo));
+
+- if (xf86LoadSubModule(pScrn, "int10")) {
++#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 12
++ if (!xf86IsPc98() && xf86LoadSubModule(pScrn, "int10")) {
+ xf86DrvMsg(pScrn->scrnIndex,X_INFO,"initializing int10\n");
+ pInt = xf86InitInt10(pCir->pEnt->index);
+ xf86FreeInt10(pInt);
+@@ -509,8 +544,8 @@ AlpPreInit(ScrnInfoPtr pScrn, int flags)
+
+ PCI_WRITE_LONG(pCir->PciInfo, PCI_REGION_BASE(pCir->PciInfo, 0, REGION_MEM), 0x10);
+ PCI_WRITE_LONG(pCir->PciInfo, PCI_REGION_BASE(pCir->PciInfo, 1, REGION_MEM), 0x14);
+-
+ }
++#endif
+
+ /* Set pScrn->monitor */
+ pScrn->monitor = pScrn->confScreen->monitor;
+@@ -574,7 +609,7 @@ AlpPreInit(ScrnInfoPtr pScrn, int flags)
+ xf86CollectOptions(pScrn, NULL);
+
+ /* Process the options */
+- if (!(pCir->Options = xalloc(sizeof(CirOptions))))
++ if (!(pCir->Options = malloc(sizeof(CirOptions))))
+ return FALSE;
+ memcpy(pCir->Options, CirOptions, sizeof(CirOptions));
+ xf86ProcessOptions(pScrn->scrnIndex, pScrn->options, pCir->Options);
+@@ -589,6 +624,16 @@ AlpPreInit(ScrnInfoPtr pScrn, int flags)
+
+ from = X_DEFAULT;
+ pCir->HWCursor = FALSE;
++
++ switch (pCir->Chipset) {
++ case PCI_CHIP_GD7555:
++ case PCI_CHIP_GD7556:
++ pCir->HWCursor = TRUE;
++ break;
++ default:
++ break;
++ }
++
+ if (xf86GetOptValBool(pCir->Options, OPTION_HW_CURSOR, &pCir->HWCursor))
+ from = X_CONFIG;
+
+@@ -863,10 +908,10 @@ AlpPreInit(ScrnInfoPtr pScrn, int flags)
+ case PCI_CHIP_GD5430:
+ case PCI_CHIP_GD5434_4:
+ case PCI_CHIP_GD5434_8:
+- case PCI_CHIP_GD5436:
+ /* case PCI_CHIP_GD5440: */
+ p = gd5430_MaxClocks;
+ break;
++ case PCI_CHIP_GD5436:
+ case PCI_CHIP_GD5446:
+ p = gd5446_MaxClocks;
+ break;
+@@ -876,6 +921,12 @@ AlpPreInit(ScrnInfoPtr pScrn, int flags)
+ case PCI_CHIP_GD7548:
+ p = gd7548_MaxClocks;
+ break;
++ case PCI_CHIP_GD7555:
++ p = gd7555_MaxClocks;
++ break;
++ case PCI_CHIP_GD7556:
++ p = gd7556_MaxClocks;
++ break;
+ }
+ if (!p)
+ return FALSE;
+@@ -1360,6 +1411,11 @@ AlpModeInit(ScrnInfoPtr pScrn, DisplayModePtr mode)
+
+ vgaHWProtect(pScrn, FALSE);
+
++#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 12
++ if (xf86IsPc98())
++ PC98CIRRUS755xEnable(pScrn);
++#endif
++
+ return TRUE;
+ }
+
+@@ -1489,7 +1545,7 @@ AlpScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
+
+ if(pCir->shadowFB) {
+ pCir->ShadowPitch = BitmapBytePad(pScrn->bitsPerPixel * width);
+- pCir->ShadowPtr = xalloc(pCir->ShadowPitch * height);
++ pCir->ShadowPtr = malloc(pCir->ShadowPitch * height);
+ displayWidth = pCir->ShadowPitch / (pScrn->bitsPerPixel >> 3);
+ FbBase = pCir->ShadowPtr;
+ } else {
+@@ -1782,6 +1838,11 @@ AlpLeaveVT(int scrnIndex, int flags)
+
+ AlpRestore(pScrn);
+ vgaHWLock(hwp);
++
++#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 12
++ if (xf86IsPc98())
++ PC98CIRRUS755xDisable(pScrn);
++#endif
+ }
+
+
+@@ -1813,12 +1874,17 @@ AlpCloseScreen(int scrnIndex, ScreenPtr pScreen)
+ xf86DestroyCursorInfoRec(pCir->CursorInfoRec);
+ pCir->CursorInfoRec = NULL;
+ if (pCir->DGAModes)
+- xfree(pCir->DGAModes);
++ free(pCir->DGAModes);
+ pCir->DGAnumModes = 0;
+ pCir->DGAModes = NULL;
+
+ pScrn->vtSema = FALSE;
+
++#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 12
++ if (xf86IsPc98())
++ PC98CIRRUS755xDisable(pScrn);
++#endif
++
+ pScreen->CloseScreen = pCir->CloseScreen;
+ return (*pScreen->CloseScreen)(scrnIndex, pScreen);
+ }
+@@ -2081,3 +2147,53 @@ AlpOffscreenAccelInit(ScrnInfoPtr pScrn)
+ box.y2 - pScrn->virtualY);
+ }
+ }
++
++#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 12
++static void
++PC98CIRRUS755xEnable(ScrnInfoPtr pScrn) /* enter_aile() */
++{
++ unsigned int index,data;
++ vgaHWPtr hwp = VGAHWPTR(pScrn);
++
++ outb(0xfac, 0x02);
++
++ outb(0x68, 0x0e);
++ outb(0x6a, 0x07);
++ outb(0x6a, 0x8f);
++ outb(0x6a, 0x06);
++
++ outw(VGA_SEQ_INDEX, 0x1206); /* unlock cirrus special */
++
++ index = hwp->IOBase + VGA_CRTC_INDEX_OFFSET;
++ data = hwp->IOBase + VGA_CRTC_DATA_OFFSET;
++ outb(index, 0x3c);
++ outb(data, inb(data) & 0xef);
++ outb(index, 0x1a);
++ outb(data, inb(data) & 0xf3);
++}
++
++static void
++PC98CIRRUS755xDisable(ScrnInfoPtr pScrn) /* leave_aile() */
++{
++ unsigned int index,data;
++ vgaHWPtr hwp = VGAHWPTR(pScrn);
++
++ outw(VGA_SEQ_INDEX, 0x1206); /* unlock cirrus special */
++
++ index = hwp->IOBase + VGA_CRTC_INDEX_OFFSET;
++ data = hwp->IOBase + VGA_CRTC_DATA_OFFSET;
++ outb(index, 0x3c);
++ outb(data, 0x71);
++ outb(index, 0x1a);
++ outb(data, inb(data) | 0x0c);
++
++ outb(0xfac,0x00);
++
++ outb(0x68, 0x0f);
++ outb(0x6a, 0x07);
++ outb(0x6a, 0x8e);
++ outb(0x6a, 0x21);
++ outb(0x6a, 0x69);
++ outb(0x6a, 0x06);
++}
++#endif
+diff --git a/src/alp_hwcurs.c b/src/alp_hwcurs.c
+index 79dfce7..9891eb4 100644
+--- a/src/alp_hwcurs.c
++++ b/src/alp_hwcurs.c
+@@ -1,5 +1,3 @@
+-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/cirrus/alp_hwcurs.c,v 1.4 2000/12/06 15:35:15 eich Exp $ */
+-
+ #ifdef HAVE_CONFIG_H
+ #include "config.h"
+ #endif
+diff --git a/src/alp_i2c.c b/src/alp_i2c.c
+index 9e6ae67..7365215 100644
+--- a/src/alp_i2c.c
++++ b/src/alp_i2c.c
+@@ -4,8 +4,6 @@
+ #include "config.h"
+ #endif
+
+-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/cirrus/alp_i2c.c,v 1.6 1999/02/28 11:19:38 dawes Exp $ */
+-
+ #include "xf86.h"
+ #include "xf86_OSproc.h"
+ #include "compiler.h"
+diff --git a/src/alp_xaa.c b/src/alp_xaa.c
+index 95741fc..7a96e1a 100644
+--- a/src/alp_xaa.c
++++ b/src/alp_xaa.c
+@@ -4,8 +4,6 @@
+ #include "config.h"
+ #endif
+
+-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/cirrus/alp_xaa.c,v 1.7 2001/10/01 13:44:05 eich Exp $ */
+-
+ #include "xf86.h"
+ #include "xf86_OSproc.h"
+ #include "compiler.h"
+diff --git a/src/alp_xaam.c b/src/alp_xaam.c
+index 0193a43..3ecc7de 100644
+--- a/src/alp_xaam.c
++++ b/src/alp_xaam.c
+@@ -1,6 +1,5 @@
+ /* (c) Itai Nahshon */
+ /* #define DEBUG */
+-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/cirrus/alp_xaam.c,v 1.7 2001/10/01 13:44:05 eich Exp $ */
+
+ #ifdef HAVE_CONFIG_H
+ #include "config.h"
+diff --git a/src/cir.h b/src/cir.h
+index 904d9cc..861966d 100644
+--- a/src/cir.h
++++ b/src/cir.h
+@@ -1,5 +1,3 @@
+-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/cirrus/cir.h,v 1.20 2002/01/04 21:26:54 tsi Exp $ */
+-
+ /* (c) Itai Nahshon */
+
+ #ifndef CIR_H
+@@ -23,7 +21,7 @@ typedef struct {
+ CARD32 properties;
+ pciVideoPtr PciInfo;
+ PCITAG PciTag;
+- IOADDRESS PIOReg;
++ unsigned long PIOReg;
+ union {
+ struct lgRec *lg;
+ struct alpRec *alp;
+diff --git a/src/cir_dga.c b/src/cir_dga.c
+index bc98df6..f930231 100644
+--- a/src/cir_dga.c
++++ b/src/cir_dga.c
+@@ -1,4 +1,3 @@
+-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/cirrus/cir_dga.c,v 1.5 2001/02/15 17:39:27 eich Exp $ */
+ /*
+ * Copyright 2000 by Egbert Eich
+ *
+@@ -83,9 +82,9 @@ CirDGAInit(ScreenPtr pScreen)
+ if (!pCir->DGAnumModes) {
+ pMode = firstMode = pScrn->modes;
+ while (pMode) {
+- newmodes = xrealloc(modes, (num + 1) * sizeof (DGAModeRec));
++ newmodes = realloc(modes, (num + 1) * sizeof (DGAModeRec));
+ if (!newmodes) {
+- xfree(modes);
++ free(modes);
+ return FALSE;
+ }
+ modes = newmodes;
+diff --git a/src/cir_driver.c b/src/cir_driver.c
+index 5466c48..7e470bb 100644
+--- a/src/cir_driver.c
++++ b/src/cir_driver.c
+@@ -15,8 +15,6 @@
+ #include "config.h"
+ #endif
+
+-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/cirrus/cir_driver.c,v 1.67 2001/05/15 10:19:37 eich Exp $ */
+-
+ /* All drivers should typically include these */
+ #include "xf86.h"
+ #include "xf86_OSproc.h"
+@@ -29,6 +27,10 @@
+ /* Drivers for PCI hardware need this */
+ #include "xf86PciInfo.h"
+
++#ifndef PCI_CHIP_GD7556 /* for old xf86PciInfo.h */
++#define PCI_CHIP_GD7556 0x004C
++#endif
++
+ /* Drivers that need to access the PCI config space directly need this */
+ #include "xf86Pci.h"
+
+@@ -90,6 +92,8 @@ SymTabRec CIRChipsets[] = {
+ { PCI_CHIP_GD5464BD, "CL-GD5464BD" },
+ { PCI_CHIP_GD5465, "CL-GD5465" },
+ { PCI_CHIP_GD7548, "CL-GD7548" },
++ { PCI_CHIP_GD7555, "CL-GD7555" },
++ { PCI_CHIP_GD7556, "CL-GD7556" },
+ {-1, NULL }
+ };
+
+@@ -107,6 +111,8 @@ _X_EXPORT PciChipsets CIRPciChipsets[] = {
+ { PCI_CHIP_GD5464BD,PCI_CHIP_GD5464BD, RES_SHARED_VGA },
+ { PCI_CHIP_GD5465, PCI_CHIP_GD5465, RES_SHARED_VGA },
+ { PCI_CHIP_GD7548, PCI_CHIP_GD7548, RES_SHARED_VGA },
++ { PCI_CHIP_GD7555, PCI_CHIP_GD7555, RES_SHARED_VGA },
++ { PCI_CHIP_GD7556, PCI_CHIP_GD7556, RES_SHARED_VGA },
+ { -1, -1, RES_UNDEFINED}
+ };
+
+@@ -238,7 +244,7 @@ CIRProbe(DriverPtr drv, int flags)
+ CIRChipsets, CIRPciChipsets, devSections,
+ numDevSections, drv, &usedChips);
+ /* Free it since we don't need that list after this */
+- xfree(devSections);
++ free(devSections);
+ if (numUsed <= 0)
+ return FALSE;
+ if (flags & PROBE_DETECT)
+@@ -280,7 +286,7 @@ CIRProbe(DriverPtr drv, int flags)
+ pScrn->Probe = NULL;
+ }
+ }
+- xfree(usedChips);
++ free(usedChips);
+
+ return foundScreen;
+ }
+diff --git a/src/cir_pcirename.h b/src/cir_pcirename.h
+index f0f5cf8..669b8fe 100644
+--- a/src/cir_pcirename.h
++++ b/src/cir_pcirename.h
+@@ -34,6 +34,33 @@ enum region_type {
+ REGION_IO
+ };
+
++#include "xf86Module.h"
++
++#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) >= 12
++
++#if (defined(__alpha__) || defined(__ia64__)) && defined (linux)
++#define PCI_DOM_MASK 0x01fful
++#else
++#define PCI_DOM_MASK 0x0ffu
++#endif
++
++#ifndef PCI_DOM_MASK
++# define PCI_DOM_MASK 0x0ffu
++#endif
++#define PCI_DOMBUS_MASK (((PCI_DOM_MASK) << 8) | 0x0ffu)
++
++static inline uint32_t
++pciTag(int busnum, int devnum, int funcnum)
++{
++ uint32_t tag;
++ tag = (busnum & (PCI_DOMBUS_MASK)) << 16;
++ tag |= (devnum & 0x00001fu) << 11;
++ tag |= (funcnum & 0x000007u) << 8;
++
++ return tag;
++}
++#endif /* GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) >= 12 */
++
+ #ifndef XSERVER_LIBPCIACCESS
+
+ /* pciVideoPtr */
+diff --git a/src/cir_shadow.c b/src/cir_shadow.c
+index b89890a..0716a64 100644
+--- a/src/cir_shadow.c
++++ b/src/cir_shadow.c
+@@ -1,5 +1,3 @@
+-/* $XFree86: Exp $ */
+-
+ /*
+ Copyright (c) 1999,2000 The XFree86 Project Inc.
+ based on code written by Mark Vojkovich <markv@valinux.com>
+diff --git a/src/lg.h b/src/lg.h
+index 9d91053..985f634 100644
+--- a/src/lg.h
++++ b/src/lg.h
+@@ -10,8 +10,6 @@
+ * Inspired by cir.h
+ */
+
+-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/cirrus/lg.h,v 1.12 2001/05/04 19:05:36 dawes Exp $ */
+-
+ #ifndef LG_H
+ #define LG_H
+ #define LG_DEBUG
+diff --git a/src/lg_driver.c b/src/lg_driver.c
+index cfc3e65..fc864f8 100644
+--- a/src/lg_driver.c
++++ b/src/lg_driver.c
+@@ -13,7 +13,6 @@
+ * David Dawes, Andrew E. Mileski, Leonard N. Zubkoff,
+ * Guy DESBIEF, Itai Nahshon.
+ */
+-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/cirrus/lg_driver.c,v 1.49 2003/11/03 05:11:09 tsi Exp $ */
+
+ #ifdef HAVE_CONFIG_H
+ #include "config.h"
+@@ -259,7 +258,7 @@ LgFreeRec(ScrnInfoPtr pScrn)
+ {
+ if (pScrn->driverPrivate == NULL)
+ return;
+- xfree(pScrn->driverPrivate);
++ free(pScrn->driverPrivate);
+ pScrn->driverPrivate = NULL;
+ }
+
+@@ -373,7 +372,12 @@ LgPreInit(ScrnInfoPtr pScrn, int flags)
+
+ pCir = CIRPTR(pScrn);
+ pCir->pScrn = pScrn;
++
++#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 12
+ pCir->PIOReg = hwp->PIOOffset + 0x3CE;
++#else
++ pCir->PIOReg = 0x3CE;
++#endif
+
+ /* Get the entity, and make sure it is PCI. */
+ pCir->pEnt = xf86GetEntityInfo(pScrn->entityList[0]);
+@@ -454,7 +458,7 @@ LgPreInit(ScrnInfoPtr pScrn, int flags)
+ xf86CollectOptions(pScrn, NULL);
+
+ /* Process the options */
+- if (!(pCir->Options = xalloc(sizeof(LgOptions))))
++ if (!(pCir->Options = malloc(sizeof(LgOptions))))
+ return FALSE;
+ memcpy(pCir->Options, LgOptions, sizeof(LgOptions));
+ xf86ProcessOptions(pScrn->scrnIndex, pScrn->options, pCir->Options);
+@@ -1314,7 +1318,7 @@ LgScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
+
+ if(pCir->shadowFB) {
+ pCir->ShadowPitch = BitmapBytePad(pScrn->bitsPerPixel * width);
+- pCir->ShadowPtr = xalloc(pCir->ShadowPitch * height);
++ pCir->ShadowPtr = malloc(pCir->ShadowPitch * height);
+ displayWidth = pCir->ShadowPitch / (pScrn->bitsPerPixel >> 3);
+ FbBase = pCir->ShadowPtr;
+ } else {
+@@ -1617,7 +1621,7 @@ LgCloseScreen(int scrnIndex, ScreenPtr pScreen)
+ xf86DestroyCursorInfoRec(pCir->CursorInfoRec);
+ pCir->CursorInfoRec = NULL;
+ if (pCir->DGAModes)
+- xfree(pCir->DGAModes);
++ free(pCir->DGAModes);
+ pCir->DGAnumModes = 0;
+ pCir->DGAModes = NULL;
+
+diff --git a/src/lg_hwcurs.c b/src/lg_hwcurs.c
+index b41b79a..381db1c 100644
+--- a/src/lg_hwcurs.c
++++ b/src/lg_hwcurs.c
+@@ -10,7 +10,6 @@
+ * Much of this code is inspired by the HW cursor code from XFree86
+ * 3.3.3.
+ */
+-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/cirrus/lg_hwcurs.c,v 1.4 2000/12/06 15:35:17 eich Exp $ */
+
+ #ifdef HAVE_CONFIG_H
+ #include "config.h"
+diff --git a/src/lg_i2c.c b/src/lg_i2c.c
+index 05e083c..145cc2e 100644
+--- a/src/lg_i2c.c
++++ b/src/lg_i2c.c
+@@ -1,7 +1,5 @@
+ /* (c) Itai Nahshon */
+
+-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/cirrus/lg_i2c.c,v 1.1 1998/11/15 04:30:25 dawes Exp $ */
+-
+ #ifdef HAVE_CONFIG_H
+ #include "config.h"
+ #endif
+diff --git a/src/lg_xaa.c b/src/lg_xaa.c
+index fd8c70a..8bab365 100644
+--- a/src/lg_xaa.c
++++ b/src/lg_xaa.c
+@@ -10,7 +10,6 @@
+ * Much of this code is inspired by the XAA acceleration from XFree86
+ * 3.3.3, laguna_acl.c
+ */
+-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/cirrus/lg_xaa.c,v 1.4 2000/12/06 15:35:17 eich Exp $ */
+
+ #ifdef HAVE_CONFIG_H
+ #include "config.h"
+diff --git a/src/lg_xaa.h b/src/lg_xaa.h
+index 7359a49..162aa5d 100644
+--- a/src/lg_xaa.h
++++ b/src/lg_xaa.h
+@@ -13,7 +13,6 @@
+ * This header file draws much from the file cir_blitLG.h in version 3.3.3
+ * of XFree86.
+ */
+-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/cirrus/lg_xaa.h,v 1.3 2000/02/08 13:13:15 eich Exp $ */
+
+ /* This header file defines the necessary structures, contstants, and
+ variables for using the bitBLT engine on a Laguna family graphics
diff --git a/extra/xf86-video-dummy/PKGBUILD b/extra/xf86-video-dummy/PKGBUILD
index 9e065565c..dbea9727e 100644
--- a/extra/xf86-video-dummy/PKGBUILD
+++ b/extra/xf86-video-dummy/PKGBUILD
@@ -1,25 +1,29 @@
-# $Id: PKGBUILD 140338 2011-10-11 21:29:27Z jgc $
+# $Id: PKGBUILD 153331 2012-03-12 20:53:23Z andyrtr $
#Maintainer: Jan de Groot <jgc@archlinux.org>
pkgname=xf86-video-dummy
-pkgver=0.3.4
-pkgrel=5
+pkgver=0.3.5
+pkgrel=1
pkgdesc="X.org dummy video driver"
arch=(i686 x86_64)
url="http://xorg.freedesktop.org/"
license=('custom')
depends=('glibc')
-makedepends=('xorg-server-devel>=1.10.99.902' 'xf86dgaproto')
-conflicts=('xorg-server<1.10.99.902')
+makedepends=('xorg-server-devel>=1.11.99.903' 'xf86dgaproto')
+conflicts=('xorg-server<1.11.99.903')
groups=('xorg-drivers' 'xorg')
options=('!libtool')
source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2)
-sha1sums=('876ed7165ea2821bbddd73232a1ce0b79c1f14ff')
+sha1sums=('41cfcaec986ab13e931d260953c5a3f626fd1d2b')
build() {
cd "${srcdir}/${pkgname}-${pkgver}"
./configure --prefix=/usr
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/extra/xf86-video-fbdev/PKGBUILD b/extra/xf86-video-fbdev/PKGBUILD
index ebef4fe1c..a42599a23 100644
--- a/extra/xf86-video-fbdev/PKGBUILD
+++ b/extra/xf86-video-fbdev/PKGBUILD
@@ -1,16 +1,16 @@
-# $Id: PKGBUILD 140336 2011-10-11 21:29:25Z jgc $
+# $Id: PKGBUILD 153333 2012-03-12 20:53:25Z andyrtr $
#Maintainer: Jan de Groot <jgc@archlinux.org>
pkgname=xf86-video-fbdev
pkgver=0.4.2
-pkgrel=5
+pkgrel=6
pkgdesc="X.org framebuffer video driver"
arch=(i686 x86_64)
license=('custom')
url="http://xorg.freedesktop.org/"
depends=('glibc')
-makedepends=('xorg-server-devel>=1.10.99.902')
-conflicts=('xorg-server<1.10.99.902')
+makedepends=('xorg-server-devel>=1.11.99.903')
+conflicts=('xorg-server<1.11.99.903')
groups=('xorg-drivers' 'xorg')
options=('!libtool')
source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2)
@@ -20,6 +20,10 @@ build() {
cd "${srcdir}/${pkgname}-${pkgver}"
./configure --prefix=/usr
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/extra/xf86-video-glint/PKGBUILD b/extra/xf86-video-glint/PKGBUILD
index 0566ff9b6..1bb95b86e 100644
--- a/extra/xf86-video-glint/PKGBUILD
+++ b/extra/xf86-video-glint/PKGBUILD
@@ -1,25 +1,29 @@
-# $Id: PKGBUILD 140334 2011-10-11 21:29:22Z jgc $
+# $Id: PKGBUILD 153336 2012-03-12 20:53:29Z andyrtr $
# Maintainer: Jan de Groot <jgc@archlinux.org>
pkgname=xf86-video-glint
-pkgver=1.2.6
+pkgver=1.2.7
pkgrel=1
pkgdesc="X.org GLINT/Permedia video driver"
arch=(i686 x86_64)
url="http://xorg.freedesktop.org/"
license=('custom')
depends=('glibc')
-makedepends=('xorg-server-devel>=1.11.0' 'xf86dgaproto')
-conflicts=('xorg-server<1.11.0')
+makedepends=('xorg-server-devel>=1.11.99.903' 'xf86dgaproto')
+conflicts=('xorg-server<1.11.99.903')
options=('!libtool')
groups=('xorg-drivers' 'xorg')
source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2)
-sha256sums=('d43350ed3c149576db1dbcacf5e9a30a3268a3f49742724c9151b6f1e4bd21a7')
+sha256sums=('9aa9689436fc78a71145d4caeaf63b0e80f9abd54e9b4a3066f62ee5b334c359')
build() {
cd "${srcdir}/${pkgname}-${pkgver}"
./configure --prefix=/usr
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/extra/xf86-video-i128/PKGBUILD b/extra/xf86-video-i128/PKGBUILD
index 7c63f8002..c4a961180 100644
--- a/extra/xf86-video-i128/PKGBUILD
+++ b/extra/xf86-video-i128/PKGBUILD
@@ -1,25 +1,32 @@
-# $Id: PKGBUILD 140332 2011-10-11 21:29:18Z jgc $
+# $Id: PKGBUILD 153338 2012-03-12 20:53:31Z andyrtr $
# Maintainer:Jan de Groot <jgc@archlinux.org>
pkgname=xf86-video-i128
pkgver=1.3.4
-pkgrel=4
+pkgrel=5
pkgdesc="X.org Number 9 I128 video driver"
arch=(i686 x86_64)
url="http://xorg.freedesktop.org/"
license=('custom')
depends=('glibc')
-makedepends=('xorg-server-devel>=1.10.99.902')
-conflicts=('xorg-server<1.10.99.902')
+makedepends=('xorg-server-devel>=1.11.99.903')
+conflicts=('xorg-server<1.11.99.903')
groups=('xorg-drivers' 'xorg')
options=('!libtool')
-source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2)
-sha1sums=('d5f755dc964eaa067b4efcafafd00814a60df775')
+source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2
+ i128-1.3.4-git.patch)
+sha1sums=('d5f755dc964eaa067b4efcafafd00814a60df775'
+ 'c282f9de94ef7225f03034c9c07f40f46bd44bdc')
build() {
cd "${srcdir}/${pkgname}-${pkgver}"
+ patch -Np1 -i ${srcdir}/i128-1.3.4-git.patch
./configure --prefix=/usr
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/extra/xf86-video-i128/i128-1.3.4-git.patch b/extra/xf86-video-i128/i128-1.3.4-git.patch
new file mode 100644
index 000000000..581ed7bb7
--- /dev/null
+++ b/extra/xf86-video-i128/i128-1.3.4-git.patch
@@ -0,0 +1,173 @@
+diff --git a/man/i128.man b/man/i128.man
+index 920d2ab..a8e2e54 100644
+--- a/man/i128.man
++++ b/man/i128.man
+@@ -1,4 +1,3 @@
+-.\" $XFree86: xc/programs/Xserver/hw/xfree86/drivers/i128/i128.man,v 1.2 2001/01/27 18:20:48 dawes Exp $
+ .\" shorthand for double quote that works everywhere.
+ .ds q \N'34'
+ .TH I128 __drivermansuffix__ __vendorversion__
+diff --git a/src/i128_driver.c b/src/i128_driver.c
+index 903a3a8..92f9d58 100644
+--- a/src/i128_driver.c
++++ b/src/i128_driver.c
+@@ -304,13 +304,13 @@ I128Probe(DriverPtr drv, int flags)
+ numDevSections, drv, &usedChips);
+
+ /* Free it since we don't need that list after this */
+- xfree(devSections);
++ free(devSections);
+
+ if (numUsed <= 0)
+ return FALSE;
+
+ if (flags & PROBE_DETECT) {
+- xfree(usedChips);
++ free(usedChips);
+ return FALSE;
+ }
+
+@@ -340,7 +340,7 @@ I128Probe(DriverPtr drv, int flags)
+ foundScreen = TRUE;
+ }
+
+- xfree(usedChips);
++ free(usedChips);
+
+ return foundScreen;
+ }
+@@ -446,7 +446,7 @@ I128PreInit(ScrnInfoPtr pScrn, int flags)
+ int i;
+ ClockRangePtr clockRanges;
+ MessageType from;
+- IOADDRESS iobase;
++ unsigned long iobase;
+ char *ramdac = NULL;
+ CARD32 tmpl, tmph, tmp;
+ unsigned char n, m, p, mdc, df;
+@@ -558,7 +558,7 @@ I128PreInit(ScrnInfoPtr pScrn, int flags)
+ xf86CollectOptions(pScrn, NULL);
+
+ /* Process the options */
+- if (!(pI128->Options = xalloc(sizeof(I128Options))))
++ if (!(pI128->Options = malloc(sizeof(I128Options))))
+ return FALSE;
+ memcpy(pI128->Options, I128Options, sizeof(I128Options));
+ xf86ProcessOptions(pScrn->scrnIndex, pScrn->options, pI128->Options);
+@@ -650,7 +650,10 @@ I128PreInit(ScrnInfoPtr pScrn, int flags)
+ xf86DrvMsg(pScrn->scrnIndex, from, "Subsystem Vendor: \"%x\"\n",
+ PCI_SUB_VENDOR_ID(pI128->PciInfo));
+
+- iobase = (PCI_REGION_BASE(pI128->PciInfo, 5, REGION_IO) & 0xFFFFFF00) + hwp->PIOOffset;
++ iobase = (PCI_REGION_BASE(pI128->PciInfo, 5, REGION_IO) & 0xFFFFFF00);
++#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 12
++ iobase += hwp->PIOOffset;
++#endif
+ pI128->RegRec.iobase = iobase;
+
+ pI128->io.rbase_g = inl(iobase) & 0xFFFFFF00;
+@@ -1157,7 +1160,7 @@ I128FreeRec(ScrnInfoPtr pScrn)
+ {
+ if (pScrn->driverPrivate == NULL)
+ return;
+- xfree(pScrn->driverPrivate);
++ free(pScrn->driverPrivate);
+ pScrn->driverPrivate = NULL;
+ }
+
+@@ -1704,12 +1707,12 @@ I128CloseScreen(int scrnIndex, ScreenPtr pScreen)
+ XAADestroyInfoRec(pI128->XaaInfoRec);
+ if (pI128->ExaDriver) {
+ exaDriverFini(pScreen);
+- xfree(pI128->ExaDriver);
++ free(pI128->ExaDriver);
+ }
+ if (pI128->CursorInfoRec)
+ xf86DestroyCursorInfoRec(pI128->CursorInfoRec);
+ if (pI128->DGAModes)
+- xfree(pI128->DGAModes);
++ free(pI128->DGAModes);
+ pScrn->vtSema = FALSE;
+
+ pScreen->CloseScreen = pI128->CloseScreen;
+@@ -1804,7 +1807,7 @@ I128DDC1Read(ScrnInfoPtr pScrn)
+ I128Ptr pI128 = I128PTR(pScrn);
+ unsigned char val;
+ unsigned long tmp, ddc;
+- IOADDRESS iobase;
++ unsigned long iobase;
+
+ iobase = pI128->RegRec.iobase;
+ ddc = inl(iobase + 0x2C);
+@@ -1839,7 +1842,7 @@ I128I2CGetBits(I2CBusPtr b, int *clock, int *data)
+ {
+ I128Ptr pI128 = I128PTR(xf86Screens[b->scrnIndex]);
+ unsigned long ddc;
+- IOADDRESS iobase;
++ unsigned long iobase;
+ #if 0
+ static int lastclock = -1, lastdata = -1;
+ #endif
+@@ -1867,7 +1870,7 @@ I128I2CPutBits(I2CBusPtr b, int clock, int data)
+ unsigned char drv, val;
+ unsigned long ddc;
+ unsigned long tmp;
+- IOADDRESS iobase;
++ unsigned long iobase;
+
+ iobase = pI128->RegRec.iobase;
+ ddc = inl(iobase + 0x2C);
+@@ -1889,7 +1892,7 @@ I128I2CInit(ScrnInfoPtr pScrn)
+ {
+ I128Ptr pI128 = I128PTR(pScrn);
+ I2CBusPtr I2CPtr;
+- IOADDRESS iobase;
++ unsigned long iobase;
+ unsigned long soft_sw, ddc;
+
+ I2CPtr = xf86CreateI2CBusRec();
+@@ -2102,7 +2105,7 @@ void
+ I128DumpActiveRegisters(ScrnInfoPtr pScrn)
+ {
+ I128Ptr pI128 = I128PTR(pScrn);
+- IOADDRESS iobase;
++ unsigned long iobase;
+ unsigned long rbase_g, rbase_w, rbase_a, rbase_b, rbase_i, rbase_e;
+ unsigned long id, config1, config2, sgram, soft_sw, ddc, vga_ctl;
+ volatile CARD32 *vrba, *vrbg, *vrbw;
+diff --git a/src/i128dga.c b/src/i128dga.c
+index 48823aa..8bc2fcb 100644
+--- a/src/i128dga.c
++++ b/src/i128dga.c
+@@ -59,15 +59,15 @@ I128DGAInit(ScreenPtr pScreen)
+ while(pMode) {
+
+ if(0 /*pScrn->displayWidth != pMode->HDisplay*/) {
+- newmodes = xrealloc(modes, (num + 2) * sizeof(DGAModeRec));
++ newmodes = realloc(modes, (num + 2) * sizeof(DGAModeRec));
+ oneMore = TRUE;
+ } else {
+- newmodes = xrealloc(modes, (num + 1) * sizeof(DGAModeRec));
++ newmodes = realloc(modes, (num + 1) * sizeof(DGAModeRec));
+ oneMore = FALSE;
+ }
+
+ if(!newmodes) {
+- xfree(modes);
++ free(modes);
+ return FALSE;
+ }
+ modes = newmodes;
+diff --git a/src/i128reg.h b/src/i128reg.h
+index 56b9c33..a72b525 100644
+--- a/src/i128reg.h
++++ b/src/i128reg.h
+@@ -75,7 +75,7 @@ struct i128mem {
+
+ /* save the registers needed for restoration in this structure */
+ typedef struct {
+- IOADDRESS iobase; /* saved only for iobase indexing */
++ unsigned long iobase; /* saved only for iobase indexing */
+ CARD32 config1; /* iobase+0x1C register */
+ CARD32 config2; /* iobase+0x20 register */
+ CARD32 sgram; /* iobase+0x24 register */
diff --git a/extra/xf86-video-i740/PKGBUILD b/extra/xf86-video-i740/PKGBUILD
index 615e7106c..04217ad7e 100644
--- a/extra/xf86-video-i740/PKGBUILD
+++ b/extra/xf86-video-i740/PKGBUILD
@@ -1,16 +1,16 @@
-# $Id: PKGBUILD 140330 2011-10-11 21:29:14Z jgc $
+# $Id: PKGBUILD 153340 2012-03-12 20:53:33Z andyrtr $
#Maintainer: Jan de Groot <jgc@archlinux.org>
pkgname=xf86-video-i740
pkgver=1.3.2
-pkgrel=7
+pkgrel=8
pkgdesc="X.org Intel i740 video driver"
arch=(i686 x86_64)
url="http://xorg.freedesktop.org/"
license=('custom')
depends=('glibc')
-makedepends=('xorg-server-devel>=1.10.99.902')
-conflicts=('xorg-server<1.10.99.902')
+makedepends=('xorg-server-devel>=1.11.99.903')
+conflicts=('xorg-server<1.11.99.903')
groups=('xorg-drivers' 'xorg')
options=('!libtool')
source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2)
@@ -20,6 +20,10 @@ build() {
cd "${srcdir}/${pkgname}-${pkgver}"
./configure --prefix=/usr
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/extra/xf86-video-intel/PKGBUILD b/extra/xf86-video-intel/PKGBUILD
index 2d96a4ec0..ca1e15eb0 100644
--- a/extra/xf86-video-intel/PKGBUILD
+++ b/extra/xf86-video-intel/PKGBUILD
@@ -1,24 +1,23 @@
-# $Id: PKGBUILD 144437 2011-12-05 19:49:35Z andyrtr $
+# $Id: PKGBUILD 153342 2012-03-12 20:53:36Z andyrtr $
# Maintainer: Jan de Groot <jgc@archlinux.org>
pkgname=xf86-video-intel
-pkgver=2.17.0
-pkgrel=2
+pkgver=2.18.0
+pkgrel=1
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')
-makedepends=('xorg-server-devel>=1.10.99.902' 'libx11' 'libdrm' 'xf86driproto' 'glproto' 'mesa' 'libxvmc' 'libxrender')
-conflicts=('xorg-server<1.10.99.902' 'xf86-video-i810' 'xf86-video-intel-legacy')
+makedepends=('xorg-server-devel>=1.11.99.903' 'libx11' 'libdrm' 'xf86driproto' 'glproto' 'mesa' 'libxvmc' 'libxrender')
+conflicts=('xorg-server<1.11.99.903' 'xf86-video-i810' 'xf86-video-intel-legacy')
options=('!libtool')
groups=('xorg-drivers' 'xorg')
source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2)
-sha1sums=('04ad9fa1f4c4e0a90f48752a709bf14700c864af')
+sha1sums=('77fae98e73414140bf214dca5da32bcf079c4463')
build() {
cd "${srcdir}/${pkgname}-${pkgver}"
-
./configure --prefix=/usr --enable-dri
make
}
diff --git a/extra/xf86-video-mach64/PKGBUILD b/extra/xf86-video-mach64/PKGBUILD
index 2cbfb8b9f..2f8f5631b 100644
--- a/extra/xf86-video-mach64/PKGBUILD
+++ b/extra/xf86-video-mach64/PKGBUILD
@@ -1,16 +1,16 @@
-# $Id: PKGBUILD 140326 2011-10-11 21:29:07Z jgc $
+# $Id: PKGBUILD 153344 2012-03-12 20:53:38Z andyrtr $
# Maintainer: Jan de Groot <jgc@archlinux.org>
pkgname=xf86-video-mach64
pkgver=6.9.0
-pkgrel=2
+pkgrel=3
pkgdesc="X.org mach64 video driver"
arch=(i686 x86_64)
url="http://xorg.freedesktop.org/"
license=('custom')
-depends=('glibc' 'mach64-dri')
-makedepends=('xorg-server-devel>=1.10.99.902' 'libdrm' 'xf86driproto' 'mesa' 'glproto')
-conflicts=('xorg-server<1.10.99.902')
+depends=('glibc')
+makedepends=('xorg-server-devel>=1.11.99.903' 'libdrm' 'xf86driproto' 'mesa>=8.0') # 'glproto')
+conflicts=('xorg-server<1.11.99.903')
groups=('xorg-drivers' 'xorg')
options=('!libtool')
source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2)
@@ -18,7 +18,7 @@ sha1sums=('95a7ec9761fe11dadbcd9078c55148198a91b2f1')
build() {
cd "${srcdir}/${pkgname}-${pkgver}"
- ./configure --prefix=/usr --enable-dri
+ ./configure --prefix=/usr #--enable-dri
make
}
diff --git a/extra/xf86-video-mga/PKGBUILD b/extra/xf86-video-mga/PKGBUILD
index 8b4289add..de2dec7d5 100644
--- a/extra/xf86-video-mga/PKGBUILD
+++ b/extra/xf86-video-mga/PKGBUILD
@@ -1,16 +1,16 @@
-# $Id: PKGBUILD 140324 2011-10-11 21:29:03Z jgc $
+# $Id: PKGBUILD 153346 2012-03-12 20:53:41Z andyrtr $
# Maintainer: Jan de Groot <jgc@archlinux.org>
pkgname=xf86-video-mga
pkgver=1.4.13
-pkgrel=4
+pkgrel=5
pkgdesc="X.org mga video driver"
arch=(i686 x86_64)
url="http://xorg.freedesktop.org/"
license=('custom')
-depends=('glibc' 'mga-dri')
-makedepends=('xorg-server-devel>=1.10.99.902' 'libdrm' 'xf86driproto' 'mesa' 'glproto')
-conflicts=('xorg-server<1.10.99.902')
+depends=('glibc')
+makedepends=('xorg-server-devel>=1.11.99.903' 'libdrm' 'xf86driproto' 'mesa>=8.0') # 'glproto')
+conflicts=('xorg-server<1.11.99.903')
options=('!libtool')
groups=('xorg-drivers' 'xorg')
source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2
@@ -21,8 +21,12 @@ sha1sums=('55aa185cf381def4b5905c8b93694b8dfbd5c378'
build() {
cd "${srcdir}/${pkgname}-${pkgver}"
patch -Np1 -i "${srcdir}/git-fixes.patch"
- ./configure --prefix=/usr --enable-dri
+ ./configure --prefix=/usr #--enable-dri
make
+}
+
+package() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
make DESTDIR="${pkgdir}" install
install -m755 -d "${pkgdir}/usr/share/licenses/${pkgname}"
diff --git a/extra/xf86-video-mga/git-fixes.patch b/extra/xf86-video-mga/git-fixes.patch
new file mode 100644
index 000000000..3534342e6
--- /dev/null
+++ b/extra/xf86-video-mga/git-fixes.patch
@@ -0,0 +1,800 @@
+diff --git a/man/Makefile.am b/man/Makefile.am
+index b3688ce..1ea26b3 100644
+--- a/man/Makefile.am
++++ b/man/Makefile.am
+@@ -1,5 +1,5 @@
+ #
+-# Copyright 2005 Sun Microsystems, Inc. All rights reserved.
++# Copyright (c) 2005, Oracle and/or its affiliates. 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"),
+@@ -19,7 +19,7 @@
+ # 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.
+-#
++#
+
+ drivermandir = $(DRIVER_MAN_DIR)
+
+diff --git a/man/mga.man b/man/mga.man
+index 3a7a9f8..e1e674f 100644
+--- a/man/mga.man
++++ b/man/mga.man
+@@ -1,4 +1,3 @@
+-.\" $XFree86: xc/programs/Xserver/hw/xfree86/drivers/mga/mga.man,v 1.7 2003/04/03 07:11:03 herrb Exp $
+ .\" shorthand for double quote that works everywhere.
+ .ds q \N'34'
+ .TH mga __drivermansuffix__ __vendorversion__
+diff --git a/src/binding.h b/src/binding.h
+index 6dcd1e9..57e9b92 100644
+--- a/src/binding.h
++++ b/src/binding.h
+@@ -13,7 +13,6 @@
+ @end
+
+ ***************************************************************************************/
+-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/mga/HALlib/binding.h,v 1.3 2000/10/24 22:45:08 dawes Exp $ */
+
+ #ifndef _BINDING
+ #define _BINDING
+diff --git a/src/mga.h b/src/mga.h
+index 2cb3d88..c520e86 100644
+--- a/src/mga.h
++++ b/src/mga.h
+@@ -1,4 +1,3 @@
+-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/mga/mga.h,v 1.87tsi Exp $ */
+ /*
+ * MGA Millennium (MGA2064W) functions
+ *
+@@ -137,6 +136,10 @@ void MGAdbg_outreg32(ScrnInfoPtr, int,int, char*);
+ #define PCI_CHIP_MGAG200_EH_PCI 0x0533
+ #endif
+
++#ifndef PCI_CHIP_MGAG200_ER_PCI
++#define PCI_CHIP_MGAG200_ER_PCI 0x0534
++#endif
++
+ /*
+ * Read/write to the DAC via MMIO
+ */
+@@ -200,7 +203,9 @@ void MGAdbg_outreg32(ScrnInfoPtr, int,int, char*);
+ typedef struct {
+ unsigned char ExtVga[6];
+ unsigned char DacClk[6];
+- unsigned char * DacRegs;
++ unsigned char ExtVga_Index24;
++ unsigned char Dac_Index90;
++ unsigned char * DacRegs;
+ unsigned long crtc2[0x58];
+ unsigned char dac2[0x21];
+ CARD32 Option;
+@@ -479,6 +484,7 @@ typedef struct {
+ int is_G200WB:1;
+ int is_G200EV:1;
+ int is_G200EH:1;
++ int is_G200ER:1;
+
+ int KVM;
+
+diff --git a/src/mga_common.h b/src/mga_common.h
+index 90f6b37..81be2bc 100644
+--- a/src/mga_common.h
++++ b/src/mga_common.h
+@@ -25,8 +25,6 @@
+ * Converted to common header format:
+ * Jens Owen <jens@tungstengraphics.com>
+ *
+- * $XFree86: xc/programs/Xserver/hw/xfree86/drivers/mga/mga_common.h,v 1.2 2002/12/16 16:19:18 dawes Exp $
+- *
+ */
+
+ #ifndef _MGA_COMMON_H_
+diff --git a/src/mga_dacG.c b/src/mga_dacG.c
+index df00765..fca1031 100644
+--- a/src/mga_dacG.c
++++ b/src/mga_dacG.c
+@@ -444,6 +444,116 @@ MGAG200WBPIXPLLSET(ScrnInfoPtr pScrn, MGARegPtr mgaReg)
+ outMGAdac(MGA1064_REMHEADCTL, ucTempByte);
+ }
+
++#define G200ER_PLLREF 48000
++#define G200ER_VCOMIN 1056000
++#define G200ER_VCOMAX 1488000
++
++static void MGAG200ERComputePLLParam(ScrnInfoPtr pScrn, long lFo, int *piM, int *piN, int *piP)
++{
++
++ int ulM;
++ int ulN;
++ int ulO;
++ int ulR;
++
++ CARD32 ulComputedFo;
++ CARD32 ulVco;
++ CARD32 ulFDelta;
++ CARD32 ulFTmpDelta;
++
++ CARD32 aulMDivValue[] = {1, 2, 4, 8};
++
++ CARD32 ulFo = lFo;
++
++ ulFDelta = 0xFFFFFFFF;
++
++ for (ulR = 0; ulR < 4; ulR++)
++ {
++ if(ulFDelta==0) break;
++ for (ulN = 5; (ulN <= 128) ; ulN++)
++ {
++ if(ulFDelta==0) break;
++ for (ulM = 3; ulM >= 0; ulM--)
++ {
++ if(ulFDelta==0) break;
++ for (ulO = 5; ulO <= 32; ulO++)
++ {
++ ulVco = (G200ER_PLLREF * (ulN+1)) / (ulR+1);
++ // Validate vco
++ if (ulVco < G200ER_VCOMIN) continue;
++ if (ulVco > G200ER_VCOMAX) continue;
++ ulComputedFo = ulVco / (aulMDivValue[ulM] * (ulO+1));
++
++ if (ulComputedFo > ulFo)
++ {
++ ulFTmpDelta = ulComputedFo - ulFo;
++ }
++ else
++ {
++ ulFTmpDelta = ulFo - ulComputedFo;
++ }
++
++ if (ulFTmpDelta < ulFDelta)
++ {
++ ulFDelta = ulFTmpDelta;
++ // XG200ERPIXPLLCM M<1:0> O<7:3>
++ *piM = (CARD8)ulM | (CARD8)(ulO<<3);
++ //
++ // XG200ERPIXPLLCN N<6:0>
++ *piN = (CARD8)ulN;
++ //
++ // XG200ERPIXPLLCP R<1:0> cg<7:4> (Use R value)
++ *piP = (CARD8)ulR | (CARD8)(ulR<<3);
++
++ // Test
++ int ftest = (G200ER_PLLREF * (ulN+1)) / ((ulR+1) * aulMDivValue[ulM] * (ulO+1));
++ ftest=ftest;
++ }
++ } // End O Loop
++ } // End M Loop
++ } // End N Loop
++ } // End R Loop
++}
++
++static void
++MGAG200ERPIXPLLSET(ScrnInfoPtr pScrn, MGARegPtr mgaReg)
++{
++ //TODO G200ER Validate sequence
++ CARD8 ucPixCtrl, ucTempByte;
++ MGAPtr pMga = MGAPTR(pScrn);
++
++
++ // Set pixclkdis to 1
++ ucPixCtrl = inMGAdac(MGA1064_PIX_CLK_CTL);
++ ucPixCtrl |= MGA1064_PIX_CLK_CTL_CLK_DIS;
++ outMGAdac(MGA1064_PIX_CLK_CTL, ucPixCtrl);
++
++ ucTempByte = inMGAdac(MGA1064_REMHEADCTL);
++ ucTempByte |= MGA1064_REMHEADCTL_CLKDIS;
++ outMGAdac(MGA1064_REMHEADCTL, ucTempByte);
++
++ // Select PLL Set C
++ ucTempByte = INREG8(MGAREG_MEM_MISC_READ);
++ ucTempByte |= (0x3<<2) | 0xc0; //select MGA pixel clock
++ OUTREG8(MGAREG_MEM_MISC_WRITE, ucTempByte);
++
++ ucPixCtrl &= ~MGA1064_PIX_CLK_CTL_CLK_DIS;
++ ucPixCtrl |= MGA1064_PIX_CLK_CTL_CLK_POW_DOWN;
++ outMGAdac(MGA1064_PIX_CLK_CTL, ucPixCtrl);
++
++ // Wait 500 us
++ usleep(500);
++
++ // Program the Pixel PLL Register
++ outMGAdac(MGA1064_ER_PIX_PLLC_N, mgaReg->PllN);
++ outMGAdac(MGA1064_ER_PIX_PLLC_M, mgaReg->PllM);
++ outMGAdac(MGA1064_ER_PIX_PLLC_P, mgaReg->PllP);
++
++ // Wait 50 us
++ usleep(50);
++
++}
++
+ static void
+ MGAG200WBPrepareForModeSwitch(ScrnInfoPtr pScrn)
+ {
+@@ -768,8 +878,13 @@ MGAGSetPCLK( ScrnInfoPtr pScrn, long f_out )
+
+ pReg->PllM = m;
+ pReg->PllN = n;
+- pReg->PllP = p;
+- } else {
++ pReg->PllP = p;
++ } else if (pMga->is_G200ER) {
++ MGAG200ERComputePLLParam(pScrn, f_out, &m, &n, &p);
++ pReg->PllM = m;
++ pReg->PllN = n;
++ pReg->PllP = p;
++ } else {
+ /* Do the calculations for m, n, p and s */
+ MGAGCalcClock( pScrn, f_out, &m, &n, &p, &s );
+
+@@ -966,6 +1081,10 @@ MGAGInit(ScrnInfoPtr pScrn, DisplayModePtr mode)
+ pReg->Option2 = 0x0000b000;
+ break;
+
++ case PCI_CHIP_MGAG200_ER_PCI:
++ pReg->Dac_Index90 = 0;
++ break;
++
+ case PCI_CHIP_MGAG200_EH_PCI:
+ pReg->DacRegs[MGA1064_MISC_CTL] =
+ MGA1064_MISC_CTL_VGA8 |
+@@ -1088,6 +1207,7 @@ MGAGInit(ScrnInfoPtr pScrn, DisplayModePtr mode)
+ if (pMga->is_G200WB){
+ pReg->ExtVga[1] |= 0x88;
+ }
++ pReg->ExtVga_Index24 = 0x05;
+
+ pVga->CRTC[0] = ht - 4;
+ pVga->CRTC[1] = hd;
+@@ -1327,10 +1447,15 @@ MGA_NOT_HAL(
+ if ( (pMga->is_G200EV || pMga->is_G200WB || pMga->is_G200EH) &&
+ (i >= 0x44) && (i <= 0x4E))
+ continue;
+-
++
+ outMGAdac(i, mgaReg->DacRegs[i]);
+ }
+
++ if (pMga->is_G200ER)
++ {
++ outMGAdac(0x90, mgaReg->Dac_Index90);
++ }
++
+ if (!MGAISGx50(pMga)) {
+ /* restore pci_option register */
+ #ifdef XSERVER_LIBPCIACCESS
+@@ -1361,7 +1486,9 @@ MGA_NOT_HAL(
+ #endif
+ }
+
+- if (pMga->is_G200EV) {
++ if (pMga->is_G200ER) {
++ MGAG200ERPIXPLLSET(pScrn, mgaReg);
++ } else if (pMga->is_G200EV) {
+ MGAG200EVPIXPLLSET(pScrn, mgaReg);
+ } else if (pMga->is_G200WB) {
+ MGAG200WBPIXPLLSET(pScrn, mgaReg);
+@@ -1388,6 +1515,11 @@ MGA_NOT_HAL(
+ for (i = 0; i < 6; i++)
+ OUTREG16(MGAREG_CRTCEXT_INDEX, (mgaReg->ExtVga[i] << 8) | i);
+
++ if (pMga->is_G200ER) {
++ OUTREG8(MGAREG_CRTCEXT_INDEX, 0x24);
++ OUTREG8(MGAREG_CRTCEXT_DATA, mgaReg->ExtVga_Index24);
++ }
++
+ /* This handles restoring the generic VGA registers. */
+ if (pMga->is_G200SE) {
+ MGAG200SERestoreMode(pScrn, vgaReg);
+@@ -1404,7 +1536,7 @@ MGA_NOT_HAL(
+ OUTREG16(MGAREG_CRTCEXT_INDEX, 6);
+ OUTREG16(MGAREG_CRTCEXT_DATA, 0);
+ }
+-
++
+ /*
+ * this is needed to properly restore start address
+ */
+@@ -1555,6 +1687,11 @@ MGAGSave(ScrnInfoPtr pScrn, vgaRegPtr vgaReg, MGARegPtr mgaReg,
+ mgaReg->PllM = inMGAdac(MGA1064_EH_PIX_PLLC_M);
+ mgaReg->PllN = inMGAdac(MGA1064_EH_PIX_PLLC_N);
+ mgaReg->PllP = inMGAdac(MGA1064_EH_PIX_PLLC_P);
++ } else if (pMga->is_G200ER) {
++ mgaReg->PllM = inMGAdac(MGA1064_ER_PIX_PLLC_M);
++ mgaReg->PllN = inMGAdac(MGA1064_ER_PIX_PLLC_N);
++ mgaReg->PllP = inMGAdac(MGA1064_ER_PIX_PLLC_P);
++ mgaReg->Dac_Index90 = inMGAdac(0x90);
+ }
+
+ mgaReg->PIXPLLCSaved = TRUE;
+@@ -1583,6 +1720,11 @@ MGAGSave(ScrnInfoPtr pScrn, vgaRegPtr vgaReg, MGARegPtr mgaReg,
+ OUTREG8(MGAREG_CRTCEXT_INDEX, i);
+ mgaReg->ExtVga[i] = INREG8(MGAREG_CRTCEXT_DATA);
+ }
++ if (pMga->is_G200ER)
++ {
++ OUTREG8(MGAREG_CRTCEXT_INDEX, 0x24);
++ mgaReg->ExtVga_Index24 = INREG8(MGAREG_CRTCEXT_DATA);
++ }
+
+ #ifdef DEBUG
+ ErrorF("Saved values:\nDAC:");
+@@ -1737,7 +1879,7 @@ static const struct mgag_i2c_private {
+ { (1 << 0), (1 << 2) },
+ { (1 << 4), (1 << 5) },
+ { (1 << 0), (1 << 1) }, /* G200SE, G200EV and G200WB I2C bits */
+- { (1 << 1), (1 << 0) }, /* G200EH I2C bits */
++ { (1 << 1), (1 << 0) }, /* G200EH, G200ER I2C bits */
+ };
+
+
+@@ -1750,7 +1892,7 @@ MGAG_ddc1Read(ScrnInfoPtr pScrn)
+
+ if (pMga->is_G200SE || pMga->is_G200WB || pMga->is_G200EV)
+ i2c_index = 3;
+- else if (pMga->is_G200EH)
++ else if (pMga->is_G200EH || pMga->is_G200ER)
+ i2c_index = 4;
+ else
+ i2c_index = 0;
+@@ -1851,7 +1993,7 @@ MGAG_i2cInit(ScrnInfoPtr pScrn)
+
+ if (pMga->is_G200SE || pMga->is_G200WB || pMga->is_G200EV)
+ i2c_index = 3;
+- else if (pMga->is_G200EH)
++ else if (pMga->is_G200EH || pMga->is_G200ER)
+ i2c_index = 4;
+ else
+ i2c_index = 0;
+@@ -1976,7 +2118,7 @@ void MGAGSetupFuncs(ScrnInfoPtr pScrn)
+ pMga->Save = MGAGSave;
+ pMga->Restore = MGAGRestore;
+ pMga->ModeInit = MGAGInit;
+- if (!pMga->is_G200WB){
++ if ((!pMga->is_G200WB) && (!pMga->is_G200ER)) {
+ pMga->ddc1Read = MGAG_ddc1Read;
+ /* vgaHWddc1SetSpeed will only work if the card is in VGA mode */
+ pMga->DDC1SetSpeed = vgaHWddc1SetSpeedWeak();
+diff --git a/src/mga_dri.c b/src/mga_dri.c
+index 3fda623..14f342f 100644
+--- a/src/mga_dri.c
++++ b/src/mga_dri.c
+@@ -32,7 +32,6 @@
+
+ #include "xf86.h"
+ #include "xf86_OSproc.h"
+-#include "xf86Priv.h"
+
+ #include "xf86PciInfo.h"
+ #include "xf86Pci.h"
+diff --git a/src/mga_dri.h b/src/mga_dri.h
+index f1afb5d..1984b9c 100644
+--- a/src/mga_dri.h
++++ b/src/mga_dri.h
+@@ -1,5 +1,3 @@
+-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/mga/mga_dri.h,v 1.6 2001/04/10 16:08:01 dawes Exp $ */
+-
+ /*
+ * Copyright 2000 VA Linux Systems Inc., Fremont, California.
+ * All Rights Reserved.
+diff --git a/src/mga_dripriv.h b/src/mga_dripriv.h
+index 3ddd133..feca134 100644
+--- a/src/mga_dripriv.h
++++ b/src/mga_dripriv.h
+@@ -1,5 +1,3 @@
+-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/mga/mga_dripriv.h,v 1.4 2001/04/10 16:08:01 dawes Exp $ */
+-
+ /*
+ * Copyright 2000 VA Linux Systems Inc., Fremont, California.
+ * All Rights Reserved.
+diff --git a/src/mga_driver.c b/src/mga_driver.c
+index 5a1e9b4..b140013 100644
+--- a/src/mga_driver.c
++++ b/src/mga_driver.c
+@@ -1,4 +1,3 @@
+-/* $XConsortium: mga_driver.c /main/12 1996/10/28 05:13:26 kaleb $ */
+ /*
+ * MGA Millennium (MGA2064W) with Ti3026 RAMDAC driver v.1.1
+ *
+@@ -404,6 +403,21 @@ static const struct mga_device_attributes attribs[] = {
+ 8192, 0x4000, /* Memory probe size & offset values */
+ },
+
++ /* G200ER */
++ [15] = { 0, 1, 0, 0, 1, 0, 0, 0, new_BARs,
++ (TRANSC_SOLID_FILL | TWO_PASS_COLOR_EXPAND | USE_LINEAR_EXPANSION),
++ {
++ { 50000, 230000 }, /* System VCO frequencies */
++ { 50000, 203400 }, /* Pixel VCO frequencies */
++ { 0, 0 }, /* Video VCO frequencies */
++ 45000, /* Memory clock */
++ 27050, /* PLL reference frequency */
++ 0, /* Supports fast bitblt? */
++ MGA_HOST_PCI /* Host interface */
++ },
++
++ 16384, 0x4000, /* Memory probe size & offset values */
++ }
+ };
+
+ #ifdef XSERVER_LIBPCIACCESS
+@@ -433,6 +447,8 @@ static const struct pci_id_match mga_device_match[] = {
+
+ MGA_DEVICE_MATCH( PCI_CHIP_MGAG200_EH_PCI, 14 ),
+
++ MGA_DEVICE_MATCH(PCI_CHIP_MGAG200_ER_PCI, 15 ),
++
+ { 0, 0, 0 },
+ };
+ #endif
+@@ -450,6 +466,7 @@ static SymTabRec MGAChipsets[] = {
+ { PCI_CHIP_MGAG200_SE_A_PCI, "mgag200 SE A PCI" },
+ { PCI_CHIP_MGAG200_SE_B_PCI, "mgag200 SE B PCI" },
+ { PCI_CHIP_MGAG200_EV_PCI, "mgag200 EV Maxim" },
++ { PCI_CHIP_MGAG200_ER_PCI, "mgag200 ER SH7757" },
+ { PCI_CHIP_MGAG200_WINBOND_PCI, "mgag200 eW Nuvoton" },
+ { PCI_CHIP_MGAG200_EH_PCI, "mgag200eH" },
+ { PCI_CHIP_MGAG400, "mgag400" },
+@@ -472,6 +489,8 @@ static PciChipsets MGAPciChipsets[] = {
+ RES_SHARED_VGA },
+ { PCI_CHIP_MGAG200_EV_PCI, PCI_CHIP_MGAG200_EV_PCI,
+ RES_SHARED_VGA },
++ { PCI_CHIP_MGAG200_ER_PCI, PCI_CHIP_MGAG200_ER_PCI,
++ RES_SHARED_VGA },
+ { PCI_CHIP_MGAG200_WINBOND_PCI, PCI_CHIP_MGAG200_WINBOND_PCI,
+ RES_SHARED_VGA },
+ { PCI_CHIP_MGAG200_EH_PCI, PCI_CHIP_MGAG200_EH_PCI,
+@@ -913,6 +932,11 @@ MGAProbe(DriverPtr drv, int flags)
+ case PCI_CHIP_MGAG200_EH_PCI:
+ attrib_no = 14;
+ break;
++
++ case PCI_CHIP_MGAG200_ER_PCI:
++ attrib_no = 15;
++ break;
++
+
+ default:
+ return FALSE;
+@@ -1081,7 +1105,7 @@ MGACountRam(ScrnInfoPtr pScrn)
+
+ if (pMga->is_G200SE)
+ pMga->reg_1e24 = INREG(0x1e24); /* stash the model for later */
+- if (pMga->reg_1e24 == 0x01) {
++ if (pMga->reg_1e24 >= 0x01) {
+ MGAUnmapMem(pScrn);
+ ProbeSize = 16384;
+ ProbeSizeOffset = 0x10000;
+@@ -1286,6 +1310,11 @@ MGAdoDDC(ScrnInfoPtr pScrn)
+ MGASave(pScrn);
+
+ /* It is now safe to talk to the card */
++ /* Allow access to DDC */
++ if (pMga->is_G200ER) {
++ CARD8 ucData = inMGAdac(MGA1064_GEN_IO_CTL2);
++ outMGAdac(MGA1064_GEN_IO_CTL2, ucData | 1);
++ }
+
+ /* Initialize I2C buses - used by DDC if available */
+ if (pMga->i2cInit) {
+@@ -1327,6 +1356,12 @@ MGAdoDDC(ScrnInfoPtr pScrn)
+ xf86DrvMsg(pScrn->scrnIndex, X_INFO, "end of monitor info\n");
+ }
+
++ /* Remove access to DDC */
++ if (pMga->is_G200ER) {
++ CARD8 ucData = inMGAdac(MGA1064_GEN_IO_CTL2);
++ outMGAdac(MGA1064_GEN_IO_CTL2, ucData & ~1);
++ }
++
+ /* Restore previous state and unmap MGA memory and MMIO areas */
+ MGARestore(pScrn);
+ MGAUnmapMem(pScrn);
+@@ -1620,6 +1655,7 @@ MGAPreInit(ScrnInfoPtr pScrn, int flags)
+ pMga->is_G200EV = (pMga->Chipset == PCI_CHIP_MGAG200_EV_PCI);
+ pMga->is_G200WB = (pMga->Chipset == PCI_CHIP_MGAG200_WINBOND_PCI);
+ pMga->is_G200EH = (pMga->Chipset == PCI_CHIP_MGAG200_EH_PCI);
++ pMga->is_G200ER = (pMga->Chipset == PCI_CHIP_MGAG200_ER_PCI);
+
+ #ifdef USEMGAHAL
+ if (pMga->chip_attribs->HAL_chipset) {
+@@ -1780,15 +1816,9 @@ MGAPreInit(ScrnInfoPtr pScrn, int flags)
+ #ifndef XSERVER_LIBPCIACCESS
+ /*
+ * Find the BIOS base. Get it from the PCI config if possible. Otherwise
+- * use the VGA default. Allow the config file to override this.
++ * use the VGA default.
+ */
+
+- pMga->BiosFrom = X_NONE;
+- if (pMga->device->BiosBase != 0) {
+- /* XXX This isn't used */
+- pMga->BiosAddress = pMga->device->BiosBase;
+- pMga->BiosFrom = X_CONFIG;
+- } else {
+ /* details: rombase sdk pp 4-15 */
+ if (pMga->PciInfo->biosBase != 0) {
+ pMga->BiosAddress = pMga->PciInfo->biosBase & 0xffff0000;
+@@ -1797,7 +1827,6 @@ MGAPreInit(ScrnInfoPtr pScrn, int flags)
+ pMga->BiosAddress = 0xc0000;
+ pMga->BiosFrom = X_DEFAULT;
+ }
+- }
+ if (pMga->BiosAddress) {
+ xf86DrvMsg(pScrn->scrnIndex, pMga->BiosFrom, "BIOS at 0x%lX\n",
+ (unsigned long)pMga->BiosAddress);
+@@ -2142,6 +2171,7 @@ MGAPreInit(ScrnInfoPtr pScrn, int flags)
+ case PCI_CHIP_MGAG200_WINBOND_PCI:
+ case PCI_CHIP_MGAG200_EV_PCI:
+ case PCI_CHIP_MGAG200_EH_PCI:
++ case PCI_CHIP_MGAG200_ER_PCI:
+ case PCI_CHIP_MGAG400:
+ case PCI_CHIP_MGAG550:
+ MGAGSetupFuncs(pScrn);
+@@ -2255,6 +2285,7 @@ MGAPreInit(ScrnInfoPtr pScrn, int flags)
+ case PCI_CHIP_MGAG200_WINBOND_PCI:
+ case PCI_CHIP_MGAG200_EV_PCI:
+ case PCI_CHIP_MGAG200_EH_PCI:
++ case PCI_CHIP_MGAG200_ER_PCI:
+ pMga->SrcOrg = 0;
+ pMga->DstOrg = 0;
+ break;
+@@ -2432,16 +2463,17 @@ MGAPreInit(ScrnInfoPtr pScrn, int flags)
+ maxPitch = 2048;
+ break;
+ case PCI_CHIP_MGAG200_SE_A_PCI:
+- if (pScrn->videoRam < 2048){
++ if (pScrn->videoRam < 2048){
+ maxPitch = 1280;
+- }
+- break;
++ }
++ break;
+ case PCI_CHIP_MGAG200:
+ case PCI_CHIP_MGAG200_PCI:
+ case PCI_CHIP_MGAG200_SE_B_PCI:
+ case PCI_CHIP_MGAG200_WINBOND_PCI:
+ case PCI_CHIP_MGAG200_EV_PCI:
+ case PCI_CHIP_MGAG200_EH_PCI:
++ case PCI_CHIP_MGAG200_ER_PCI:
+ case PCI_CHIP_MGAG400:
+ case PCI_CHIP_MGAG550:
+ maxPitch = 4096;
+@@ -3250,15 +3282,71 @@ MGA_HAL(
+ outb(0xfac, 0x02);
+ }
+
+- MGA_NOT_HAL(
+- if (pMga->is_G200SE) {
++ /*
++ This function optimize the Priority Request control
++ Higher HiPriLvl will reduce drawing performance
++ We need to give enough bandwith to crtc to avoid visual artifact
++ */
++ if (pMga->is_G200SE)
++ {
++ if (pMga->reg_1e24 >= 0x02)
++ {
++ /* Calulate CRTC Priority value */
++ CARD8 ucHiPriLvl;
++ CARD32 ulBitsPerPixel;
++ CARD32 ulMemoryBandwidth;
++
++ /* uiBitsPerPixel can only be 8,16 or32 */
++ if (pScrn->bitsPerPixel > 16)
++ {
++ ulBitsPerPixel = 32;
++ }
++ else if (pScrn->bitsPerPixel > 8)
++ {
++ ulBitsPerPixel = 16;
++ }
++ else
++ {
++ ulBitsPerPixel = 8;
++ }
++
++
++ ulMemoryBandwidth = (mode->Clock * ulBitsPerPixel) / 1000;
++
++ if (ulMemoryBandwidth > 3100) ucHiPriLvl = 0;
++ else if (ulMemoryBandwidth > 2600) ucHiPriLvl = 1;
++ else if (ulMemoryBandwidth > 1900) ucHiPriLvl = 2;
++ else if (ulMemoryBandwidth > 1160) ucHiPriLvl = 3;
++ else if (ulMemoryBandwidth > 440) ucHiPriLvl = 4;
++ else ucHiPriLvl = 5;
++
+ OUTREG8(0x1FDE, 0x06);
+- if (pMga->reg_1e24 == 0x01)
+- OUTREG8(0x1FDF, 0x03);
+- else
+- OUTREG8(0x1FDF, 0x14);
++ OUTREG8(0x1FDF, ucHiPriLvl);
++
++ xf86DrvMsg(pScrn->scrnIndex, X_INFO, "Clock == %d\n", mode->Clock);
++ xf86DrvMsg(pScrn->scrnIndex, X_INFO, "BitsPerPixel == %d\n", pScrn->bitsPerPixel);
++ xf86DrvMsg(pScrn->scrnIndex, X_INFO, "MemoryBandwidth == %d\n", ulMemoryBandwidth);
++ xf86DrvMsg(pScrn->scrnIndex, X_INFO, "HiPriLvl == %02X\n", ucHiPriLvl);
+ }
+- );
++ else
++ {
++ MGA_NOT_HAL(
++ xf86DrvMsg(pScrn->scrnIndex, X_INFO, "Clock == %d\n", mode->Clock);
++ xf86DrvMsg(pScrn->scrnIndex, X_INFO, "BitsPerPixel == %d\n", pScrn->bitsPerPixel);
++ OUTREG8(0x1FDE, 0x06);
++ if (pMga->reg_1e24 >= 0x01)
++ {
++ OUTREG8(0x1FDF, 0x03);
++ xf86DrvMsg(pScrn->scrnIndex, X_INFO, "HiPriLvl == 03\n");
++ }
++ else
++ {
++ OUTREG8(0x1FDF, 0x14);
++ xf86DrvMsg(pScrn->scrnIndex, X_INFO, "HiPriLvl == 14h\n");
++ }
++ );
++ }
++ }
+
+ pMga->CurrentLayout.mode = mode;
+
+@@ -4322,13 +4410,23 @@ MGAValidMode(int scrnIndex, DisplayModePtr mode, Bool verbose, int flags)
+ MGAPtr pMga = MGAPTR(pScrn);
+
+ if (pMga->Chipset == PCI_CHIP_MGAG200_SE_A_PCI) {
+- if (mode->HDisplay > 1600)
+- return MODE_VIRTUAL_X;
+- if (mode->VDisplay > 1200)
+- return MODE_VIRTUAL_Y;
+- if (pMga->reg_1e24 == 0x01 &&
+- xf86ModeBandwidth(mode, pScrn->bitsPerPixel) > 244)
+- return MODE_BANDWIDTH;
++ if (pMga->reg_1e24 == 0x01) {
++ if (mode->HDisplay > 1600)
++ return MODE_VIRTUAL_X;
++ if (mode->VDisplay > 1200)
++ return MODE_VIRTUAL_Y;
++ if (xf86ModeBandwidth(mode, pScrn->bitsPerPixel) > 244)
++ return MODE_BANDWIDTH;
++ } else {
++ if (pMga->reg_1e24 >= 0x02) {
++ if (mode->HDisplay > 1920)
++ return MODE_VIRTUAL_X;
++ if (mode->VDisplay > 1200)
++ return MODE_VIRTUAL_Y;
++ if (xf86ModeBandwidth(mode, pScrn->bitsPerPixel) > 301)
++ return MODE_BANDWIDTH;
++ }
++ }
+ } else if (pMga->is_G200WB){
+ if (mode->Flags & V_DBLSCAN)
+ return MODE_NO_DBLESCAN;
+@@ -4340,10 +4438,13 @@ MGAValidMode(int scrnIndex, DisplayModePtr mode, Bool verbose, int flags)
+ return MODE_BANDWIDTH;
+ } else if (pMga->is_G200EV
+ && (xf86ModeBandwidth(mode, pScrn->bitsPerPixel) > 327)) {
+- return MODE_BANDWIDTH;
++ return MODE_BANDWIDTH;
+ } else if (pMga->is_G200EH
+ && (xf86ModeBandwidth(mode, pScrn->bitsPerPixel) > 375)) {
+ return MODE_BANDWIDTH;
++ } else if (pMga->is_G200ER
++ && (xf86ModeBandwidth(mode, pScrn->bitsPerPixel) > 550)) {
++ return MODE_BANDWIDTH;
+ }
+
+ lace = 1 + ((mode->Flags & V_INTERLACE) != 0);
+diff --git a/src/mga_macros.h b/src/mga_macros.h
+index 69dc8e3..bffd063 100644
+--- a/src/mga_macros.h
++++ b/src/mga_macros.h
+@@ -1,5 +1,3 @@
+-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/mga/mga_macros.h,v 1.21 2001/09/26 12:59:17 alanh Exp $ */
+-
+ #ifndef _MGA_MACROS_H_
+ #define _MGA_MACROS_H_
+
+diff --git a/src/mga_merge.c b/src/mga_merge.c
+index 753f752..1fd0572 100644
+--- a/src/mga_merge.c
++++ b/src/mga_merge.c
+@@ -363,6 +363,7 @@ MGAPreInitMergedFB(ScrnInfoPtr pScrn1, int flags)
+ case PCI_CHIP_MGAG200_WINBOND_PCI:
+ case PCI_CHIP_MGAG200_EV_PCI:
+ case PCI_CHIP_MGAG200_EH_PCI:
++ case PCI_CHIP_MGAG200_ER_PCI:
+ case PCI_CHIP_MGAG400:
+ case PCI_CHIP_MGAG550:
+ MGAGSetupFuncs(pScrn);
+@@ -518,6 +519,7 @@ MGAPreInitMergedFB(ScrnInfoPtr pScrn1, int flags)
+ case PCI_CHIP_MGAG200_WINBOND_PCI:
+ case PCI_CHIP_MGAG200_EV_PCI:
+ case PCI_CHIP_MGAG200_EH_PCI:
++ case PCI_CHIP_MGAG200_ER_PCI:
+ case PCI_CHIP_MGAG400:
+ case PCI_CHIP_MGAG550:
+ maxPitch = 4096;
+diff --git a/src/mga_reg.h b/src/mga_reg.h
+index 6251976..5a37db6 100644
+--- a/src/mga_reg.h
++++ b/src/mga_reg.h
+@@ -1,11 +1,3 @@
+-/* $XConsortium: mgareg.h /main/2 1996/10/25 10:33:21 kaleb $ */
+-
+-
+-
+-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/mga/mga_reg.h,v 1.18 2001/09/26 12:59:18 alanh Exp $ */
+-
+-
+-
+ /*
+ * MGA Millennium (MGA2064W) functions
+ * MGA Mystique (MGA1064SG) functions
+@@ -377,6 +369,7 @@
+ #define MGA1064_MISC_CTL_VGA8 ( 0x01 << 3 )
+ #define MGA1064_MISC_CTL_DAC_RAM_CS ( 0x01 << 4 )
+
++#define MGA1064_GEN_IO_CTL2 0x29
+ #define MGA1064_GEN_IO_CTL 0x2a
+ #define MGA1064_GEN_IO_DATA 0x2b
+ #define MGA1064_SYS_PLL_M 0x2c
+@@ -437,6 +430,10 @@
+ #define MGA1064_EH_PIX_PLLC_N 0xb7
+ #define MGA1064_EH_PIX_PLLC_P 0xb8
+
++/* Modified PLL for G200 Maxim (G200ER) */
++#define MGA1064_ER_PIX_PLLC_M 0xb7
++#define MGA1064_ER_PIX_PLLC_N 0xb6
++#define MGA1064_ER_PIX_PLLC_P 0xb8
+
+ #define MGA1064_DISP_CTL 0x8a
+ #define MGA1064_DISP_CTL_DAC1OUTSEL_MASK 0x01
+diff --git a/src/mga_sarea.h b/src/mga_sarea.h
+index c5ffbbc..16fc9ce 100644
+--- a/src/mga_sarea.h
++++ b/src/mga_sarea.h
+@@ -1,5 +1,3 @@
+-/* $XFree86$ */
+-
+ /*
+ * Copyright 2000 Gareth Hughes
+ * All Rights Reserved.
+diff --git a/src/mga_storm.c b/src/mga_storm.c
+index 87473c8..db7fae7 100644
+--- a/src/mga_storm.c
++++ b/src/mga_storm.c
+@@ -1131,6 +1131,7 @@ void MGAStormEngineInit( ScrnInfoPtr pScrn )
+ case PCI_CHIP_MGAG200_WINBOND_PCI:
+ case PCI_CHIP_MGAG200_EV_PCI:
+ case PCI_CHIP_MGAG200_EH_PCI:
++ case PCI_CHIP_MGAG200_ER_PCI:
+ pMga->SrcOrg = 0;
+ OUTREG(MGAREG_SRCORG, pMga->realSrcOrg);
+ OUTREG(MGAREG_DSTORG, pMga->DstOrg);
+diff --git a/src/mgareg_flags.h b/src/mgareg_flags.h
+index 69050fc..548af86 100644
+--- a/src/mgareg_flags.h
++++ b/src/mgareg_flags.h
+@@ -19,7 +19,6 @@
+ * OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE
+ * OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+ */
+-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/mga/mgareg_flags.h,v 1.2 2003/01/12 03:55:47 tsi Exp $ */
+
+ #ifndef _MGAREGS_H_
+ #define _MGAREGS_H_
+diff --git a/util/stormdwg.c b/util/stormdwg.c
+index 99f76cc..b43cc32 100644
+--- a/util/stormdwg.c
++++ b/util/stormdwg.c
+@@ -1,8 +1,3 @@
+-/* $XConsortium: dwg.c /main/2 1996/10/28 06:57:55 kaleb $ */
+-
+-
+-
+-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/mga/util/stormdwg.c,v 1.1 1997/04/12 14:11:29 hohndel Exp $ */
+
+ #include <stdio.h>
+ #include <stdlib.h>
diff --git a/extra/xf86-video-neomagic/PKGBUILD b/extra/xf86-video-neomagic/PKGBUILD
index b996da01c..1fcad1c30 100644
--- a/extra/xf86-video-neomagic/PKGBUILD
+++ b/extra/xf86-video-neomagic/PKGBUILD
@@ -1,16 +1,16 @@
-# $Id: PKGBUILD 140322 2011-10-11 21:29:00Z jgc $
+# $Id: PKGBUILD 153348 2012-03-12 20:53:43Z andyrtr $
#Maintainer: Jan de Groot <jgc@archlinux.org>
pkgname=xf86-video-neomagic
pkgver=1.2.5
-pkgrel=5
+pkgrel=6
pkgdesc="X.org neomagic video driver"
arch=(i686 x86_64)
url="http://xorg.freedesktop.org/"
license=('custom')
depends=('glibc')
-makedepends=('xorg-server-devel>=1.11.0' 'xf86dgaproto')
-conflicts=('xorg-server<1.11.0')
+makedepends=('xorg-server-devel>=1.11.99.903' 'xf86dgaproto')
+conflicts=('xorg-server<1.11.99.903')
groups=('xorg-drivers' 'xorg')
options=('!libtool')
source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2)
@@ -20,6 +20,10 @@ build() {
cd "${srcdir}/${pkgname}-${pkgver}"
./configure --prefix=/usr
make
+}
+
+package() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
make DESTDIR="${pkgdir}" install
install -d -m755 "${pkgdir}/usr/share/licenses/${pkgname}"
install -m644 COPYING "${pkgdir}/usr/share/licenses/${pkgname}/"
diff --git a/extra/xf86-video-nouveau/PKGBUILD b/extra/xf86-video-nouveau/PKGBUILD
index f08fb5823..048771a53 100644
--- a/extra/xf86-video-nouveau/PKGBUILD
+++ b/extra/xf86-video-nouveau/PKGBUILD
@@ -1,9 +1,9 @@
-# $Id: PKGBUILD 146316 2012-01-09 16:15:38Z ibiru $
+# $Id: PKGBUILD 153350 2012-03-12 20:53:45Z andyrtr $
# Maintainer: Andreas Radke <andyrtr@archlinux.org>
# Contributor: buddabrod <buddabrod@gmail.com>
pkgname=xf86-video-nouveau
-_gitdate=20120106
+_gitdate=20120210
pkgver=0.0.16_git${_gitdate} # see configure.ac
pkgrel=1
pkgdesc="Open Source 3D acceleration driver for nVidia cards (experimental)"
@@ -13,11 +13,11 @@ license=('GPL') #and MIT, not yet a license file, see http://nouveau.freedesktop
depends=('libdrm' 'udev')
optdepends=('nouveau-dri: experimental gallium3d features')
makedepends=('xorg-server-devel' 'libdrm' 'xf86driproto')
-conflicts=('xorg-server<1.11.0')
+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=('4b0ee8643b3322ff3a0c5d70262a54af')
+md5sums=('f35c12d64542d0ea792a9e5af63a2e5a')
# source PKGBUILD && mksource
mksource() {
diff --git a/extra/xf86-video-nv/PKGBUILD b/extra/xf86-video-nv/PKGBUILD
index 7dab5a944..d29e82627 100644
--- a/extra/xf86-video-nv/PKGBUILD
+++ b/extra/xf86-video-nv/PKGBUILD
@@ -1,16 +1,16 @@
-# $Id: PKGBUILD 140318 2011-10-11 21:28:55Z jgc $
+# $Id: PKGBUILD 153352 2012-03-12 20:53:48Z andyrtr $
# Maintainer:Jan de Groot <jgc@archlinux.org>
pkgname=xf86-video-nv
pkgver=2.1.18
-pkgrel=4
+pkgrel=5
pkgdesc="X.org nv video driver"
arch=(i686 x86_64)
license=('custom')
url="http://xorg.freedesktop.org/"
depends=('glibc')
-makedepends=('xorg-server-devel>=1.11.0')
-conflicts=('xorg-server<1.11.0')
+makedepends=('xorg-server-devel>=1.11.99.903')
+conflicts=('xorg-server<1.11.99.903')
options=('!libtool')
groups=('xorg-drivers' 'xorg')
source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2)
@@ -20,6 +20,10 @@ build() {
cd "${srcdir}/${pkgname}-${pkgver}"
./configure --prefix=/usr
make
+}
+
+package() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
make DESTDIR="${pkgdir}" install
install -m755 -d "${pkgdir}/usr/share/licenses/${pkgname}"
diff --git a/extra/xf86-video-openchrome/PKGBUILD b/extra/xf86-video-openchrome/PKGBUILD
index cb982ec8b..72dc5b204 100644
--- a/extra/xf86-video-openchrome/PKGBUILD
+++ b/extra/xf86-video-openchrome/PKGBUILD
@@ -1,27 +1,30 @@
-# $Id: PKGBUILD 140316 2011-10-11 21:28:53Z jgc $
+# $Id: PKGBUILD 153354 2012-03-12 20:53:50Z andyrtr $
# Contributor: Paul Mattal <paul@mattal.com>
# Maintainer: Juergen Hoetzel <juergen@hoetzel.info>
pkgname=xf86-video-openchrome
-pkgver=0.2.904
-_svnver=r933
-pkgrel=6
+pkgver=0.2.905
+pkgrel=1
pkgdesc="X.Org Openchrome drivers"
arch=(i686 x86_64)
license=('custom')
url="http://www.openchrome.org"
-depends=('libdrm' 'libxvmc' 'unichrome-dri')
-makedepends=('xorg-server-devel>=1.11.0' 'libdrm' 'xf86driproto' 'mesa' 'libxvmc' 'glproto')
+depends=('libdrm' 'libxvmc')
+makedepends=('xorg-server-devel>=1.11.99.902' 'libx11' 'xf86driproto' 'mesa') #'glproto' 'libgl')
replaces=('openchrome' 'xf86-video-via')
-options=('!libtool' '!makeflags')
-conflicts=('xf86-video-via' 'xf86-video-unichrome' 'openchrome' 'xorg-server<1.11.0')
-source=(ftp://ftp.archlinux.org/other/${pkgname}/${pkgname}-${pkgver}-${_svnver}.tar.bz2)
-md5sums=('d661460276a31d3d012d8cdb1a0a73c1')
+options=('!libtool' '!emptydirs' '!makeflags')
+conflicts=('xf86-video-via' 'xf86-video-unichrome' 'openchrome' 'xorg-server<1.11.99.902' 'unichrome-dri')
+source=(http://xorg.freedesktop.org/archive/individual/driver/${pkgname}-${pkgver}.tar.bz2)
+md5sums=('51871431a4a9204ab8ec79335c0cc041')
build() {
cd "${srcdir}/${pkgname}-${pkgver}"
- ./configure --prefix=/usr
+ ./configure --prefix=/usr # --disable-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/extra/xf86-video-r128/PKGBUILD b/extra/xf86-video-r128/PKGBUILD
index 86b9f89e1..6a83bdf15 100644
--- a/extra/xf86-video-r128/PKGBUILD
+++ b/extra/xf86-video-r128/PKGBUILD
@@ -1,16 +1,16 @@
-# $Id: PKGBUILD 140314 2011-10-11 21:28:51Z jgc $
+# $Id: PKGBUILD 153356 2012-03-12 20:53:53Z andyrtr $
# Maintainer: Jan de Groot <jgc@archlinux.org>
pkgname=xf86-video-r128
pkgver=6.8.1
-pkgrel=7
+pkgrel=8
pkgdesc="X.org ati Rage128 video driver"
arch=(i686 x86_64)
url="http://xorg.freedesktop.org/"
license=('custom')
-depends=('glibc' 'r128-dri')
-makedepends=('xorg-server-devel>=1.11.0' 'xf86driproto' 'libdrm' 'mesa' 'glproto')
-conflicts=('xorg-server<1.11.0')
+depends=('glibc')
+makedepends=('xorg-server-devel>=1.11.99.903' 'xf86driproto' 'libdrm' 'mesa') # 'glproto')
+conflicts=('xorg-server<1.11.99.903')
groups=('xorg-drivers' 'xorg')
options=('!libtool')
source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2
@@ -23,8 +23,12 @@ build() {
patch -Np1 -i "${srcdir}/git-fixes.patch"
autoreconf -fi
- ./configure --prefix=/usr --enable-dri
+ ./configure --prefix=/usr #--enable-dri
make
+}
+
+package() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
make DESTDIR="${pkgdir}" install
install -m755 -d "${pkgdir}/usr/share/licenses/${pkgname}"
diff --git a/extra/xf86-video-rendition/PKGBUILD b/extra/xf86-video-rendition/PKGBUILD
index 32ee7deba..4043c0d71 100644
--- a/extra/xf86-video-rendition/PKGBUILD
+++ b/extra/xf86-video-rendition/PKGBUILD
@@ -1,25 +1,32 @@
-# $Id: PKGBUILD 140312 2011-10-11 21:28:49Z jgc $
+# $Id: PKGBUILD 153358 2012-03-12 20:53:56Z andyrtr $
# Maintainer: Jan de Groot <jgc@archlinux.org>
pkgname=xf86-video-rendition
pkgver=4.2.4
-pkgrel=5
+pkgrel=6
pkgdesc="X.org Rendition video driver"
arch=(i686 x86_64)
url="http://xorg.freedesktop.org/"
license=('custom')
depends=('glibc')
-makedepends=('xorg-server-devel>=1.11.0')
-conflicts=('xorg-server<1.11.0')
+makedepends=('xorg-server-devel>=1.11.99.903')
+conflicts=('xorg-server<1.11.99.903')
options=('!libtool' '!strip')
groups=('xorg-drivers' 'xorg')
-source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2)
-sha1sums=('16148c25183f7829c22bc9dfdb588c1a16bf4565')
+source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2
+ rendition-4.2.4-git.patch)
+sha1sums=('16148c25183f7829c22bc9dfdb588c1a16bf4565'
+ 'e023650fa418be9a92d159acd8ac0bc23704dfb3')
build() {
cd "${srcdir}/${pkgname}-${pkgver}"
+ patch -Np1 -i ${srcdir}/rendition-4.2.4-git.patch
./configure --prefix=/usr
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/extra/xf86-video-rendition/rendition-4.2.4-git.patch b/extra/xf86-video-rendition/rendition-4.2.4-git.patch
new file mode 100644
index 000000000..26cff2fd3
--- /dev/null
+++ b/extra/xf86-video-rendition/rendition-4.2.4-git.patch
@@ -0,0 +1,809 @@
+diff --git a/configure.ac b/configure.ac
+index 5091e50..f74b912 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -20,45 +20,45 @@
+ #
+ # Process this file with autoconf to produce a configure script
+
+-AC_PREREQ(2.57)
++# Initialize Autoconf
++AC_PREREQ([2.60])
+ AC_INIT([xf86-video-rendition],
+- 4.2.4,
++ [4.2.4],
+ [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg],
+- xf86-video-rendition)
+-
++ [xf86-video-rendition])
+ AC_CONFIG_SRCDIR([Makefile.am])
+-AM_CONFIG_HEADER([config.h])
++AC_CONFIG_HEADERS([config.h])
+ AC_CONFIG_AUX_DIR(.)
+
++# Initialize Automake
+ AM_INIT_AUTOMAKE([foreign dist-bzip2])
+-
+ AM_MAINTAINER_MODE
+
+-# Require xorg-macros: XORG_DEFAULT_OPTIONS
++# Require X.Org macros 1.8 or later for MAN_SUBSTS set by XORG_MANPAGE_SECTIONS
+ m4_ifndef([XORG_MACROS_VERSION],
+- [m4_fatal([must install xorg-macros 1.3 or later before running autoconf/autogen])])
+-XORG_MACROS_VERSION(1.3)
++ [m4_fatal([must install xorg-macros 1.8 or later before running autoconf/autogen])])
++XORG_MACROS_VERSION(1.8)
+ XORG_DEFAULT_OPTIONS
+
+-# Checks for programs.
++# Initialize libtool
+ AC_DISABLE_STATIC
+ AC_PROG_LIBTOOL
+-AC_PROG_CC
+
+ AH_TOP([#include "xorg-server.h"])
+
++# Define a configure option for an alternate module directory
+ AC_ARG_WITH(xorg-module-dir,
+- AC_HELP_STRING([--with-xorg-module-dir=DIR],
++ AS_HELP_STRING([--with-xorg-module-dir=DIR],
+ [Default xorg module directory [[default=$libdir/xorg/modules]]]),
+ [moduledir="$withval"],
+ [moduledir="$libdir/xorg/modules"])
+
+-# Checks for extensions
++# Store the list of server defined optional extensions in REQUIRED_MODULES
+ XORG_DRIVER_CHECK_EXT(RANDR, randrproto)
+ XORG_DRIVER_CHECK_EXT(RENDER, renderproto)
+ XORG_DRIVER_CHECK_EXT(DPMSExtension, xextproto)
+
+-# Checks for pkg-config packages
++# Obtain compiler/linker options for the driver dependencies
+ PKG_CHECK_MODULES(XORG, [xorg-server >= 1.0.99.901 xproto fontsproto $REQUIRED_MODULES])
+
+ # Checks for libraries.
+@@ -78,17 +78,16 @@ fi
+ AM_CONDITIONAL(XSERVER_LIBPCIACCESS, test "x$XSERVER_LIBPCIACCESS" = xyes)
+
+ # Checks for header files.
+-AC_HEADER_STDC
+ AC_CHECK_HEADERS([elf.h] [elf_abi.h])
+
+-AC_SUBST([XORG_CFLAGS])
+ AC_SUBST([moduledir])
+
+ DRIVER_NAME=rendition
+ AC_SUBST([DRIVER_NAME])
+
+-AC_OUTPUT([
+- Makefile
+- src/Makefile
+- man/Makefile
++AC_CONFIG_FILES([
++ Makefile
++ src/Makefile
++ man/Makefile
+ ])
++AC_OUTPUT
+diff --git a/man/Makefile.am b/man/Makefile.am
+index 8f2454b..b3688ce 100644
+--- a/man/Makefile.am
++++ b/man/Makefile.am
+@@ -31,25 +31,11 @@ EXTRA_DIST = @DRIVER_NAME@.man
+
+ CLEANFILES = $(driverman_DATA)
+
+-SED = sed
+-
+-# Strings to replace in man pages
+-XORGRELSTRING = @PACKAGE_STRING@
+- XORGMANNAME = X Version 11
+-
+-MAN_SUBSTS = \
+- -e 's|__vendorversion__|"$(XORGRELSTRING)" "$(XORGMANNAME)"|' \
+- -e 's|__xorgversion__|"$(XORGRELSTRING)" "$(XORGMANNAME)"|' \
+- -e 's|__xservername__|Xorg|g' \
+- -e 's|__xconfigfile__|xorg.conf|g' \
+- -e 's|__projectroot__|$(prefix)|g' \
+- -e 's|__appmansuffix__|$(APP_MAN_SUFFIX)|g' \
+- -e 's|__drivermansuffix__|$(DRIVER_MAN_SUFFIX)|g' \
+- -e 's|__adminmansuffix__|$(ADMIN_MAN_SUFFIX)|g' \
+- -e 's|__miscmansuffix__|$(MISC_MAN_SUFFIX)|g' \
+- -e 's|__filemansuffix__|$(FILE_MAN_SUFFIX)|g'
++
++# String replacements in MAN_SUBSTS now come from xorg-macros.m4 via configure
++
+
+ SUFFIXES = .$(DRIVER_MAN_SUFFIX) .man
+
+ .man.$(DRIVER_MAN_SUFFIX):
+- sed $(MAN_SUBSTS) < $< > $@
++ $(AM_V_GEN)$(SED) $(MAN_SUBSTS) < $< > $@
+diff --git a/man/rendition.man b/man/rendition.man
+index 3658ab0..afeee91 100644
+--- a/man/rendition.man
++++ b/man/rendition.man
+@@ -1,4 +1,3 @@
+-.\" $__xservername__: xc/programs/Xserver/hw/xfree86/drivers/rendition/rendition.man,v 1.3 2003/06/18 16:17:39 eich Exp $
+ .\" shorthand for double quote that works everywhere.
+ .ds q \N'34'
+ .TH RENDITION __drivermansuffix__ __vendorversion__
+diff --git a/src/accelX.c b/src/accelX.c
+index a499c56..ed4964e 100644
+--- a/src/accelX.c
++++ b/src/accelX.c
+@@ -289,7 +289,7 @@ int
+ RENDITIONInitUcode(ScrnInfoPtr pScreenInfo)
+ {
+ renditionPtr pRendition = RENDITIONPTR(pScreenInfo);
+- IOADDRESS iob = pRendition->board.io_base;
++ unsigned long iob = pRendition->board.io_base;
+
+ if (0 == verite_getstride(pScreenInfo, NULL,
+ &pRendition->board.mode.stride0,
+@@ -367,7 +367,7 @@ void
+ RENDITIONRestoreUcode(ScrnInfoPtr pScreenInfo)
+ {
+ renditionPtr pRendition = RENDITIONPTR(pScreenInfo);
+- IOADDRESS iob = pRendition->board.io_base;
++ unsigned long iob = pRendition->board.io_base;
+
+ vu8 memend;
+
+@@ -410,7 +410,7 @@ void
+ RENDITIONSaveUcode(ScrnInfoPtr pScreenInfo)
+ {
+ renditionPtr pRendition = RENDITIONPTR(pScreenInfo);
+- IOADDRESS iob = pRendition->board.io_base;
++ unsigned long iob = pRendition->board.io_base;
+ vu8 memend;
+
+ #ifdef DEBUG
+@@ -445,7 +445,7 @@ void
+ RENDITIONSyncV1000(ScrnInfoPtr pScreenInfo)
+ {
+ renditionPtr pRendition = RENDITIONPTR(pScreenInfo);
+- IOADDRESS iob = pRendition->board.io_base;
++ unsigned long iob = pRendition->board.io_base;
+
+ int c;
+
+@@ -555,7 +555,7 @@ RENDITIONSubsequentScreenToScreenCopy(ScrnInfoPtr pScreenInfo,
+ int w, int h)
+ {
+ renditionPtr pRendition = RENDITIONPTR(pScreenInfo);
+- IOADDRESS iob = pRendition->board.io_base;
++ unsigned long iob = pRendition->board.io_base;
+
+
+ #ifdef DEBUG
+@@ -607,7 +607,7 @@ RENDITIONSubsequentSolidFillRect(ScrnInfoPtr pScreenInfo,
+ int x, int y, int w, int h)
+ {
+ renditionPtr pRendition = RENDITIONPTR(pScreenInfo);
+- IOADDRESS iob = pRendition->board.io_base;
++ unsigned long iob = pRendition->board.io_base;
+
+
+ #ifdef DEBUG
+@@ -639,7 +639,7 @@ RENDITIONSubsequentTwoPointLine(ScrnInfoPtr pScreenInfo,
+ int bias)
+ {
+ renditionPtr pRendition = RENDITIONPTR(pScreenInfo);
+- IOADDRESS iob = pRendition->board.io_base;
++ unsigned long iob = pRendition->board.io_base;
+
+
+ #ifdef DEBUG
+diff --git a/src/rendition.c b/src/rendition.c
+index 7a9e18b..3202b49 100644
+--- a/src/rendition.c
++++ b/src/rendition.c
+@@ -330,7 +330,7 @@ renditionProbe(DriverPtr drv, int flags)
+ renditionChipsets, renditionPCIchipsets,
+ devSections, numDevSections, drv, &usedChips);
+
+- xfree(devSections);
++ free(devSections);
+ if (numUsed <= 0)
+ return FALSE;
+
+@@ -359,7 +359,7 @@ renditionProbe(DriverPtr drv, int flags)
+ foundScreen=TRUE;
+ }
+ }
+- xfree(usedChips);
++ free(usedChips);
+ }
+ return foundScreen;
+ }
+@@ -400,7 +400,7 @@ renditionGetRec(ScrnInfoPtr pScreenInfo)
+ sleep(1);
+ #endif
+ if (!pScreenInfo->driverPrivate)
+- pScreenInfo->driverPrivate=xcalloc(sizeof(renditionRec), 1);
++ pScreenInfo->driverPrivate=calloc(sizeof(renditionRec), 1);
+
+ /* perhaps some initialization? <ml> */
+
+@@ -421,7 +421,7 @@ renditionFreeRec(ScrnInfoPtr pScreenInfo)
+ #endif
+ if (xf86LoaderCheckSymbol("vgaHWFreeHWRec"))
+ vgaHWFreeHWRec(pScreenInfo);
+- xfree(pScreenInfo->driverPrivate);
++ free(pScreenInfo->driverPrivate);
+ pScreenInfo->driverPrivate=NULL;
+
+ #ifdef DEBUG
+@@ -596,7 +596,7 @@ renditionPreInit(ScrnInfoPtr pScreenInfo, int flags)
+ /* collect all of the options flags and process them */
+
+ xf86CollectOptions(pScreenInfo, NULL);
+- if (!(pRendition->Options = xalloc(sizeof(renditionOptions))))
++ if (!(pRendition->Options = malloc(sizeof(renditionOptions))))
+ return FALSE;
+ memcpy(pRendition->Options, renditionOptions, sizeof(renditionOptions));
+ xf86ProcessOptions(pScreenInfo->scrnIndex, pScreenInfo->options,
+@@ -663,7 +663,11 @@ renditionPreInit(ScrnInfoPtr pScreenInfo, int flags)
+ vgaHWGetIOBase(pvgaHW); /* Get VGA I/O base */
+
+ pRendition->board.accel=0;
++#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 12
+ pRendition->board.vgaio_base = pvgaHW->PIOOffset;
++#else
++ pRendition->board.vgaio_base = 0;
++#endif
+ pRendition->board.io_base = pRendition->board.vgaio_base
+ #ifdef XSERVER_LIBPCIACCESS
+ + pRendition->PciInfo->regions[1].base_addr;
+@@ -1167,7 +1171,7 @@ renditionScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
+ pRendition->board.shadowPitch
+ = BitmapBytePad(pScreenInfo->bitsPerPixel * width);
+ pRendition->board.shadowPtr
+- = xalloc(pRendition->board.shadowPitch * height);
++ = malloc(pRendition->board.shadowPitch * height);
+ displayWidth = pRendition->board.shadowPitch
+ / (pScreenInfo->bitsPerPixel >> 3);
+ FBBase = pRendition->board.shadowPtr;
+@@ -1484,7 +1488,7 @@ static xf86MonPtr
+ renditionDDC (ScrnInfoPtr pScreenInfo)
+ {
+ renditionPtr pRendition = RENDITIONPTR(pScreenInfo);
+- IOADDRESS iob=pRendition->board.io_base;
++ unsigned long iob=pRendition->board.io_base;
+ vu32 temp;
+
+ xf86MonPtr MonInfo = NULL;
+@@ -1517,7 +1521,7 @@ static unsigned int
+ renditionDDC1Read (ScrnInfoPtr pScreenInfo)
+ {
+ renditionPtr pRendition = RENDITIONPTR(pScreenInfo);
+- IOADDRESS iob=pRendition->board.io_base;
++ unsigned long iob=pRendition->board.io_base;
+ vu32 value = 0;
+
+ /* wait for Vsync */
+diff --git a/src/v1krisc.c b/src/v1krisc.c
+index 2554263..9b7b4e2 100644
+--- a/src/v1krisc.c
++++ b/src/v1krisc.c
+@@ -83,20 +83,20 @@
+ * local function prototypes
+ */
+
+-static void verite_iopoll(IOADDRESS port, vu32 data, vu32 mask);
+-static void verite_iopoll8(IOADDRESS port, vu8 data, vu8 mask);
++static void verite_iopoll(unsigned long port, vu32 data, vu32 mask);
++static void verite_iopoll8(unsigned long port, vu8 data, vu8 mask);
+
+-static vu32 readRF(IOADDRESS io_base, vu8 index);
+-static void writeRF(IOADDRESS io_base, vu8 index, vu32 data);
++static vu32 readRF(unsigned long io_base, vu8 index);
++static void writeRF(unsigned long io_base, vu8 index, vu32 data);
+
+-static vu32 risc_readmem(IOADDRESS io_base, vu32 addr, vu8 read_type);
+-static void risc_writemem(IOADDRESS io_base, vu32 addr, vu32 data, vu8 write_type);
++static vu32 risc_readmem(unsigned long io_base, vu32 addr, vu8 read_type);
++static void risc_writemem(unsigned long io_base, vu32 addr, vu32 data, vu8 write_type);
+
+ #if 0
+-static void risc_step(IOADDRESS io_base, vu32 count);
++static void risc_step(unsigned long io_base, vu32 count);
+ #endif
+-static void risc_forcestep(IOADDRESS io_base, vu32 instruction);
+-static void risc_continue(IOADDRESS io_base);
++static void risc_forcestep(unsigned long io_base, vu32 instruction);
++static void risc_continue(unsigned long io_base);
+
+
+
+@@ -113,7 +113,7 @@ void
+ v1k_start(ScrnInfoPtr pScreenInfo, vu32 pc)
+ {
+ renditionPtr pRendition = RENDITIONPTR(pScreenInfo);
+- IOADDRESS io_base=pRendition->board.io_base;
++ unsigned long io_base=pRendition->board.io_base;
+
+ v1k_stop(pScreenInfo);
+ risc_forcestep(io_base, NOP_INSTR);
+@@ -152,7 +152,7 @@ v1k_stop(ScrnInfoPtr pScreenInfo)
+ {
+ renditionPtr pRendition = RENDITIONPTR(pScreenInfo);
+ vu8 debugreg, statusreg;
+- IOADDRESS io_base=pRendition->board.io_base;
++ unsigned long io_base=pRendition->board.io_base;
+ vu16 STATUS = 0x4A; /* v2x00 io register offset */
+ int c;
+
+@@ -207,7 +207,7 @@ v1k_flushicache(ScrnInfoPtr pScreenInfo)
+ {
+ renditionPtr pRendition = RENDITIONPTR(pScreenInfo);
+ vu32 c, p1, p2;
+- IOADDRESS io_base=pRendition->board.io_base;
++ unsigned long io_base=pRendition->board.io_base;
+
+ /* first flush store accumulation buffers so data is all in memory */
+ p1=risc_readmem(io_base, 0, READ_WORD);
+@@ -255,7 +255,7 @@ void
+ v1k_softreset(ScrnInfoPtr pScreenInfo)
+ {
+ renditionPtr pRendition = RENDITIONPTR(pScreenInfo);
+- IOADDRESS io_base=pRendition->board.io_base;
++ unsigned long io_base=pRendition->board.io_base;
+
+ verite_out8(io_base+DEBUGREG, SOFTRESET|HOLDRISC);
+ verite_out8(io_base+STATEINDEX, STATEINDEX_PC);
+@@ -300,12 +300,12 @@ v1k_getriscprocs(verite_board_desc *boardDesc)
+ */
+
+ /*
+- * static void verite_iopoll(IOADDRESS port, vu32 data, vu32 mask)
++ * static void verite_iopoll(unsigned long port, vu32 data, vu32 mask)
+ *
+ * Loop on IO read until expected data is read or VERITE_MAX_POLLS is reached.
+ */
+ static void
+-verite_iopoll(IOADDRESS port, vu32 data, vu32 mask)
++verite_iopoll(unsigned long port, vu32 data, vu32 mask)
+ {
+ vu32 c;
+
+@@ -320,12 +320,12 @@ verite_iopoll(IOADDRESS port, vu32 data, vu32 mask)
+
+
+ /*
+- * static void verite_iopoll8(IOADDRESS port, vu8 data, vu8 mask)
++ * static void verite_iopoll8(unsigned long port, vu8 data, vu8 mask)
+ *
+ * Loop on IO read until expected data is read or VERITE_MAX_POLLS is reached.
+ */
+ static void
+-verite_iopoll8(IOADDRESS port, vu8 data, vu8 mask)
++verite_iopoll8(unsigned long port, vu8 data, vu8 mask)
+ {
+ vu32 c;
+
+@@ -340,12 +340,12 @@ verite_iopoll8(IOADDRESS port, vu8 data, vu8 mask)
+
+
+ /*
+- * static vu32 readRF(IOADDRESS io_base, vu8 index)
++ * static vu32 readRF(unsigned long io_base, vu8 index)
+ *
+ * Reads data from register file.
+ */
+ static vu32
+-readRF(IOADDRESS io_base, vu8 index)
++readRF(unsigned long io_base, vu8 index)
+ {
+ vu32 data, instr;
+ vu8 debug, stateindex;
+@@ -378,12 +378,12 @@ readRF(IOADDRESS io_base, vu8 index)
+
+
+ /*
+- * static void writeRF(IOADDRESS io_base, vu8 index, vu32 data)
++ * static void writeRF(unsigned long io_base, vu8 index, vu32 data)
+ *
+ * Set RF register, being careful on how to set regs below 64.
+ */
+ static void
+-writeRF(IOADDRESS io_base, vu8 index, vu32 data)
++writeRF(unsigned long io_base, vu8 index, vu32 data)
+ {
+ vu8 special=0;
+
+@@ -417,12 +417,12 @@ writeRF(IOADDRESS io_base, vu8 index, vu32 data)
+
+
+ /*
+- * static vu32 risc_readmem(IOADDRESS io_base, vu32 addr, vu8 read_type)
++ * static vu32 risc_readmem(unsigned long io_base, vu32 addr, vu8 read_type)
+ *
+ * NOTE: Assumes RISC is in hold mode.
+ */
+ static vu32
+-risc_readmem(IOADDRESS io_base, vu32 addr, vu8 read_type)
++risc_readmem(unsigned long io_base, vu32 addr, vu8 read_type)
+ {
+ vu32 data;
+
+@@ -445,12 +445,12 @@ risc_readmem(IOADDRESS io_base, vu32 addr, vu8 read_type)
+
+
+ /*
+- * static vu32 risc_writemem(IOADDRESS io_base, vu32 addr, vu32 data, vu8 write_type)
++ * static vu32 risc_writemem(unsigned long io_base, vu32 addr, vu32 data, vu8 write_type)
+ *
+ * NOTE: Assumes RISC is in hold mode.
+ */
+ static void
+-risc_writemem(IOADDRESS io_base, vu32 addr, vu32 data, vu8 write_type)
++risc_writemem(unsigned long io_base, vu32 addr, vu32 data, vu8 write_type)
+ {
+ writeRF(io_base, RISC_RA, addr); /* point to memory */
+ writeRF(io_base, RISC_FP, data); /* set data */
+@@ -466,12 +466,12 @@ risc_writemem(IOADDRESS io_base, vu32 addr, vu32 data, vu8 write_type)
+
+ #if 0
+ /*
+- * static void risc_step(IOADDRESS io_base, vu32 count)
++ * static void risc_step(unsigned long io_base, vu32 count)
+ *
+ * Single step the RISC. NOTE: Do not force instruction into RISCIR!
+ */
+ static void
+-risc_step(IOADDRESS io_base, vu32 count)
++risc_step(unsigned long io_base, vu32 count)
+ {
+ vu32 c, d;
+ vu8 debugreg;
+@@ -494,12 +494,12 @@ risc_step(IOADDRESS io_base, vu32 count)
+
+
+ /*
+- * static void risc_forcestep(IOADDRESS io_base, vu32 instruction)
++ * static void risc_forcestep(unsigned long io_base, vu32 instruction)
+ *
+ * Single step RISC; force instruction; assumes RISC held.
+ */
+ static void
+-risc_forcestep(IOADDRESS io_base, vu32 instruction)
++risc_forcestep(unsigned long io_base, vu32 instruction)
+ {
+ vu32 c;
+ vu8 debugreg, stateindex;
+@@ -525,12 +525,12 @@ risc_forcestep(IOADDRESS io_base, vu32 instruction)
+
+
+ /*
+- * static void risc_continue(IOADDRESS io_base)
++ * static void risc_continue(unsigned long io_base)
+ *
+ * Turn off hold bit.
+ */
+ static void
+-risc_continue(IOADDRESS io_base)
++risc_continue(unsigned long io_base)
+ {
+ vu8 debugreg;
+
+diff --git a/src/vboard.c b/src/vboard.c
+index 49499e2..622715f 100644
+--- a/src/vboard.c
++++ b/src/vboard.c
+@@ -38,7 +38,7 @@ verite_initboard(ScrnInfoPtr pScreenInfo)
+ {
+ renditionPtr pRendition = RENDITIONPTR(pScreenInfo);
+
+- IOADDRESS iob=pRendition->board.io_base;
++ unsigned long iob=pRendition->board.io_base;
+ vu8 *vmb;
+ vu32 offset;
+ vu8 memendian;
+@@ -207,7 +207,7 @@ void
+ verite_check_csucode(ScrnInfoPtr pScreenInfo)
+ {
+ renditionPtr pRendition = RENDITIONPTR(pScreenInfo);
+- IOADDRESS iob=pRendition->board.io_base;
++ unsigned long iob=pRendition->board.io_base;
+ vu8 *vmb;
+ vu32 offset;
+ int c;
+diff --git a/src/vgafont-std.data b/src/vgafont-std.data
+index db63ea8..c47983f 100644
+--- a/src/vgafont-std.data
++++ b/src/vgafont-std.data
+@@ -1,4 +1,3 @@
+-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/rendition/vgafont-std.data,v 1.3 1999/10/13 04:21:22 dawes Exp $ */
+ #ifndef __VGAFONT_STD__
+ #define __VGAFONT_STD__
+
+diff --git a/src/vgafont-vrx.data b/src/vgafont-vrx.data
+index ad34582..23b5908 100644
+--- a/src/vgafont-vrx.data
++++ b/src/vgafont-vrx.data
+@@ -1,4 +1,3 @@
+-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/rendition/vgafont-vrx.data,v 1.3 1999/10/13 04:21:23 dawes Exp $ */
+ #ifndef __VGAFONT_VRX__
+ #define __VGAFONT_VRX__
+
+diff --git a/src/vgapalette.data b/src/vgapalette.data
+index 5267608..106028d 100644
+--- a/src/vgapalette.data
++++ b/src/vgapalette.data
+@@ -1,4 +1,3 @@
+-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/rendition/vgapalette.data,v 1.3 1999/10/13 04:21:23 dawes Exp $ */
+ #ifndef __VGAPALETTE__
+ #define __VGAPALETTE__
+
+diff --git a/src/vloaduc.c b/src/vloaduc.c
+index 67bf901..5c6aab0 100644
+--- a/src/vloaduc.c
++++ b/src/vloaduc.c
+@@ -103,7 +103,7 @@ verite_load_ucfile(ScrnInfoPtr pScreenInfo, char *file_name)
+ sz=SW16(ehdr.e_phentsize);
+ num=SW16(ehdr.e_phnum);
+ if (0!=sz && 0!=num) {
+- orig_pphdr=pphdr=(Elf32_Phdr *)xalloc(sz*num);
++ orig_pphdr=pphdr=(Elf32_Phdr *)malloc(sz*num);
+ if (!pphdr) {
+ ErrorF("RENDITION: Cannot allocate global memory (1)\n");
+ close(fd);
+@@ -125,7 +125,7 @@ verite_load_ucfile(ScrnInfoPtr pScreenInfo, char *file_name)
+ sz=SW16(ehdr.e_shentsize);
+ num=SW16(ehdr.e_shnum);
+ if (0!=sz && 0!=num) {
+- orig_pshdr=pshdr=(Elf32_Shdr *)xalloc(sz*num);
++ orig_pshdr=pshdr=(Elf32_Shdr *)malloc(sz*num);
+ if (!pshdr) {
+ ErrorF("RENDITION: Cannot allocate global memory (2)\n");
+ close(fd);
+@@ -148,7 +148,7 @@ verite_load_ucfile(ScrnInfoPtr pScreenInfo, char *file_name)
+ loadSegment2board(pScreenInfo, fd, pphdr);
+ pphdr=(Elf32_Phdr *)(((char *)pphdr)+sz);
+ } while (--num);
+- xfree(orig_pphdr);
++ free(orig_pphdr);
+ }
+ else {
+ do {
+@@ -158,7 +158,7 @@ verite_load_ucfile(ScrnInfoPtr pScreenInfo, char *file_name)
+ loadSection2board(pScreenInfo, fd, pshdr);
+ pshdr=(Elf32_Shdr *)(((char *)pshdr)+sz);
+ } while (--num) ;
+- xfree(orig_pshdr);
++ free(orig_pshdr);
+ }
+ close(fd);
+
+@@ -195,7 +195,7 @@ loadSegment2board(ScrnInfoPtr pScreenInfo, int fd, Elf32_Phdr *phdr)
+ return;
+ }
+
+- data=(vu8 *)xalloc(size);
++ data=(vu8 *)malloc(size);
+ if (NULL == data){
+ ErrorF("RENDITION: GlobalAllocPtr couldn't allocate %lx bytes",
+ (unsigned long)size);
+@@ -210,7 +210,7 @@ loadSegment2board(ScrnInfoPtr pScreenInfo, int fd, Elf32_Phdr *phdr)
+
+ mmve(pScreenInfo, size, data, physAddr);
+
+- xfree(data);
++ free(data);
+ }
+
+
+diff --git a/src/vmodes.c b/src/vmodes.c
+index c0bd0df..f2dae0b 100644
+--- a/src/vmodes.c
++++ b/src/vmodes.c
+@@ -20,6 +20,7 @@
+ #include "v1kregs.h"
+ #include "v2kregs.h"
+
++#include <unistd.h>
+
+ #undef DEBUG
+
+@@ -201,7 +202,7 @@ struct V1000ClocksStr {
+ * local function prototypes
+ */
+
+-static void set_PLL(IOADDRESS iob, vu32 value);
++static void set_PLL(unsigned long iob, vu32 value);
+ static double V1000CalcClock(double target, int *M, int *N, int *P);
+ static double V2200CalcClock(double target, int *m, int *n, int *p);
+
+@@ -509,13 +510,13 @@ verite_getstride(ScrnInfoPtr pScreenInfo, int *width,
+ */
+
+ /*
+- * void set_PLL(IOADDRESS iob, vu32 value)
++ * void set_PLL(unsigned long iob, vu32 value)
+ *
+ * Set PLL clock to desired frequency for the V1000.
+ */
+
+ void
+-set_PLL(IOADDRESS iob, vu32 value)
++set_PLL(unsigned long iob, vu32 value)
+ {
+ vu32 ulD;
+ int b;
+diff --git a/src/vos.h b/src/vos.h
+index 7b55f77..999c870 100644
+--- a/src/vos.h
++++ b/src/vos.h
+@@ -23,18 +23,18 @@
+ /*
+ * function prototypes
+ */
+-#define /*void*/ verite_out8(/*IOADDRESS*/ port, /*vu8*/ data) \
++#define /*void*/ verite_out8(/*unsigned long*/ port, /*vu8*/ data) \
+ outb(port, data)
+
+-#define /*void*/ verite_out16(/*IOADDRESS*/ port, /*vu16*/ data) \
++#define /*void*/ verite_out16(/*unsigned long*/ port, /*vu16*/ data) \
+ outw(port, data)
+
+-#define /*void*/ verite_out32(/*IOADDRESS*/ port, /*vu32*/ data) \
++#define /*void*/ verite_out32(/*unsigned long*/ port, /*vu32*/ data) \
+ outl(port, data)
+
+-#define /*vu8*/ verite_in8(/*IOADDRESS*/ io_base) ((vu8)inb(io_base))
+-#define /*vu16*/ verite_in16(/*IOADDRESS*/ io_base) ((vu16)inw(io_base))
+-#define /*vu32*/ verite_in32(/*IOADDRESS*/ io_base) ((vu32)inl(io_base))
++#define /*vu8*/ verite_in8(/*unsigned long*/ io_base) ((vu8)inb(io_base))
++#define /*vu16*/ verite_in16(/*unsigned long*/ io_base) ((vu16)inw(io_base))
++#define /*vu32*/ verite_in32(/*unsigned long*/ io_base) ((vu32)inl(io_base))
+
+ /* memory accesses */
+ #define verite_read_memory32(base, offset) MMIO_IN32(base, offset)
+diff --git a/src/vramdac.c b/src/vramdac.c
+index 7c8acbd..21c1df7 100644
+--- a/src/vramdac.c
++++ b/src/vramdac.c
+@@ -93,11 +93,11 @@
+ * local function prototypes
+ */
+
+-static void Bt485_write_masked(IOADDRESS port, vu8 reg, vu8 mask, vu8 data);
+-static void Bt485_write_cmd3_masked(IOADDRESS port, vu8 mask, vu8 data);
++static void Bt485_write_masked(unsigned long port, vu8 reg, vu8 mask, vu8 data);
++static void Bt485_write_cmd3_masked(unsigned long port, vu8 mask, vu8 data);
+ #if 0
+-static vu8 Bt485_read_masked(IOADDRESS port, vu8 reg, vu8 mask);
+-static vu8 Bt485_read_cmd3_masked(IOADDRESS port, vu8 mask);
++static vu8 Bt485_read_masked(unsigned long port, vu8 reg, vu8 mask);
++static vu8 Bt485_read_cmd3_masked(unsigned long port, vu8 mask);
+ #endif
+
+ /*
+@@ -159,7 +159,7 @@ int
+ verite_initdac(ScrnInfoPtr pScreenInfo, vu8 bpp, vu8 doubleclock)
+ {
+ renditionPtr pRendition = RENDITIONPTR(pScreenInfo);
+- IOADDRESS iob=pRendition->board.io_base+RAMDACBASEADDR;
++ unsigned long iob=pRendition->board.io_base+RAMDACBASEADDR;
+ vu8 cmd0,cmd1,cmd2;
+ vu8 cmd3_data=0;
+
+@@ -271,7 +271,7 @@ verite_enablecursor(ScrnInfoPtr pScreenInfo, int type, int size)
+ BT485_3_COLOR_CURSOR, BT485_X_WINDOW_CURSOR };
+ static vu8 csizes[]={ BT485_32_BY_32_CURSOR, BT485_64_BY_64_CURSOR };
+
+- IOADDRESS iob=pRendition->board.io_base+RAMDACBASEADDR;
++ unsigned long iob=pRendition->board.io_base+RAMDACBASEADDR;
+
+ #ifdef DEBUG
+ ErrorF ("Rendition: Debug verite_enablecursor called type=0x%x\n",type);
+@@ -304,7 +304,7 @@ void
+ verite_movecursor(ScrnInfoPtr pScreenInfo, vu16 x, vu16 y, vu8 xo, vu8 yo)
+ {
+ renditionPtr pRendition = RENDITIONPTR(pScreenInfo);
+- IOADDRESS iob=pRendition->board.io_base+RAMDACBASEADDR;
++ unsigned long iob=pRendition->board.io_base+RAMDACBASEADDR;
+
+ x+=Cursor_size-xo;
+ y+=Cursor_size-yo;
+@@ -327,7 +327,7 @@ void
+ verite_setcursorcolor(ScrnInfoPtr pScreenInfo, vu32 fg, vu32 bg)
+ {
+ renditionPtr pRendition = RENDITIONPTR(pScreenInfo);
+- IOADDRESS iob=pRendition->board.io_base+RAMDACBASEADDR;
++ unsigned long iob=pRendition->board.io_base+RAMDACBASEADDR;
+
+ #ifdef DEBUG
+ ErrorF ("Rendition: Debug verite_setcursorcolor called FG=0x%x BG=0x%x\n",
+@@ -374,7 +374,7 @@ verite_loadcursor(ScrnInfoPtr pScreenInfo, vu8 size, vu8 *cursorimage)
+ int c, bytes, row;
+ vu8 *src = cursorimage;
+ renditionPtr pRendition = RENDITIONPTR(pScreenInfo);
+- IOADDRESS iob=pRendition->board.io_base+RAMDACBASEADDR;
++ unsigned long iob=pRendition->board.io_base+RAMDACBASEADDR;
+ vu8 tmp;
+ vu8 memend; /* Added for byte-swap fix */
+
+@@ -454,7 +454,7 @@ verite_setpalette(ScrnInfoPtr pScreenInfo, int numColors, int *indices,
+ LOCO *colors, VisualPtr pVisual)
+ {
+ renditionPtr pRendition = RENDITIONPTR(pScreenInfo);
+- IOADDRESS iob=pRendition->board.io_base;
++ unsigned long iob=pRendition->board.io_base;
+ vu32 crtc_status;
+ int i, index;
+
+@@ -485,12 +485,12 @@ verite_setpalette(ScrnInfoPtr pScreenInfo, int numColors, int *indices,
+ */
+
+ /*
+- * static void Bt485_write_masked(IOADDRESS port, vu8 reg, vu8 mask, vu8 data)
++ * static void Bt485_write_masked(unsigned long port, vu8 reg, vu8 mask, vu8 data)
+ *
+ *
+ */
+ static void
+-Bt485_write_masked(IOADDRESS port, vu8 reg, vu8 mask, vu8 data)
++Bt485_write_masked(unsigned long port, vu8 reg, vu8 mask, vu8 data)
+ {
+ vu8 tmp;
+
+@@ -501,12 +501,12 @@ Bt485_write_masked(IOADDRESS port, vu8 reg, vu8 mask, vu8 data)
+
+
+ /*
+- * static void Bt485_write_cmd3_masked(IOADDRESS port, vu8 mask, vu8 data)
++ * static void Bt485_write_cmd3_masked(unsigned long port, vu8 mask, vu8 data)
+ *
+ *
+ */
+ static void
+-Bt485_write_cmd3_masked(IOADDRESS port, vu8 mask, vu8 data)
++Bt485_write_cmd3_masked(unsigned long port, vu8 mask, vu8 data)
+ {
+ /*
+ * Bt485_write_masked(port, BT485_COMMAND_REG_0, 0x7f, 0x80);
+@@ -522,24 +522,24 @@ Bt485_write_cmd3_masked(IOADDRESS port, vu8 mask, vu8 data)
+
+ #if 0
+ /*
+- * static vu8 Bt485_read_masked(IOADDRESS port, vu8 reg, vu8 mask)
++ * static vu8 Bt485_read_masked(unsigned long port, vu8 reg, vu8 mask)
+ *
+ *
+ */
+ static vu8
+-Bt485_read_masked(IOADDRESS port, vu8 reg, vu8 mask)
++Bt485_read_masked(unsigned long port, vu8 reg, vu8 mask)
+ {
+ return verite_in8(port+reg)&mask;
+ }
+
+
+ /*
+- * static vu8 Bt485_read_cmd3_masked(IOADDRESS port, vu8 mask)
++ * static vu8 Bt485_read_cmd3_masked(unsigned long port, vu8 mask)
+ *
+ *
+ */
+ static vu8
+-Bt485_read_cmd3_masked(IOADDRESS port, vu8 mask)
++Bt485_read_cmd3_masked(unsigned long port, vu8 mask)
+ {
+ vu8 value;
+
+diff --git a/src/vtypes.h b/src/vtypes.h
+index 257870b..e4ad468 100644
+--- a/src/vtypes.h
++++ b/src/vtypes.h
+@@ -123,7 +123,7 @@ struct verite_board_t {
+ vu16 chip;
+
+ /* */
+- IOADDRESS io_base, vgaio_base;
++ unsigned long io_base, vgaio_base;
+ vu32 mmio_base;
+ vu32 vmmio_base;
+ vu32 mem_size;
diff --git a/extra/xf86-video-s3/PKGBUILD b/extra/xf86-video-s3/PKGBUILD
index 54b255a01..15590e56c 100644
--- a/extra/xf86-video-s3/PKGBUILD
+++ b/extra/xf86-video-s3/PKGBUILD
@@ -1,16 +1,16 @@
-# $Id: PKGBUILD 140308 2011-10-11 21:28:45Z jgc $
+# $Id: PKGBUILD 153360 2012-03-12 20:54:02Z andyrtr $
# Maintainer: Jan de Groot <jgc@archlinux.org>
pkgname=xf86-video-s3
pkgver=0.6.3
-pkgrel=6
+pkgrel=7
pkgdesc="X.org S3 video driver"
arch=(i686 x86_64)
url="http://xorg.freedesktop.org/"
license=('custom')
depends=('glibc')
-makedepends=('xorg-server-devel>=1.11.0')
-conflicts=('xorg-server<1.11.0')
+makedepends=('xorg-server-devel>=1.11.99.903')
+conflicts=('xorg-server<1.11.99.903')
options=('!libtool')
groups=('xorg-drivers' 'xorg')
source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2
@@ -24,6 +24,10 @@ build() {
autoreconf -fi
./configure --prefix=/usr
make
+}
+
+package() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
make DESTDIR="${pkgdir}" install
install -m755 -d "${pkgdir}/usr/share/licenses/${pkgname}"
diff --git a/extra/xf86-video-s3virge/PKGBUILD b/extra/xf86-video-s3virge/PKGBUILD
index 650769602..95a00dd82 100644
--- a/extra/xf86-video-s3virge/PKGBUILD
+++ b/extra/xf86-video-s3virge/PKGBUILD
@@ -1,29 +1,36 @@
-# $Id: PKGBUILD 140310 2011-10-11 21:28:47Z jgc $
+# $Id: PKGBUILD 153362 2012-03-12 20:54:08Z andyrtr $
# Maintainer: Jan de Groot <jgc@archlinux.org>
# Contributor: Alexander Baldeck <alexander@archlinux.org>
pkgname=xf86-video-s3virge
pkgver=1.10.4
-pkgrel=6
+pkgrel=7
pkgdesc="X.org S3 Virge video driver"
arch=(i686 x86_64)
url="http://xorg.freedesktop.org/"
license=('custom')
depends=('glibc')
-makedepends=('pkgconfig' 'xorg-server-devel>=1.10.99.902')
-conflicts=('xorg-server<1.10.99.902')
+makedepends=('pkgconfig' 'xorg-server-devel>=1.11.99.903')
+conflicts=('xorg-server<1.11.99.903')
options=(!libtool)
groups=('xorg-drivers' 'xorg')
source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2
- copyright.patch)
+ copyright.patch
+ s3virge-1.10.4-vga.patch)
md5sums=('6517bbbf808c700502d51acdc44662f8'
- 'f91fb259e3632fb9130fcbe69ecd9d6a')
+ 'f91fb259e3632fb9130fcbe69ecd9d6a'
+ '45c7d912734c9f7dfc1f42077827cb8e')
build() {
cd "${srcdir}/${pkgname}-${pkgver}"
patch -Np1 -i "${srcdir}/copyright.patch"
+ patch -Np1 -i ${srcdir}/s3virge-1.10.4-vga.patch
./configure --prefix=/usr
make
+}
+
+package() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
make DESTDIR="${pkgdir}" install
install -m755 -d "${pkgdir}/usr/share/licenses/${pkgname}"
diff --git a/extra/xf86-video-s3virge/copyright.patch b/extra/xf86-video-s3virge/copyright.patch
new file mode 100644
index 000000000..ba988c6d6
--- /dev/null
+++ b/extra/xf86-video-s3virge/copyright.patch
@@ -0,0 +1,82 @@
+From c26da404906258951341c4c4ace793f2dfdc47f8 Mon Sep 17 00:00:00 2001
+From: Gaetan Nadon <memsize@videotron.ca>
+Date: Sun, 13 Jun 2010 14:26:32 +0000
+Subject: COPYING: update file with Copyright notices from source code.
+
+Signed-off-by: Gaetan Nadon <memsize@videotron.ca>
+---
+diff --git a/COPYING b/COPYING
+index 7f33cbf..727ca51 100644
+--- a/COPYING
++++ b/COPYING
+@@ -1,12 +1,60 @@
+-This is a stub file. This package has not yet had its complete licensing
+-information compiled. Please see the individual source files for details on
+-your rights to use and modify this software.
++Copyright (C) 1994-2000 The XFree86 Project, Inc. All Rights Reserved.
+
+-Please submit updated COPYING files to the Xorg bugzilla:
++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:
+
+-https://bugs.freedesktop.org/enter_bug.cgi?product=xorg
++The above copyright notice and this permission notice shall be included in all
++copies or substantial portions of the Software.
+
+-All licensing questions regarding this software should be directed at the
+-Xorg mailing list:
++THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
++IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FIT-
++NESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
++XFREE86 PROJECT 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.
++
++Except as contained in this notice, the name of the XFree86 Project shall not
++be used in advertising or otherwise to promote the sale, use or other dealings
++in this Software without prior written authorization from the XFree86 Project.
++
++Written by Jake Richter Copyright (c) 1989, 1990 Panacea Inc., Londonderry,
++NH - All Rights Reserved
++
++This code may be freely incorporated in any program without royalty, as long
++as the copyright notice stays intact.
++
++Additions by Kevin E. Martin (martin@cs.unc.edu)
++
++KEVIN E. MARTIN DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
++INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO
++EVENT SHALL KEVIN E. MARTIN BE LIABLE FOR ANY SPECIAL, INDIRECT OR
++CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF
++USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
++OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
++PERFORMANCE OF THIS SOFTWARE.
++
++Copyright 2007 George Sapountzis
++
++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 (including the next
++paragraph) 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
++THE AUTHORS OR COPYRIGHT HOLDERS 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.
+
+-http://lists.freedesktop.org/mailman/listinfo/xorg
+--
+cgit v0.9.0.2-2-gbebe
diff --git a/extra/xf86-video-s3virge/s3virge-1.10.4-vga.patch b/extra/xf86-video-s3virge/s3virge-1.10.4-vga.patch
new file mode 100644
index 000000000..3fb1fd6cf
--- /dev/null
+++ b/extra/xf86-video-s3virge/s3virge-1.10.4-vga.patch
@@ -0,0 +1,76 @@
+From 92b4671ca75022a56ad9e85b347f81c12157c98f Mon Sep 17 00:00:00 2001
+From: Adam Jackson <ajax@redhat.com>
+Date: Wed, 16 Nov 2011 19:58:29 +0000
+Subject: Adapt to missing PIOOffset in videoabi 12
+
+Signed-off-by: Adam Jackson <ajax@redhat.com>
+---
+diff --git a/src/s3v_driver.c b/src/s3v_driver.c
+index 2ced9ac..0f754dd 100644
+--- a/src/s3v_driver.c
++++ b/src/s3v_driver.c
+@@ -3516,11 +3516,17 @@ S3VEnableMmio(ScrnInfoPtr pScrn)
+ S3VPtr ps3v;
+ IOADDRESS vgaCRIndex, vgaCRReg;
+ unsigned char val;
+-
++ unsigned int PIOOffset = 0;
++
+ PVERB5(" S3VEnableMmio\n");
+
+ hwp = VGAHWPTR(pScrn);
+ ps3v = S3VPTR(pScrn);
++
++#if ABI_VIDEODRV_VERSION < 12
++ PIOOffset = hwp->PIOOffset;
++#endif
++
+ /*
+ * enable chipset (seen on uninitialized secondary cards)
+ * might not be needed once we use the VGA softbooter
+@@ -3533,17 +3539,17 @@ S3VEnableMmio(ScrnInfoPtr pScrn)
+ * to be set correctly already and MMIO _has_ to be
+ * enabled.
+ */
+- val = inb(hwp->PIOOffset + 0x3C3); /*@@@EE*/
+- outb(hwp->PIOOffset + 0x3C3, val | 0x01);
++ val = inb(PIOOffset + 0x3C3); /*@@@EE*/
++ outb(PIOOffset + 0x3C3, val | 0x01);
+ /*
+ * set CR registers to color mode
+ * in mono mode extended CR registers
+ * are not accessible. (EE 05/04/99)
+ */
+- val = inb(hwp->PIOOffset + VGA_MISC_OUT_R); /*@@@EE*/
+- outb(hwp->PIOOffset + VGA_MISC_OUT_W, val | 0x01);
++ val = inb(PIOOffset + VGA_MISC_OUT_R); /*@@@EE*/
++ outb(PIOOffset + VGA_MISC_OUT_W, val | 0x01);
+ vgaHWGetIOBase(hwp); /* Get VGA I/O base */
+- vgaCRIndex = hwp->PIOOffset + hwp->IOBase + 4;
++ vgaCRIndex = PIOOffset + hwp->IOBase + 4;
+ vgaCRReg = vgaCRIndex + 1;
+ #if 1
+ /*
+@@ -3562,7 +3568,7 @@ S3VEnableMmio(ScrnInfoPtr pScrn)
+ /* Enable new MMIO, if TRIO mmio is already */
+ /* enabled, then it stays enabled. */
+ outb(vgaCRReg, ps3v->EnableMmioCR53 | 0x08);
+- outb(hwp->PIOOffset + VGA_MISC_OUT_W, val);
++ outb(PIOOffset + VGA_MISC_OUT_W, val);
+ if (S3_TRIO_3D_SERIES(ps3v->Chipset)) {
+ outb(vgaCRIndex, 0x40);
+ val = inb(vgaCRReg);
+@@ -3584,7 +3590,10 @@ S3VDisableMmio(ScrnInfoPtr pScrn)
+ hwp = VGAHWPTR(pScrn);
+ ps3v = S3VPTR(pScrn);
+
+- vgaCRIndex = hwp->PIOOffset + hwp->IOBase + 4;
++ vgaCRIndex = hwp->IOBase + 4;
++#if ABI_VIDEODRV_VERSION < 12
++ vgaCRIndex += hwp->PIOOffset;
++#endif
+ vgaCRReg = vgaCRIndex + 1;
+ outb(vgaCRIndex, 0x53);
+ /* Restore register's original state */
+--
+cgit v0.9.0.2-2-gbebe
diff --git a/extra/xf86-video-savage/PKGBUILD b/extra/xf86-video-savage/PKGBUILD
index f305995f7..e01fa5d93 100644
--- a/extra/xf86-video-savage/PKGBUILD
+++ b/extra/xf86-video-savage/PKGBUILD
@@ -1,25 +1,35 @@
-# $Id: PKGBUILD 140306 2011-10-11 21:28:43Z jgc $
+# $Id: PKGBUILD 153364 2012-03-12 20:54:13Z andyrtr $
# Maintainer: Jan de Groot <jgc@archlinux.org>
pkgname=xf86-video-savage
pkgver=2.3.3
-pkgrel=1
+pkgrel=3
+_gitver=c4022796ec69bb3223d435d8442f9168aebe9c3d
pkgdesc="X.org savage video driver"
arch=(i686 x86_64)
url="http://xorg.freedesktop.org/"
license=('custom')
-depends=('glibc' 'savage-dri')
-makedepends=('xorg-server-devel' 'libdrm' 'xf86driproto' 'mesa' 'glproto')
-conflicts=('xorg-server<1.10.0')
+depends=('glibc')
+makedepends=('xorg-server-devel>=1.11.99.903') # 'libdrm' 'xf86driproto' 'mesa>=8.0') # 'glproto')
+conflicts=('xorg-server<1.11.99.903' 'savage-dri')
options=(!libtool !makeflags)
groups=('xorg-drivers' 'xorg')
-source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2)
-sha256sums=('d3854d375dbf7d83bf90e30d72837ce60d808119c6fa4bb98088e68e7cc7e7b2')
+source=(#${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2
+ #http://cgit.freedesktop.org/xorg/driver/xf86-video-savage/snapshot/xf86-video-savage-${_gitver}.tar.gz
+ ftp://ftp..archlinux.org/other/xf86-video-savage/xf86-video-savage-${_gitver}.tar.gz)
+md5sums=('3a7921de0d365ab5dd1af15010807e36')
build() {
- cd "${srcdir}/${pkgname}-${pkgver}"
- ./configure --prefix=/usr --enable-dri
+ #cd "${srcdir}/${pkgname}-${pkgver}"
+ cd ${srcdir}/${pkgname}*
+ autoreconf -fi
+ ./configure --prefix=/usr --disable-dri
make
+}
+
+package() {
+ #cd "${srcdir}/${pkgname}-${pkgver}"
+ cd ${srcdir}/${pkgname}*
make DESTDIR="${pkgdir}" install
install -d -m755 "${pkgdir}/usr/share/licenses/${pkgname}"
diff --git a/extra/xf86-video-siliconmotion/PKGBUILD b/extra/xf86-video-siliconmotion/PKGBUILD
index d77e30c1e..6ca6aca44 100644
--- a/extra/xf86-video-siliconmotion/PKGBUILD
+++ b/extra/xf86-video-siliconmotion/PKGBUILD
@@ -1,26 +1,33 @@
-# $Id: PKGBUILD 140304 2011-10-11 21:28:41Z jgc $
+# $Id: PKGBUILD 153366 2012-03-12 20:54:19Z andyrtr $
# Maintainer: Jan de Groot <jgc@archlinux.org>
# Contributor: Alexander Baldeck <alexander@archlinux.org>
pkgname=xf86-video-siliconmotion
pkgver=1.7.5
-pkgrel=3
+pkgrel=4
pkgdesc="X.org siliconmotion video driver"
arch=(i686 x86_64)
url="http://xorg.freedesktop.org/"
license=('custom')
depends=('glibc')
-makedepends=('xorg-server-devel>=1.10.99.902')
-conflicts=('xorg-server<1.10.99.902')
+makedepends=('xorg-server-devel>=1.11.99.903')
+conflicts=('xorg-server<1.11.99.903')
options=('!libtool')
groups=('xorg-drivers' 'xorg')
-source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2)
-sha1sums=('946acae0822d51da57abe8b7ed049691bd731589')
+source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2
+ smi-1.7.5-vga.patch)
+sha1sums=('946acae0822d51da57abe8b7ed049691bd731589'
+ '50b0e4aa858d7f8eb6f7e826f62fde23f01afe48')
build() {
cd "${srcdir}/${pkgname}-${pkgver}"
+ patch -Np1 -i ${srcdir}/smi-1.7.5-vga.patch
./configure --prefix=/usr
make
+}
+
+package() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
make DESTDIR="${pkgdir}" install
install -m755 -d "${pkgdir}/usr/share/licenses/${pkgname}"
diff --git a/extra/xf86-video-siliconmotion/smi-1.7.5-vga.patch b/extra/xf86-video-siliconmotion/smi-1.7.5-vga.patch
new file mode 100644
index 000000000..ef353f0df
--- /dev/null
+++ b/extra/xf86-video-siliconmotion/smi-1.7.5-vga.patch
@@ -0,0 +1,25 @@
+From 037b839c84ad6dcbe9aade420cf0d3bf06f23119 Mon Sep 17 00:00:00 2001
+From: Adam Jackson <ajax@redhat.com>
+Date: Wed, 16 Nov 2011 20:03:25 +0000
+Subject: Adapt to missing PIOOffset in videoabi 12
+
+Signed-off-by: Adam Jackson <ajax@redhat.com>
+---
+diff --git a/src/smi_driver.c b/src/smi_driver.c
+index 9c10e46..86644c7 100644
+--- a/src/smi_driver.c
++++ b/src/smi_driver.c
+@@ -442,7 +442,11 @@ SMI_PreInit(ScrnInfoPtr pScrn, int flags)
+ LEAVE(FALSE);
+
+ hwp = VGAHWPTR(pScrn);
++#if ABI_VIDEODRV_VERSION < 12
+ pSmi->PIOBase = hwp->PIOOffset;
++#else
++ pSmi->PIOBase = 0;
++#endif
+
+ xf86ErrorFVerb(VERBLEV, "\tSMI_PreInit vgaCRIndex=%x, vgaIOBase=%x, "
+ "MMIOBase=%p\n", hwp->IOBase + VGA_CRTC_INDEX_OFFSET,
+--
+cgit v0.9.0.2-2-gbebe
diff --git a/extra/xf86-video-sis/PKGBUILD b/extra/xf86-video-sis/PKGBUILD
index 8f247c1d4..42addf67d 100644
--- a/extra/xf86-video-sis/PKGBUILD
+++ b/extra/xf86-video-sis/PKGBUILD
@@ -1,25 +1,37 @@
-# $Id: PKGBUILD 140302 2011-10-11 21:28:39Z jgc $
+# $Id: PKGBUILD 153368 2012-03-12 20:54:25Z andyrtr $
# Maintainer: Jan de Groot <jgc@archlinux.org>
pkgname=xf86-video-sis
pkgver=0.10.3
-pkgrel=5
+pkgrel=7
pkgdesc="X.org SiS video driver"
arch=(i686 x86_64)
url="http://xorg.freedesktop.org/"
license=('custom')
-depends=('glibc' 'sis-dri')
-makedepends=('xorg-server-devel>=1.11.0' 'xf86dgaproto' 'libdrm' 'xf86driproto' 'mesa' 'glproto')
-conflicts=('xorg-server<1.11.0')
+depends=('glibc')
+makedepends=('xorg-server-devel>=1.11.99.903' 'xf86dgaproto')
+conflicts=('xorg-server<1.11.99.903')
options=('!libtool')
groups=('xorg-drivers' 'xorg')
-source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2)
-sha1sums=('158673747e240b0c33499685a32d46bdaead7cd5')
+source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2
+ git-f5dafa24.patch)
+sha1sums=('158673747e240b0c33499685a32d46bdaead7cd5'
+ 'b61c6a78723aa59f8c82152fec42475b611cd1e7')
build() {
cd "${srcdir}/${pkgname}-${pkgver}"
- ./configure --prefix=/usr --enable-dri
+ patch -Np1 -i "${srcdir}/git-f5dafa24.patch"
+ libtoolize --force --copy
+ aclocal
+ autoconf
+ automake
+
+ ./configure --prefix=/usr --disable-dri
make
+}
+
+package() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
make DESTDIR="${pkgdir}" install
install -m755 -d "${pkgdir}/usr/share/licenses/${pkgname}"
diff --git a/extra/xf86-video-sis/git-f5dafa24.patch b/extra/xf86-video-sis/git-f5dafa24.patch
new file mode 100644
index 000000000..8c15b974b
--- /dev/null
+++ b/extra/xf86-video-sis/git-f5dafa24.patch
@@ -0,0 +1,1654 @@
+diff --git a/configure.ac b/configure.ac
+index 33c0d65..62ad933 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -20,54 +20,53 @@
+ #
+ # Process this file with autoconf to produce a configure script
+
+-AC_PREREQ(2.57)
++# Initialize Autoconf
++AC_PREREQ([2.60])
+ AC_INIT([xf86-video-sis],
+- 0.10.3,
++ [0.10.3],
+ [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg],
+- xf86-video-sis)
+-
++ [xf86-video-sis])
+ AC_CONFIG_SRCDIR([Makefile.am])
+-AM_CONFIG_HEADER([config.h])
++AC_CONFIG_HEADERS([config.h])
+ AC_CONFIG_AUX_DIR(.)
+
++# Initialize Automake
+ AM_INIT_AUTOMAKE([foreign dist-bzip2])
+-
+ AM_MAINTAINER_MODE
+
+-# Require xorg-macros: XORG_DEFAULT_OPTIONS
++# Require X.Org macros 1.8 or later for MAN_SUBSTS set by XORG_MANPAGE_SECTIONS
+ m4_ifndef([XORG_MACROS_VERSION],
+- [m4_fatal([must install xorg-macros 1.3 or later before running autoconf/autogen])])
+-XORG_MACROS_VERSION(1.3)
++ [m4_fatal([must install xorg-macros 1.8 or later before running autoconf/autogen])])
++XORG_MACROS_VERSION(1.8)
+ XORG_DEFAULT_OPTIONS
+
+-# Checks for programs.
++# Initialize libtool
+ AC_DISABLE_STATIC
+ AC_PROG_LIBTOOL
+-AC_PROG_CC
+-XORG_PROG_RAWCPP
+
+ AH_TOP([#include "xorg-server.h"])
+
++# Define a configure option for an alternate module directory
+ AC_ARG_WITH(xorg-module-dir,
+- AC_HELP_STRING([--with-xorg-module-dir=DIR],
++ AS_HELP_STRING([--with-xorg-module-dir=DIR],
+ [Default xorg module directory [[default=$libdir/xorg/modules]]]),
+ [moduledir="$withval"],
+ [moduledir="$libdir/xorg/modules"])
+
+-AC_ARG_ENABLE(dri, AC_HELP_STRING([--disable-dri],
++AC_ARG_ENABLE(dri, AS_HELP_STRING([--disable-dri],
+ [Disable DRI support [[default=auto]]]),
+ [DRI="$enableval"],
+ [DRI=auto])
+
+-# Checks for extensions
++# Store the list of server defined optional extensions in REQUIRED_MODULES
+ XORG_DRIVER_CHECK_EXT(XINERAMA, xineramaproto)
+ XORG_DRIVER_CHECK_EXT(RANDR, randrproto)
+ XORG_DRIVER_CHECK_EXT(RENDER, renderproto)
+ XORG_DRIVER_CHECK_EXT(XV, videoproto)
+ XORG_DRIVER_CHECK_EXT(DPMSExtension, xextproto)
+
+-# Checks for pkg-config packages
+-PKG_CHECK_MODULES(XORG, [xorg-server >= 1.0.99.901 xproto fontsproto xf86dgaproto $REQUIRED_MODULES])
++# Obtain compiler/linker options for the driver dependencies
++PKG_CHECK_MODULES(XORG, [xorg-server >= 1.0.99.901 xproto fontsproto xf86dgaproto >= 2.1 $REQUIRED_MODULES])
+ PKG_CHECK_MODULES(XEXT, [xextproto >= 7.0.99.1],
+ HAVE_XEXTPROTO_71="yes"; AC_DEFINE(HAVE_XEXTPROTO_71, 1, [xextproto 7.1 available]),
+ HAVE_XEXTPROTO_71="no")
+@@ -76,9 +75,6 @@ sdkdir=`$PKG_CONFIG --variable=sdkdir xorg-server`
+
+ # Checks for libraries.
+
+-# Checks for header files.
+-AC_HEADER_STDC
+-
+ if test "$DRI" != no; then
+ AC_CHECK_FILE([${sdkdir}/dri.h],
+ [have_dri_h="yes"], [have_dri_h="no"])
+@@ -103,8 +99,8 @@ AC_MSG_RESULT([$DRI])
+ AM_CONDITIONAL(DRI, test x$DRI = xyes)
+ if test "$DRI" = yes; then
+ PKG_CHECK_MODULES(DRI, [libdrm >= 2.0 xf86driproto])
+- AC_DEFINE(XF86DRI,1,[Enable DRI driver support])
+- AC_DEFINE(XF86DRI_DEVEL,1,[Enable developmental DRI driver support])
++ AC_DEFINE(SISDRI,1,[Enable DRI driver support])
++ AC_DEFINE(SISDRI_DEVEL,1,[Enable developmental DRI driver support])
+ fi
+
+ # technically this should be a configure flag. meh.
+@@ -118,20 +114,19 @@ AC_CHECK_DECL(XSERVER_LIBPCIACCESS,
+ CPPFLAGS="$SAVE_CPPFLAGS"
+
+ if test "x$XSERVER_LIBPCIACCESS" = xyes; then
+- PKG_CHECK_MODULES([PCIACCESS], [pciaccess >= 0.10])
++ PKG_CHECK_MODULES([PCIACCESS], [pciaccess >= 0.12.901])
+ XORG_CFLAGS="$XORG_CFLAGS $PCIACCESS_CFLAGS"
+ fi
+ AM_CONDITIONAL(XSERVER_LIBPCIACCESS, test "x$XSERVER_LIBPCIACCESS" = xyes)
+
+-AC_SUBST([DRI_CFLAGS])
+-AC_SUBST([XORG_CFLAGS])
+ AC_SUBST([moduledir])
+
+ DRIVER_NAME=sis
+ AC_SUBST([DRIVER_NAME])
+
+-AC_OUTPUT([
+- Makefile
+- src/Makefile
+- man/Makefile
++AC_CONFIG_FILES([
++ Makefile
++ src/Makefile
++ man/Makefile
+ ])
++AC_OUTPUT
+diff --git a/man/Makefile.am b/man/Makefile.am
+index 1b26ac2..9ceb36f 100644
+--- a/man/Makefile.am
++++ b/man/Makefile.am
+@@ -31,39 +31,9 @@ EXTRA_DIST = @DRIVER_NAME@.man
+
+ CLEANFILES = $(driverman_DATA)
+
+-SED = sed
+-
+-# Strings to replace in man pages
+-XORGRELSTRING = @PACKAGE_STRING@
+- XORGMANNAME = X Version 11
+-
+-MANDEFS = \
+- -D__vendorversion__="\"$(XORGRELSTRING)\" \"$(XORGMANNAME)\"" \
+- -D__appmansuffix__=$(APP_MAN_SUFFIX) \
+- -D__filemansuffix__=$(FILE_MAN_SUFFIX) \
+- -D__libmansuffix__=$(LIB_MAN_SUFFIX) \
+- -D__miscmansuffix__=$(MISC_MAN_SUFFIX) \
+- -D__drivermansuffix__=$(DRIVER_MAN_SUFFIX) \
+- -D__adminmansuffix__=$(ADMIN_MAN_SUFFIX) \
+- -D__xconfigfile__=xorg.conf \
+- -D__xservername__=Xorg
+-
+-# Translate XCOMM into pound sign with sed, rather than passing -DXCOMM=XCOMM
+-# to cpp, because that trick does not work on all ANSI C preprocessors.
+-# Delete line numbers from the cpp output (-P is not portable, I guess).
+-# Allow XCOMM to be preceded by whitespace and provide a means of generating
+-# output lines with trailing backslashes.
+-# Allow XHASH to always be substituted, even in cases where XCOMM isn't.
+-
+-CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \
+- -e '/^\#line *[0-9][0-9]* *.*$$/d' \
+- -e '/^[ ]*XCOMM$$/s/XCOMM/\#/' \
+- -e '/^[ ]*XCOMM[^a-zA-Z0-9_]/s/XCOMM/\#/' \
+- -e '/^[ ]*XHASH/s/XHASH/\#/' \
+- -e '/\@\@$$/s/\@\@$$/\\/'
+-
+ SUFFIXES = .$(DRIVER_MAN_SUFFIX) .man
+
++# String replacements in MAN_SUBSTS now come from xorg-macros.m4 via configure
+ .man.$(DRIVER_MAN_SUFFIX):
+- $(RAWCPP) $(RAWCPPFLAGS) $(MANDEFS) $(EXTRAMANDEFS) < $< | $(CPP_SED_MAGIC) > $@
++ $(AM_V_GEN)$(SED) $(MAN_SUBSTS) < $< > $@
+
+diff --git a/man/sis.man b/man/sis.man
+index 9ae4a1b..578bb68 100644
+--- a/man/sis.man
++++ b/man/sis.man
+@@ -1,17 +1,5 @@
+-.\" $XFree86$
+-.\" $XdotOrg$
+ .\" shorthand for double quote that works everywhere.
+ .ds q \N'34'
+-#ifdef __xservername__
+-#define __myservername__ __xservername__
+-#else
+-#define __myservername__ XFree86
+-#endif
+-#ifdef __xconfigfile__
+-#define __myxconfigfile__ __xconfigfile__
+-#else
+-#define __myxconfigfile__ XF86Config
+-#endif
+ .TH SIS __drivermansuffix__ __vendorversion__
+ .SH NAME
+ sis \- SiS and XGI video driver
+@@ -25,7 +13,7 @@ sis \- SiS and XGI video driver
+ .fi
+ .SH DESCRIPTION
+ .B sis
+-is an __myservername__ driver for SiS (Silicon Integrated Systems) and XGI video
++is an __xservername__ driver for SiS (Silicon Integrated Systems) and XGI video
+ chips. The driver is accelerated and provides support for colordepths of 8, 16
+ and 24 bpp. XVideo, Render and other extensions are supported as well.
+ .SH SUPPORTED HARDWARE
+@@ -60,7 +48,7 @@ for SiS315, 55x, 330, 661/741/76x (plus M, FX, MX, GX variants thereof), 340
+ and all XGI chips.
+ .PP
+ .SH CONFIGURATION DETAILS
+-Please refer to __myxconfigfile__(__filemansuffix__) for general configuration
++Please refer to __xconfigfile__(__filemansuffix__) for general configuration
+ details. This section only covers configuration details specific to this
+ driver.
+ .PP
+@@ -428,11 +416,7 @@ The amount is to be specified in megabyte, the default is 8.
+ .SH "KNOWN BUGS"
+ none.
+ .SH "SEE ALSO"
+-#ifdef __xservername__
+ __xservername__(__appmansuffix__), __xconfigfile__(__filemansuffix__), Xserver(__appmansuffix__), X(__miscmansuffix__)
+-#else
+-XFree86(1), XF86Config(__filemansuffix__), xf86config(1), Xserver(1), X(__miscmansuffix__)
+-#endif
+ .PP
+ .B "http://www.winischhofer.eu/linuxsisvga.shtml"
+ for more information and updates
+diff --git a/src/initextx.c b/src/initextx.c
+index 5c00398..1e84d0f 100644
+--- a/src/initextx.c
++++ b/src/initextx.c
+@@ -238,10 +238,10 @@ SiSBuildBuiltInModeList(ScrnInfoPtr pScrn, BOOLEAN includelcdmodes, BOOLEAN isfo
+ continue;
+ }
+
+- if(!(new = xalloc(sizeof(DisplayModeRec)))) return first;
++ if(!(new = malloc(sizeof(DisplayModeRec)))) return first;
+ memset(new, 0, sizeof(DisplayModeRec));
+- if(!(new->name = xalloc(10))) {
+- xfree(new);
++ if(!(new->name = malloc(10))) {
++ free(new);
+ return first;
+ }
+ if(!first) first = new;
+@@ -385,11 +385,11 @@ SiSBuildBuiltInModeList(ScrnInfoPtr pScrn, BOOLEAN includelcdmodes, BOOLEAN isfo
+ }
+ }
+
+- if(!(new = xalloc(sizeof(DisplayModeRec)))) return first;
++ if(!(new = malloc(sizeof(DisplayModeRec)))) return first;
+
+ memset(new, 0, sizeof(DisplayModeRec));
+- if(!(new->name = xalloc(12))) {
+- xfree(new);
++ if(!(new->name = malloc(12))) {
++ free(new);
+ return first;
+ }
+ if(!first) first = new;
+@@ -470,11 +470,11 @@ SiSBuildBuiltInModeList(ScrnInfoPtr pScrn, BOOLEAN includelcdmodes, BOOLEAN isfo
+
+ if(pSiS->SiS_Pr->CP_DataValid[i]) {
+
+- if(!(new = xalloc(sizeof(DisplayModeRec)))) return first;
++ if(!(new = malloc(sizeof(DisplayModeRec)))) return first;
+
+ memset(new, 0, sizeof(DisplayModeRec));
+- if(!(new->name = xalloc(10))) {
+- xfree(new);
++ if(!(new->name = malloc(10))) {
++ free(new);
+ return first;
+ }
+ if(!first) first = new;
+diff --git a/src/osdef.h b/src/osdef.h
+index cd6b907..5776910 100644
+--- a/src/osdef.h
++++ b/src/osdef.h
+@@ -110,12 +110,12 @@
+ #warning sisfb will not work!
+ #endif
+
+-#define OutPortByte(p,v) outb((u8)(v),(IOADDRESS)(p))
+-#define OutPortWord(p,v) outw((u16)(v),(IOADDRESS)(p))
+-#define OutPortLong(p,v) outl((u32)(v),(IOADDRESS)(p))
+-#define InPortByte(p) inb((IOADDRESS)(p))
+-#define InPortWord(p) inw((IOADDRESS)(p))
+-#define InPortLong(p) inl((IOADDRESS)(p))
++#define OutPortByte(p,v) outb((u8)(v),(unsigned long)(p))
++#define OutPortWord(p,v) outw((u16)(v),(unsigned long)(p))
++#define OutPortLong(p,v) outl((u32)(v),(unsigned long)(p))
++#define InPortByte(p) inb((unsigned long)(p))
++#define InPortWord(p) inw((unsigned long)(p))
++#define InPortLong(p) inl((unsigned long)(p))
+ #define SiS_SetMemory(MemoryAddress,MemorySize,value) memset_io(MemoryAddress, value, MemorySize)
+
+ #endif /* LINUX_KERNEL */
+@@ -129,12 +129,12 @@
+ #define SIS300
+ #define SIS315H
+
+-#define OutPortByte(p,v) outSISREG((IOADDRESS)(p),(CARD8)(v))
+-#define OutPortWord(p,v) outSISREGW((IOADDRESS)(p),(CARD16)(v))
+-#define OutPortLong(p,v) outSISREGL((IOADDRESS)(p),(CARD32)(v))
+-#define InPortByte(p) inSISREG((IOADDRESS)(p))
+-#define InPortWord(p) inSISREGW((IOADDRESS)(p))
+-#define InPortLong(p) inSISREGL((IOADDRESS)(p))
++#define OutPortByte(p,v) outSISREG((unsigned long)(p),(CARD8)(v))
++#define OutPortWord(p,v) outSISREGW((unsigned long)(p),(CARD16)(v))
++#define OutPortLong(p,v) outSISREGL((unsigned long)(p),(CARD32)(v))
++#define InPortByte(p) inSISREG((unsigned long)(p))
++#define InPortWord(p) inSISREGW((unsigned long)(p))
++#define InPortLong(p) inSISREGL((unsigned long)(p))
+ #define SiS_SetMemory(MemoryAddress,MemorySize,value) memset(MemoryAddress, value, MemorySize)
+
+ #endif /* XF86 */
+diff --git a/src/sis.h b/src/sis.h
+index 400b83f..f2ca3a9 100644
+--- a/src/sis.h
++++ b/src/sis.h
+@@ -86,6 +86,14 @@
+ #include "xf86cmap.h"
+ #include "vbe.h"
+
++#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 12
++#define _swapl(x, n) swapl(x,n)
++#define _swaps(x, n) swaps(x,n)
++#else
++#define _swapl(x, n) swapl(x)
++#define _swaps(x, n) swaps(x)
++#endif
++
+ #define SIS_HaveDriverFuncs 0
+
+ #undef SISISXORG6899900
+@@ -173,7 +181,13 @@
+
+ #undef SISHAVEDRMWRITE
+ #undef SISNEWDRI
+-#ifdef XF86DRI
++
++/* if the server was built without DRI support, force-disable DRI */
++#ifndef XF86DRI
++#undef SISDRI
++#endif
++
++#ifdef SISDRI
+ #if XF86_VERSION_CURRENT >= XF86_VERSION_NUMERIC(4,2,99,3,0)
+ #define SISHAVEDRMWRITE
+ #endif
+@@ -187,7 +201,7 @@
+ #include "dri.h"
+ #include "GL/glxint.h"
+ #include "sis_dri.h"
+-#endif /* XF86DRI */
++#endif /* SISDRI */
+
+ /* Configurable stuff: ------------------------------------- */
+
+@@ -251,7 +265,6 @@
+ #endif
+
+ /* Need that for SiSCtrl and Pseudo-Xinerama */
+-#define NEED_REPLIES /* ? */
+ #define EXTENSION_PROC_ARGS void *
+ #include "extnsionst.h" /* required */
+ #include <X11/extensions/panoramiXproto.h> /* required */
+@@ -805,7 +818,7 @@ typedef struct {
+ ScrnInfoPtr pScrn_2;
+ UChar *BIOS;
+ struct SiS_Private *SiS_Pr;
+-#ifdef XF86DRI
++#ifdef SISDRI
+ SISAGPHTYPE agpHandle;
+ ULong agpAddr;
+ UChar *agpBase;
+@@ -971,7 +984,7 @@ typedef struct {
+ void *RealFbBase; /* Real VRAM virtual linear address (for DHM and SiS76x UMA skipping) */
+ CARD32 IOAddress; /* MMIO physical address */
+ void *IOBase; /* MMIO linear address */
+- IOADDRESS IODBase; /* Base of PIO memory area */
++ unsigned long IODBase; /* Base of PIO memory area */
+ #ifdef __alpha__
+ void *IOBaseDense; /* MMIO for Alpha platform */
+ #endif
+@@ -1085,7 +1098,7 @@ typedef struct {
+ unsigned int cmdQueueSize_div2;
+ unsigned int cmdQueueSize_div4;
+ unsigned int cmdQueueSize_4_3;
+-#ifdef XF86DRI
++#ifdef SISDRI
+ SISAGPHTYPE agpHandle;
+ ULong agpAddr;
+ UChar *agpBase;
+@@ -1144,7 +1157,7 @@ typedef struct {
+
+ /* DRI */
+ Bool loadDRI;
+-#ifdef XF86DRI
++#ifdef SISDRI
+ Bool directRenderingEnabled;
+ DRIInfoPtr pDRIInfo;
+ int drmSubFD;
+@@ -1348,7 +1361,7 @@ typedef struct {
+ Bool skipswitchcheck;
+ unsigned int VBFlagsInit;
+ DisplayModePtr currentModeLast;
+- IOADDRESS MyPIOOffset;
++ unsigned long MyPIOOffset;
+ Bool OverruleRanges;
+ Bool BenchMemCpy;
+ Bool NeedCopyFastVidCpy;
+diff --git a/src/sis6326_video.c b/src/sis6326_video.c
+index c6b18e2..66352b7 100644
+--- a/src/sis6326_video.c
++++ b/src/sis6326_video.c
+@@ -170,7 +170,7 @@ void SIS6326InitVideo(ScreenPtr pScreen)
+ adaptors = &newAdaptor;
+ } else {
+ /* need to free this someplace */
+- newAdaptors = xalloc((num_adaptors + 1) * sizeof(XF86VideoAdaptorPtr*));
++ newAdaptors = malloc((num_adaptors + 1) * sizeof(XF86VideoAdaptorPtr*));
+ if(newAdaptors) {
+ memcpy(newAdaptors, adaptors, num_adaptors *
+ sizeof(XF86VideoAdaptorPtr));
+@@ -185,7 +185,7 @@ void SIS6326InitVideo(ScreenPtr pScreen)
+ xf86XVScreenInit(pScreen, adaptors, num_adaptors);
+
+ if(newAdaptors)
+- xfree(newAdaptors);
++ free(newAdaptors);
+ }
+
+ /* client libraries expect an encoding */
+@@ -531,7 +531,7 @@ SIS6326SetupImageVideo(ScreenPtr pScreen)
+ return NULL;
+ #endif
+
+- if(!(adapt = xcalloc(1, sizeof(XF86VideoAdaptorRec) +
++ if(!(adapt = calloc(1, sizeof(XF86VideoAdaptorRec) +
+ sizeof(SISPortPrivRec) +
+ sizeof(DevUnion))))
+ return NULL;
+diff --git a/src/sis_dga.c b/src/sis_dga.c
+index d358645..16b0ee4 100644
+--- a/src/sis_dga.c
++++ b/src/sis_dga.c
+@@ -150,18 +150,18 @@ SISSetupDGAMode(
+
+ if(pMode->HDisplay != otherPitch) {
+
+- newmodes = xrealloc(modes, (*num + 2) * sizeof(DGAModeRec));
++ newmodes = realloc(modes, (*num + 2) * sizeof(DGAModeRec));
+ oneMore = TRUE;
+
+ } else {
+
+- newmodes = xrealloc(modes, (*num + 1) * sizeof(DGAModeRec));
++ newmodes = realloc(modes, (*num + 1) * sizeof(DGAModeRec));
+ oneMore = FALSE;
+
+ }
+
+ if(!newmodes) {
+- xfree(modes);
++ free(modes);
+ return NULL;
+ }
+ modes = newmodes;
+diff --git a/src/sis_dri.c b/src/sis_dri.c
+index 3a476a2..97ed951 100644
+--- a/src/sis_dri.c
++++ b/src/sis_dri.c
+@@ -149,19 +149,19 @@ SISInitVisualConfigs(ScreenPtr pScreen)
+ case 32:
+ numConfigs = (useZ16) ? 8 : 16;
+
+- if(!(pConfigs = (__GLXvisualConfig*)xcalloc(sizeof(__GLXvisualConfig),
++ if(!(pConfigs = (__GLXvisualConfig*)calloc(sizeof(__GLXvisualConfig),
+ numConfigs))) {
+ return FALSE;
+ }
+- if(!(pSISConfigs = (SISConfigPrivPtr)xcalloc(sizeof(SISConfigPrivRec),
++ if(!(pSISConfigs = (SISConfigPrivPtr)calloc(sizeof(SISConfigPrivRec),
+ numConfigs))) {
+- xfree(pConfigs);
++ free(pConfigs);
+ return FALSE;
+ }
+- if(!(pSISConfigPtrs = (SISConfigPrivPtr*)xcalloc(sizeof(SISConfigPrivPtr),
++ if(!(pSISConfigPtrs = (SISConfigPrivPtr*)calloc(sizeof(SISConfigPrivPtr),
+ numConfigs))) {
+- xfree(pConfigs);
+- xfree(pSISConfigs);
++ free(pConfigs);
++ free(pSISConfigs);
+ return FALSE;
+ }
+ for(i=0; i<numConfigs; i++) pSISConfigPtrs[i] = &pSISConfigs[i];
+@@ -319,7 +319,7 @@ SISDRIScreenInit(ScreenPtr pScreen)
+ pDRIInfo->busIdString = DRICreatePCIBusID(pSIS->PciInfo);
+ } else {
+ #endif
+- pDRIInfo->busIdString = xalloc(64);
++ pDRIInfo->busIdString = malloc(64);
+ sprintf(pDRIInfo->busIdString, "PCI:%d:%d:%d",
+ pSIS->PciBus, pSIS->PciDevice, pSIS->PciFunc);
+ #ifdef SISHAVECREATEBUSID
+@@ -383,7 +383,7 @@ SISDRIScreenInit(ScreenPtr pScreen)
+ pDRIInfo->SAREASize = SAREA_MAX;
+ #endif
+
+- if(!(pSISDRI = (SISDRIPtr)xcalloc(sizeof(SISDRIRec), 1))) {
++ if(!(pSISDRI = (SISDRIPtr)calloc(sizeof(SISDRIRec), 1))) {
+ DRIDestroyInfoRec(pSIS->pDRIInfo);
+ pSIS->pDRIInfo = 0;
+ return FALSE;
+@@ -401,7 +401,7 @@ SISDRIScreenInit(ScreenPtr pScreen)
+
+ if(!DRIScreenInit(pScreen, pDRIInfo, &pSIS->drmSubFD)) {
+ xf86DrvMsg(pScreen->myNum, X_ERROR, "[dri] DRIScreenInit failed. Disabling the DRI.\n");
+- xfree(pDRIInfo->devPrivate);
++ free(pDRIInfo->devPrivate);
+ pDRIInfo->devPrivate = 0;
+ DRIDestroyInfoRec(pSIS->pDRIInfo);
+ pSIS->pDRIInfo = 0;
+@@ -794,7 +794,7 @@ SISDRICloseScreen(ScreenPtr pScreen)
+
+ if(pSIS->pDRIInfo) {
+ if(pSIS->pDRIInfo->devPrivate) {
+- xfree(pSIS->pDRIInfo->devPrivate);
++ free(pSIS->pDRIInfo->devPrivate);
+ pSIS->pDRIInfo->devPrivate = NULL;
+ }
+ DRIDestroyInfoRec(pSIS->pDRIInfo);
+@@ -802,12 +802,12 @@ SISDRICloseScreen(ScreenPtr pScreen)
+ }
+
+ if(pSIS->pVisualConfigs) {
+- xfree(pSIS->pVisualConfigs);
++ free(pSIS->pVisualConfigs);
+ pSIS->pVisualConfigs = NULL;
+ }
+
+ if(pSIS->pVisualConfigsPriv) {
+- xfree(pSIS->pVisualConfigsPriv);
++ free(pSIS->pVisualConfigsPriv);
+ pSIS->pVisualConfigsPriv = NULL;
+ }
+
+diff --git a/src/sis_driver.c b/src/sis_driver.c
+index d95b5f1..7a5be4e 100644
+--- a/src/sis_driver.c
++++ b/src/sis_driver.c
+@@ -74,8 +74,7 @@
+
+ #include "sis_driver.h"
+
+-#define _XF86DGA_SERVER_
+-#include <X11/extensions/xf86dgastr.h>
++#include <X11/extensions/xf86dgaproto.h>
+
+ #include "globals.h"
+
+@@ -86,11 +85,35 @@
+ #include <X11/extensions/dpms.h>
+ #endif
+
++#if GET_ABI_MAJOR(ABI_XINPUT_VERSION) >= 5
++#include <inputstr.h> /* for inputInfo */
++#endif
++
+
+-#ifdef XF86DRI
++#ifdef SISDRI
+ #include "dri.h"
+ #endif
+
++/*
++ * LookupWindow was removed with video abi 11.
++ */
++#if (GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 4)
++#ifndef DixGetAttrAccess
++#define DixGetAttrAccess (1<<4)
++#endif
++#endif
++
++#if (GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 2)
++static inline int
++dixLookupWindow(WindowPtr *pWin, XID id, ClientPtr client, Mask access)
++{
++ *pWin = LookupWindow(id, client);
++ if (!*pWin)
++ return BadWindow;
++ return Success;
++}
++#endif
++
+ /* Globals (yes, these ARE really required to be global) */
+
+ #ifdef SISUSEDEVPORT
+@@ -299,9 +322,9 @@ SISFreeRec(ScrnInfoPtr pScrn)
+ pSiSEnt = pSiS->entityPrivate;
+ #endif
+
+- if(pSiS->pstate) xfree(pSiS->pstate);
++ if(pSiS->pstate) free(pSiS->pstate);
+ pSiS->pstate = NULL;
+- if(pSiS->fonts) xfree(pSiS->fonts);
++ if(pSiS->fonts) free(pSiS->fonts);
+ pSiS->fonts = NULL;
+
+ #ifdef SISDUALHEAD
+@@ -312,11 +335,11 @@ SISFreeRec(ScrnInfoPtr pScrn)
+ * and we need the BIOS image and SiS_Private for the first
+ * head.
+ */
+- if(pSiSEnt->BIOS) xfree(pSiSEnt->BIOS);
++ if(pSiSEnt->BIOS) free(pSiSEnt->BIOS);
+ pSiSEnt->BIOS = pSiS->BIOS = NULL;
+- if(pSiSEnt->SiS_Pr) xfree(pSiSEnt->SiS_Pr);
++ if(pSiSEnt->SiS_Pr) free(pSiSEnt->SiS_Pr);
+ pSiSEnt->SiS_Pr = pSiS->SiS_Pr = NULL;
+- if(pSiSEnt->RenderAccelArray) xfree(pSiSEnt->RenderAccelArray);
++ if(pSiSEnt->RenderAccelArray) free(pSiSEnt->RenderAccelArray);
+ pSiSEnt->RenderAccelArray = pSiS->RenderAccelArray = NULL;
+ pSiSEnt->pScrn_1 = NULL;
+ } else {
+@@ -327,21 +350,21 @@ SISFreeRec(ScrnInfoPtr pScrn)
+ }
+ } else {
+ #endif
+- if(pSiS->BIOS) xfree(pSiS->BIOS);
++ if(pSiS->BIOS) free(pSiS->BIOS);
+ pSiS->BIOS = NULL;
+- if(pSiS->SiS_Pr) xfree(pSiS->SiS_Pr);
++ if(pSiS->SiS_Pr) free(pSiS->SiS_Pr);
+ pSiS->SiS_Pr = NULL;
+- if(pSiS->RenderAccelArray) xfree(pSiS->RenderAccelArray);
++ if(pSiS->RenderAccelArray) free(pSiS->RenderAccelArray);
+ pSiS->RenderAccelArray = NULL;
+ #ifdef SISDUALHEAD
+ }
+ #endif
+ #ifdef SISMERGED
+- if(pSiS->CRT2HSync) xfree(pSiS->CRT2HSync);
++ if(pSiS->CRT2HSync) free(pSiS->CRT2HSync);
+ pSiS->CRT2HSync = NULL;
+- if(pSiS->CRT2VRefresh) xfree(pSiS->CRT2VRefresh);
++ if(pSiS->CRT2VRefresh) free(pSiS->CRT2VRefresh);
+ pSiS->CRT2VRefresh = NULL;
+- if(pSiS->MetaModes) xfree(pSiS->MetaModes);
++ if(pSiS->MetaModes) free(pSiS->MetaModes);
+ pSiS->MetaModes = NULL;
+ if(pSiS->CRT2pScrn) {
+ if(pSiS->CRT2pScrn->modes) {
+@@ -353,10 +376,10 @@ SISFreeRec(ScrnInfoPtr pScrn)
+ while(pSiS->CRT2pScrn->monitor->Modes)
+ xf86DeleteMode(&pSiS->CRT2pScrn->monitor->Modes, pSiS->CRT2pScrn->monitor->Modes);
+ }
+- if(pSiS->CRT2pScrn->monitor->DDC) xfree(pSiS->CRT2pScrn->monitor->DDC);
+- xfree(pSiS->CRT2pScrn->monitor);
++ if(pSiS->CRT2pScrn->monitor->DDC) free(pSiS->CRT2pScrn->monitor->DDC);
++ free(pSiS->CRT2pScrn->monitor);
+ }
+- xfree(pSiS->CRT2pScrn);
++ free(pSiS->CRT2pScrn);
+ pSiS->CRT2pScrn = NULL;
+ }
+ if(pSiS->CRT1Modes) {
+@@ -366,8 +389,8 @@ SISFreeRec(ScrnInfoPtr pScrn)
+ do {
+ DisplayModePtr p = pScrn->currentMode->next;
+ if(pScrn->currentMode->Private)
+- xfree(pScrn->currentMode->Private);
+- xfree(pScrn->currentMode);
++ free(pScrn->currentMode->Private);
++ free(pScrn->currentMode);
+ pScrn->currentMode = p;
+ } while(pScrn->currentMode != pScrn->modes);
+ }
+@@ -380,7 +403,7 @@ SISFreeRec(ScrnInfoPtr pScrn)
+ #endif
+ while(pSiS->SISVESAModeList) {
+ sisModeInfoPtr mp = pSiS->SISVESAModeList->next;
+- xfree(pSiS->SISVESAModeList);
++ free(pSiS->SISVESAModeList);
+ pSiS->SISVESAModeList = mp;
+ }
+ if(pSiS->pVbe) vbeFree(pSiS->pVbe);
+@@ -392,7 +415,7 @@ SISFreeRec(ScrnInfoPtr pScrn)
+
+ if(pScrn->driverPrivate == NULL)
+ return;
+- xfree(pScrn->driverPrivate);
++ free(pScrn->driverPrivate);
+ pScrn->driverPrivate = NULL;
+ }
+
+@@ -501,7 +524,7 @@ SISProbe(DriverPtr drv, int flags)
+ numDevSections, drv, &usedChipsXGI);
+
+ /* Free it since we don't need that list after this */
+- xfree(devSections);
++ free(devSections);
+
+ numUsed = numUsedSiS + numUsedXGI;
+
+@@ -577,8 +600,8 @@ SISProbe(DriverPtr drv, int flags)
+
+ }
+
+- if(usedChipsSiS) xfree(usedChipsSiS);
+- if(usedChipsXGI) xfree(usedChipsXGI);
++ if(usedChipsSiS) free(usedChipsSiS);
++ if(usedChipsXGI) free(usedChipsXGI);
+
+ return foundScreen;
+ }
+@@ -642,10 +665,10 @@ SISCalculateGammaRamp(ScreenPtr pScreen, ScrnInfoPtr pScrn)
+ if(!(nramp = xf86GetGammaRampSize(pScreen))) return;
+
+ for(i=0; i<3; i++) {
+- ramp[i] = (UShort *)xalloc(nramp * sizeof(UShort));
++ ramp[i] = (UShort *)malloc(nramp * sizeof(UShort));
+ if(!ramp[i]) {
+- if(ramp[0]) { xfree(ramp[0]); ramp[0] = NULL; }
+- if(ramp[1]) { xfree(ramp[1]); ramp[1] = NULL; }
++ if(ramp[0]) { free(ramp[0]); ramp[0] = NULL; }
++ if(ramp[1]) { free(ramp[1]); ramp[1] = NULL; }
+ return;
+ }
+ }
+@@ -705,9 +728,9 @@ SISCalculateGammaRamp(ScreenPtr pScreen, ScrnInfoPtr pScrn)
+
+ xf86ChangeGammaRamp(pScreen, nramp, ramp[0], ramp[1], ramp[2]);
+
+- xfree(ramp[0]);
+- xfree(ramp[1]);
+- xfree(ramp[2]);
++ free(ramp[0]);
++ free(ramp[1]);
++ free(ramp[2]);
+ ramp[0] = ramp[1] = ramp[2] = NULL;
+ }
+ #endif
+@@ -1135,10 +1158,10 @@ SiSCopyModeNLink(ScrnInfoPtr pScrn, DisplayModePtr dest,
+ DisplayModePtr mode;
+ int dx = 0,dy = 0;
+
+- if(!((mode = xalloc(sizeof(DisplayModeRec))))) return dest;
++ if(!((mode = malloc(sizeof(DisplayModeRec))))) return dest;
+ memcpy(mode, i, sizeof(DisplayModeRec));
+- if(!((mode->Private = xalloc(sizeof(SiSMergedDisplayModeRec))))) {
+- xfree(mode);
++ if(!((mode->Private = malloc(sizeof(SiSMergedDisplayModeRec))))) {
++ free(mode);
+ return dest;
+ }
+ ((SiSMergedDisplayModePtr)mode->Private)->CRT1 = i;
+@@ -1223,8 +1246,8 @@ SiSCopyModeNLink(ScrnInfoPtr pScrn, DisplayModePtr dest,
+ xf86DrvMsg(pScrn->scrnIndex, X_ERROR,
+ "Skipped \"%s\" (%dx%d), not enough video RAM or beyond hardware specs\n",
+ mode->name, mode->HDisplay, mode->VDisplay);
+- xfree(mode->Private);
+- xfree(mode);
++ free(mode->Private);
++ free(mode);
+
+ return dest;
+ }
+@@ -2131,10 +2154,10 @@ SiSProcXineramaQueryVersion(ClientPtr client)
+ rep.majorVersion = SIS_XINERAMA_MAJOR_VERSION;
+ rep.minorVersion = SIS_XINERAMA_MINOR_VERSION;
+ if(client->swapped) {
+- swaps(&rep.sequenceNumber, n);
+- swapl(&rep.length, n);
+- swaps(&rep.majorVersion, n);
+- swaps(&rep.minorVersion, n);
++ _swaps(&rep.sequenceNumber, n);
++ _swapl(&rep.length, n);
++ _swaps(&rep.majorVersion, n);
++ _swaps(&rep.minorVersion, n);
+ }
+ WriteToClient(client, sizeof(xPanoramiXQueryVersionReply), (char *)&rep);
+ return (client->noClientException);
+@@ -2147,19 +2170,20 @@ SiSProcXineramaGetState(ClientPtr client)
+ WindowPtr pWin;
+ xPanoramiXGetStateReply rep;
+ register int n;
++ int rc;
+
+ REQUEST_SIZE_MATCH(xPanoramiXGetStateReq);
+- pWin = LookupWindow(stuff->window, client);
+- if(!pWin) return BadWindow;
++ rc = dixLookupWindow(&pWin, stuff->window, client, DixGetAttrAccess);
++ if (rc != Success)
++ return rc;
+
+ rep.type = X_Reply;
+ rep.length = 0;
+ rep.sequenceNumber = client->sequence;
+ rep.state = !SiSnoPanoramiXExtension;
+ if(client->swapped) {
+- swaps (&rep.sequenceNumber, n);
+- swapl (&rep.length, n);
+- swaps (&rep.state, n);
++ _swaps (&rep.sequenceNumber, n);
++ _swapl (&rep.length, n);
+ }
+ WriteToClient(client, sizeof(xPanoramiXGetStateReply), (char *)&rep);
+ return client->noClientException;
+@@ -2172,19 +2196,20 @@ SiSProcXineramaGetScreenCount(ClientPtr client)
+ WindowPtr pWin;
+ xPanoramiXGetScreenCountReply rep;
+ register int n;
++ int rc;
+
+ REQUEST_SIZE_MATCH(xPanoramiXGetScreenCountReq);
+- pWin = LookupWindow(stuff->window, client);
+- if(!pWin) return BadWindow;
++ rc = dixLookupWindow(&pWin, stuff->window, client, DixGetAttrAccess);
++ if (rc != Success)
++ return rc;
+
+ rep.type = X_Reply;
+ rep.length = 0;
+ rep.sequenceNumber = client->sequence;
+ rep.ScreenCount = SiSXineramaNumScreens;
+ if(client->swapped) {
+- swaps(&rep.sequenceNumber, n);
+- swapl(&rep.length, n);
+- swaps(&rep.ScreenCount, n);
++ _swaps(&rep.sequenceNumber, n);
++ _swapl(&rep.length, n);
+ }
+ WriteToClient(client, sizeof(xPanoramiXGetScreenCountReply), (char *)&rep);
+ return client->noClientException;
+@@ -2197,10 +2222,12 @@ SiSProcXineramaGetScreenSize(ClientPtr client)
+ WindowPtr pWin;
+ xPanoramiXGetScreenSizeReply rep;
+ register int n;
++ int rc;
+
+ REQUEST_SIZE_MATCH(xPanoramiXGetScreenSizeReq);
+- pWin = LookupWindow (stuff->window, client);
+- if(!pWin) return BadWindow;
++ rc = dixLookupWindow(&pWin, stuff->window, client, DixGetAttrAccess);
++ if (rc != Success)
++ return rc;
+
+ rep.type = X_Reply;
+ rep.length = 0;
+@@ -2208,10 +2235,10 @@ SiSProcXineramaGetScreenSize(ClientPtr client)
+ rep.width = SiSXineramadataPtr[stuff->screen].width;
+ rep.height = SiSXineramadataPtr[stuff->screen].height;
+ if(client->swapped) {
+- swaps(&rep.sequenceNumber, n);
+- swapl(&rep.length, n);
+- swaps(&rep.width, n);
+- swaps(&rep.height, n);
++ _swaps(&rep.sequenceNumber, n);
++ _swapl(&rep.length, n);
++ _swapl(&rep.width, n);
++ _swapl(&rep.height, n);
+ }
+ WriteToClient(client, sizeof(xPanoramiXGetScreenSizeReply), (char *)&rep);
+ return client->noClientException;
+@@ -2230,9 +2257,9 @@ SiSProcXineramaIsActive(ClientPtr client)
+ rep.state = !SiSnoPanoramiXExtension;
+ if(client->swapped) {
+ register int n;
+- swaps(&rep.sequenceNumber, n);
+- swapl(&rep.length, n);
+- swapl(&rep.state, n);
++ _swaps(&rep.sequenceNumber, n);
++ _swapl(&rep.length, n);
++ _swapl(&rep.state, n);
+ }
+ WriteToClient(client, sizeof(xXineramaIsActiveReply), (char *) &rep);
+ return client->noClientException;
+@@ -2251,9 +2278,9 @@ SiSProcXineramaQueryScreens(ClientPtr client)
+ rep.length = rep.number * sz_XineramaScreenInfo >> 2;
+ if(client->swapped) {
+ register int n;
+- swaps(&rep.sequenceNumber, n);
+- swapl(&rep.length, n);
+- swapl(&rep.number, n);
++ _swaps(&rep.sequenceNumber, n);
++ _swapl(&rep.length, n);
++ _swapl(&rep.number, n);
+ }
+ WriteToClient(client, sizeof(xXineramaQueryScreensReply), (char *)&rep);
+
+@@ -2268,10 +2295,10 @@ SiSProcXineramaQueryScreens(ClientPtr client)
+ scratch.height = SiSXineramadataPtr[i].height;
+ if(client->swapped) {
+ register int n;
+- swaps(&scratch.x_org, n);
+- swaps(&scratch.y_org, n);
+- swaps(&scratch.width, n);
+- swaps(&scratch.height, n);
++ _swaps(&scratch.x_org, n);
++ _swaps(&scratch.y_org, n);
++ _swaps(&scratch.width, n);
++ _swaps(&scratch.height, n);
+ }
+ WriteToClient(client, sz_XineramaScreenInfo, (char *)&scratch);
+ }
+@@ -2308,7 +2335,7 @@ SiSSProcXineramaQueryVersion (ClientPtr client)
+ {
+ REQUEST(xPanoramiXQueryVersionReq);
+ register int n;
+- swaps(&stuff->length,n);
++ _swaps(&stuff->length,n);
+ REQUEST_SIZE_MATCH (xPanoramiXQueryVersionReq);
+ return SiSProcXineramaQueryVersion(client);
+ }
+@@ -2318,7 +2345,7 @@ SiSSProcXineramaGetState(ClientPtr client)
+ {
+ REQUEST(xPanoramiXGetStateReq);
+ register int n;
+- swaps (&stuff->length, n);
++ _swaps (&stuff->length, n);
+ REQUEST_SIZE_MATCH(xPanoramiXGetStateReq);
+ return SiSProcXineramaGetState(client);
+ }
+@@ -2328,7 +2355,7 @@ SiSSProcXineramaGetScreenCount(ClientPtr client)
+ {
+ REQUEST(xPanoramiXGetScreenCountReq);
+ register int n;
+- swaps (&stuff->length, n);
++ _swaps (&stuff->length, n);
+ REQUEST_SIZE_MATCH(xPanoramiXGetScreenCountReq);
+ return SiSProcXineramaGetScreenCount(client);
+ }
+@@ -2338,7 +2365,7 @@ SiSSProcXineramaGetScreenSize(ClientPtr client)
+ {
+ REQUEST(xPanoramiXGetScreenSizeReq);
+ register int n;
+- swaps (&stuff->length, n);
++ _swaps (&stuff->length, n);
+ REQUEST_SIZE_MATCH(xPanoramiXGetScreenSizeReq);
+ return SiSProcXineramaGetScreenSize(client);
+ }
+@@ -2348,7 +2375,7 @@ SiSSProcXineramaIsActive(ClientPtr client)
+ {
+ REQUEST(xXineramaIsActiveReq);
+ register int n;
+- swaps (&stuff->length, n);
++ _swaps (&stuff->length, n);
+ REQUEST_SIZE_MATCH(xXineramaIsActiveReq);
+ return SiSProcXineramaIsActive(client);
+ }
+@@ -2358,7 +2385,7 @@ SiSSProcXineramaQueryScreens(ClientPtr client)
+ {
+ REQUEST(xXineramaQueryScreensReq);
+ register int n;
+- swaps (&stuff->length, n);
++ _swaps (&stuff->length, n);
+ REQUEST_SIZE_MATCH(xXineramaQueryScreensReq);
+ return SiSProcXineramaQueryScreens(client);
+ }
+@@ -2389,7 +2416,7 @@ SiSXineramaResetProc(ExtensionEntry* extEntry)
+ {
+ /* Called by CloseDownExtensions() */
+ if(SiSXineramadataPtr) {
+- Xfree(SiSXineramadataPtr);
++ free(SiSXineramadataPtr);
+ SiSXineramadataPtr = NULL;
+ }
+ }
+@@ -2454,7 +2481,7 @@ SiSXineramaExtensionInit(ScrnInfoPtr pScrn)
+ if(!pSiS->XineramaExtEntry) break;
+
+ if(!(SiSXineramadataPtr = (SiSXineramaData *)
+- xcalloc(SiSXineramaNumScreens, sizeof(SiSXineramaData)))) break;
++ calloc(SiSXineramaNumScreens, sizeof(SiSXineramaData)))) break;
+
+ SiSXineramaGeneration = serverGeneration;
+ success = TRUE;
+@@ -2493,10 +2520,10 @@ SiSFreeCRT2Structs(SISPtr pSiS)
+ while(pSiS->CRT2pScrn->monitor->Modes)
+ xf86DeleteMode(&pSiS->CRT2pScrn->monitor->Modes, pSiS->CRT2pScrn->monitor->Modes);
+ }
+- if(pSiS->CRT2pScrn->monitor->DDC) xfree(pSiS->CRT2pScrn->monitor->DDC);
+- xfree(pSiS->CRT2pScrn->monitor);
++ if(pSiS->CRT2pScrn->monitor->DDC) free(pSiS->CRT2pScrn->monitor->DDC);
++ free(pSiS->CRT2pScrn->monitor);
+ }
+- xfree(pSiS->CRT2pScrn);
++ free(pSiS->CRT2pScrn);
+ pSiS->CRT2pScrn = NULL;
+ }
+ }
+@@ -2902,22 +2929,22 @@ SiS_CheckKernelFB(ScrnInfoPtr pScrn)
+ Bool gotit = FALSE;
+
+ if(!ioctl(fd, SISFB_GET_INFO_SIZE, &sisfbinfosize)) {
+- if((mysisfbinfo = xalloc(sisfbinfosize))) {
++ if((mysisfbinfo = malloc(sisfbinfosize))) {
+ if(!ioctl(fd, (SISFB_GET_INFO | (sisfbinfosize << 16)), mysisfbinfo)) {
+ gotit = TRUE;
+ } else {
+- xfree(mysisfbinfo);
++ free(mysisfbinfo);
+ mysisfbinfo = NULL;
+ }
+ }
+ } else {
+- if((mysisfbinfo = xalloc(sizeof(*mysisfbinfo) + 16))) {
++ if((mysisfbinfo = malloc(sizeof(*mysisfbinfo) + 16))) {
+ if(!ioctl(fd, SISFB_GET_INFO_OLD, mysisfbinfo)) {
+ gotit = TRUE;
+ xf86DrvMsg(pScrn->scrnIndex, X_WARNING,
+ "Possibly old version of sisfb detected. Please update.\n");
+ } else {
+- xfree(mysisfbinfo);
++ free(mysisfbinfo);
+ mysisfbinfo = NULL;
+ }
+ }
+@@ -3056,7 +3083,7 @@ SiS_CheckKernelFB(ScrnInfoPtr pScrn)
+ }
+ }
+ }
+- xfree(mysisfbinfo);
++ free(mysisfbinfo);
+ mysisfbinfo = NULL;
+ }
+ close (fd);
+@@ -3216,7 +3243,7 @@ SISPreInit(ScrnInfoPtr pScrn, int flags)
+ pSiS->pInt = NULL;
+
+ /* Save PCI Domain Base */
+-#if XF86_VERSION_CURRENT < XF86_VERSION_NUMERIC(4,2,99,0,0)
++#if XF86_VERSION_CURRENT < XF86_VERSION_NUMERIC(4,2,99,0,0) || GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) >= 12
+ pSiS->IODBase = 0;
+ #else
+ pSiS->IODBase = pScrn->domainIOBase;
+@@ -4078,7 +4105,7 @@ SISPreInit(ScrnInfoPtr pScrn, int flags)
+ }
+ #endif
+ if(!pSiS->BIOS) {
+- if(!(pSiS->BIOS = xcalloc(1, BIOS_SIZE))) {
++ if(!(pSiS->BIOS = calloc(1, BIOS_SIZE))) {
+ xf86DrvMsg(pScrn->scrnIndex, X_WARNING,
+ "Could not allocate memory for video BIOS image\n");
+ } else {
+@@ -4173,7 +4200,7 @@ SISPreInit(ScrnInfoPtr pScrn, int flags)
+ } else {
+ xf86DrvMsg(pScrn->scrnIndex, X_WARNING,
+ "Could not find/read video BIOS\n");
+- xfree(pSiS->BIOS);
++ free(pSiS->BIOS);
+ pSiS->BIOS = NULL;
+ }
+ }
+@@ -5559,7 +5586,7 @@ SISPreInit(ScrnInfoPtr pScrn, int flags)
+ /* Do some MergedFB mode initialisation */
+ #ifdef SISMERGED
+ if(pSiS->MergedFB) {
+- pSiS->CRT2pScrn = xalloc(sizeof(ScrnInfoRec));
++ pSiS->CRT2pScrn = malloc(sizeof(ScrnInfoRec));
+ if(!pSiS->CRT2pScrn) {
+ SISErrorLog(pScrn, "Failed to allocate memory for 2nd pScrn, %s\n", mergeddisstr);
+ pSiS->MergedFB = FALSE;
+@@ -5592,7 +5619,7 @@ SISPreInit(ScrnInfoPtr pScrn, int flags)
+ } else {
+ SISErrorLog(pScrn, mergednocrt1, mergeddisstr);
+ }
+- if(pSiS->CRT2pScrn) xfree(pSiS->CRT2pScrn);
++ if(pSiS->CRT2pScrn) free(pSiS->CRT2pScrn);
+ pSiS->CRT2pScrn = NULL;
+ pSiS->MergedFB = FALSE;
+ }
+@@ -5639,7 +5666,7 @@ SISPreInit(ScrnInfoPtr pScrn, int flags)
+ } else {
+ SISErrorLog(pScrn, mergednocrt2, mergeddisstr);
+ }
+- if(pSiS->CRT2pScrn) xfree(pSiS->CRT2pScrn);
++ if(pSiS->CRT2pScrn) free(pSiS->CRT2pScrn);
+ pSiS->CRT2pScrn = NULL;
+ pSiS->MergedFB = FALSE;
+ }
+@@ -6016,7 +6043,7 @@ SISPreInit(ScrnInfoPtr pScrn, int flags)
+
+ #ifdef SISMERGED
+ if(pSiS->MergedFB) {
+- pSiS->CRT2pScrn->monitor = xalloc(sizeof(MonRec));
++ pSiS->CRT2pScrn->monitor = malloc(sizeof(MonRec));
+ if(pSiS->CRT2pScrn->monitor) {
+ DisplayModePtr tempm = NULL, currentm = NULL, newm = NULL;
+ memcpy(pSiS->CRT2pScrn->monitor, pScrn->monitor, sizeof(MonRec));
+@@ -6025,10 +6052,10 @@ SISPreInit(ScrnInfoPtr pScrn, int flags)
+ pSiS->CRT2pScrn->monitor->id = (char *)crt2monname;
+ tempm = pScrn->monitor->Modes;
+ while(tempm) {
+- if(!(newm = xalloc(sizeof(DisplayModeRec)))) break;
++ if(!(newm = malloc(sizeof(DisplayModeRec)))) break;
+ memcpy(newm, tempm, sizeof(DisplayModeRec));
+- if(!(newm->name = xalloc(strlen(tempm->name) + 1))) {
+- xfree(newm);
++ if(!(newm->name = malloc(strlen(tempm->name) + 1))) {
++ free(newm);
+ break;
+ }
+ strcpy(newm->name, tempm->name);
+@@ -6070,7 +6097,7 @@ SISPreInit(ScrnInfoPtr pScrn, int flags)
+ } else {
+ SISErrorLog(pScrn, "Failed to allocate memory for CRT2 monitor, %s.\n",
+ mergeddisstr);
+- if(pSiS->CRT2pScrn) xfree(pSiS->CRT2pScrn);
++ if(pSiS->CRT2pScrn) free(pSiS->CRT2pScrn);
+ pSiS->CRT2pScrn = NULL;
+ pSiS->MergedFB = FALSE;
+ }
+@@ -6835,8 +6862,10 @@ SISPreInit(ScrnInfoPtr pScrn, int flags)
+ #ifdef SIS_USE_XAA
+ if(!pSiS->useEXA) {
+ if (!xf86LoadSubModule(pScrn, "xaa")) {
+- SISErrorLog(pScrn, "Could not load xaa module\n");
+- goto my_error_1;
++ xf86DrvMsg(pScrn->scrnIndex, X_INFO,
++ "Falling back to shadowfb\n");
++ pSiS->NoAccel = 1;
++ pSiS->ShadowFB = 1;
+ }
+ }
+ #endif
+@@ -6855,7 +6884,6 @@ SISPreInit(ScrnInfoPtr pScrn, int flags)
+ }
+ }
+ #endif
+- xf86DrvMsg(pScrn->scrnIndex, X_INFO, "2D acceleration enabled\n");
+ }
+
+ /* Load shadowfb (if needed) */
+@@ -6867,7 +6895,7 @@ SISPreInit(ScrnInfoPtr pScrn, int flags)
+ }
+
+ /* Load the dri and glx modules if requested. */
+-#ifdef XF86DRI
++#ifdef SISDRI
+ if(pSiS->loadDRI) {
+ if(!xf86LoaderCheckSymbol("DRIScreenInit")) {
+ if(xf86LoadSubModule(pScrn, "dri")) {
+@@ -7454,7 +7482,7 @@ SISVESASaveRestore(ScrnInfoPtr pScrn, vbeSaveRestoreFunction function)
+ (function == MODE_SAVE)) {
+ /* don't rely on the memory not being touched */
+ if(!pSiS->pstate) {
+- pSiS->pstate = xalloc(pSiS->stateSize);
++ pSiS->pstate = malloc(pSiS->stateSize);
+ }
+ memcpy(pSiS->pstate, pSiS->state, pSiS->stateSize);
+ }
+@@ -8675,7 +8703,7 @@ SISScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
+
+ if(pSiS->ShadowFB) {
+ pSiS->ShadowPitch = BitmapBytePad(pScrn->bitsPerPixel * width);
+- pSiS->ShadowPtr = xalloc(pSiS->ShadowPitch * height);
++ pSiS->ShadowPtr = malloc(pSiS->ShadowPitch * height);
+ displayWidth = pSiS->ShadowPitch / (pScrn->bitsPerPixel >> 3);
+ FBStart = pSiS->ShadowPtr;
+ } else {
+@@ -8703,7 +8731,7 @@ SISScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
+
+ pSiS->cmdQueueLen = 0; /* Force an EngineIdle() at start */
+
+-#ifdef XF86DRI
++#ifdef SISDRI
+ if(pSiS->loadDRI) {
+ #ifdef SISDUALHEAD
+ /* No DRI in dual head mode */
+@@ -8849,14 +8877,14 @@ SISScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
+
+ pSiS->CRT2ColNum = 1 << pScrn->rgbBits;
+
+- if((pSiS->crt2gcolortable = xalloc(pSiS->CRT2ColNum * 2 * sizeof(LOCO)))) {
++ if((pSiS->crt2gcolortable = malloc(pSiS->CRT2ColNum * 2 * sizeof(LOCO)))) {
+ pSiS->crt2colors = &pSiS->crt2gcolortable[pSiS->CRT2ColNum];
+- if((pSiS->crt2cindices = xalloc(256 * sizeof(int)))) {
++ if((pSiS->crt2cindices = malloc(256 * sizeof(int)))) {
+ int i = pSiS->CRT2ColNum;
+ SISCalculateGammaRampCRT2(pScrn);
+ while(i--) pSiS->crt2cindices[i] = i;
+ } else {
+- xfree(pSiS->crt2gcolortable);
++ free(pSiS->crt2gcolortable);
+ pSiS->crt2gcolortable = NULL;
+ pSiS->CRT2SepGamma = FALSE;
+ }
+@@ -9016,7 +9044,7 @@ SISScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
+ }
+ #endif
+
+-#ifdef XF86DRI
++#ifdef SISDRI
+ if(pSiS->loadDRI) {
+ if(pSiS->directRenderingEnabled) {
+ /* Now that mi, drm and others have done their thing,
+@@ -9322,9 +9350,22 @@ SISMergedPointerMoved(int scrnIndex, int x, int y)
+ }
+ }
+ if(doit) {
+- UpdateCurrentTime();
+ sigstate = xf86BlockSIGIO();
++#if GET_ABI_MAJOR(ABI_XINPUT_VERSION) >= 15
++ {
++ double dx = x, dy = y;
++ miPointerSetPosition(inputInfo.pointer, Absolute, &dx, &dy);
++ x = (int)dx;
++ y = (int)dy;
++ }
++#elif GET_ABI_MAJOR(ABI_XINPUT_VERSION) >= 13
++ miPointerSetPosition(inputInfo.pointer, Absolute, x, y);
++#elif GET_ABI_MAJOR(ABI_XINPUT_VERSION) >= 5
++ miPointerSetPosition(inputInfo.pointer, x, y);
++#else
++ UpdateCurrentTime();
+ miPointerAbsoluteCursor(x, y, currentTime.milliseconds);
++#endif
+ xf86UnblockSIGIO(sigstate);
+ return;
+ }
+@@ -9737,7 +9778,7 @@ SISEnterVT(int scrnIndex, int flags)
+
+ SISAdjustFrame(scrnIndex, pScrn->frameX0, pScrn->frameY0, 0);
+
+-#ifdef XF86DRI
++#ifdef SISDRI
+ if(pSiS->directRenderingEnabled) {
+ DRIUnlock(screenInfo.screens[scrnIndex]);
+ }
+@@ -9763,7 +9804,7 @@ SISLeaveVT(int scrnIndex, int flags)
+ {
+ ScrnInfoPtr pScrn = xf86Screens[scrnIndex];
+ SISPtr pSiS = SISPTR(pScrn);
+-#ifdef XF86DRI
++#ifdef SISDRI
+ ScreenPtr pScreen;
+
+ if(pSiS->directRenderingEnabled) {
+@@ -9847,7 +9888,7 @@ SISCloseScreen(int scrnIndex, ScreenPtr pScreen)
+ SiSCtrlExtUnregister(pSiS, pScrn->scrnIndex);
+ }
+
+-#ifdef XF86DRI
++#ifdef SISDRI
+ if(pSiS->directRenderingEnabled) {
+ SISDRICloseScreen(pScreen);
+ pSiS->directRenderingEnabled = FALSE;
+@@ -9941,7 +9982,7 @@ SISCloseScreen(int scrnIndex, ScreenPtr pScreen)
+ if(pSiS->useEXA) {
+ if(pSiS->EXADriverPtr) {
+ exaDriverFini(pScreen);
+- xfree(pSiS->EXADriverPtr);
++ free(pSiS->EXADriverPtr);
+ pSiS->EXADriverPtr = NULL;
+ pSiS->exa_scratch = NULL;
+ }
+@@ -9954,33 +9995,33 @@ SISCloseScreen(int scrnIndex, ScreenPtr pScreen)
+ }
+
+ if(pSiS->ShadowPtr) {
+- xfree(pSiS->ShadowPtr);
++ free(pSiS->ShadowPtr);
+ pSiS->ShadowPtr = NULL;
+ }
+
+ if(pSiS->DGAModes) {
+- xfree(pSiS->DGAModes);
++ free(pSiS->DGAModes);
+ pSiS->DGAModes = NULL;
+ }
+
+ if(pSiS->adaptor) {
+- xfree(pSiS->adaptor);
++ free(pSiS->adaptor);
+ pSiS->adaptor = NULL;
+ pSiS->ResetXv = pSiS->ResetXvGamma = pSiS->ResetXvDisplay = NULL;
+ }
+
+ if(pSiS->blitadaptor) {
+- xfree(pSiS->blitadaptor);
++ free(pSiS->blitadaptor);
+ pSiS->blitadaptor = NULL;
+ }
+
+ if(pSiS->crt2gcolortable) {
+- xfree(pSiS->crt2gcolortable);
++ free(pSiS->crt2gcolortable);
+ pSiS->crt2gcolortable = NULL;
+ }
+
+ if(pSiS->crt2cindices) {
+- xfree(pSiS->crt2cindices);
++ free(pSiS->crt2cindices);
+ pSiS->crt2cindices = NULL;
+ }
+
+diff --git a/src/sis_memcpy.c b/src/sis_memcpy.c
+index 6ad62e8..3634401 100644
+--- a/src/sis_memcpy.c
++++ b/src/sis_memcpy.c
+@@ -638,13 +638,13 @@ SiS_AllocBuffers(ScrnInfoPtr pScrn, UChar **buf1, UChar **buf2, UChar **buf3)
+ (*buf1) = (UChar *)pSiS->FbBase + offset;
+ (*buf1) = (UChar *)(((ULong)(*buf1) + 31) & ~31);
+
+- if(!((*buf2) = (UChar *)xalloc(BUFFERSIZE + 15))) {
++ if(!((*buf2) = (UChar *)malloc(BUFFERSIZE + 15))) {
+ SISFreeFBMemory(pScrn, &handle);
+ return NULL;
+ }
+
+- if(!((*buf3) = (UChar *)xalloc(BUFFERSIZE + 15))) {
+- xfree((*buf2));
++ if(!((*buf3) = (UChar *)malloc(BUFFERSIZE + 15))) {
++ free((*buf2));
+ SISFreeFBMemory(pScrn, &handle);
+ return NULL;
+ }
+@@ -1098,8 +1098,8 @@ SiSVidCopyInitGen(ScreenPtr pScreen, SISMCFuncData *MCFunctions, vidCopyFunc *UM
+
+ /* Free buffers */
+ SISFreeFBMemory(pScrn, &fbhandle);
+- xfree(buf2);
+- xfree(buf3);
++ free(buf2);
++ free(buf3);
+
+ xf86DrvMsg(pScrn->scrnIndex, X_PROBED,
+ "Using %s method for aligned data transfers %s video RAM\n",
+diff --git a/src/sis_opt.c b/src/sis_opt.c
+index 3517549..3fa12c9 100644
+--- a/src/sis_opt.c
++++ b/src/sis_opt.c
+@@ -448,7 +448,7 @@ SiSOptions(ScrnInfoPtr pScrn)
+ xf86CollectOptions(pScrn, NULL);
+
+ /* Process the options */
+- if(!(pSiS->Options = xalloc(sizeof(SISOptions)))) return;
++ if(!(pSiS->Options = malloc(sizeof(SISOptions)))) return;
+
+ memcpy(pSiS->Options, SISOptions, sizeof(SISOptions));
+
+@@ -480,7 +480,7 @@ SiSOptions(ScrnInfoPtr pScrn)
+ #endif
+ pSiS->ShadowFB = FALSE;
+ pSiS->loadDRI = FALSE;
+-#ifdef XF86DRI
++#ifdef SISDRI
+ pSiS->agpWantedPages = AGP_PAGES;
+ #endif
+ pSiS->VESA = -1;
+@@ -888,7 +888,7 @@ SiSOptions(ScrnInfoPtr pScrn)
+ if((strptr = (char *)xf86GetOptValString(pSiS->Options, OPTION_CRT2POS))) {
+ int result;
+ Bool valid = FALSE;
+- char *tempstr = xalloc(strlen(strptr) + 1);
++ char *tempstr = malloc(strlen(strptr) + 1);
+ result = sscanf(strptr, "%s %d", tempstr, &ival);
+ if(result >= 1) {
+ if(!xf86NameCmp(tempstr,"LeftOf")) {
+@@ -946,18 +946,18 @@ SiSOptions(ScrnInfoPtr pScrn)
+ xf86DrvMsg(pScrn->scrnIndex, X_INFO,
+ "Except for \"Clone\", the parameter may be followed by an integer.\n");
+ }
+- xfree(tempstr);
++ free(tempstr);
+ }
+ if((strptr = (char *)xf86GetOptValString(pSiS->Options, OPTION_METAMODES))) {
+- pSiS->MetaModes = xalloc(strlen(strptr) + 1);
++ pSiS->MetaModes = malloc(strlen(strptr) + 1);
+ if(pSiS->MetaModes) memcpy(pSiS->MetaModes, strptr, strlen(strptr) + 1);
+ }
+ if((strptr = (char *)xf86GetOptValString(pSiS->Options, OPTION_CRT2HSYNC))) {
+- pSiS->CRT2HSync = xalloc(strlen(strptr) + 1);
++ pSiS->CRT2HSync = malloc(strlen(strptr) + 1);
+ if(pSiS->CRT2HSync) memcpy(pSiS->CRT2HSync, strptr, strlen(strptr) + 1);
+ }
+ if((strptr = (char *)xf86GetOptValString(pSiS->Options, OPTION_CRT2VREFRESH))) {
+- pSiS->CRT2VRefresh = xalloc(strlen(strptr) + 1);
++ pSiS->CRT2VRefresh = malloc(strlen(strptr) + 1);
+ if(pSiS->CRT2VRefresh) memcpy(pSiS->CRT2VRefresh, strptr, strlen(strptr) + 1);
+ }
+ if((strptr = (char *)xf86GetOptValString(pSiS->Options, OPTION_MERGEDDPI))) {
+@@ -2034,7 +2034,7 @@ SiSOptions(ScrnInfoPtr pScrn)
+ }
+ }
+
+-#ifdef XF86DRI
++#ifdef SISDRI
+ /* DRI */
+ from = X_DEFAULT;
+ if(xf86GetOptValBool(pSiS->Options, OPTION_DRI, &pSiS->loadDRI)) {
+diff --git a/src/sis_utility.c b/src/sis_utility.c
+index a9bcd2b..eda194f 100644
+--- a/src/sis_utility.c
++++ b/src/sis_utility.c
+@@ -34,8 +34,6 @@
+ #endif
+
+ #include "sis.h"
+-#define NEED_REPLIES
+-#define NEED_EVENTS
+ #include <X11/X.h>
+ #include "dixstruct.h"
+
+@@ -1882,10 +1880,10 @@ SiSProcSiSCtrlQueryVersion(ClientPtr client)
+ rep.majorVersion = SISCTRL_MAJOR_VERSION;
+ rep.minorVersion = SISCTRL_MINOR_VERSION;
+ if(client->swapped) {
+- swaps(&rep.sequenceNumber, n);
+- swapl(&rep.length, n);
+- swaps(&rep.majorVersion, n);
+- swaps(&rep.minorVersion, n);
++ _swaps(&rep.sequenceNumber, n);
++ _swapl(&rep.length, n);
++ _swaps(&rep.majorVersion, n);
++ _swaps(&rep.minorVersion, n);
+ }
+ WriteToClient(client, sizeof(xSiSCtrlQueryVersionReply), (char *)&rep);
+ return (client->noClientException);
+@@ -1926,15 +1924,15 @@ SiSProcSiSCtrlCommand(ClientPtr client)
+ rep.sequenceNumber = client->sequence;
+
+ if(client->swapped) {
+- swaps(&rep.sequenceNumber, n);
+- swapl(&rep.length, n);
+- swapl(&rep.screen, n);
+- swapl(&rep.sdc_id, n);
+- swapl(&rep.sdc_command, n);
+- swapl(&rep.sdc_result_header, n);
++ _swaps(&rep.sequenceNumber, n);
++ _swapl(&rep.length, n);
++ _swapl(&rep.screen, n);
++ _swapl(&rep.sdc_id, n);
++ _swapl(&rep.sdc_command, n);
++ _swapl(&rep.sdc_result_header, n);
+ for(i = 0; i < SDC_NUM_PARM_RESULT; i++) {
+- swapl(&rep.sdc_parm[i], n);
+- swapl(&rep.sdc_result[i], n);
++ _swapl(&rep.sdc_parm[i], n);
++ _swapl(&rep.sdc_result[i], n);
+ }
+ }
+ WriteToClient(client, sizeof(xSiSCtrlCommandReply), (char *)&rep);
+@@ -1961,7 +1959,7 @@ SiSSProcSiSCtrlQueryVersion(ClientPtr client)
+ {
+ REQUEST(xSiSCtrlQueryVersionReq);
+ register int n;
+- swaps(&stuff->length, n);
++ _swaps(&stuff->length, n);
+ REQUEST_SIZE_MATCH(xSiSCtrlQueryVersionReq);
+ return SiSProcSiSCtrlQueryVersion(client);
+ }
+@@ -1972,14 +1970,14 @@ SiSSProcSiSCtrlCommand(ClientPtr client)
+ REQUEST(xSiSCtrlCommandReq);
+ register int n;
+ int i;
+- swaps(&stuff->length, n);
+- swapl(&stuff->screen, n);
+- swapl(&stuff->sdc_id, n);
+- swapl(&stuff->sdc_command, n);
+- swapl(&stuff->sdc_result_header, n);
++ _swaps(&stuff->length, n);
++ _swapl(&stuff->screen, n);
++ _swapl(&stuff->sdc_id, n);
++ _swapl(&stuff->sdc_command, n);
++ _swapl(&stuff->sdc_result_header, n);
+ for(i = 0; i < SDC_NUM_PARM_RESULT; i++) {
+- swapl(&stuff->sdc_parm[i], n);
+- swapl(&stuff->sdc_result[i], n);
++ _swapl(&stuff->sdc_parm[i], n);
++ _swapl(&stuff->sdc_result[i], n);
+ }
+ REQUEST_SIZE_MATCH(xSiSCtrlCommandReq);
+ return SiSProcSiSCtrlCommand(client);
+@@ -2007,7 +2005,7 @@ SiSCtrlResetProc(ExtensionEntry* extEntry)
+ * in SiSCtrlExtUnregister())
+ */
+ if(extEntry->extPrivate) {
+- xfree(extEntry->extPrivate);
++ free(extEntry->extPrivate);
+ extEntry->extPrivate = NULL;
+ }
+ }
+@@ -2028,7 +2026,7 @@ SiSCtrlExtInit(ScrnInfoPtr pScrn)
+
+ if(!(myext = CheckExtension(SISCTRL_PROTOCOL_NAME))) {
+
+- if(!(myctrl = xcalloc(sizeof(xSiSCtrlScreenTable), 1)))
++ if(!(myctrl = calloc(sizeof(xSiSCtrlScreenTable), 1)))
+ return;
+
+ if(!(myext = AddExtension(SISCTRL_PROTOCOL_NAME, 0, 0,
+@@ -2038,7 +2036,7 @@ SiSCtrlExtInit(ScrnInfoPtr pScrn)
+ StandardMinorOpcode))) {
+ xf86DrvMsg(pScrn->scrnIndex, X_ERROR,
+ "Failed to add SISCTRL extension\n");
+- xfree(myctrl);
++ free(myctrl);
+ return;
+ }
+
+diff --git a/src/sis_vga.c b/src/sis_vga.c
+index 3f6219b..4c887b8 100644
+--- a/src/sis_vga.c
++++ b/src/sis_vga.c
+@@ -1429,7 +1429,7 @@ SiSVGASaveFonts(ScrnInfoPtr pScrn)
+ attr10 = SiS_ReadAttr(pSiS, 0x10);
+ if(attr10 & 0x01) return;
+
+- if(!(pSiS->fonts = xalloc(SIS_FONTS_SIZE * 2))) {
++ if(!(pSiS->fonts = malloc(SIS_FONTS_SIZE * 2))) {
+ xf86DrvMsg(pScrn->scrnIndex, X_ERROR,
+ "Could not save console fonts, mem allocation failed\n");
+ return;
+@@ -1716,8 +1716,8 @@ SiSVGAMapMem(ScrnInfoPtr pScrn)
+
+ #if XF86_VERSION_CURRENT >= XF86_VERSION_NUMERIC(4,3,0,0,0)
+ #if XSERVER_LIBPCIACCESS
+- pSiS->VGAMemBase = xf86MapDomainMemory(pScrn->scrnIndex, VIDMEM_MMIO_32BIT,
+- pSiS->PciInfo, pSiS->VGAMapPhys, pSiS->VGAMapSize);
++ (void) pci_device_map_legacy(pSiS->PciInfo, pSiS->VGAMapPhys, pSiS->VGAMapSize,
++ PCI_DEV_MAP_FLAG_WRITABLE, &pSiS->VGAMemBase);
+ #else
+ pSiS->VGAMemBase = xf86MapDomainMemory(pScrn->scrnIndex, VIDMEM_MMIO_32BIT,
+ pSiS->PciTag, pSiS->VGAMapPhys, pSiS->VGAMapSize);
+@@ -1737,7 +1737,12 @@ SiSVGAUnmapMem(ScrnInfoPtr pScrn)
+
+ if(pSiS->VGAMemBase == NULL) return;
+
++#if XSERVER_LIBPCIACCESS
++ (void) pci_device_unmap_legacy(pSiS->PciInfo, pSiS->VGAMemBase, pSiS->VGAMapSize);
++#else
+ xf86UnMapVidMem(pScrn->scrnIndex, pSiS->VGAMemBase, pSiS->VGAMapSize);
++#endif
++
+ pSiS->VGAMemBase = NULL;
+ }
+ #endif
+diff --git a/src/sis_video.c b/src/sis_video.c
+index 7322efb..2006858 100644
+--- a/src/sis_video.c
++++ b/src/sis_video.c
+@@ -326,7 +326,7 @@ SISInitVideo(ScreenPtr pScreen)
+ if(newAdaptor) size++;
+ if(newBlitAdaptor) size++;
+
+- newAdaptors = xalloc(size * sizeof(XF86VideoAdaptorPtr*));
++ newAdaptors = malloc(size * sizeof(XF86VideoAdaptorPtr*));
+ if(newAdaptors) {
+ if(num_adaptors) {
+ memcpy(newAdaptors, adaptors, num_adaptors * sizeof(XF86VideoAdaptorPtr));
+@@ -356,7 +356,7 @@ SISInitVideo(ScreenPtr pScreen)
+ }
+
+ if(newAdaptors) {
+- xfree(newAdaptors);
++ free(newAdaptors);
+ }
+ }
+
+@@ -877,7 +877,7 @@ SISSetupImageVideo(ScreenPtr pScreen)
+ }
+ #endif
+
+- if(!(adapt = xcalloc(1, sizeof(XF86VideoAdaptorRec) +
++ if(!(adapt = calloc(1, sizeof(XF86VideoAdaptorRec) +
+ sizeof(SISPortPrivRec) +
+ sizeof(DevUnion)))) {
+ return NULL;
+@@ -4067,7 +4067,7 @@ SISSetupBlitVideo(ScreenPtr pScreen)
+ }
+ #endif
+
+- if(!(adapt = xcalloc(1, sizeof(XF86VideoAdaptorRec) +
++ if(!(adapt = calloc(1, sizeof(XF86VideoAdaptorRec) +
+ (sizeof(DevUnion) * NUM_BLIT_PORTS) +
+ sizeof(SISBPortPrivRec)))) {
+ return NULL;
+diff --git a/src/sispcirename.h b/src/sispcirename.h
+index c4beac6..a354ac4 100644
+--- a/src/sispcirename.h
++++ b/src/sispcirename.h
+@@ -29,11 +29,40 @@
+ #ifndef SISPCIRENAME_H
+ #define SISPCIRENAME_H
+
++#include <stdint.h>
++
+ enum region_type {
+ REGION_MEM,
+ REGION_IO
+ };
+
++#include "xf86Module.h"
++
++#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) >= 12
++
++#if (defined(__alpha__) || defined(__ia64__)) && defined (linux)
++#define PCI_DOM_MASK 0x01fful
++#else
++#define PCI_DOM_MASK 0x0ffu
++#endif
++
++#ifndef PCI_DOM_MASK
++# define PCI_DOM_MASK 0x0ffu
++#endif
++#define PCI_DOMBUS_MASK (((PCI_DOM_MASK) << 8) | 0x0ffu)
++
++static inline uint32_t
++pciTag(int busnum, int devnum, int funcnum)
++{
++ uint32_t tag;
++ tag = (busnum & (PCI_DOMBUS_MASK)) << 16;
++ tag |= (devnum & 0x00001fu) << 11;
++ tag |= (funcnum & 0x000007u) << 8;
++
++ return tag;
++}
++#endif /* GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) >= 12 */
++
+ #ifndef XSERVER_LIBPCIACCESS
+
+ /* pciVideoPtr */
+diff --git a/src/vgatypes.h b/src/vgatypes.h
+index 4be31e4..d6e7b6e 100644
+--- a/src/vgatypes.h
++++ b/src/vgatypes.h
+@@ -69,8 +69,9 @@ typedef unsigned int BOOLEAN;
+
+ #define SISIOMEMTYPE
+
+-#ifdef SIS_LINUX_KERNEL
+ typedef unsigned long SISIOADDRESS;
++
++#ifdef SIS_LINUX_KERNEL
+ #if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,8)
+ #include <linux/types.h> /* Need __iomem */
+ #undef SISIOMEMTYPE
+@@ -78,15 +79,6 @@ typedef unsigned long SISIOADDRESS;
+ #endif
+ #endif
+
+-#ifdef SIS_XORG_XF86
+-#if XF86_VERSION_CURRENT < XF86_VERSION_NUMERIC(4,2,0,0,0)
+-typedef unsigned long IOADDRESS;
+-typedef unsigned long SISIOADDRESS;
+-#else
+-typedef IOADDRESS SISIOADDRESS;
+-#endif
+-#endif
+-
+ typedef enum _SIS_CHIP_TYPE {
+ SIS_VGALegacy = 0,
+ SIS_530,
diff --git a/extra/xf86-video-sisusb/PKGBUILD b/extra/xf86-video-sisusb/PKGBUILD
index aad955f07..57339c20f 100644
--- a/extra/xf86-video-sisusb/PKGBUILD
+++ b/extra/xf86-video-sisusb/PKGBUILD
@@ -1,25 +1,32 @@
-# $Id: PKGBUILD 140300 2011-10-11 21:28:37Z jgc $
+# $Id: PKGBUILD 153370 2012-03-12 20:54:32Z andyrtr $
#Maintainer: Jan de Groot <jgc@archlinux.org>
pkgname=xf86-video-sisusb
pkgver=0.9.4
-pkgrel=5
+pkgrel=6
pkgdesc="X.org SiS USB video driver"
arch=(i686 x86_64)
url="http://xorg.freedesktop.org/"
license=('custom')
depends=('glibc')
-makedepends=('xorg-server-devel>=1.10.99.902')
-conflicts=('xorg-server<1.10.99.902')
+makedepends=('xorg-server-devel>=1.11.99.903')
+conflicts=('xorg-server<1.11.99.903')
groups=('xorg-drivers' 'xorg')
options=('!libtool')
-source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2)
-sha1sums=('600fd49dffe00121f9042555fea55948653d1a7e')
+source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2
+ sisusb-0.9.4-git.patch)
+sha1sums=('600fd49dffe00121f9042555fea55948653d1a7e'
+ 'd74ce7732889c7a00d9d2dcd2bfc8be05c6eb912')
build() {
cd "${srcdir}/${pkgname}-${pkgver}"
+ patch -Np1 -i ${srcdir}/sisusb-0.9.4-git.patch
./configure --prefix=/usr
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/extra/xf86-video-sisusb/sisusb-0.9.4-git.patch b/extra/xf86-video-sisusb/sisusb-0.9.4-git.patch
new file mode 100644
index 000000000..24474954a
--- /dev/null
+++ b/extra/xf86-video-sisusb/sisusb-0.9.4-git.patch
@@ -0,0 +1,794 @@
+diff --git a/configure.ac b/configure.ac
+index 86c6ac5..725d6cb 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -20,49 +20,48 @@
+ #
+ # Process this file with autoconf to produce a configure script
+
+-AC_PREREQ(2.57)
++# Initialize Autoconf
++AC_PREREQ([2.60])
+ AC_INIT([xf86-video-sisusb],
+- 0.9.4,
++ [0.9.4],
+ [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg],
+- xf86-video-sisusb)
+-
++ [xf86-video-sisusb])
+ AC_CONFIG_SRCDIR([Makefile.am])
+-AM_CONFIG_HEADER([config.h])
++AC_CONFIG_HEADERS([config.h])
+ AC_CONFIG_AUX_DIR(.)
+
++# Initialize Automake
+ AM_INIT_AUTOMAKE([foreign dist-bzip2])
+-
+ AM_MAINTAINER_MODE
+
+-# Require xorg-macros: XORG_DEFAULT_OPTIONS
++# Require X.Org macros 1.8 or later for MAN_SUBSTS set by XORG_MANPAGE_SECTIONS
+ m4_ifndef([XORG_MACROS_VERSION],
+- [m4_fatal([must install xorg-macros 1.3 or later before running autoconf/autogen])])
+-XORG_MACROS_VERSION(1.3)
++ [m4_fatal([must install xorg-macros 1.8 or later before running autoconf/autogen])])
++XORG_MACROS_VERSION(1.8)
+ XORG_DEFAULT_OPTIONS
+
+-# Checks for programs.
++# Initialize libtool
+ AC_DISABLE_STATIC
+ AC_PROG_LIBTOOL
+-AC_PROG_CC
+-XORG_PROG_RAWCPP
+
+ AH_TOP([#include "xorg-server.h"])
+
++# Define a configure option for an alternate module directory
+ AC_ARG_WITH(xorg-module-dir,
+- AC_HELP_STRING([--with-xorg-module-dir=DIR],
++ AS_HELP_STRING([--with-xorg-module-dir=DIR],
+ [Default xorg module directory [[default=$libdir/xorg/modules]]]),
+ [moduledir="$withval"],
+ [moduledir="$libdir/xorg/modules"])
+
+-# Checks for extensions
++# Store the list of server defined optional extensions in REQUIRED_MODULES
+ XORG_DRIVER_CHECK_EXT(XINERAMA, xineramaproto)
+ XORG_DRIVER_CHECK_EXT(RANDR, randrproto)
+ XORG_DRIVER_CHECK_EXT(RENDER, renderproto)
+ XORG_DRIVER_CHECK_EXT(XV, videoproto)
+ XORG_DRIVER_CHECK_EXT(DPMSExtension, xextproto)
+
+-# Checks for pkg-config packages
+-PKG_CHECK_MODULES(XORG, [xorg-server >= 1.0.99.901 xproto fontsproto $REQUIRED_MODULES])
++# Obtain compiler/linker options for the driver dependencies
++PKG_CHECK_MODULES(XORG, [xorg-server >= 1.0.99.901 xproto fontsproto pciaccess $REQUIRED_MODULES])
+ PKG_CHECK_MODULES(XEXT, [xextproto >= 7.0.99.1],
+ HAVE_XEXTPROTO_71="yes"; AC_DEFINE(HAVE_XEXTPROTO_71, 1, [xextproto 7.1 available]),
+ HAVE_XEXTPROTO_71="no")
+@@ -70,17 +69,14 @@ AM_CONDITIONAL(HAVE_XEXTPROTO_71, [ test "$HAVE_XEXTPROTO_71" = "yes" ])
+
+ # Checks for libraries.
+
+-# Checks for header files.
+-AC_HEADER_STDC
+-
+-AC_SUBST([XORG_CFLAGS])
+ AC_SUBST([moduledir])
+
+ DRIVER_NAME=sisusb
+ AC_SUBST([DRIVER_NAME])
+
+-AC_OUTPUT([
+- Makefile
+- src/Makefile
+- man/Makefile
++AC_CONFIG_FILES([
++ Makefile
++ src/Makefile
++ man/Makefile
+ ])
++AC_OUTPUT
+diff --git a/man/Makefile.am b/man/Makefile.am
+index 1b26ac2..9ceb36f 100644
+--- a/man/Makefile.am
++++ b/man/Makefile.am
+@@ -31,39 +31,9 @@ EXTRA_DIST = @DRIVER_NAME@.man
+
+ CLEANFILES = $(driverman_DATA)
+
+-SED = sed
+-
+-# Strings to replace in man pages
+-XORGRELSTRING = @PACKAGE_STRING@
+- XORGMANNAME = X Version 11
+-
+-MANDEFS = \
+- -D__vendorversion__="\"$(XORGRELSTRING)\" \"$(XORGMANNAME)\"" \
+- -D__appmansuffix__=$(APP_MAN_SUFFIX) \
+- -D__filemansuffix__=$(FILE_MAN_SUFFIX) \
+- -D__libmansuffix__=$(LIB_MAN_SUFFIX) \
+- -D__miscmansuffix__=$(MISC_MAN_SUFFIX) \
+- -D__drivermansuffix__=$(DRIVER_MAN_SUFFIX) \
+- -D__adminmansuffix__=$(ADMIN_MAN_SUFFIX) \
+- -D__xconfigfile__=xorg.conf \
+- -D__xservername__=Xorg
+-
+-# Translate XCOMM into pound sign with sed, rather than passing -DXCOMM=XCOMM
+-# to cpp, because that trick does not work on all ANSI C preprocessors.
+-# Delete line numbers from the cpp output (-P is not portable, I guess).
+-# Allow XCOMM to be preceded by whitespace and provide a means of generating
+-# output lines with trailing backslashes.
+-# Allow XHASH to always be substituted, even in cases where XCOMM isn't.
+-
+-CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \
+- -e '/^\#line *[0-9][0-9]* *.*$$/d' \
+- -e '/^[ ]*XCOMM$$/s/XCOMM/\#/' \
+- -e '/^[ ]*XCOMM[^a-zA-Z0-9_]/s/XCOMM/\#/' \
+- -e '/^[ ]*XHASH/s/XHASH/\#/' \
+- -e '/\@\@$$/s/\@\@$$/\\/'
+-
+ SUFFIXES = .$(DRIVER_MAN_SUFFIX) .man
+
++# String replacements in MAN_SUBSTS now come from xorg-macros.m4 via configure
+ .man.$(DRIVER_MAN_SUFFIX):
+- $(RAWCPP) $(RAWCPPFLAGS) $(MANDEFS) $(EXTRAMANDEFS) < $< | $(CPP_SED_MAGIC) > $@
++ $(AM_V_GEN)$(SED) $(MAN_SUBSTS) < $< > $@
+
+diff --git a/man/sisusb.man b/man/sisusb.man
+index 7817cb5..6eafb8e 100644
+--- a/man/sisusb.man
++++ b/man/sisusb.man
+@@ -1,17 +1,5 @@
+-.\" $XFree86$
+-.\" $XdotOrg$
+ .\" shorthand for double quote that works everywhere.
+ .ds q \N'34'
+-#ifdef __xservername__
+-#define __myservername__ __xservername__
+-#else
+-#define __myservername__ XFree86
+-#endif
+-#ifdef __xconfigfile__
+-#define __myxconfigfile__ __xconfigfile__
+-#else
+-#define __myxconfigfile__ XF86Config
+-#endif
+ .TH SISUSB __drivermansuffix__ __vendorversion__
+ .SH NAME
+ sisusb \- SiS USB video driver
+@@ -25,7 +13,7 @@ sisusb \- SiS USB video driver
+ .fi
+ .SH DESCRIPTION
+ .B sisusb
+-is an __myservername__ driver for SiS (Silicon Integrated Systems) video chips that
++is an __xservername__ driver for SiS (Silicon Integrated Systems) video chips that
+ are connected via a Net2280-based USB dongle. The driver is not accelerated, but
+ provides support for colordepths of 8, 16 and 24 bpp as well as Render and other
+ extensions.
+@@ -39,7 +27,7 @@ driver supports USB video cards based on the following chipsets:
+ The SiS315E/PRO features two CRT controllers. However, in its USB version, only
+ the first output, referred to as "CRT1", is being used.
+ .SH CONFIGURATION DETAILS
+-Please refer to __myxconfigfile__(__filemansuffix__) for general configuration
++Please refer to __xconfigfile__(__filemansuffix__) for general configuration
+ details and to sis(__drivermansuffix__) for more information. This manpage only
+ covers a subset of the supported options.
+ .PP
+@@ -81,11 +69,7 @@ for device reconnection).
+ .SH "KNOWN BUGS"
+ none.
+ .SH "SEE ALSO"
+-#ifdef __xservername__
+ __xservername__(__appmansuffix__), __xconfigfile__(__filemansuffix__), Xserver(__appmansuffix__), X(__miscmansuffix__), sis(__drivermansuffix__)
+-#else
+-XFree86(1), XF86Config(__filemansuffix__), xf86config(1), Xserver(1), X(__miscmansuffix__), sis(__drivermansuffix__)
+-#endif
+ .PP
+ .B "http://www.winischhofer.at/linuxsisvga.shtml"
+ for more information and updates
+diff --git a/src/sisusb.h b/src/sisusb.h
+index b9992ac..82ed509 100644
+--- a/src/sisusb.h
++++ b/src/sisusb.h
+@@ -113,6 +113,14 @@
+ #include <X11/extensions/Xv.h>
+ #endif
+
++#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 12
++#define _swapl(x, n) swapl(x,n)
++#define _swaps(x, n) swaps(x,n)
++#else
++#define _swapl(x, n) swapl(x)
++#define _swaps(x, n) swaps(x)
++#endif
++
+ /* Platform/architecture related definitions: */
+
+ #undef SIS_PC_PLATFORM
+@@ -141,7 +149,6 @@
+ #define UNLOCK_ALWAYS /* Always unlock the registers (should be set!) */
+
+ /* Need that for SiSCtrl */
+-#define NEED_REPLIES /* ? */
+ #define EXTENSION_PROC_ARGS void *
+ #include "extnsionst.h" /* required */
+ #include <X11/extensions/panoramiXproto.h> /* required */
+@@ -732,7 +739,7 @@ typedef struct {
+ Bool skipswitchcheck;
+ ULong VBFlagsInit;
+ DisplayModePtr currentModeLast;
+- IOADDRESS MyPIOOffset;
++ unsigned long MyPIOOffset;
+
+ char messagebuffer[64];
+ unsigned int VGAMapSize; /* SiSVGA stuff */
+diff --git a/src/sisusb_dac.c b/src/sisusb_dac.c
+index 5e3eb7f..b5c4dce 100644
+--- a/src/sisusb_dac.c
++++ b/src/sisusb_dac.c
+@@ -672,7 +672,7 @@ SiSUSBMemCopyToVideoRam(SISUSBPtr pSiSUSB, UChar *to, UChar *from, int size)
+ int num, retry = 3;
+ if(pSiSUSB->sisusbfatalerror) return;
+ do {
+- lseek(pSiSUSB->sisusbdev, (int)to, SEEK_SET);
++ lseek(pSiSUSB->sisusbdev, (uintptr_t)to, SEEK_SET);
+ num = write(pSiSUSB->sisusbdev, from, size);
+ } while((num != size) && --retry);
+ if(!retry) SiSLostConnection(pSiSUSB);
+@@ -958,7 +958,7 @@ void sisclearvram(SISUSBPtr pSiSUSB, UChar *where, unsigned int howmuch)
+ if(pSiSUSB->sisusbfatalerror) return;
+ do {
+ x.operation = SUCMD_CLRSCR;
+- x.data3 = (CARD32)where;
++ x.data3 = (CARD32)(uintptr_t)where;
+ x.data0 = (howmuch >> 16) & 0xff;
+ x.data1 = (howmuch >> 8) & 0xff;
+ x.data2 = howmuch & 0xff;
+@@ -990,7 +990,7 @@ void SIS_MMIO_OUT8(SISUSBPtr pSiSUSB, UChar *base, unsigned int offset, CARD8 va
+ int num, retry = 3;
+ if(pSiSUSB->sisusbfatalerror) return;
+ do {
+- lseek(pSiSUSB->sisusbdev, (int)base + offset, SEEK_SET);
++ lseek(pSiSUSB->sisusbdev, (uintptr_t)base + offset, SEEK_SET);
+ num = write(pSiSUSB->sisusbdev, &val, 1);
+ } while((num != 1) && --retry);
+ if(!retry) SiSLostConnection(pSiSUSB);
+@@ -1002,7 +1002,7 @@ void SIS_MMIO_OUT16(SISUSBPtr pSiSUSB, UChar *base, unsigned int offset, CARD16
+ CARD16 buf = sisusb_cpu_to_le16(val);
+ if(pSiSUSB->sisusbfatalerror) return;
+ do {
+- lseek(pSiSUSB->sisusbdev, (int)base + offset, SEEK_SET);
++ lseek(pSiSUSB->sisusbdev, (uintptr_t)base + offset, SEEK_SET);
+ num = write(pSiSUSB->sisusbdev, &buf, 2);
+ } while((num != 2) && --retry);
+ if(!retry) SiSLostConnection(pSiSUSB);
+@@ -1014,7 +1014,7 @@ void SIS_MMIO_OUT32(SISUSBPtr pSiSUSB, UChar *base, unsigned int offset, CARD32
+ CARD32 buf = sisusb_cpu_to_le32(val);
+ if(pSiSUSB->sisusbfatalerror) return;
+ do {
+- lseek(pSiSUSB->sisusbdev, (int)base + offset, SEEK_SET);
++ lseek(pSiSUSB->sisusbdev, (uintptr_t)base + offset, SEEK_SET);
+ num = write(pSiSUSB->sisusbdev, &buf, 4);
+ } while((num != 4) && --retry);
+ if(!retry) SiSLostConnection(pSiSUSB);
+@@ -1026,7 +1026,7 @@ CARD8 SIS_MMIO_IN8(SISUSBPtr pSiSUSB, UChar *base, unsigned int offset)
+ CARD8 tmp;
+ if(pSiSUSB->sisusbfatalerror) return 0;
+ do {
+- lseek(pSiSUSB->sisusbdev, (int)base + offset, SEEK_SET);
++ lseek(pSiSUSB->sisusbdev, (uintptr_t)base + offset, SEEK_SET);
+ num = read(pSiSUSB->sisusbdev, &tmp, 1);
+ } while((num != 1) && --retry);
+ if(!retry) SiSLostConnection(pSiSUSB);
+@@ -1039,7 +1039,7 @@ CARD16 SIS_MMIO_IN16(SISUSBPtr pSiSUSB, UChar *base, unsigned int offset)
+ CARD16 tmp;
+ if(pSiSUSB->sisusbfatalerror) return 0;
+ do {
+- lseek(pSiSUSB->sisusbdev, (int)base + offset, SEEK_SET);
++ lseek(pSiSUSB->sisusbdev, (uintptr_t)base + offset, SEEK_SET);
+ num = read(pSiSUSB->sisusbdev, &tmp, 2);
+ } while((num != 2) && --retry);
+ if(!retry) SiSLostConnection(pSiSUSB);
+@@ -1052,7 +1052,7 @@ CARD32 SIS_MMIO_IN32(SISUSBPtr pSiSUSB, UChar *base, unsigned int offset)
+ CARD32 tmp;
+ if(pSiSUSB->sisusbfatalerror) return 0;
+ do {
+- lseek(pSiSUSB->sisusbdev, (int)base + offset, SEEK_SET);
++ lseek(pSiSUSB->sisusbdev, (uintptr_t)base + offset, SEEK_SET);
+ num = read(pSiSUSB->sisusbdev, &tmp, 4);
+ } while((num != 4) && --retry);
+ if(!retry) SiSLostConnection(pSiSUSB);
+diff --git a/src/sisusb_driver.c b/src/sisusb_driver.c
+index 8ba2c33..032225c 100644
+--- a/src/sisusb_driver.c
++++ b/src/sisusb_driver.c
+@@ -186,12 +186,12 @@ SISUSBFreeRec(ScrnInfoPtr pScrn)
+ /* Just to make sure... */
+ if(!pSiSUSB) return;
+
+- if(pSiSUSB->pstate) xfree(pSiSUSB->pstate);
++ if(pSiSUSB->pstate) free(pSiSUSB->pstate);
+ pSiSUSB->pstate = NULL;
+- if(pSiSUSB->fonts) xfree(pSiSUSB->fonts);
++ if(pSiSUSB->fonts) free(pSiSUSB->fonts);
+ pSiSUSB->fonts = NULL;
+
+- if(pSiSUSB->SiS_Pr) xfree(pSiSUSB->SiS_Pr);
++ if(pSiSUSB->SiS_Pr) free(pSiSUSB->SiS_Pr);
+ pSiSUSB->SiS_Pr = NULL;
+
+ if(pSiSUSB->sisusbdevopen) {
+@@ -200,12 +200,12 @@ SISUSBFreeRec(ScrnInfoPtr pScrn)
+ }
+
+ if(pScrn->chipset) {
+- xfree(pScrn->chipset);
++ free(pScrn->chipset);
+ pScrn->chipset = NULL;
+ }
+
+ if(pScrn->driverPrivate) {
+- xfree(pScrn->driverPrivate);
++ free(pScrn->driverPrivate);
+ pScrn->driverPrivate = NULL;
+ }
+ }
+@@ -217,14 +217,14 @@ SISUSBErrorLog(ScrnInfoPtr pScrn, const char *format, ...)
+ static const char *str = "**************************************************\n";
+
+ va_start(ap, format);
+- xf86DrvMsg(pScrn->scrnIndex, X_ERROR, str);
++ xf86DrvMsg(pScrn->scrnIndex, X_ERROR, "%s", str);
+ xf86DrvMsg(pScrn->scrnIndex, X_ERROR,
+ " ERROR:\n");
+ xf86VDrvMsgVerb(pScrn->scrnIndex, X_ERROR, 1, format, ap);
+ va_end(ap);
+ xf86DrvMsg(pScrn->scrnIndex, X_ERROR,
+ " END OF MESSAGE\n");
+- xf86DrvMsg(pScrn->scrnIndex, X_ERROR, str);
++ xf86DrvMsg(pScrn->scrnIndex, X_ERROR, "%s", str);
+ }
+
+ static int
+@@ -248,7 +248,7 @@ SiSUSBCheckForUSBDongle(char *filename, SISUSBPtr pSiSUSB, int *filehandle)
+
+ if((myfile = open(filename, O_RDWR, 0)) != -1) {
+ if(!ioctl(myfile, SISUSB_GET_CONFIG_SIZE, &sisusbinfosize)) {
+- if((mysisusbinfo = xalloc(sisusbinfosize))) {
++ if((mysisusbinfo = malloc(sisusbinfosize))) {
+ if(!ioctl(myfile, (SISUSB_GET_CONFIG | (sisusbinfosize << 16)), mysisusbinfo)) {
+ if(mysisusbinfo->sisusb_id == SISUSB_ID) {
+ sisusbversion = (mysisusbinfo->sisusb_version << 16) |
+@@ -280,7 +280,7 @@ SiSUSBCheckForUSBDongle(char *filename, SISUSBPtr pSiSUSB, int *filehandle)
+ retval = mysisusbinfo->sisusb_minor;
+ }
+ }
+- xfree(mysisusbinfo);
++ free(mysisusbinfo);
+ mysisusbinfo = NULL;
+ }
+ }
+@@ -307,13 +307,13 @@ SiSUSBFindUSBDongle(GDevPtr dev, int *minorArray, int numDevSections, char **nam
+ }
+ if((p) && (*p) && (*p == '/')) {
+ gotdev = 1;
+- *nameptr = xalloc(strlen(p) + 1);
++ *nameptr = malloc(strlen(p) + 1);
+ strcpy(*nameptr, p);
+ retval = SiSUSBCheckForUSBDongle(*nameptr, NULL, NULL);
+ } else if((p) && (*p) && (sscanf(p, "%d", &i) == 1)) {
+ if(i >= 0 && i <= 31) {
+ gotdev = 1;
+- *nameptr = xalloc(32);
++ *nameptr = malloc(32);
+ sprintf(*nameptr, "/dev/sisusbvga%d", i);
+ retval = SiSUSBCheckForUSBDongle(*nameptr, NULL, NULL);
+ if(retval < 0) {
+@@ -324,7 +324,7 @@ SiSUSBFindUSBDongle(GDevPtr dev, int *minorArray, int numDevSections, char **nam
+ }
+ }
+ if(!gotdev) {
+- *nameptr = xalloc(32);
++ *nameptr = malloc(32);
+ for(i = 0; i < 64; i++) {
+ if(i < 32) sprintf(*nameptr, "/dev/sisusbvga%d", i);
+ else sprintf(*nameptr, "/dev/usb/sisusbvga%d", i);
+@@ -338,7 +338,7 @@ SiSUSBFindUSBDongle(GDevPtr dev, int *minorArray, int numDevSections, char **nam
+ if(retval >= 0) {
+ xf86Msg(X_INFO, "Found SiSUSB dongle (node %s, minor %d)\n", *nameptr, retval);
+ } else if((*nameptr)) {
+- xfree(*nameptr);
++ free(*nameptr);
+ *nameptr = NULL;
+ }
+
+@@ -401,14 +401,14 @@ SISUSBProbe(DriverPtr drv, int flags)
+ */
+
+ /* Allocate and initialize an array of ints for storing the minors */
+- if(!(minorArray = (int *)xalloc(numDevSections * sizeof(int)))) {
++ if(!(minorArray = (int *)malloc(numDevSections * sizeof(int)))) {
+ return FALSE;
+ }
+ for(i = 0; i < numDevSections; i++) minorArray[i] = -1;
+
+ /* Allocate an array of char ptrs for storing the device node names */
+- if(!(devnameArray = (char **)xalloc(numDevSections * sizeof(char *)))) {
+- xfree(minorArray);
++ if(!(devnameArray = (char **)malloc(numDevSections * sizeof(char *)))) {
++ free(minorArray);
+ return FALSE;
+ }
+
+@@ -420,20 +420,20 @@ SISUSBProbe(DriverPtr drv, int flags)
+ if((myminor = SiSUSBFindUSBDongle(devSections[i], minorArray, numDevSections, &nameptr)) >= 0) {
+ if(!SiSUSBFindDuplicate(myminor, minorArray, numDevSections)) {
+ minorArray[numUsed] = myminor;
+- devnameArray[numUsed] = xalloc(strlen(nameptr) + 1);
++ devnameArray[numUsed] = malloc(strlen(nameptr) + 1);
+ strcpy(devnameArray[numUsed], nameptr);
+ numUsed++;
+ }
+- xfree(nameptr);
++ free(nameptr);
+ }
+ }
+
+ /* Free the minor array, we don't need it anymore */
+- xfree(minorArray);
++ free(minorArray);
+
+ if(numUsed <= 0) {
+- xfree(devSections);
+- xfree(devnameArray);
++ free(devSections);
++ free(devnameArray);
+ return FALSE;
+ }
+
+@@ -470,8 +470,8 @@ SISUSBProbe(DriverPtr drv, int flags)
+
+ }
+
+- xfree(devSections);
+- xfree(devnameArray);
++ free(devSections);
++ free(devnameArray);
+ return foundScreen;
+ }
+
+@@ -622,10 +622,10 @@ SISUSBCalculateGammaRamp(ScreenPtr pScreen, ScrnInfoPtr pScrn)
+ if(!(nramp = xf86GetGammaRampSize(pScreen))) return;
+
+ for(i=0; i<3; i++) {
+- ramp[i] = (UShort *)xalloc(nramp * sizeof(UShort));
++ ramp[i] = (UShort *)malloc(nramp * sizeof(UShort));
+ if(!ramp[i]) {
+- if(ramp[0]) { xfree(ramp[0]); ramp[0] = NULL; }
+- if(ramp[1]) { xfree(ramp[1]); ramp[1] = NULL; }
++ if(ramp[0]) { free(ramp[0]); ramp[0] = NULL; }
++ if(ramp[1]) { free(ramp[1]); ramp[1] = NULL; }
+ return;
+ }
+ }
+@@ -685,9 +685,9 @@ SISUSBCalculateGammaRamp(ScreenPtr pScreen, ScrnInfoPtr pScrn)
+
+ xf86ChangeGammaRamp(pScreen, nramp, ramp[0], ramp[1], ramp[2]);
+
+- xfree(ramp[0]);
+- xfree(ramp[1]);
+- xfree(ramp[2]);
++ free(ramp[0]);
++ free(ramp[1]);
++ free(ramp[2]);
+ ramp[0] = ramp[1] = ramp[2] = NULL;
+ }
+ #endif
+@@ -906,11 +906,11 @@ SISUSBPreInit(ScrnInfoPtr pScrn, int flags)
+ Bool gotit = FALSE;
+
+ if(!ioctl(fd, SISUSBFB_GET_INFO_SIZE, &sisfbinfosize)) {
+- if((mysisfbinfo = xalloc(sisfbinfosize))) {
++ if((mysisfbinfo = malloc(sisfbinfosize))) {
+ if(!ioctl(fd, (SISUSBFB_GET_INFO | (sisfbinfosize << 16)), mysisfbinfo)) {
+ gotit = TRUE;
+ } else {
+- xfree(mysisfbinfo);
++ free(mysisfbinfo);
+ mysisfbinfo = NULL;
+ }
+ }
+@@ -944,7 +944,7 @@ SISUSBPreInit(ScrnInfoPtr pScrn, int flags)
+
+ }
+ }
+- xfree(mysisfbinfo);
++ free(mysisfbinfo);
+ mysisfbinfo = NULL;
+ }
+ close (fd);
+@@ -1147,7 +1147,7 @@ SISUSBPreInit(ScrnInfoPtr pScrn, int flags)
+ #endif
+
+ if(pSiSUSB->HWCursor) {
+- if(!(pSiSUSB->USBCursorBuf = xcalloc(pSiSUSB->CursorSize * 4, 1))) pSiSUSB->HWCursor = FALSE;
++ if(!(pSiSUSB->USBCursorBuf = calloc(pSiSUSB->CursorSize * 4, 1))) pSiSUSB->HWCursor = FALSE;
+
+ pSiSUSB->availMem -= (pSiSUSB->CursorSize * 2);
+ if(pSiSUSB->OptUseColorCursor) pSiSUSB->availMem -= (pSiSUSB->CursorSize * 2);
+@@ -1456,8 +1456,8 @@ SISUSBMapMem(ScrnInfoPtr pScrn)
+ {
+ SISUSBPtr pSiSUSB = SISUSBPTR(pScrn);
+
+- pSiSUSB->FbBase = (UChar *)pSiSUSB->FbAddress;
+- pSiSUSB->IOBase = (UChar *)pSiSUSB->IOAddress;
++ pSiSUSB->FbBase = (UChar *)(uintptr_t)pSiSUSB->FbAddress;
++ pSiSUSB->IOBase = (UChar *)(uintptr_t)pSiSUSB->IOAddress;
+
+ return TRUE;
+ }
+@@ -1811,7 +1811,7 @@ SISUSBScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
+
+ if(pSiSUSB->ShadowFB) {
+ pSiSUSB->ShadowPitch = BitmapBytePad(pScrn->bitsPerPixel * displayWidth);
+- pSiSUSB->ShadowPtr = xalloc(pSiSUSB->ShadowPitch * height);
++ pSiSUSB->ShadowPtr = malloc(pSiSUSB->ShadowPitch * height);
+ if(!(FBStart = pSiSUSB->ShadowPtr)) {
+ SISUSBSaveScreen(pScreen, SCREEN_SAVER_OFF);
+ SISUSBErrorLog(pScrn, "Failed to allocate shadow framebuffer\n");
+@@ -1820,7 +1820,7 @@ SISUSBScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
+ #if X_BYTE_ORDER == X_BIG_ENDIAN
+ if(pScrn->bitsPerPixel == 16) {
+ /* For 16bpp, we need to swap the bytes in the framebuffer */
+- if(!(pSiSUSB->ShadowPtrSwap = xalloc(pSiSUSB->ShadowPitch * height))) {
++ if(!(pSiSUSB->ShadowPtrSwap = malloc(pSiSUSB->ShadowPitch * height))) {
+ SISUSBSaveScreen(pScreen, SCREEN_SAVER_OFF);
+ SISUSBErrorLog(pScrn, "Failed to allocate swap buffer for shadow framebuffer\n");
+ return FALSE;
+@@ -2238,24 +2238,24 @@ SISUSBCloseScreen(int scrnIndex, ScreenPtr pScreen)
+ }
+
+ if(pSiSUSB->USBCursorBuf) {
+- xfree(pSiSUSB->USBCursorBuf);
++ free(pSiSUSB->USBCursorBuf);
+ pSiSUSB->USBCursorBuf = NULL;
+ }
+
+ if(pSiSUSB->ShadowPtr) {
+- xfree(pSiSUSB->ShadowPtr);
++ free(pSiSUSB->ShadowPtr);
+ pSiSUSB->ShadowPtr = NULL;
+ }
+
+ #if 0
+ if(pSiSUSB->PreAllocMem) {
+- xfree(pSiSUSB->PreAllocMem);
++ free(pSiSUSB->PreAllocMem);
+ pSiSUSB->PreAllocMem = NULL;
+ }
+ #endif
+
+ if(pSiSUSB->adaptor) {
+- xfree(pSiSUSB->adaptor);
++ free(pSiSUSB->adaptor);
+ pSiSUSB->adaptor = NULL;
+ pSiSUSB->ResetXv = pSiSUSB->ResetXvGamma = NULL;
+ }
+diff --git a/src/sisusb_init.c b/src/sisusb_init.c
+index ba44431..99ec519 100644
+--- a/src/sisusb_init.c
++++ b/src/sisusb_init.c
+@@ -1301,10 +1301,10 @@ SiSUSBBuildBuiltInModeList(ScrnInfoPtr pScrn, BOOLEAN includelcdmodes, BOOLEAN i
+ }
+ }
+
+- if(!(new = xalloc(sizeof(DisplayModeRec)))) return first;
++ if(!(new = malloc(sizeof(DisplayModeRec)))) return first;
+ memset(new, 0, sizeof(DisplayModeRec));
+- if(!(new->name = xalloc(10))) {
+- xfree(new);
++ if(!(new->name = malloc(10))) {
++ free(new);
+ return first;
+ }
+ if(!first) first = new;
+diff --git a/src/sisusb_opt.c b/src/sisusb_opt.c
+index d4612b0..4d5cfa3 100644
+--- a/src/sisusb_opt.c
++++ b/src/sisusb_opt.c
+@@ -228,7 +228,7 @@ SiSUSBOptions(ScrnInfoPtr pScrn)
+ xf86CollectOptions(pScrn, NULL);
+
+ /* Process the options */
+- if(!(pSiSUSB->Options = xalloc(sizeof(SISUSBOptions)))) return;
++ if(!(pSiSUSB->Options = malloc(sizeof(SISUSBOptions)))) return;
+
+ memcpy(pSiSUSB->Options, SISUSBOptions, sizeof(SISUSBOptions));
+
+diff --git a/src/sisusb_osdef.h b/src/sisusb_osdef.h
+index 2d938ad..500bffb 100644
+--- a/src/sisusb_osdef.h
++++ b/src/sisusb_osdef.h
+@@ -77,11 +77,11 @@
+
+ #define SIS315H
+
+-#define OutPortByte(p,v) outSISREG((IOADDRESS)(p),(CARD8)(v))
+-#define OutPortWord(p,v) outSISREGW((IOADDRESS)(p),(CARD16)(v))
+-#define OutPortLong(p,v) outSISREGL((IOADDRESS)(p),(CARD32)(v))
+-#define InPortByte(p) inSISREG((IOADDRESS)(p))
+-#define InPortWord(p) inSISREGW((IOADDRESS)(p))
+-#define InPortLong(p) inSISREGL((IOADDRESS)(p))
++#define OutPortByte(p,v) outSISREG((unsigned long)(p),(CARD8)(v))
++#define OutPortWord(p,v) outSISREGW((unsigned long)(p),(CARD16)(v))
++#define OutPortLong(p,v) outSISREGL((unsigned long)(p),(CARD32)(v))
++#define InPortByte(p) inSISREG((unsigned long)(p))
++#define InPortWord(p) inSISREGW((unsigned long)(p))
++#define InPortLong(p) inSISREGL((unsigned long)(p))
+
+ #endif /* _SISUSB_OSDEF_H_ */
+diff --git a/src/sisusb_types.h b/src/sisusb_types.h
+index 04c7a7a..9fc6b41 100644
+--- a/src/sisusb_types.h
++++ b/src/sisusb_types.h
+@@ -51,6 +51,8 @@
+ #ifndef _VGATYPES_
+ #define _VGATYPES_
+
++#include <xf86Pci.h>
++
+ #ifndef FALSE
+ #define FALSE 0
+ #endif
+@@ -93,7 +95,7 @@ typedef unsigned char BOOLEAN;
+
+ #define SISIOMEMTYPE
+
+-typedef IOADDRESS SISIOADDRESS;
++typedef unsigned long SISIOADDRESS;
+
+ typedef enum _SIS_CHIP_TYPE {
+ SIS_VGALegacy = 0,
+diff --git a/src/sisusb_utility.c b/src/sisusb_utility.c
+index 8c03d63..a9c1ee1 100644
+--- a/src/sisusb_utility.c
++++ b/src/sisusb_utility.c
+@@ -34,8 +34,6 @@
+ #endif
+
+ #include "sisusb.h"
+-#define NEED_REPLIES
+-#define NEED_EVENTS
+ #include <X11/X.h>
+ #include "dixstruct.h"
+
+@@ -789,10 +787,10 @@ SiSUSBProcSiSCtrlQueryVersion(ClientPtr client)
+ rep.majorVersion = SISCTRL_MAJOR_VERSION;
+ rep.minorVersion = SISCTRL_MINOR_VERSION;
+ if(client->swapped) {
+- swaps(&rep.sequenceNumber, n);
+- swapl(&rep.length, n);
+- swaps(&rep.majorVersion, n);
+- swaps(&rep.minorVersion, n);
++ _swaps(&rep.sequenceNumber, n);
++ _swapl(&rep.length, n);
++ _swaps(&rep.majorVersion, n);
++ _swaps(&rep.minorVersion, n);
+ }
+ WriteToClient(client, sizeof(xSiSCtrlQueryVersionReply), (char *)&rep);
+ return (client->noClientException);
+@@ -834,15 +832,15 @@ SiSUSBProcSiSCtrlCommand(ClientPtr client)
+ rep.sequenceNumber = client->sequence;
+
+ if(client->swapped) {
+- swaps(&rep.sequenceNumber, n);
+- swapl(&rep.length, n);
+- swapl(&rep.screen, n);
+- swapl(&rep.sdc_id, n);
+- swapl(&rep.sdc_command, n);
+- swapl(&rep.sdc_result_header, n);
++ _swaps(&rep.sequenceNumber, n);
++ _swapl(&rep.length, n);
++ _swapl(&rep.screen, n);
++ _swapl(&rep.sdc_id, n);
++ _swapl(&rep.sdc_command, n);
++ _swapl(&rep.sdc_result_header, n);
+ for(i = 0; i < SDC_NUM_PARM_RESULT; i++) {
+- swapl(&rep.sdc_parm[i], n);
+- swapl(&rep.sdc_result[i], n);
++ _swapl(&rep.sdc_parm[i], n);
++ _swapl(&rep.sdc_result[i], n);
+ }
+ }
+ WriteToClient(client, sizeof(xSiSCtrlCommandReply), (char *)&rep);
+@@ -869,7 +867,7 @@ SiSUSBSProcSiSCtrlQueryVersion(ClientPtr client)
+ {
+ REQUEST(xSiSCtrlQueryVersionReq);
+ register int n;
+- swaps(&stuff->length, n);
++ _swaps(&stuff->length, n);
+ REQUEST_SIZE_MATCH(xSiSCtrlQueryVersionReq);
+ return SiSUSBProcSiSCtrlQueryVersion(client);
+ }
+@@ -880,14 +878,14 @@ SiSUSBSProcSiSCtrlCommand(ClientPtr client)
+ REQUEST(xSiSCtrlCommandReq);
+ register int n;
+ int i;
+- swaps(&stuff->length, n);
+- swapl(&stuff->screen, n);
+- swapl(&stuff->sdc_id, n);
+- swapl(&stuff->sdc_command, n);
+- swapl(&stuff->sdc_result_header, n);
++ _swaps(&stuff->length, n);
++ _swapl(&stuff->screen, n);
++ _swapl(&stuff->sdc_id, n);
++ _swapl(&stuff->sdc_command, n);
++ _swapl(&stuff->sdc_result_header, n);
+ for(i = 0; i < SDC_NUM_PARM_RESULT; i++) {
+- swapl(&stuff->sdc_parm[i], n);
+- swapl(&stuff->sdc_result[i], n);
++ _swapl(&stuff->sdc_parm[i], n);
++ _swapl(&stuff->sdc_result[i], n);
+ }
+ REQUEST_SIZE_MATCH(xSiSCtrlCommandReq);
+ return SiSUSBProcSiSCtrlCommand(client);
+@@ -911,7 +909,7 @@ SiSUSBCtrlResetProc(ExtensionEntry* extEntry)
+ {
+ /* Called by CloseDownExtensions() */
+ if(extEntry->extPrivate) {
+- xfree(extEntry->extPrivate);
++ free(extEntry->extPrivate);
+ extEntry->extPrivate = NULL;
+ }
+ }
+@@ -928,7 +926,7 @@ SiSUSBCtrlExtInit(ScrnInfoPtr pScrn)
+
+ if(!(myext = CheckExtension(SISCTRL_PROTOCOL_NAME))) {
+
+- if(!(myctrl = xcalloc(sizeof(xSiSCtrlScreenTable), 1)))
++ if(!(myctrl = calloc(sizeof(xSiSCtrlScreenTable), 1)))
+ return;
+
+ if(!(myext = AddExtension(SISCTRL_PROTOCOL_NAME, 0, 0,
+@@ -938,7 +936,7 @@ SiSUSBCtrlExtInit(ScrnInfoPtr pScrn)
+ StandardMinorOpcode))) {
+ xf86DrvMsg(pScrn->scrnIndex, X_ERROR,
+ "Failed to add SISCTRL extension\n");
+- xfree(myctrl);
++ free(myctrl);
+ return;
+ }
+
+diff --git a/src/sisusb_video.c b/src/sisusb_video.c
+index bc469b0..1dbf4f1 100644
+--- a/src/sisusb_video.c
++++ b/src/sisusb_video.c
+@@ -216,7 +216,7 @@ void SISUSBInitVideo(ScreenPtr pScreen)
+
+ if(newAdaptor) size++;
+
+- newAdaptors = xalloc(size * sizeof(XF86VideoAdaptorPtr*));
++ newAdaptors = malloc(size * sizeof(XF86VideoAdaptorPtr*));
+ if(newAdaptors) {
+ if(num_adaptors) {
+ memcpy(newAdaptors, adaptors, num_adaptors * sizeof(XF86VideoAdaptorPtr));
+@@ -234,7 +234,7 @@ void SISUSBInitVideo(ScreenPtr pScreen)
+ }
+
+ if(newAdaptors) {
+- xfree(newAdaptors);
++ free(newAdaptors);
+ }
+ }
+
+@@ -377,7 +377,7 @@ SISUSBSetupImageVideo(ScreenPtr pScreen)
+ XF86VideoAdaptorPtr adapt;
+ SISUSBPortPrivPtr pPriv;
+
+- if(!(adapt = xcalloc(1, sizeof(XF86VideoAdaptorRec) +
++ if(!(adapt = calloc(1, sizeof(XF86VideoAdaptorRec) +
+ sizeof(SISUSBPortPrivRec) +
+ sizeof(DevUnion))))
+ return NULL;
diff --git a/extra/xf86-video-tdfx/PKGBUILD b/extra/xf86-video-tdfx/PKGBUILD
index 1d8a6948b..ecbb31fcb 100644
--- a/extra/xf86-video-tdfx/PKGBUILD
+++ b/extra/xf86-video-tdfx/PKGBUILD
@@ -1,28 +1,34 @@
-# $Id: PKGBUILD 140298 2011-10-11 21:28:35Z jgc $
+# $Id: PKGBUILD 153372 2012-03-12 20:54:36Z andyrtr $
# Maintainer: Jan de Groot <jgc@archlinux.org>
pkgname=xf86-video-tdfx
pkgver=1.4.3
-pkgrel=7
+pkgrel=8
+_gitver=a985b54c8559d7ff8f5481004d54989ed7499237
pkgdesc="X.org tdfx video driver"
arch=(i686 x86_64)
url="http://xorg.freedesktop.org/"
license=('custom')
-depends=('glibc' 'tdfx-dri')
-makedepends=('xorg-server-devel>=1.10.99.902' 'libdrm' 'xf86driproto' 'mesa' 'glproto')
-conflicts=('xorg-server<1.10.99.902')
+depends=('glibc')
+makedepends=('xorg-server-devel>=1.11.99.903' 'libdrm' 'xf86driproto' 'mesa>=8.0') # 'glproto')
+conflicts=('xorg-server<1.11.99.902')
options=(!libtool)
groups=('xorg-drivers' 'xorg')
-source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2
- copyright.patch)
-md5sums=('8161bbf2b100c21b609163f0010766b3'
- 'a3be7ac534ceb846d3f155ddbe14378f')
+source=(#${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2
+ http://cgit.freedesktop.org/xorg/driver/xf86-video-tdfx/snapshot/xf86-video-tdfx-${_gitver}.tar.gz)
+sha1sums=('01c13cdec926c1aaa9c8c8855995c6cc38149ab2')
build() {
- cd "${srcdir}/${pkgname}-${pkgver}"
- patch -Np1 -i "${srcdir}/copyright.patch"
- ./configure --prefix=/usr --enable-dri
+ #cd "${srcdir}/${pkgname}-${pkgver}"
+ cd ${srcdir}/${pkgname}*
+ autoreconf -fi
+ ./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}"
diff --git a/extra/xf86-video-trident/PKGBUILD b/extra/xf86-video-trident/PKGBUILD
index f7d60ed27..c8551a0f9 100644
--- a/extra/xf86-video-trident/PKGBUILD
+++ b/extra/xf86-video-trident/PKGBUILD
@@ -1,25 +1,32 @@
-# $Id: PKGBUILD 140296 2011-10-11 21:28:33Z jgc $
+# $Id: PKGBUILD 153374 2012-03-12 20:54:43Z andyrtr $
# Maintainer: Jan de Groot <jgc@archlinux.org>
pkgname=xf86-video-trident
pkgver=1.3.4
-pkgrel=5
+pkgrel=6
pkgdesc="X.org Trident video driver"
arch=(i686 x86_64)
url="http://xorg.freedesktop.org/"
license=('custom')
depends=('glibc')
-makedepends=('xorg-server-devel>=1.10.99.902' 'xf86dgaproto')
-conflicts=('xorg-server<1.10.99.902')
+makedepends=('xorg-server-devel>=1.11.99.903' 'xf86dgaproto')
+conflicts=('xorg-server<1.11.99.903')
groups=('xorg-drivers' 'xorg')
options=(!libtool)
-source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2)
-sha1sums=('7c40f5c02bddf399862782b708941e79302318af')
+source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2
+ trident-1.3.4-git.patch)
+sha1sums=('7c40f5c02bddf399862782b708941e79302318af'
+ 'cba17aad6cf2f051d89e65ffe26242ed62ea4454')
build() {
cd "${srcdir}/${pkgname}-${pkgver}"
+ patch -Np1 -i ${srcdir}/trident-1.3.4-git.patch
./configure --prefix=/usr
make
+}
+
+package() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
make DESTDIR="${pkgdir}" install
install -m755 -d "${pkgdir}/usr/share/licenses/${pkgname}"
diff --git a/extra/xf86-video-trident/trident-1.3.4-git.patch b/extra/xf86-video-trident/trident-1.3.4-git.patch
new file mode 100644
index 000000000..4e0cc27b2
--- /dev/null
+++ b/extra/xf86-video-trident/trident-1.3.4-git.patch
@@ -0,0 +1,523 @@
+diff --git a/configure.ac b/configure.ac
+index be54427..0fc2066 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -20,47 +20,47 @@
+ #
+ # Process this file with autoconf to produce a configure script
+
+-AC_PREREQ(2.57)
++# Initialize Autoconf
++AC_PREREQ([2.60])
+ AC_INIT([xf86-video-trident],
+- 1.3.4,
++ [1.3.4],
+ [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg],
+- xf86-video-trident)
+-
++ [xf86-video-trident])
+ AC_CONFIG_SRCDIR([Makefile.am])
+-AM_CONFIG_HEADER([config.h])
++AC_CONFIG_HEADERS([config.h])
+ AC_CONFIG_AUX_DIR(.)
+
++# Initialize Automake
+ AM_INIT_AUTOMAKE([foreign dist-bzip2])
+-
+ AM_MAINTAINER_MODE
+
+-# Require xorg-macros: XORG_DEFAULT_OPTIONS
++# Require X.Org macros 1.8 or later for MAN_SUBSTS set by XORG_MANPAGE_SECTIONS
+ m4_ifndef([XORG_MACROS_VERSION],
+- [m4_fatal([must install xorg-macros 1.3 or later before running autoconf/autogen])])
+-XORG_MACROS_VERSION(1.3)
++ [m4_fatal([must install xorg-macros 1.8 or later before running autoconf/autogen])])
++XORG_MACROS_VERSION(1.8)
+ XORG_DEFAULT_OPTIONS
+
+-# Checks for programs.
++# Initialize libtool
+ AC_DISABLE_STATIC
+ AC_PROG_LIBTOOL
+-AC_PROG_CC
+
+ AH_TOP([#include "xorg-server.h"])
+
++# Define a configure option for an alternate module directory
+ AC_ARG_WITH(xorg-module-dir,
+- AC_HELP_STRING([--with-xorg-module-dir=DIR],
++ AS_HELP_STRING([--with-xorg-module-dir=DIR],
+ [Default xorg module directory [[default=$libdir/xorg/modules]]]),
+ [moduledir="$withval"],
+ [moduledir="$libdir/xorg/modules"])
+
+-# Checks for extensions
++# Store the list of server defined optional extensions in REQUIRED_MODULES
+ XORG_DRIVER_CHECK_EXT(RANDR, randrproto)
+ XORG_DRIVER_CHECK_EXT(RENDER, renderproto)
+ XORG_DRIVER_CHECK_EXT(XV, videoproto)
+ XORG_DRIVER_CHECK_EXT(DPMSExtension, xextproto)
+ XORG_DRIVER_CHECK_EXT(XFreeXDGA, xf86dgaproto)
+
+-# Checks for pkg-config packages
++# Obtain compiler/linker options for the driver dependencies
+ PKG_CHECK_MODULES(XORG, [xorg-server >= 1.0.99.901 xproto fontsproto $REQUIRED_MODULES])
+ PKG_CHECK_MODULES(XEXT, [xextproto >= 7.0.99.1],
+ HAVE_XEXTPROTO_71="yes"; AC_DEFINE(HAVE_XEXTPROTO_71, 1, [xextproto 7.1 available]),
+@@ -90,17 +90,14 @@ AM_CONDITIONAL(XSERVER_LIBPCIACCESS, test "x$XSERVER_LIBPCIACCESS" = xyes)
+
+ # Checks for libraries.
+
+-# Checks for header files.
+-AC_HEADER_STDC
+-
+-AC_SUBST([XORG_CFLAGS])
+ AC_SUBST([moduledir])
+
+ DRIVER_NAME=trident
+ AC_SUBST([DRIVER_NAME])
+
+-AC_OUTPUT([
+- Makefile
+- src/Makefile
+- man/Makefile
++AC_CONFIG_FILES([
++ Makefile
++ src/Makefile
++ man/Makefile
+ ])
++AC_OUTPUT
+diff --git a/man/Makefile.am b/man/Makefile.am
+index 8f2454b..b3688ce 100644
+--- a/man/Makefile.am
++++ b/man/Makefile.am
+@@ -31,25 +31,11 @@ EXTRA_DIST = @DRIVER_NAME@.man
+
+ CLEANFILES = $(driverman_DATA)
+
+-SED = sed
+-
+-# Strings to replace in man pages
+-XORGRELSTRING = @PACKAGE_STRING@
+- XORGMANNAME = X Version 11
+-
+-MAN_SUBSTS = \
+- -e 's|__vendorversion__|"$(XORGRELSTRING)" "$(XORGMANNAME)"|' \
+- -e 's|__xorgversion__|"$(XORGRELSTRING)" "$(XORGMANNAME)"|' \
+- -e 's|__xservername__|Xorg|g' \
+- -e 's|__xconfigfile__|xorg.conf|g' \
+- -e 's|__projectroot__|$(prefix)|g' \
+- -e 's|__appmansuffix__|$(APP_MAN_SUFFIX)|g' \
+- -e 's|__drivermansuffix__|$(DRIVER_MAN_SUFFIX)|g' \
+- -e 's|__adminmansuffix__|$(ADMIN_MAN_SUFFIX)|g' \
+- -e 's|__miscmansuffix__|$(MISC_MAN_SUFFIX)|g' \
+- -e 's|__filemansuffix__|$(FILE_MAN_SUFFIX)|g'
++
++# String replacements in MAN_SUBSTS now come from xorg-macros.m4 via configure
++
+
+ SUFFIXES = .$(DRIVER_MAN_SUFFIX) .man
+
+ .man.$(DRIVER_MAN_SUFFIX):
+- sed $(MAN_SUBSTS) < $< > $@
++ $(AM_V_GEN)$(SED) $(MAN_SUBSTS) < $< > $@
+diff --git a/man/trident.man b/man/trident.man
+index 8d04ed0..f461e10 100644
+--- a/man/trident.man
++++ b/man/trident.man
+@@ -1,4 +1,3 @@
+-.\" $XFree86: xc/programs/Xserver/hw/xfree86/drivers/trident/trident.man,v 1.14 2003/05/29 21:48:09 herrb Exp $
+ .\" shorthand for double quote that works everywhere.
+ .ds q \N'34'
+ .TH TRIDENT __drivermansuffix__ __vendorversion__
+diff --git a/src/blade_accel_exa.c b/src/blade_accel_exa.c
+index 80e3f23..3129623 100644
+--- a/src/blade_accel_exa.c
++++ b/src/blade_accel_exa.c
+@@ -251,14 +251,6 @@ static void WaitMarker(ScreenPtr pScreen, int marker)
+ }
+ }
+
+-static Bool PrepareAccess(PixmapPtr pPix, int index)
+-{
+-}
+-
+-static void FinishAccess(PixmapPtr pPix, int index)
+-{
+-}
+-
+ static void BladeInitializeAccelerator(ScrnInfoPtr pScrn)
+ {
+ TRIDENTPtr pTrident = TRIDENTPTR(pScrn);
+diff --git a/src/trident.h b/src/trident.h
+index c15d39c..a28c9fc 100644
+--- a/src/trident.h
++++ b/src/trident.h
+@@ -70,7 +70,7 @@ typedef struct {
+ typedef struct {
+ ScrnInfoPtr pScrn;
+ pciVideoPtr PciInfo;
+- PCITAG PciTag;
++ uint32_t PciTag;
+ EntityInfoPtr pEnt;
+ ExaDriverPtr EXADriverPtr;
+ int useEXA;
+@@ -85,7 +85,7 @@ typedef struct {
+ unsigned char * IOBase;
+ unsigned char * FbBase;
+ long FbMapSize;
+- IOADDRESS PIOBase;
++ unsigned long PIOBase;
+ Bool NoAccel;
+ Bool HWCursor;
+ Bool UsePCIRetry;
+diff --git a/src/trident_dga.c b/src/trident_dga.c
+index 78fa8f4..dd836a6 100644
+--- a/src/trident_dga.c
++++ b/src/trident_dga.c
+@@ -83,15 +83,15 @@ TRIDENTDGAInit(ScreenPtr pScreen)
+ while(pMode) {
+
+ if(0 /*pScrn->displayWidth != pMode->HDisplay*/) {
+- newmodes = xrealloc(modes, (num + 2) * sizeof(DGAModeRec));
++ newmodes = realloc(modes, (num + 2) * sizeof(DGAModeRec));
+ oneMore = TRUE;
+ } else {
+- newmodes = xrealloc(modes, (num + 1) * sizeof(DGAModeRec));
++ newmodes = realloc(modes, (num + 1) * sizeof(DGAModeRec));
+ oneMore = FALSE;
+ }
+
+ if(!newmodes) {
+- xfree(modes);
++ free(modes);
+ return FALSE;
+ }
+ modes = newmodes;
+diff --git a/src/trident_driver.c b/src/trident_driver.c
+index 31cbb83..472c9b7 100644
+--- a/src/trident_driver.c
++++ b/src/trident_driver.c
+@@ -63,7 +63,7 @@
+
+ #ifdef XFreeXDGA
+ #define _XF86DGA_SERVER_
+-#include <X11/extensions/xf86dgastr.h>
++#include <X11/extensions/xf86dgaproto.h>
+ #endif
+
+ #include "globals.h"
+@@ -560,7 +560,7 @@ TRIDENTFreeRec(ScrnInfoPtr pScrn)
+ {
+ if (pScrn->driverPrivate == NULL)
+ return;
+- xfree(pScrn->driverPrivate);
++ free(pScrn->driverPrivate);
+ pScrn->driverPrivate = NULL;
+ }
+
+@@ -900,7 +900,7 @@ TRIDENTProbe(DriverPtr drv, int flags)
+ foundScreen = TRUE;
+ }
+ }
+- xfree(usedChips);
++ free(usedChips);
+ }
+ }
+
+@@ -933,11 +933,11 @@ TRIDENTProbe(DriverPtr drv, int flags)
+ foundScreen = TRUE;
+ }
+ }
+- xfree(usedChips);
++ free(usedChips);
+ }
+ #endif
+
+- xfree(devSections);
++ free(devSections);
+ return foundScreen;
+ }
+
+@@ -1109,7 +1109,12 @@ TRIDENTPreInit(ScrnInfoPtr pScrn, int flags)
+ hwp = VGAHWPTR(pScrn);
+ vgaHWGetIOBase(hwp);
+ vgaIOBase = hwp->IOBase;
++
++#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 12
+ pTrident->PIOBase = hwp->PIOOffset;
++#else
++ pTrident->PIOBase = 0;
++#endif
+
+ #ifndef XSERVER_LIBPCIACCESS
+ xf86SetOperatingState(resVga, pTrident->pEnt->index, ResUnusedOpr);
+@@ -1163,7 +1168,7 @@ TRIDENTPreInit(ScrnInfoPtr pScrn, int flags)
+ xf86CollectOptions(pScrn, NULL);
+
+ /* Process the options */
+- if (!(pTrident->Options = xalloc(sizeof(TRIDENTOptions))))
++ if (!(pTrident->Options = malloc(sizeof(TRIDENTOptions))))
+ return FALSE;
+ memcpy(pTrident->Options, TRIDENTOptions, sizeof(TRIDENTOptions));
+ xf86ProcessOptions(pScrn->scrnIndex, pScrn->options, pTrident->Options);
+@@ -2617,7 +2622,10 @@ TRIDENTModeInit(ScrnInfoPtr pScrn, DisplayModePtr mode)
+ TRIDENTPtr pTrident = TRIDENTPTR(pScrn);
+ TRIDENTRegPtr tridentReg;
+
+- if (!xf86IsPc98()) WAITFORVSYNC;
++#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 12
++ if (!xf86IsPc98())
++#endif
++ WAITFORVSYNC;
+
+ TridentFindClock(pScrn,mode->Clock);
+
+@@ -2709,8 +2717,10 @@ TRIDENTModeInit(ScrnInfoPtr pScrn, DisplayModePtr mode)
+
+ vgaHWProtect(pScrn, FALSE);
+
++#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 12
+ if (xf86IsPc98())
+ PC98TRIDENTEnable(pScrn);
++#endif
+
+ if (pTrident->TVChipset != 0)
+ VIA_TVInit(pScrn);
+@@ -2782,7 +2792,10 @@ TRIDENTScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
+ if (!TRIDENTMapMem(pScrn))
+ return FALSE;
+
+- if (!xf86IsPc98()) {
++#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 12
++ if (!xf86IsPc98())
++#endif
++ {
+ #ifdef VBE_INFO
+ if (pTrident->vbeModes) {
+ pTrident->pVbe = VBEInit(NULL,pTrident->pEnt->index);
+@@ -2796,7 +2809,7 @@ TRIDENTScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
+ }
+ }
+ }
+-
++
+ hwp = VGAHWPTR(pScrn);
+
+ if (IsPciCard && UseMMIO) {
+@@ -2813,9 +2826,12 @@ TRIDENTScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
+ * Some Trident chip on PC-9821 needs setup,
+ * because VGA chip is not initialized by VGA BIOS.
+ */
++#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 12
+ if (IsPciCard && xf86IsPc98()) {
+ PC98TRIDENTInit(pScrn);
+- } else tridentSetModeBIOS(pScrn,pScrn->currentMode);
++ } else
++#endif
++ tridentSetModeBIOS(pScrn,pScrn->currentMode);
+
+ /* Initialise the first mode */
+ if (!TRIDENTModeInit(pScrn, pScrn->currentMode))
+@@ -2868,7 +2884,7 @@ TRIDENTScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
+
+ if(pTrident->ShadowFB) {
+ pTrident->ShadowPitch = BitmapBytePad(pScrn->bitsPerPixel * width);
+- pTrident->ShadowPtr = xalloc(pTrident->ShadowPitch * height);
++ pTrident->ShadowPtr = malloc(pTrident->ShadowPitch * height);
+ displayWidth = pTrident->ShadowPitch / (pScrn->bitsPerPixel >> 3);
+ FBStart = pTrident->ShadowPtr;
+ } else {
+@@ -2958,7 +2974,7 @@ TRIDENTScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
+ (miBankProcPtr)TVGA8900SetReadWrite;
+ if (!miInitializeBanking(pScreen, pScrn->virtualX, pScrn->virtualY,
+ pScrn->displayWidth, pBankInfo)) {
+- xfree(pBankInfo);
++ free(pBankInfo);
+ pBankInfo = NULL;
+ if (pTrident->pVbe)
+ vbeFree(pTrident->pVbe);
+@@ -3200,8 +3216,10 @@ TRIDENTLeaveVT(int scrnIndex, int flags)
+ TRIDENTRestore(pScrn);
+ vgaHWLock(hwp);
+
++#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 12
+ if (xf86IsPc98())
+ PC98TRIDENTDisable(pScrn);
++#endif
+
+ if (IsPciCard && UseMMIO) TRIDENTDisableMMIO(pScrn);
+ }
+@@ -3225,28 +3243,31 @@ TRIDENTCloseScreen(int scrnIndex, ScreenPtr pScreen)
+ pTrident->AccelInfoRec->Sync(pScrn);
+ else if (!pTrident->NoAccel && pTrident->useEXA)
+ pTrident->EXADriverPtr->WaitMarker(pScreen, 0);
+-
++
++#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 12
+ if (xf86IsPc98())
+ PC98TRIDENTDisable(pScrn);
++#endif
+
+ TRIDENTRestore(pScrn);
+ vgaHWLock(hwp);
+ if (IsPciCard && UseMMIO) TRIDENTDisableMMIO(pScrn);
+ TRIDENTUnmapMem(pScrn);
+ }
++
+ if (pTrident->AccelInfoRec)
+ XAADestroyInfoRec(pTrident->AccelInfoRec);
+ if (pTrident->EXADriverPtr) {
+ exaDriverFini(pScreen);
+- xfree(pTrident->EXADriverPtr);
++ free(pTrident->EXADriverPtr);
+ pTrident->EXADriverPtr = NULL;
+ }
+ if (pTrident->CursorInfoRec)
+ xf86DestroyCursorInfoRec(pTrident->CursorInfoRec);
+ if (pTrident->ShadowPtr)
+- xfree(pTrident->ShadowPtr);
++ free(pTrident->ShadowPtr);
+ if (pTrident->DGAModes)
+- xfree(pTrident->DGAModes);
++ free(pTrident->DGAModes);
+ pScrn->vtSema = FALSE;
+
+ if(pTrident->BlockHandler)
+@@ -3317,15 +3338,17 @@ static void
+ TRIDENTEnableMMIO(ScrnInfoPtr pScrn)
+ {
+ TRIDENTPtr pTrident = TRIDENTPTR(pScrn);
+- IOADDRESS vgaIOBase = pTrident->PIOBase + VGAHWPTR(pScrn)->IOBase;
++ unsigned long vgaIOBase = pTrident->PIOBase + VGAHWPTR(pScrn)->IOBase;
+ CARD8 temp = 0, protect = 0;
+
+ /*
+ * Skip MMIO Enable in PC-9821 PCI Trident Card!!
+ * Because of lack of non PCI VGA port
+ */
++#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 12
+ if (IsPciCard && xf86IsPc98())
+ return;
++#endif
+
+ /* Goto New Mode */
+ outb(pTrident->PIOBase + 0x3C4, 0x0B);
+@@ -3366,8 +3389,10 @@ TRIDENTDisableMMIO(ScrnInfoPtr pScrn)
+ * Skip MMIO Disable in PC-9821 PCI Trident Card!!
+ * Because of lack of non PCI VGA port
+ */
++#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 12
+ if (IsPciCard && xf86IsPc98())
+ return;
++#endif
+
+ /* Goto New Mode */
+ OUTB(0x3C4, 0x0B); temp = INB(0x3C5);
+@@ -3395,6 +3420,7 @@ TRIDENTDisableMMIO(ScrnInfoPtr pScrn)
+ outb(pTrident->PIOBase + 0x3C5, temp);
+ }
+
++#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 12
+ /* Initialize VGA Block for Trident Chip on PC-98x1 */
+ static void
+ PC98TRIDENTInit(ScrnInfoPtr pScrn)
+@@ -3637,7 +3663,7 @@ PC98TRIDENT96xxDisable(ScrnInfoPtr pScrn)
+ outb(0x6A, 0x06);
+ outb(0x68, 0x0F);
+ }
+-
++#endif
+
+ /*
+ * This is a terrible hack! If we are on a notebook in a stretched
+diff --git a/src/trident_video.c b/src/trident_video.c
+index 0c5497b..0ae1d14 100644
+--- a/src/trident_video.c
++++ b/src/trident_video.c
+@@ -125,7 +125,7 @@ void TRIDENTInitVideo(ScreenPtr pScreen)
+ adaptors = &newAdaptor;
+ } else {
+ newAdaptors = /* need to free this someplace */
+- xalloc((num_adaptors + 1) * sizeof(XF86VideoAdaptorPtr*));
++ malloc((num_adaptors + 1) * sizeof(XF86VideoAdaptorPtr*));
+ if(newAdaptors) {
+ memcpy(newAdaptors, adaptors, num_adaptors *
+ sizeof(XF86VideoAdaptorPtr));
+@@ -140,7 +140,7 @@ void TRIDENTInitVideo(ScreenPtr pScreen)
+ xf86XVScreenInit(pScreen, adaptors, num_adaptors);
+
+ if(newAdaptors)
+- xfree(newAdaptors);
++ free(newAdaptors);
+
+ if (pTrident->videoFlags)
+ xf86DrvMsgVerb(pScrn->scrnIndex,X_INFO,3,
+@@ -321,7 +321,7 @@ TRIDENTSetupImageVideo(ScreenPtr pScreen)
+ XF86VideoAdaptorPtr adapt;
+ TRIDENTPortPrivPtr pPriv;
+
+- if(!(adapt = xcalloc(1, sizeof(XF86VideoAdaptorRec) +
++ if(!(adapt = calloc(1, sizeof(XF86VideoAdaptorRec) +
+ sizeof(TRIDENTPortPrivRec) +
+ sizeof(DevUnion))))
+ return NULL;
+@@ -978,18 +978,18 @@ TRIDENTAllocateSurface(
+ surface->width = w;
+ surface->height = h;
+
+- if(!(surface->pitches = xalloc(sizeof(int)))) {
++ if(!(surface->pitches = malloc(sizeof(int)))) {
+ xf86FreeOffscreenLinear(linear);
+ return BadAlloc;
+ }
+- if(!(surface->offsets = xalloc(sizeof(int)))) {
+- xfree(surface->pitches);
++ if(!(surface->offsets = malloc(sizeof(int)))) {
++ free(surface->pitches);
+ xf86FreeOffscreenLinear(linear);
+ return BadAlloc;
+ }
+- if(!(pPriv = xalloc(sizeof(OffscreenPrivRec)))) {
+- xfree(surface->pitches);
+- xfree(surface->offsets);
++ if(!(pPriv = malloc(sizeof(OffscreenPrivRec)))) {
++ free(surface->pitches);
++ free(surface->offsets);
+ xf86FreeOffscreenLinear(linear);
+ return BadAlloc;
+ }
+@@ -1034,9 +1034,9 @@ TRIDENTFreeSurface(
+ if(pPriv->isOn)
+ TRIDENTStopSurface(surface);
+ xf86FreeOffscreenLinear(pPriv->linear);
+- xfree(surface->pitches);
+- xfree(surface->offsets);
+- xfree(surface->devPrivate.ptr);
++ free(surface->pitches);
++ free(surface->offsets);
++ free(surface->devPrivate.ptr);
+
+ return Success;
+ }
+@@ -1128,7 +1128,7 @@ TRIDENTInitOffscreenImages(ScreenPtr pScreen)
+ XF86OffscreenImagePtr offscreenImages;
+
+ /* need to free this someplace */
+- if(!(offscreenImages = xalloc(sizeof(XF86OffscreenImageRec))))
++ if(!(offscreenImages = malloc(sizeof(XF86OffscreenImageRec))))
+ return;
+
+ offscreenImages[0].image = &Images[0];
+@@ -1342,7 +1342,10 @@ WaitForVBlank(ScrnInfoPtr pScrn)
+ * full vblank has passed.
+ * - Alan.
+ */
+- if (!xf86IsPc98()) {
++#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 12
++ if (!xf86IsPc98())
++#endif
++ {
+ WAITFORVSYNC;
+ WAITFORVSYNC;
+ }
diff --git a/extra/xf86-video-tseng/PKGBUILD b/extra/xf86-video-tseng/PKGBUILD
index ce88b5e0b..cab1cfcda 100644
--- a/extra/xf86-video-tseng/PKGBUILD
+++ b/extra/xf86-video-tseng/PKGBUILD
@@ -1,28 +1,32 @@
-# $Id: PKGBUILD 140294 2011-10-11 21:28:31Z jgc $
+# $Id: PKGBUILD 153376 2012-03-12 20:54:48Z andyrtr $
# Maintainer: Jan de Groot <jgc@archlinux.org>
pkgname=xf86-video-tseng
pkgver=1.2.4
-pkgrel=5
+pkgrel=6
pkgdesc="X.org tseng video driver"
arch=(i686 x86_64)
url="http://xorg.freedesktop.org/"
license=('custom')
depends=('glibc')
-makedepends=('xorg-server-devel>=1.10.99.902')
-conflicts=('xorg-server<1.10.99.902')
+makedepends=('xorg-server-devel>=1.11.99.903')
+conflicts=('xorg-server<1.11.99.903')
groups=('xorg-drivers' 'xorg')
options=('!libtool')
source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2
- fix-regression-from-pciaccess-conversion.patch)
+ tseng-1.2.4-git.patch)
sha1sums=('1b45f55657b2c92f30abb0769cae57fca98d93b7'
- 'df7660ec18cce3e9f04a7c70f72c75daa947e4a9')
+ 'd84bb75d62888096da7477b38e8b13f9c23d4e3a')
build() {
cd "${srcdir}/${pkgname}-${pkgver}"
- patch -Np1 -i "${srcdir}/fix-regression-from-pciaccess-conversion.patch"
+ patch -Np1 -i ${srcdir}/tseng-1.2.4-git.patch
./configure --prefix=/usr
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/extra/xf86-video-tseng/tseng-1.2.4-git.patch b/extra/xf86-video-tseng/tseng-1.2.4-git.patch
new file mode 100644
index 000000000..082b2cb0b
--- /dev/null
+++ b/extra/xf86-video-tseng/tseng-1.2.4-git.patch
@@ -0,0 +1,317 @@
+diff --git a/configure.ac b/configure.ac
+index 62cc318..8458c06 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -20,46 +20,46 @@
+ #
+ # Process this file with autoconf to produce a configure script
+
+-AC_PREREQ(2.57)
++# Initialize Autoconf
++AC_PREREQ([2.60])
+ AC_INIT([xf86-video-tseng],
+- 1.2.4,
++ [1.2.4],
+ [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg],
+- xf86-video-tseng)
+-
++ [xf86-video-tseng])
+ AC_CONFIG_SRCDIR([Makefile.am])
+-AM_CONFIG_HEADER([config.h])
++AC_CONFIG_HEADERS([config.h])
+ AC_CONFIG_AUX_DIR(.)
+
++# Initialize Automake
+ AM_INIT_AUTOMAKE([foreign dist-bzip2])
+-
+ AM_MAINTAINER_MODE
+
+-# Require xorg-macros: XORG_DEFAULT_OPTIONS
++# Require X.Org macros 1.8 or later for MAN_SUBSTS set by XORG_MANPAGE_SECTIONS
+ m4_ifndef([XORG_MACROS_VERSION],
+- [m4_fatal([must install xorg-macros 1.3 or later before running autoconf/autogen])])
+-XORG_MACROS_VERSION(1.3)
++ [m4_fatal([must install xorg-macros 1.8 or later before running autoconf/autogen])])
++XORG_MACROS_VERSION(1.8)
+ XORG_DEFAULT_OPTIONS
+
+-# Checks for programs.
++# Initialize libtool
+ AC_DISABLE_STATIC
+ AC_PROG_LIBTOOL
+-AC_PROG_CC
+
+ AH_TOP([#include "xorg-server.h"])
+
++# Define a configure option for an alternate module directory
+ AC_ARG_WITH(xorg-module-dir,
+- AC_HELP_STRING([--with-xorg-module-dir=DIR],
++ AS_HELP_STRING([--with-xorg-module-dir=DIR],
+ [Default xorg module directory [[default=$libdir/xorg/modules]]]),
+ [moduledir="$withval"],
+ [moduledir="$libdir/xorg/modules"])
+
+-# Checks for extensions
++# Store the list of server defined optional extensions in REQUIRED_MODULES
+ XORG_DRIVER_CHECK_EXT(RANDR, randrproto)
+ XORG_DRIVER_CHECK_EXT(RENDER, renderproto)
+ XORG_DRIVER_CHECK_EXT(XV, videoproto)
+ XORG_DRIVER_CHECK_EXT(DPMSExtension, xextproto)
+
+-# Checks for pkg-config packages
++# Obtain compiler/linker options for the driver dependencies
+ PKG_CHECK_MODULES(XORG, [xorg-server >= 1.0.99.901 xproto fontsproto $REQUIRED_MODULES])
+
+ # Checks for libraries.
+@@ -78,17 +78,14 @@ if test "x$XSERVER_LIBPCIACCESS" = xyes; then
+ fi
+ AM_CONDITIONAL(XSERVER_LIBPCIACCESS, test "x$XSERVER_LIBPCIACCESS" = xyes)
+
+-# Checks for header files.
+-AC_HEADER_STDC
+-
+-AC_SUBST([XORG_CFLAGS])
+ AC_SUBST([moduledir])
+
+ DRIVER_NAME=tseng
+ AC_SUBST([DRIVER_NAME])
+
+-AC_OUTPUT([
+- Makefile
+- src/Makefile
+- man/Makefile
++AC_CONFIG_FILES([
++ Makefile
++ src/Makefile
++ man/Makefile
+ ])
++AC_OUTPUT
+diff --git a/man/Makefile.am b/man/Makefile.am
+index 8f2454b..b3688ce 100644
+--- a/man/Makefile.am
++++ b/man/Makefile.am
+@@ -31,25 +31,11 @@ EXTRA_DIST = @DRIVER_NAME@.man
+
+ CLEANFILES = $(driverman_DATA)
+
+-SED = sed
+-
+-# Strings to replace in man pages
+-XORGRELSTRING = @PACKAGE_STRING@
+- XORGMANNAME = X Version 11
+-
+-MAN_SUBSTS = \
+- -e 's|__vendorversion__|"$(XORGRELSTRING)" "$(XORGMANNAME)"|' \
+- -e 's|__xorgversion__|"$(XORGRELSTRING)" "$(XORGMANNAME)"|' \
+- -e 's|__xservername__|Xorg|g' \
+- -e 's|__xconfigfile__|xorg.conf|g' \
+- -e 's|__projectroot__|$(prefix)|g' \
+- -e 's|__appmansuffix__|$(APP_MAN_SUFFIX)|g' \
+- -e 's|__drivermansuffix__|$(DRIVER_MAN_SUFFIX)|g' \
+- -e 's|__adminmansuffix__|$(ADMIN_MAN_SUFFIX)|g' \
+- -e 's|__miscmansuffix__|$(MISC_MAN_SUFFIX)|g' \
+- -e 's|__filemansuffix__|$(FILE_MAN_SUFFIX)|g'
++
++# String replacements in MAN_SUBSTS now come from xorg-macros.m4 via configure
++
+
+ SUFFIXES = .$(DRIVER_MAN_SUFFIX) .man
+
+ .man.$(DRIVER_MAN_SUFFIX):
+- sed $(MAN_SUBSTS) < $< > $@
++ $(AM_V_GEN)$(SED) $(MAN_SUBSTS) < $< > $@
+diff --git a/man/tseng.man b/man/tseng.man
+index 403782f..984c8e7 100644
+--- a/man/tseng.man
++++ b/man/tseng.man
+@@ -1,4 +1,3 @@
+-.\" $XFree86: xc/programs/Xserver/hw/xfree86/drivers/tseng/tseng.man,v 1.2 2001/01/27 18:20:55 dawes Exp $
+ .\" shorthand for double quote that works everywhere.
+ .ds q \N'34'
+ .TH TSENG __drivermansuffix__ __vendorversion__
+diff --git a/src/tseng_cursor.c b/src/tseng_cursor.c
+index d4fb847..2412b31 100644
+--- a/src/tseng_cursor.c
++++ b/src/tseng_cursor.c
+@@ -159,7 +159,7 @@ TsengSetCursorColors(ScrnInfoPtr pScrn, int bg, int fg)
+ }
+ }
+
+-void
++static void
+ TsengLoadCursorImage(ScrnInfoPtr pScrn, unsigned char *bits)
+ {
+ vgaHWPtr hwp = VGAHWPTR(pScrn);
+diff --git a/src/tseng_dga.c b/src/tseng_dga.c
+index 70ebe23..528ba4c 100644
+--- a/src/tseng_dga.c
++++ b/src/tseng_dga.c
+@@ -74,9 +74,9 @@ TsengDGAInit(ScreenPtr pScreen)
+ if (!pTseng->DGAnumModes) {
+ pMode = firstMode = pScrn->modes;
+ while (pMode) {
+- newmodes = xrealloc(modes, (num + 1) * sizeof (DGAModeRec));
++ newmodes = realloc(modes, (num + 1) * sizeof (DGAModeRec));
+ if (!newmodes) {
+- xfree(modes);
++ free(modes);
+ return FALSE;
+ }
+ modes = newmodes;
+@@ -135,7 +135,7 @@ Tseng_OpenFramebuffer(
+ TsengPtr pTseng = TsengPTR(pScrn);
+
+ *name = NULL; /* no special device */
+- *mem = (unsigned char*)pTseng->FbAddress;
++ *mem = (unsigned char*)(uintptr_t)pTseng->FbAddress;
+ *size = pTseng->FbMapSize;
+ *offset = 0; /* Always */
+ *flags = 0; /* Root permissions OS-dependent */
+diff --git a/src/tseng_driver.c b/src/tseng_driver.c
+index 445c17e..d36b62c 100644
+--- a/src/tseng_driver.c
++++ b/src/tseng_driver.c
+@@ -269,9 +269,9 @@ TsengFreeRec(ScrnInfoPtr pScrn)
+ pTseng = TsengPTR(pScrn);
+
+ if (pTseng->SavedReg.RAMDAC)
+- xfree(pTseng->SavedReg.RAMDAC);
++ free(pTseng->SavedReg.RAMDAC);
+
+- xfree(pScrn->driverPrivate);
++ free(pScrn->driverPrivate);
+ pScrn->driverPrivate = NULL;
+ }
+
+@@ -395,10 +395,10 @@ TsengProbe(DriverPtr drv, int flags)
+ foundScreen = TRUE;
+ }
+ }
+- xfree(usedChips);
++ free(usedChips);
+ }
+
+- xfree(devSections);
++ free(devSections);
+ return foundScreen;
+ }
+
+@@ -806,7 +806,7 @@ TsengProcessOptions(ScrnInfoPtr pScrn)
+ xf86CollectOptions(pScrn, NULL);
+
+ /* Process the options */
+- if (!(pTseng->Options = xalloc(sizeof(TsengOptions))))
++ if (!(pTseng->Options = malloc(sizeof(TsengOptions))))
+ return FALSE;
+ memcpy(pTseng->Options, TsengOptions, sizeof(TsengOptions));
+ xf86ProcessOptions(pScrn->scrnIndex, pScrn->options, pTseng->Options);
+@@ -883,7 +883,7 @@ TsengGetFbAddress(ScrnInfoPtr pScrn)
+ PDEBUG(" TsengGetFbAddress\n");
+
+ /* base0 is the framebuffer and base1 is the PCI IO space. */
+- if (PCI_REGION_BASE(pTseng->PciInfo, 0, REGION_MEM)) {
++ if (!PCI_REGION_BASE(pTseng->PciInfo, 0, REGION_MEM)) {
+ xf86DrvMsg(pScrn->scrnIndex, X_ERROR,
+ "No valid Framebuffer address in PCI config space;\n");
+ return FALSE;
+diff --git a/src/tseng_mode.c b/src/tseng_mode.c
+index f075226..a3ff87d 100644
+--- a/src/tseng_mode.c
++++ b/src/tseng_mode.c
+@@ -41,7 +41,11 @@ vgaHWWriteBank(vgaHWPtr hwp, CARD8 value)
+ if (hwp->MMIOBase)
+ MMIO_OUT8(hwp->MMIOBase, hwp->MMIOOffset + VGA_BANK, value);
+ else
++#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 12
+ outb(hwp->PIOOffset + VGA_BANK, value);
++#else
++ pci_io_write8(hwp->io, VGA_BANK, value);
++#endif
+ }
+
+ CARD8
+@@ -50,7 +54,11 @@ vgaHWReadBank(vgaHWPtr hwp)
+ if (hwp->MMIOBase)
+ return MMIO_IN8(hwp->MMIOBase, hwp->MMIOOffset + VGA_BANK);
+ else
++#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 12
+ return inb(hwp->PIOOffset + VGA_BANK);
++#else
++ return pci_io_read8(hwp->io, VGA_BANK);
++#endif
+ }
+
+ #define VGA_SEGMENT 0x3CD
+@@ -61,7 +69,11 @@ vgaHWWriteSegment(vgaHWPtr hwp, CARD8 value)
+ if (hwp->MMIOBase)
+ MMIO_OUT8(hwp->MMIOBase, hwp->MMIOOffset + VGA_SEGMENT, value);
+ else
++#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 12
+ outb(hwp->PIOOffset + VGA_SEGMENT, value);
++#else
++ pci_io_write8(hwp->io, VGA_SEGMENT, value);
++#endif
+ }
+
+ CARD8
+@@ -70,7 +82,11 @@ vgaHWReadSegment(vgaHWPtr hwp)
+ if (hwp->MMIOBase)
+ return MMIO_IN8(hwp->MMIOBase, hwp->MMIOOffset + VGA_SEGMENT);
+ else
++#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 12
+ return inb(hwp->PIOOffset + VGA_SEGMENT);
++#else
++ return pci_io_read8(hwp->io, VGA_SEGMENT);
++#endif
+ }
+
+ /*
+@@ -84,8 +100,12 @@ vgaHWWriteModeControl(vgaHWPtr hwp, CARD8 value)
+ if (hwp->MMIOBase)
+ MMIO_OUT8(hwp->MMIOBase,
+ hwp->MMIOOffset + hwp->IOBase + VGA_MODE_CONTROL, value);
+- else
+- outb(hwp->IOBase + hwp->PIOOffset + VGA_MODE_CONTROL, value);
++ else
++#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 12
++ outb(hwp->PIOOffset + VGA_MODE_CONTROL, value);
++#else
++ pci_io_write8(hwp->io, VGA_MODE_CONTROL, value);
++#endif
+ }
+
+ /*
+@@ -110,14 +130,22 @@ vgaHWHerculesSecondPage(vgaHWPtr hwp, Bool Enable)
+
+ MMIO_OUT8(hwp->MMIOBase, hwp->MMIOOffset + VGA_HERCULES, tmp);
+ } else {
+- tmp = inb(hwp->PIOOffset + VGA_HERCULES);
++#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 12
++ tmp = inb(hwp->PIOOffset + VGA_HERCULES);
++#else
++ tmp = pci_io_read8(hwp->io, VGA_HERCULES);
++#endif
+
+ if (Enable)
+ tmp |= 0x02;
+ else
+ tmp &= ~0x02;
+
+- outb(hwp->PIOOffset + VGA_HERCULES, tmp);
++#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 12
++ outb(hwp->PIOOffset + VGA_HERCULES, tmp);
++#else
++ pci_io_write8(hwp->io, VGA_HERCULES, tmp);
++#endif
+ }
+ }
+
+@@ -1502,7 +1530,7 @@ TsengModeInit(ScrnInfoPtr pScrn, DisplayModePtr OrigMode)
+
+ /* clean up */
+ if (new->RAMDAC)
+- xfree(new->RAMDAC);
++ free(new->RAMDAC);
+
+ return TRUE;
+ }
diff --git a/extra/xf86-video-unichrome/PKGBUILD b/extra/xf86-video-unichrome/PKGBUILD
index ca012bc28..1647f8cf1 100644
--- a/extra/xf86-video-unichrome/PKGBUILD
+++ b/extra/xf86-video-unichrome/PKGBUILD
@@ -1,25 +1,29 @@
-# $Id: PKGBUILD 140292 2011-10-11 21:28:27Z jgc $
+# $Id: PKGBUILD 153378 2012-03-12 20:54:55Z andyrtr $
# Maintainer: Jan de Groot <jgc@archlinux.org>
pkgname=xf86-video-unichrome
pkgver=0.2.7
-pkgrel=6
+pkgrel=7
_gitversion=b917bee87db8a65b8e8da0ca12c24a176c9e9fb2
pkgdesc="Unichrome video drivers for X.Org"
arch=(i686 x86_64)
url="http://unichrome.sf.net/"
license=('custom')
-depends=('glibc' 'unichrome-dri')
-makedepends=('xorg-server-devel>=1.10.99.902' 'libx11' 'libdrm' 'xf86driproto' 'mesa' 'libxvmc' 'glproto')
+depends=('glibc')
+makedepends=('xorg-server-devel>=1.11.99.903' 'libx11' 'libdrm' 'xf86driproto' 'mesa' 'libxvmc') # 'glproto')
options=('!libtool')
-conflicts=('xf86-video-via' 'openchrome' 'xf86-video-openchrome' 'xorg-server<1.10.99.902')
+conflicts=('xf86-video-via' 'openchrome' 'xf86-video-openchrome' 'xorg-server<1.11.99.903')
source=(http://cgit.freedesktop.org/~libv/${pkgname}/snapshot/${pkgname}-${_gitversion}.tar.bz2)
md5sums=('f7adef052de08a01af86e245d1932239')
build() {
cd "${srcdir}/${pkgname}-${_gitversion}"
- ./autogen.sh --prefix=/usr --enable-dri
+ ./autogen.sh --prefix=/usr #--enable-dri
make
+}
+
+package() {
+ cd "${srcdir}/${pkgname}-${_gitversion}"
make DESTDIR="${pkgdir}" install
install -m755 -d "${pkgdir}/usr/share/licenses/${pkgname}"
install -m644 debian/copyright "${pkgdir}/usr/share/licenses/${pkgname}/COPYING"
diff --git a/extra/xf86-video-v4l/PKGBUILD b/extra/xf86-video-v4l/PKGBUILD
index bc3f36b95..16a11493d 100644
--- a/extra/xf86-video-v4l/PKGBUILD
+++ b/extra/xf86-video-v4l/PKGBUILD
@@ -1,16 +1,16 @@
-# $Id: PKGBUILD 140290 2011-10-11 21:28:21Z jgc $
+# $Id: PKGBUILD 153380 2012-03-12 20:55:02Z andyrtr $
#Maintainer: Jan de Groot <jgc@archlinux.org>
pkgname=xf86-video-v4l
pkgver=0.2.0
-pkgrel=9
+pkgrel=10
pkgdesc="X.org v4l video driver"
arch=(i686 x86_64)
url="http://xorg.freedesktop.org/"
license=('custom')
depends=('glibc')
-makedepends=('xorg-server-devel')
-conflicts=('xorg-server<1.10.0')
+makedepends=('xorg-server-devel>=1.11.99.903')
+conflicts=('xorg-server<1.11.99.903')
groups=('xorg-drivers' 'xorg')
options=('!libtool')
source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2
@@ -26,6 +26,10 @@ build() {
autoreconf -fi
./configure --prefix=/usr
make
+}
+
+package() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
make DESTDIR="${pkgdir}" install
install -m755 -d "${pkgdir}/usr/share/licenses/${pkgname}"
install -m644 "${srcdir}/LICENSE" "${pkgdir}/usr/share/licenses/${pkgname}/"
diff --git a/extra/xf86-video-v4l/git-fixes.patch b/extra/xf86-video-v4l/git-fixes.patch
new file mode 100644
index 000000000..2f752fc8c
--- /dev/null
+++ b/extra/xf86-video-v4l/git-fixes.patch
@@ -0,0 +1,4362 @@
+diff --git a/ChangeLog b/ChangeLog
+deleted file mode 100644
+index 02fc6fa..0000000
+--- a/ChangeLog
++++ /dev/null
+@@ -1,57 +0,0 @@
+-2006-04-07 Adam Jackson <ajax@freedesktop.org>
+-
+- * configure.ac:
+- * src/v4l.c:
+- Bump to 0.1.1 for Xv changes.
+-
+-2006-04-07 Aaron Plattner <aplattner@nvidia.com>
+-
+- * src/v4l.c: (V4lPutVideo), (V4lPutStill):
+- Add a DrawablePtr argument to the XV functions to pave the way for
+- redirected video.
+-
+-2006-04-07 Adam Jackson <ajax@freedesktop.org>
+-
+- * configure.ac:
+- * src/v4l.c:
+- Unlibcwrap. Bump server version requirement. Bump to 0.1.0.
+-
+-2005-12-20 Kevin E. Martin <kem-at-freedesktop-dot-org>
+-
+- * configure.ac:
+- Update package version for X11R7 release.
+-
+-2005-12-14 Kevin E. Martin <kem-at-freedesktop-dot-org>
+-
+- * configure.ac:
+- Update package version number for final X11R7 release candidate.
+-
+-2005-12-06 Kevin E. Martin <kem-at-freedesktop-dot-org>
+-
+- * man/Makefile.am:
+- Change *man_SOURCES ==> *man_PRE to fix autotools warnings.
+-
+-2005-12-03 Kevin E. Martin <kem-at-freedesktop-dot-org>
+-
+- * configure.ac:
+- Update package version number for X11R7 RC3 release.
+-
+-2005-12-01 Kevin E. Martin <kem-at-freedesktop-dot-org>
+-
+- * configure.ac:
+- Remove extraneous AC_MSG_RESULT.
+-
+-2005-11-29 Adam Jackson <ajax@freedesktop.org>
+-
+- * configure.ac:
+- Only build dlloader modules by default.
+-
+-2005-11-09 Kevin E. Martin <kem-at-freedesktop-dot-org>
+-
+- * configure.ac:
+- Update package version number for X11R7 RC2 release.
+-
+-2005-11-01 Kevin E. Martin <kem-at-freedesktop-dot-org>
+-
+- * configure.ac:
+- Update pkgcheck dependencies to work with separate build roots.
+diff --git a/Makefile.am b/Makefile.am
+index 3ae2692..4c278ba 100644
+--- a/Makefile.am
++++ b/Makefile.am
+@@ -18,6 +18,15 @@
+ # 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.
+
+-AUTOMAKE_OPTIONS = foreign
+ SUBDIRS = src man
+-EXTRA_DIST = README
++MAINTAINERCLEANFILES = ChangeLog INSTALL
++
++.PHONY: ChangeLog INSTALL
++
++INSTALL:
++ $(INSTALL_CMD)
++
++ChangeLog:
++ $(CHANGELOG_CMD)
++
++dist-hook: ChangeLog INSTALL
+diff --git a/configure.ac b/configure.ac
+index d9ac542..c490919 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -20,57 +20,56 @@
+ #
+ # Process this file with autoconf to produce a configure script
+
+-AC_PREREQ(2.57)
++# Initialize Autoconf
++AC_PREREQ([2.60])
+ AC_INIT([xf86-video-v4l],
+- 0.2.0,
++ [0.2.0],
+ [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg],
+- xf86-video-v4l)
+-
++ [xf86-video-v4l])
+ AC_CONFIG_SRCDIR([Makefile.am])
+-AM_CONFIG_HEADER([config.h])
++AC_CONFIG_HEADERS([config.h])
+ AC_CONFIG_AUX_DIR(.)
+
+-AM_INIT_AUTOMAKE([dist-bzip2])
+-
++# Initialize Automake
++AM_INIT_AUTOMAKE([foreign dist-bzip2])
+ AM_MAINTAINER_MODE
+
+-# Checks for programs.
++# Require X.Org macros 1.8 or later for MAN_SUBSTS set by XORG_MANPAGE_SECTIONS
++m4_ifndef([XORG_MACROS_VERSION],
++ [m4_fatal([must install xorg-macros 1.8 or later before running autoconf/autogen])])
++XORG_MACROS_VERSION(1.8)
++XORG_DEFAULT_OPTIONS
++
++# Initialize libtool
+ AC_DISABLE_STATIC
+ AC_PROG_LIBTOOL
+-AC_PROG_CC
+
+ AH_TOP([#include "xorg-server.h"])
+
++# Define a configure option for an alternate module directory
+ AC_ARG_WITH(xorg-module-dir,
+- AC_HELP_STRING([--with-xorg-module-dir=DIR],
++ AS_HELP_STRING([--with-xorg-module-dir=DIR],
+ [Default xorg module directory [[default=$libdir/xorg/modules]]]),
+ [moduledir="$withval"],
+ [moduledir="$libdir/xorg/modules"])
+
+-# Checks for extensions
++# Store the list of server defined optional extensions in REQUIRED_MODULES
+ XORG_DRIVER_CHECK_EXT(RANDR, randrproto)
+ XORG_DRIVER_CHECK_EXT(XV, videoproto)
+
+-# Checks for pkg-config packages
++# Obtain compiler/linker options for the driver dependencies
+ PKG_CHECK_MODULES(XORG, [xorg-server >= 1.0.99.901 xproto $REQUIRED_MODULES])
+-sdkdir=$(pkg-config --variable=sdkdir xorg-server)
+
+ # Checks for libraries.
+
+-# Checks for header files.
+-AC_HEADER_STDC
+-
+-AC_SUBST([XORG_CFLAGS])
+ AC_SUBST([moduledir])
+
+ DRIVER_NAME=v4l
+ AC_SUBST([DRIVER_NAME])
+
+-XORG_MANPAGE_SECTIONS
+-XORG_RELEASE_VERSION
+-
+-AC_OUTPUT([
+- Makefile
+- src/Makefile
+- man/Makefile
++AC_CONFIG_FILES([
++ Makefile
++ src/Makefile
++ man/Makefile
+ ])
++AC_OUTPUT
+diff --git a/man/Makefile.am b/man/Makefile.am
+index f0eb29b..b3688ce 100644
+--- a/man/Makefile.am
++++ b/man/Makefile.am
+@@ -1,27 +1,24 @@
+ #
+ # Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+-#
+-# Permission to use, copy, modify, distribute, and sell this software and its
+-# documentation for any purpose is hereby granted without fee, provided that
+-# the above copyright notice appear in all copies and that both that
+-# copyright notice and this permission notice appear in supporting
+-# documentation.
+-#
+-# 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 THE OPEN GROUP 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.
+-#
+-# Except as contained in this notice, the name of the copyright holders shall
+-# not be used in advertising or otherwise to promote the sale, use or
+-# other dealings in this Software without prior written authorization
+-# from the copyright holders.
++#
++# 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 (including the next
++# paragraph) 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
++# THE AUTHORS OR COPYRIGHT HOLDERS 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.
+ #
+
+ drivermandir = $(DRIVER_MAN_DIR)
+@@ -34,25 +31,11 @@ EXTRA_DIST = @DRIVER_NAME@.man
+
+ CLEANFILES = $(driverman_DATA)
+
+-SED = sed
+
+-# Strings to replace in man pages
+-XORGRELSTRING = @PACKAGE_STRING@
+- XORGMANNAME = X Version 11
++# String replacements in MAN_SUBSTS now come from xorg-macros.m4 via configure
+
+-MAN_SUBSTS = \
+- -e 's|__vendorversion__|"$(XORGRELSTRING)" "$(XORGMANNAME)"|' \
+- -e 's|__xorgversion__|"$(XORGRELSTRING)" "$(XORGMANNAME)"|' \
+- -e 's|__xservername__|Xorg|g' \
+- -e 's|__xconfigfile__|xorg.conf|g' \
+- -e 's|__projectroot__|$(prefix)|g' \
+- -e 's|__appmansuffix__|$(APP_MAN_SUFFIX)|g' \
+- -e 's|__drivermansuffix__|$(DRIVER_MAN_SUFFIX)|g' \
+- -e 's|__adminmansuffix__|$(ADMIN_MAN_SUFFIX)|g' \
+- -e 's|__miscmansuffix__|$(MISC_MAN_SUFFIX)|g' \
+- -e 's|__filemansuffix__|$(FILE_MAN_SUFFIX)|g'
+
+ SUFFIXES = .$(DRIVER_MAN_SUFFIX) .man
+
+ .man.$(DRIVER_MAN_SUFFIX):
+- sed $(MAN_SUBSTS) < $< > $@
++ $(AM_V_GEN)$(SED) $(MAN_SUBSTS) < $< > $@
+diff --git a/man/v4l.man b/man/v4l.man
+index 7d35b86..dc1e201 100644
+--- a/man/v4l.man
++++ b/man/v4l.man
+@@ -34,6 +34,6 @@ Please refer to __xconfigfile__(__filemansuffix__) for general configuration
+ details. This section only covers configuration details specific to this
+ driver.
+ .SH "SEE ALSO"
+-__xservername__(__appmansuffix__), __xconfigfile__(__filemansuffix__), xorgconfig(__appmansuffix__), Xserver(__appmansuffix__), X(__miscmansuffix__)
++__xservername__(__appmansuffix__), __xconfigfile__(__filemansuffix__), Xserver(__appmansuffix__), X(__miscmansuffix__)
+ .SH AUTHORS
+ Authors include: Gerd Knorr <kraxel@bytesex.org>
+diff --git a/src/Makefile.am b/src/Makefile.am
+index ed30a80..08afe60 100644
+--- a/src/Makefile.am
++++ b/src/Makefile.am
+@@ -28,7 +28,6 @@ v4l_drv_la_LTLIBRARIES = v4l_drv.la
+ v4l_drv_la_LDFLAGS = -module -avoid-version
+ v4l_drv_ladir = @moduledir@/drivers
+
+-v4l_drv_la_SOURCES = \
+- v4l.c
+-
+-EXTRA_DIST = videodev.h
++v4l_drv_la_SOURCES = \
++ v4l.c \
++ videodev.h
+diff --git a/src/v4l.c b/src/v4l.c
+index b827f80..10e782b 100644
+--- a/src/v4l.c
++++ b/src/v4l.c
+@@ -1,6 +1,9 @@
+ /*
+- * video4linux Xv Driver
++ * video4linux Xv Driver
+ * based on Michael Schimek's permedia 2 driver.
++ *
++ * Copyright (c) 2011 Mauro Carvalho Chehab <mchehab@redhat.com> for:
++ * - Major rewrite, as driver got ported to V4L2 API
+ */
+
+ #ifdef HAVE_CONFIG_H
+@@ -9,12 +12,16 @@
+
+ #include <sys/types.h>
+ #include <sys/stat.h>
++#include <ctype.h>
++
+ #include <fcntl.h>
+ #include <errno.h>
+ #include <string.h>
+ #include <stdio.h>
++#include <unistd.h>
++#include <sys/ioctl.h>
+
+-#include "videodev.h"
++#include "videodev2.h"
+ #include "xf86.h"
+ #include "xf86_OSproc.h"
+ #include "xf86Pci.h"
+@@ -25,8 +32,9 @@
+ #include "regionstr.h"
+ #include "dgaproc.h"
+ #include "xf86str.h"
++#include "fourcc.h"
+
+-#include <asm/ioctl.h> /* _IORW(xxx) #defines are here */
++#include <asm/ioctl.h> /* _IORW(xxx) #defines are here */
+
+ #if 0
+ # define DEBUG(x) (x)
+@@ -34,20 +42,22 @@
+ # define DEBUG(x)
+ #endif
+
++/***************************************************************************/
++
+ static void V4LIdentify(int flags);
+ static Bool V4LProbe(DriverPtr drv, int flags);
+ static const OptionInfoRec * V4LAvailableOptions(int chipid, int busid);
+
+ _X_EXPORT DriverRec V4L = {
+- 40000,
+- "v4l",
+- V4LIdentify, /* Identify*/
+- V4LProbe, /* Probe */
+- V4LAvailableOptions,
+- NULL,
+- 0
+-};
+-
++ .driverVersion = 50000,
++ .driverName = "v4l",
++ .Identify = V4LIdentify,
++ .Probe = V4LProbe,
++ .AvailableOptions = V4LAvailableOptions,
++ .module = NULL,
++ .refCount = 0,
++ .driverFunc = NULL, /* FIXME: Need to implement for new probing mode */
++};
+
+ #ifdef XFree86LOADER
+
+@@ -55,16 +65,16 @@ static MODULESETUPPROTO(v4lSetup);
+
+ static XF86ModuleVersionInfo v4lVersRec =
+ {
+- "v4l",
+- MODULEVENDORSTRING,
+- MODINFOSTRING1,
+- MODINFOSTRING2,
+- XORG_VERSION_CURRENT,
+- 0, 1, 1,
+- ABI_CLASS_VIDEODRV,
+- ABI_VIDEODRV_VERSION,
+- MOD_CLASS_NONE,
+- {0,0,0,0}
++ "v4l",
++ MODULEVENDORSTRING,
++ MODINFOSTRING1,
++ MODINFOSTRING2,
++ XORG_VERSION_CURRENT,
++ 0, 1, 1,
++ ABI_CLASS_VIDEODRV,
++ ABI_VIDEODRV_VERSION,
++ MOD_CLASS_NONE,
++ {0,0,0,0}
+ };
+
+ _X_EXPORT XF86ModuleData v4lModuleData = { &v4lVersRec, v4lSetup, NULL };
+@@ -72,32 +82,32 @@ _X_EXPORT XF86ModuleData v4lModuleData = { &v4lVersRec, v4lSetup, NULL };
+ static pointer
+ v4lSetup(pointer module, pointer opts, int *errmaj, int *errmin)
+ {
+- const char *osname;
+- static Bool setupDone = FALSE;
+-
+- if (setupDone) {
+- if (errmaj)
+- *errmaj = LDR_ONCEONLY;
+- return NULL;
+- }
+-
+- setupDone = TRUE;
+-
+- /* Check that we're being loaded on a Linux system */
+- LoaderGetOS(&osname, NULL, NULL, NULL);
+- if (!osname || strcmp(osname, "linux") != 0) {
+- if (errmaj)
+- *errmaj = LDR_BADOS;
+- if (errmin)
+- *errmin = 0;
+- return NULL;
+- } else {
+- /* OK */
+-
+- xf86AddDriver (&V4L, module, 0);
+-
+- return (pointer)1;
+- }
++ const char *osname;
++ static Bool setupDone = FALSE;
++
++ if (setupDone) {
++ if (errmaj)
++ *errmaj = LDR_ONCEONLY;
++ return NULL;
++ }
++
++ setupDone = TRUE;
++
++ /* Check that we're being loaded on a Linux system */
++ LoaderGetOS(&osname, NULL, NULL, NULL);
++ if (!osname || strcmp(osname, "linux") != 0) {
++ if (errmaj)
++ *errmaj = LDR_BADOS;
++ if (errmin)
++ *errmin = 0;
++ return NULL;
++ } else {
++ /* OK */
++
++ xf86AddDriver (&V4L, module, 0);
++
++ return (pointer)1;
++ }
+ }
+
+ #else
+@@ -112,25 +122,28 @@ v4lSetup(pointer module, pointer opts, int *errmaj, int *errmin)
+ #define VIDEO_YUV 2 /* yuv overlay (to offscreen memory + hw scaling) */
+ #define VIDEO_RECLIP 3 /* temporarly off, window clipping changes */
+
++typedef struct _XvV4LCtrlRec {
++ struct v4l2_queryctrl qctrl;
++ Atom xv;
++} XvV4LCtrlRec, *XvV4LCtrlPtr;
++
+ typedef struct _PortPrivRec {
+ ScrnInfoPtr pScrn;
+- FBAreaPtr pFBArea[2];
+- int VideoOn;
+- Bool StreamOn;
++ FBAreaPtr pFBArea[2];
++ int VideoOn;
++ Bool StreamOn;
+
+ /* file handle */
+- int nr;
+- struct video_capability cap;
++ int nr;
++ struct v4l2_capability cap;
+
+ /* RGB overlay */
+- struct video_buffer rgb_fbuf;
+- struct video_window rgb_win;
+- int rgbpalette;
++ struct v4l2_framebuffer rgb_fbuf;
++ struct v4l2_window rgb_win;
+ int rgbdepth;
+
+ /* attributes */
+- struct video_picture pict;
+- struct video_audio audio;
++ CARD32 pixelformat;
+
+ XF86VideoEncodingPtr enc;
+ int *input;
+@@ -145,24 +158,21 @@ typedef struct _PortPrivRec {
+
+ int yuv_width,yuv_height;
+ XF86SurfacePtr surface;
+- struct video_buffer yuv_fbuf;
+- struct video_window yuv_win;
+-} PortPrivRec, *PortPrivPtr;
++ struct v4l2_framebuffer yuv_fbuf;
++ struct v4l2_window yuv_win;
++
++ struct v4l2_standard *standard; /* FIXME: can be removed */
+
+-#define XV_ENCODING "XV_ENCODING"
+-#define XV_BRIGHTNESS "XV_BRIGHTNESS"
+-#define XV_CONTRAST "XV_CONTRAST"
+-#define XV_SATURATION "XV_SATURATION"
+-#define XV_HUE "XV_HUE"
++ XvV4LCtrlPtr XvV4LCtrl;
++ int n_qctrl;
++} PortPrivRec, *PortPrivPtr;
+
+-#define XV_FREQ "XV_FREQ"
+-#define XV_MUTE "XV_MUTE"
+-#define XV_VOLUME "XV_VOLUME"
++#define XV_ENCODING "XV_ENCODING"
++#define XV_FREQ "XV_FREQ"
+
+-#define MAKE_ATOM(a) MakeAtom(a, sizeof(a) - 1, TRUE)
++#define MAKE_ATOM(a) MakeAtom(a, strlen(a), TRUE)
+
+-static Atom xvEncoding, xvBrightness, xvContrast, xvSaturation, xvHue;
+-static Atom xvFreq, xvMute, xvVolume;
++static Atom xvEncoding, xvFreq;
+
+ static XF86VideoFormatRec
+ InputVideoFormats[] = {
+@@ -176,16 +186,8 @@ InputVideoFormats[] = {
+
+ static const XF86AttributeRec Attributes[] = {
+ {XvSettable | XvGettable, -1000, 1000, XV_ENCODING},
+- {XvSettable | XvGettable, -1000, 1000, XV_BRIGHTNESS},
+- {XvSettable | XvGettable, -1000, 1000, XV_CONTRAST},
+- {XvSettable | XvGettable, -1000, 1000, XV_SATURATION},
+- {XvSettable | XvGettable, -1000, 1000, XV_HUE},
+ };
+-static const XF86AttributeRec VolumeAttr =
+- {XvSettable | XvGettable, -1000, 1000, XV_VOLUME};
+-static const XF86AttributeRec MuteAttr =
+- {XvSettable | XvGettable, 0, 1, XV_MUTE};
+-static const XF86AttributeRec FreqAttr =
++static const XF86AttributeRec FreqAttr =
+ {XvSettable | XvGettable, 0, 16*1000, XV_FREQ};
+
+
+@@ -206,59 +208,247 @@ static struct V4L_DEVICE {
+ };
+
+ /* ---------------------------------------------------------------------- */
+-/* forward decl */
+
+-static void V4lQueryBestSize(ScrnInfoPtr pScrn, Bool motion,
+- short vid_w, short vid_h, short drw_w, short drw_h,
+- unsigned int *p_w, unsigned int *p_h, pointer data);
++static int SetV4LFmt(int fd, CARD32 pixelformat)
++{
++ struct v4l2_framebuffer fbuf;
++ char *p = (char *)&pixelformat;
++
++ memset(&fbuf, 0, sizeof(fbuf));
++ if (ioctl(fd, VIDIOC_G_FBUF, &fbuf) == -1) {
++ xf86Msg(X_ERROR, "v4l: Error %d: Can't get FBUF\n", errno);
++ return errno;
++ }
++ if (fbuf.fmt.pixelformat != pixelformat) {
++ fbuf.fmt.pixelformat = pixelformat;
++ if (ioctl(fd, VIDIOC_S_FBUF, &fbuf) == -1) {
++ xf86Msg(X_ERROR, "v4l: Error %d: Can't set FBUF to %c%c%c%c\n",
++ errno, p[0], p[1], p[2], p[3]);
++ return errno;
++ }
++ }
++ DEBUG(xf86Msg(X_INFO, "v4l: Set overlay format to %c%c%c%c\n",
++ p[0], p[1], p[2], p[3]));
++ return 0;
++}
++static int GetV4LFmt(int fd, CARD32 *pixelformat)
++{
++ struct v4l2_framebuffer fbuf;
++
++ memset(&fbuf, 0, sizeof(fbuf));
++ if (ioctl(fd, VIDIOC_G_FBUF, &fbuf) == -1) {
++ xf86Msg(X_ERROR, "v4l: Error %d: Can't get FBUF\n", errno);
++ return errno;
++ }
++
++ *pixelformat = fbuf.fmt.pixelformat;
++
++ return 0;
++}
++
++#define ATTR_NAME_PREFIX "XV_"
++static int AddControl(PortPrivPtr p, XF86AttributeRec **list, int *count,
++ struct v4l2_queryctrl *qctrl, int *n)
++{
++ char *ptr;
++
++/* v4l_add_attr */
++ if (qctrl->flags & V4L2_CTRL_FLAG_DISABLED)
++ return 0;
++ switch (qctrl->type) {
++ case V4L2_CTRL_TYPE_INTEGER:
++ case V4L2_CTRL_TYPE_BOOLEAN:
++ case V4L2_CTRL_TYPE_MENU:
++ case V4L2_CTRL_TYPE_BUTTON:
++ break;
++ default:
++ return 0;
++ }
++
++ p->XvV4LCtrl = realloc(p->XvV4LCtrl, sizeof(XvV4LCtrlRec) * (*n + 1));
++ if (!p->XvV4LCtrl) {
++ if (*list) {
++ free (*list);
++ *count = 0;
++ *n = 0;
++ }
++ return -1;
++ }
++
++ *list = realloc(*list, sizeof(XF86AttributeRec) * (*count + 1));
++ if (NULL == *list) {
++ if (p->XvV4LCtrl)
++ free (p->XvV4LCtrl);
++ *count = 0;
++ return -1;
++ }
++
++ memset(*list + *count, 0, sizeof(XF86AttributeRec));
++ (*list)[*count].flags = XvSettable | XvGettable;
++
++ if (qctrl->flags & V4L2_CTRL_FLAG_READ_ONLY)
++ (*list)[*count].flags &= ~XvSettable;
++ if (qctrl->flags & V4L2_CTRL_FLAG_WRITE_ONLY)
++ (*list)[*count].flags &= ~XvGettable;
++ (*list)[*count].min_value = qctrl->minimum;
++ (*list)[*count].max_value = qctrl->maximum;
++ (*list)[*count].name = malloc(strlen((char *)qctrl->name) + 1 + sizeof (ATTR_NAME_PREFIX));
++ strcpy((*list)[*count].name, ATTR_NAME_PREFIX);
++ strcat((*list)[*count].name, (char *)qctrl->name);
++ for (ptr = (*list)[*count].name; *ptr; ptr++) {
++ *ptr = toupper(*ptr);
++ if (*ptr == ' ')
++ *ptr = '_';
++ }
++
++ p->XvV4LCtrl[*n].xv = MAKE_ATOM((*list)[*count].name);
++ memcpy(&p->XvV4LCtrl[*n].qctrl, qctrl, sizeof(*qctrl));
++
++ xf86Msg(X_INFO, "v4l: add attr %s (Xv/GPA %d) (%d to %d)\n",
++ (*list)[*count].name, (int)p->XvV4LCtrl[*n].xv,
++ p->XvV4LCtrl[*n].qctrl.minimum,
++ p->XvV4LCtrl[*n].qctrl.maximum);
++
++ (*count)++;
++ (*n)++;
++
++ return 0;
++}
++
++static void AddAllV4LControls(PortPrivPtr p, XF86AttributeRec **list,
++ int *count, int fd)
++{
++ int entries = 0;
++ CARD32 id;
++ struct v4l2_queryctrl qctrl;
++
++ memset(&qctrl, 0, sizeof(qctrl));
++ qctrl.id = V4L2_CTRL_FLAG_NEXT_CTRL;
++ while (!ioctl(fd, VIDIOC_QUERYCTRL, &qctrl)) {
++ if (AddControl(p, list, count, &qctrl, &entries))
++ return;
++ qctrl.id |= V4L2_CTRL_FLAG_NEXT_CTRL;
++ }
++ if (qctrl.id != V4L2_CTRL_FLAG_NEXT_CTRL)
++ return;
++ for (id = V4L2_CID_USER_BASE; id < V4L2_CID_LASTP1; id++) {
++ qctrl.id = id;
++ if (!ioctl(fd, VIDIOC_QUERYCTRL, &qctrl)) {
++ if (AddControl(p, list, count, &qctrl, &entries))
++ return;
++ }
++ }
++ qctrl.id = V4L2_CID_PRIVATE_BASE;
++ while (!ioctl(fd, VIDIOC_QUERYCTRL, &qctrl)) {
++ if (AddControl(p, list, count, &qctrl, &entries))
++ return;
++ qctrl.id++;
++ }
++ p->n_qctrl = entries;
++}
+
+ /* ---------------------------------------------------------------------- */
+
++/* setup yuv overlay + hw scaling: look if we find some common video
++ format which both v4l driver and the X-Server can handle */
++static int v4l_check_yuv(ScrnInfoPtr pScrn, PortPrivPtr pPPriv,
++ char *dev, int fd)
++{
++ static const struct {
++ CARD32 v4l_palette;
++ unsigned int xv_id;
++ unsigned int xv_format;
++ } yuvlist[] = {
++ { V4L2_PIX_FMT_YUYV, FOURCC_YUY2, XvPacked },
++ { V4L2_PIX_FMT_UYVY, FOURCC_UYVY, XvPacked },
++ { 0 /* end of list */ },
++ };
++ /* FIXME: Why pScrn->scrnIndex? */
++ ScreenPtr pScreen = screenInfo.screens[pScrn->scrnIndex];
++ int fmt,i;
++
++ pPPriv->format = xf86XVQueryOffscreenImages(pScreen, &pPPriv->nformat);
++ xf86DrvMsgVerb(pScrn->scrnIndex, X_INFO, 2,
++ "v4l: Number of Xv formats: %d\n", pPPriv->nformat);
++ if (!pPPriv->nformat)
++ return FALSE;
++
++ for (fmt = 0; yuvlist[fmt].v4l_palette != 0; fmt++) {
++ pPPriv->pixelformat = yuvlist[fmt].v4l_palette;
++ if (-1 == SetV4LFmt(fd, pPPriv->pixelformat))
++ continue;
++ GetV4LFmt(fd, &pPPriv->pixelformat);
++ if (pPPriv->pixelformat != yuvlist[fmt].v4l_palette)
++ continue;
++ /* ... works, check available offscreen image formats now ... */
++ for (i = 0; i < pPPriv->nformat; i++) {
++ if (pPPriv->format[i].image->id == yuvlist[fmt].xv_id &&
++ pPPriv->format[i].image->format == yuvlist[fmt].xv_format) {
++ /* ... match found, good. */
++ pPPriv->yuv_format = yuvlist[fmt].v4l_palette;
++ pPPriv->myfmt = pPPriv->format+i;
++ xf86DrvMsg(pScrn->scrnIndex, X_INFO,
++ "v4l[%s]: using hw video scaling [%4.4s].\n",
++ dev,(char*)&(pPPriv->format[i].image->id));
++ return TRUE;
++ }
++ }
++ }
++ return TRUE;
++}
++
+ static int V4lOpenDevice(PortPrivPtr pPPriv, ScrnInfoPtr pScrn)
+ {
+ static int first = 1;
+
++#if 0
++ /*
++ * It may be a good idea to probe here, but this would break
++ * some things, as initialization uses yuv_format
++ */
++ if (!pPPriv->yuv_format && first)
++ v4l_check_yuv(pScrn, pPPriv, V4L_NAME, V4L_FD);
++#endif
+ if (-1 == V4L_FD) {
+- V4L_FD = open(V4L_NAME, O_RDWR, 0);
+-
+- pPPriv->rgb_fbuf.width = pScrn->virtualX;
+- pPPriv->rgb_fbuf.height = pScrn->virtualY;
+- pPPriv->rgb_fbuf.depth = pScrn->bitsPerPixel;
+- pPPriv->rgb_fbuf.bytesperline = pScrn->displayWidth * ((pScrn->bitsPerPixel + 7)/8);
+- pPPriv->rgb_fbuf.base = (pointer)(pScrn->memPhysBase + pScrn->fbOffset);
+- if (first) {
+- first = 0;
+- xf86DrvMsgVerb(pScrn->scrnIndex, X_INFO, 2,
+- "v4l: memPhysBase=0x%lx\n", pScrn->memPhysBase);
+- }
+-
+- switch (pScrn->bitsPerPixel) {
+- case 16:
+- if (pScrn->weight.green == 5) {
+- pPPriv->rgbpalette = VIDEO_PALETTE_RGB555;
+- pPPriv->rgbdepth = 16;
+- } else {
+- pPPriv->rgbpalette = VIDEO_PALETTE_RGB565;
+- pPPriv->rgbdepth = 16;
+- }
+- break;
+- case 24:
+- pPPriv->rgbpalette = VIDEO_PALETTE_RGB24;
+- pPPriv->rgbdepth = 24;
+- break;
+- case 32:
+- pPPriv->rgbpalette = VIDEO_PALETTE_RGB32;
+- pPPriv->rgbdepth = 32;
+- break;
+- }
++ V4L_FD = open(V4L_NAME, O_RDWR, 0);
++
++ if (-1 == V4L_FD)
++ return errno;
++
++ if (-1 == ioctl(V4L_FD, VIDIOC_G_FBUF, &pPPriv->rgb_fbuf)) {
++ xf86Msg(X_ERROR, "v4l: Error %d: Can't get FBUF\n", errno);
++ return errno;
++ }
++ pPPriv->rgb_fbuf.fmt.width = pScrn->virtualX;
++ pPPriv->rgb_fbuf.fmt.height = pScrn->virtualY;
++ pPPriv->rgb_fbuf.fmt.bytesperline = pScrn->displayWidth * ((pScrn->bitsPerPixel + 7)/8);
++ pPPriv->rgb_fbuf.base = (pointer)(pScrn->memPhysBase + pScrn->fbOffset);
++ if (first) {
++ xf86DrvMsgVerb(pScrn->scrnIndex, X_INFO, 2,
++ "v4l: memPhysBase=0x%lx\n", pScrn->memPhysBase);
++ first = 0;
++ }
++
++ switch (pScrn->bitsPerPixel) {
++ case 16:
++ if (pScrn->weight.green == 5) {
++ pPPriv->rgb_fbuf.fmt.pixelformat = V4L2_PIX_FMT_RGB555;
++ } else {
++ pPPriv->rgb_fbuf.fmt.pixelformat = V4L2_PIX_FMT_RGB565;
++ }
++ break;
++ case 24:
++ pPPriv->rgb_fbuf.fmt.pixelformat = V4L2_PIX_FMT_BGR24;
++ break;
++ case 32:
++ pPPriv->rgb_fbuf.fmt.pixelformat = V4L2_PIX_FMT_BGR32;
++ break;
++ }
+ }
+
+- if (-1 == V4L_FD)
+- return errno;
+-
+ V4L_REF++;
+ DEBUG(xf86DrvMsgVerb(pScrn->scrnIndex, X_INFO, 2,
+- "Xv/open: refcount=%d\n",V4L_REF));
++ "Xv/open: refcount=%d\n",V4L_REF));
+
+ return 0;
+ }
+@@ -267,10 +457,10 @@ static void V4lCloseDevice(PortPrivPtr pPPriv, ScrnInfoPtr pScrn)
+ {
+ V4L_REF--;
+ DEBUG(xf86DrvMsgVerb(pScrn->scrnIndex, X_INFO, 2,
+- "Xv/close: refcount=%d\n",V4L_REF));
++ "Xv/close: refcount=%d\n",V4L_REF));
+ if (0 == V4L_REF && -1 != V4L_FD) {
+- close(V4L_FD);
+- V4L_FD = -1;
++ close(V4L_FD);
++ V4L_FD = -1;
+ }
+ }
+
+@@ -280,8 +470,10 @@ V4lPutVideo(ScrnInfoPtr pScrn,
+ short vid_w, short vid_h, short drw_w, short drw_h,
+ RegionPtr clipBoxes, pointer data, DrawablePtr pDraw)
+ {
++ struct v4l2_format fmt;
++
+ PortPrivPtr pPPriv = (PortPrivPtr) data;
+- struct video_clip *clip;
++ struct v4l2_clip *clip;
+ BoxPtr pBox;
+ RegionRec newReg;
+ BoxRec newBox;
+@@ -291,179 +483,214 @@ V4lPutVideo(ScrnInfoPtr pScrn,
+
+ /* Open a file handle to the device */
+ if (VIDEO_OFF == pPPriv->VideoOn) {
+- if (V4lOpenDevice(pPPriv, pScrn))
+- return Success;
++ if (V4lOpenDevice(pPPriv, pScrn))
++ return Success;
+ }
+
+ if (0 != pPPriv->yuv_format) {
+- DEBUG(xf86DrvMsgVerb(pScrn->scrnIndex, X_INFO, 2, "Xv/PV yuv\n"));
+- width = pPPriv->enc[pPPriv->cenc].width;
++ DEBUG(xf86DrvMsgVerb(pScrn->scrnIndex, X_INFO, 2, "Xv/PV yuv\n"));
++ width = pPPriv->enc[pPPriv->cenc].width;
+ height = pPPriv->enc[pPPriv->cenc].height/2; /* no interlace */
+- if (drw_w < width)
+- width = drw_w;
+- if (drw_h < height)
+- height = drw_h;
+- if ((height != pPPriv->yuv_height) || (width != pPPriv->yuv_width)) {
+- /* new size -- free old surface */
+- DEBUG(xf86DrvMsgVerb(pScrn->scrnIndex, X_INFO, 2, " surface resize\n"));
+- if (pPPriv->surface) {
+- pPPriv->VideoOn = VIDEO_OFF;
+- pPPriv->myfmt->stop(pPPriv->surface);
+- pPPriv->myfmt->free_surface(pPPriv->surface);
+- xfree(pPPriv->surface);
+- pPPriv->surface = NULL;
+- }
+- pPPriv->yuv_width = width;
+- pPPriv->yuv_height = height;
+- }
+- if (!pPPriv->surface) {
+- /* allocate + setup offscreen surface */
+- if (NULL == (pPPriv->surface = xalloc(sizeof(XF86SurfaceRec))))
+- return FALSE;
+- if (Success != pPPriv->myfmt->alloc_surface
+- (pScrn,pPPriv->myfmt->image->id,
+- pPPriv->yuv_width,pPPriv->yuv_height,pPPriv->surface)) {
+- xfree(pPPriv->surface);
+- pPPriv->surface = NULL;
+- goto fallback_to_rgb;
+- }
+- pPPriv->yuv_fbuf.width = pPPriv->surface->width;
+- pPPriv->yuv_fbuf.height = pPPriv->surface->height;
+- pPPriv->yuv_fbuf.depth = 16;
+- pPPriv->yuv_fbuf.bytesperline = pPPriv->surface->pitches[0];
+- pPPriv->yuv_fbuf.base =
+- (pointer)(pScrn->memPhysBase + pPPriv->surface->offsets[0]);
+- DEBUG(xf86DrvMsgVerb(pScrn->scrnIndex, X_INFO, 2, " surface: %p+%d = %p, %dx%d, pitch %d\n",
+- pScrn->memPhysBase,pPPriv->surface->offsets[0],
+- pScrn->memPhysBase+pPPriv->surface->offsets[0],
+- pPPriv->surface->width,pPPriv->surface->height,
+- pPPriv->surface->pitches[0]));
+- pPPriv->yuv_win.width = pPPriv->surface->width;
+- pPPriv->yuv_win.height = pPPriv->surface->height;
+- }
+-
+- /* program driver */
+- if (-1 == ioctl(V4L_FD,VIDIOCSFBUF,&(pPPriv->yuv_fbuf)))
+- perror("ioctl VIDIOCSFBUF");
+- if (-1 == ioctl(V4L_FD,VIDIOCGPICT,&pPPriv->pict))
+- perror("ioctl VIDIOCGPICT");
+- pPPriv->pict.palette = pPPriv->yuv_format;
+- pPPriv->pict.depth = 16;
+- if (-1 == ioctl(V4L_FD,VIDIOCSPICT,&pPPriv->pict))
+- perror("ioctl VIDIOCSPICT");
+- if (-1 == ioctl(V4L_FD,VIDIOCSWIN,&(pPPriv->yuv_win)))
+- perror("ioctl VIDIOCSWIN");
+- if (-1 == ioctl(V4L_FD, VIDIOCCAPTURE, &one))
+- perror("ioctl VIDIOCCAPTURE(1)");
+-
+- if (0 == (pPPriv->myfmt->flags & VIDEO_INVERT_CLIPLIST)) {
+- /* invert cliplist */
+- newBox.x1 = drw_x;
+- newBox.y1 = drw_y;
+- newBox.x2 = drw_x + drw_w;
+- newBox.y2 = drw_y + drw_h;
+-
+- if (pPPriv->myfmt->flags & VIDEO_CLIP_TO_VIEWPORT) {
+- /* trim to the viewport */
+- if(newBox.x1 < pScrn->frameX0)
+- newBox.x1 = pScrn->frameX0;
+- if(newBox.x2 > pScrn->frameX1)
+- newBox.x2 = pScrn->frameX1;
+-
+- if(newBox.y1 < pScrn->frameY0)
+- newBox.y1 = pScrn->frameY0;
+- if(newBox.y2 > pScrn->frameY1)
+- newBox.y2 = pScrn->frameY1;
+- }
++ if (drw_w < width)
++ width = drw_w;
++ if (drw_h < height)
++ height = drw_h;
++ if ((height != pPPriv->yuv_height) || (width != pPPriv->yuv_width)) {
++ /* new size -- free old surface */
++ DEBUG(xf86DrvMsgVerb(pScrn->scrnIndex, X_INFO, 2, " surface resize\n"));
++ if (pPPriv->surface) {
++ pPPriv->VideoOn = VIDEO_OFF;
++ pPPriv->myfmt->stop(pPPriv->surface);
++ pPPriv->myfmt->free_surface(pPPriv->surface);
++ free(pPPriv->surface);
++ pPPriv->surface = NULL;
++ }
++ pPPriv->yuv_width = width;
++ pPPriv->yuv_height = height;
++ }
++ if (!pPPriv->surface) {
++ /* allocate + setup offscreen surface */
++ if (NULL == (pPPriv->surface = malloc(sizeof(XF86SurfaceRec))))
++ return FALSE;
++ if (Success != pPPriv->myfmt->alloc_surface
++ (pScrn,pPPriv->myfmt->image->id,
++ pPPriv->yuv_width,pPPriv->yuv_height,pPPriv->surface)) {
++ free(pPPriv->surface);
++ pPPriv->surface = NULL;
++ goto fallback_to_rgb;
++ }
++
++ if (-1 == ioctl(V4L_FD, VIDIOC_G_FBUF, &pPPriv->yuv_fbuf)) {
++ xf86Msg(X_ERROR, "v4l: Error %d: Can't get FBUF\n", errno);
++ return errno;
++ }
++ pPPriv->yuv_fbuf.fmt.width = pPPriv->surface->width;
++ pPPriv->yuv_fbuf.fmt.height = pPPriv->surface->height;
++ pPPriv->yuv_fbuf.fmt.bytesperline = pPPriv->surface->pitches[0];
++ pPPriv->yuv_fbuf.fmt.pixelformat = pPPriv->yuv_format;
++ pPPriv->yuv_fbuf.base =
++ (pointer)(pScrn->memPhysBase + pPPriv->surface->offsets[0]);
++ DEBUG(xf86DrvMsgVerb(pScrn->scrnIndex, X_INFO, 2,
++ " surface: %p+%d = %p, %dx%d, pitch %d\n",
++ (void *)pScrn->memPhysBase, pPPriv->surface->offsets[0],
++ (void *)pScrn->memPhysBase+pPPriv->surface->offsets[0],
++ pPPriv->surface->width, pPPriv->surface->height,
++ pPPriv->surface->pitches[0]));
++ memset(&pPPriv->yuv_win, 0, sizeof(pPPriv->yuv_win));
++ pPPriv->yuv_win.w.left = 0;
++ pPPriv->yuv_win.w.top = 0;
++ pPPriv->yuv_win.w.width = pPPriv->surface->width;
++ pPPriv->yuv_win.w.height = pPPriv->surface->height;
++ }
+
+- REGION_INIT(pScrn->pScreen, &newReg, &newBox, 1);
+- REGION_SUBTRACT(pScrn->pScreen, &newReg, &newReg, clipBoxes);
+- clipBoxes = &newReg;
+- }
+-
+- /* start overlay */
+- DEBUG(xf86DrvMsgVerb(pScrn->scrnIndex, X_INFO, 2,
+- "over: - %d,%d -> %d,%d (%dx%d) (yuv=%dx%d)\n",
+- drw_x, drw_y,
+- drw_x+drw_w, drw_y+drw_h,
+- drw_w, drw_h,
+- pPPriv->surface->width,pPPriv->surface->height));
+- pPPriv->myfmt->display(pPPriv->surface,
+- 0, 0, drw_x, drw_y,
+- pPPriv->surface->width,
+- pPPriv->surface->height,
+- drw_w, drw_h,
+- clipBoxes);
+- if (0 == (pPPriv->myfmt->flags & VIDEO_INVERT_CLIPLIST)) {
+- REGION_UNINIT(pScrn->pScreen, &newReg);
+- }
+- pPPriv->VideoOn = VIDEO_YUV;
+- return Success;
++ /* program driver */
++ if (-1 == ioctl(V4L_FD, VIDIOC_S_FBUF, &pPPriv->yuv_fbuf)) {
++ xf86Msg(X_ERROR, "Error %d at VIDIOC_S_FBUF\n", errno);
++ return BadValue;
++ }
++ pPPriv->pixelformat = pPPriv->yuv_format;
++ if (-1 == SetV4LFmt(V4L_FD, pPPriv->pixelformat))
++ return BadValue;
++
++ memset(&fmt, 0, sizeof(fmt));
++ fmt.type = V4L2_BUF_TYPE_VIDEO_OVERLAY;
++ memcpy(&fmt.fmt.win, &pPPriv->yuv_win, sizeof(pPPriv->yuv_win));
++ if (-1 == ioctl(V4L_FD, VIDIOC_S_FMT, &fmt)) {
++ xf86Msg(X_ERROR, "Error %d at VIDIOC_S_FMT\n", errno);
++ return BadValue;
++ }
++ if (-1 == ioctl(V4L_FD, VIDIOC_OVERLAY, &one)) {
++ xf86Msg(X_ERROR, "v4l: Error %d while enabling Overlay\n", errno);
++ return BadValue;
++ }
++
++ if (0 == (pPPriv->myfmt->flags & VIDEO_INVERT_CLIPLIST)) {
++ /* invert cliplist */
++ newBox.x1 = drw_x;
++ newBox.y1 = drw_y;
++ newBox.x2 = drw_x + drw_w;
++ newBox.y2 = drw_y + drw_h;
++
++ if (pPPriv->myfmt->flags & VIDEO_CLIP_TO_VIEWPORT) {
++ /* trim to the viewport */
++ if(newBox.x1 < pScrn->frameX0)
++ newBox.x1 = pScrn->frameX0;
++ if(newBox.x2 > pScrn->frameX1)
++ newBox.x2 = pScrn->frameX1;
++
++ if(newBox.y1 < pScrn->frameY0)
++ newBox.y1 = pScrn->frameY0;
++ if(newBox.y2 > pScrn->frameY1)
++ newBox.y2 = pScrn->frameY1;
++ }
++
++ REGION_INIT(pScrn->pScreen, &newReg, &newBox, 1);
++ REGION_SUBTRACT(pScrn->pScreen, &newReg, &newReg, clipBoxes);
++ clipBoxes = &newReg;
++ }
++
++ /* start overlay */
++ DEBUG(xf86DrvMsgVerb(pScrn->scrnIndex, X_INFO, 2,
++ "over: - %d,%d -> %d,%d (%dx%d) (yuv=%dx%d)\n",
++ drw_x, drw_y,
++ drw_x+drw_w, drw_y+drw_h,
++ drw_w, drw_h,
++ pPPriv->surface->width,pPPriv->surface->height));
++ pPPriv->myfmt->display(pPPriv->surface,
++ 0, 0, drw_x, drw_y,
++ pPPriv->surface->width,
++ pPPriv->surface->height,
++ drw_w, drw_h,
++ clipBoxes);
++ if (0 == (pPPriv->myfmt->flags & VIDEO_INVERT_CLIPLIST)) {
++ REGION_UNINIT(pScrn->pScreen, &newReg);
++ }
++ pPPriv->VideoOn = VIDEO_YUV;
++ return Success;
+ }
+
+- fallback_to_rgb:
++fallback_to_rgb:
+ DEBUG(xf86DrvMsgVerb(pScrn->scrnIndex, X_INFO, 2, "Xv/PV rgb\n"));
+ /* FIXME: vid-* is ignored for now, not supported by v4l */
+
+ dw = (drw_w < pPPriv->enc[pPPriv->cenc].width) ?
+- drw_w : pPPriv->enc[pPPriv->cenc].width;
++ drw_w : pPPriv->enc[pPPriv->cenc].width;
+ dh = (drw_h < pPPriv->enc[pPPriv->cenc].height) ?
+- drw_h : pPPriv->enc[pPPriv->cenc].height;
++ drw_h : pPPriv->enc[pPPriv->cenc].height;
+ /* if the window is too big, center the video */
+ dx = drw_x + (drw_w - dw)/2;
+ dy = drw_y + (drw_h - dh)/2;
+ /* bttv prefeares aligned addresses */
+ dx &= ~3;
+- if (dx < drw_x) dx += 4;
+- if (dx+dw > drw_x+drw_w) dw -= 4;
++ if (dx < drw_x)
++ dx += 4;
++ if (dx+dw > drw_x+drw_w)
++ dw -= 4;
+
+ /* window */
+ DEBUG(xf86DrvMsgVerb(pScrn->scrnIndex, X_INFO, 2, " win: %dx%d+%d+%d\n",
+- drw_w,drw_h,drw_x,drw_y));
++ drw_w,drw_h,drw_x,drw_y));
+ DEBUG(xf86DrvMsgVerb(pScrn->scrnIndex, X_INFO, 2, " use: %dx%d+%d+%d\n",
+- dw,dh,dx,dy));
+- pPPriv->rgb_win.x = dx;
+- pPPriv->rgb_win.y = dy;
+- pPPriv->rgb_win.width = dw;
+- pPPriv->rgb_win.height = dh;
+- pPPriv->rgb_win.flags = 0;
+-
++ dw,dh,dx,dy));
++ memset(&pPPriv->rgb_win, 0, sizeof(pPPriv->rgb_win));
++ pPPriv->rgb_win.w.left = dx;
++ pPPriv->rgb_win.w.top = dy;
++ pPPriv->rgb_win.w.width = dw;
++ pPPriv->rgb_win.w.height = dh;
++
+ /* clipping */
+ if (pPPriv->rgb_win.clips) {
+- xfree(pPPriv->rgb_win.clips);
+- pPPriv->rgb_win.clips = NULL;
++ free(pPPriv->rgb_win.clips);
++ pPPriv->rgb_win.clips = NULL;
+ }
+ pPPriv->rgb_win.clipcount = REGION_NUM_RECTS(clipBoxes);
+ DEBUG(xf86DrvMsgVerb(pScrn->scrnIndex, X_INFO, 2," clip: have #%d\n",
+- pPPriv->rgb_win.clipcount));
++ pPPriv->rgb_win.clipcount));
+ if (0 != pPPriv->rgb_win.clipcount) {
+- pPPriv->rgb_win.clips = xalloc(pPPriv->rgb_win.clipcount*sizeof(struct video_clip));
+- if (NULL != pPPriv->rgb_win.clips) {
+- memset(pPPriv->rgb_win.clips,0,pPPriv->rgb_win.clipcount*sizeof(struct video_clip));
+- pBox = REGION_RECTS(clipBoxes);
+- clip = pPPriv->rgb_win.clips;
+- for (i = 0; i < REGION_NUM_RECTS(clipBoxes); i++, pBox++, clip++) {
+- clip->x = pBox->x1 - dx;
+- clip->y = pBox->y1 - dy;
+- clip->width = pBox->x2 - pBox->x1;
+- clip->height = pBox->y2 - pBox->y1;
+- }
+- }
++ pPPriv->rgb_win.clips = malloc(pPPriv->rgb_win.clipcount*sizeof(struct v4l2_clip));
++ if (NULL != pPPriv->rgb_win.clips) {
++ memset(pPPriv->rgb_win.clips,0,pPPriv->rgb_win.clipcount*sizeof(struct v4l2_clip));
++ pBox = REGION_RECTS(clipBoxes);
++ clip = pPPriv->rgb_win.clips;
++
++ /*
++ * FIXME: This code currently does nothing, as we don't emulate
++ * The V4L1 clipping stuff
++ */
++ for (i = 0; i < REGION_NUM_RECTS(clipBoxes); i++, pBox++, clip++) {
++ clip->c.left = pBox->x1 - dx;
++ clip->c.top = pBox->y1 - dy;
++ clip->c.width = pBox->x2 - pBox->x1;
++ clip->c.height = pBox->y2 - pBox->y1;
++ }
++ }
+ }
+
+ /* start */
+- if (-1 == ioctl(V4L_FD,VIDIOCSFBUF,&(pPPriv->rgb_fbuf)))
+- perror("ioctl VIDIOCSFBUF");
+- if (-1 == ioctl(V4L_FD,VIDIOCGPICT,&pPPriv->pict))
+- perror("ioctl VIDIOCGPICT");
+- pPPriv->pict.palette = pPPriv->rgbpalette;
+- pPPriv->pict.depth = pPPriv->rgbdepth;
+- if (-1 == ioctl(V4L_FD,VIDIOCSPICT,&pPPriv->pict))
+- perror("ioctl VIDIOCSPICT");
+- if (-1 == ioctl(V4L_FD,VIDIOCSWIN,&(pPPriv->rgb_win)))
+- perror("ioctl VIDIOCSWIN");
+- if (-1 == ioctl(V4L_FD, VIDIOCCAPTURE, &one))
+- perror("ioctl VIDIOCCAPTURE(1)");
++ if (-1 == ioctl(V4L_FD, VIDIOC_S_FBUF, &pPPriv->rgb_fbuf)) {
++ xf86Msg(X_ERROR, "Error %d at VIDIOC_S_FBUF\n", errno);
++ return BadValue;
++ }
++ if (-1 == GetV4LFmt(V4L_FD, &pPPriv->pixelformat)) {
++ xf86Msg(X_ERROR, "Error %d getting pixelformat\n", errno);
++ return BadValue;
++ }
++ pPPriv->pixelformat = pPPriv->rgb_fbuf.fmt.pixelformat;
++ if (-1 == SetV4LFmt(V4L_FD, pPPriv->pixelformat)) {
++ xf86Msg(X_ERROR, "Error %d getting pixelformat\n", errno);
++ return BadValue;
++ }
++ memset(&fmt, 0, sizeof(fmt));
++ fmt.type = V4L2_BUF_TYPE_VIDEO_OVERLAY;
++ memcpy(&fmt.fmt.win, &pPPriv->rgb_win, sizeof(pPPriv->rgb_win));
++ if (-1 == ioctl(V4L_FD, VIDIOC_S_FMT, &fmt)) {
++ xf86Msg(X_ERROR, "Error %d at VIDIOC_S_FMT\n", errno);
++ return BadValue;
++ }
++ if (-1 == ioctl(V4L_FD, VIDIOC_OVERLAY, &one)) {
++ xf86Msg(X_ERROR, "v4l: Error %d while enabling Overlay\n", errno);
++ return BadValue;
++ }
+ pPPriv->VideoOn = VIDEO_RGB;
+
+ return Success;
+@@ -476,7 +703,7 @@ V4lPutStill(ScrnInfoPtr pScrn,
+ RegionPtr clipBoxes, pointer data, DrawablePtr pDraw)
+ {
+ #if 0
+- PortPrivPtr pPPriv = (PortPrivPtr) data;
++ PortPrivPtr pPPriv = (PortPrivPtr) data;
+ #endif
+
+ DEBUG(xf86DrvMsgVerb(pScrn->scrnIndex, X_INFO, 2, "Xv/PS\n"));
+@@ -488,177 +715,152 @@ V4lPutStill(ScrnInfoPtr pScrn,
+ static void
+ V4lStopVideo(ScrnInfoPtr pScrn, pointer data, Bool shutdown)
+ {
+- PortPrivPtr pPPriv = (PortPrivPtr) data;
++ PortPrivPtr pPPriv = (PortPrivPtr) data;
+ int zero=0;
+
+ if (VIDEO_OFF == pPPriv->VideoOn) {
+- DEBUG(xf86DrvMsgVerb(pScrn->scrnIndex, X_INFO, 2,
+- "Xv/StopVideo called with video already off\n"));
+- return;
++ DEBUG(xf86DrvMsgVerb(pScrn->scrnIndex, X_INFO, 2,
++ "Xv/StopVideo called with video already off\n"));
++ return;
+ }
+ DEBUG(xf86DrvMsgVerb(pScrn->scrnIndex, X_INFO, 2, "Xv/StopVideo shutdown=%d\n",shutdown));
+
+ if (!shutdown) {
+- /* just reclipping, we have to stop DMA transfers to the visible screen */
+- if (VIDEO_RGB == pPPriv->VideoOn) {
+- if (-1 == ioctl(V4L_FD, VIDIOCCAPTURE, &zero))
+- perror("ioctl VIDIOCCAPTURE(0)");
+- pPPriv->VideoOn = VIDEO_RECLIP;
+- }
++ /* just reclipping, we have to stop DMA transfers to the visible screen */
++ if (VIDEO_RGB == pPPriv->VideoOn) {
++ if (-1 == ioctl(V4L_FD, VIDIOC_OVERLAY, &zero))
++ xf86Msg(X_ERROR, "v4l: Error %d while disabling Overlay\n", errno);
++ pPPriv->VideoOn = VIDEO_RECLIP;
++ }
+ } else {
+- /* video stop - turn off and free everything */
+- if (VIDEO_YUV == pPPriv->VideoOn) {
+- pPPriv->myfmt->stop(pPPriv->surface);
+- pPPriv->myfmt->free_surface(pPPriv->surface);
+- xfree(pPPriv->surface);
+- pPPriv->surface = NULL;
+- }
+- if (-1 == ioctl(V4L_FD, VIDIOCCAPTURE, &zero))
+- perror("ioctl VIDIOCCAPTURE(0)");
+-
+- V4lCloseDevice(pPPriv,pScrn);
+- pPPriv->VideoOn = VIDEO_OFF;
+- }
+-}
++ /* video stop - turn off and free everything */
++ if (VIDEO_YUV == pPPriv->VideoOn) {
++ pPPriv->myfmt->stop(pPPriv->surface);
++ pPPriv->myfmt->free_surface(pPPriv->surface);
++ free(pPPriv->surface);
++ pPPriv->surface = NULL;
++ }
++ if (-1 == ioctl(V4L_FD, VIDIOC_OVERLAY, &zero))
++ xf86Msg(X_ERROR, "v4l: Error %d while disabling Overlay\n", errno);
+
+-/* v4l uses range 0 - 65535; Xv uses -1000 - 1000 */
+-static int
+-v4l_to_xv(int val) {
+- val = val * 2000 / 65536 - 1000;
+- if (val < -1000) val = -1000;
+- if (val > 1000) val = 1000;
+- return val;
+-}
+-static int
+-xv_to_v4l(int val) {
+- val = val * 65536 / 2000 + 32768;
+- if (val < -0) val = 0;
+- if (val > 65535) val = 65535;
+- return val;
++ V4lCloseDevice(pPPriv,pScrn);
++ pPPriv->VideoOn = VIDEO_OFF;
++ }
+ }
+
+ static int
+ V4lSetPortAttribute(ScrnInfoPtr pScrn,
+ Atom attribute, INT32 value, pointer data)
+ {
+- PortPrivPtr pPPriv = (PortPrivPtr) data;
+- struct video_channel chan;
+- int ret = Success;
++ struct v4l2_control ctrl;
++ PortPrivPtr pPPriv = (PortPrivPtr) data;
++ int i, ret = BadValue;
+
+ if (V4lOpenDevice(pPPriv, pScrn))
+- return Success;
++ return Success;
+
+ DEBUG(xf86DrvMsgVerb(pScrn->scrnIndex, X_INFO, 2, "Xv/SPA %d, %d\n",
+- attribute, value));
++ (int)attribute, (int)value));
+
+ if (-1 == V4L_FD) {
+- ret = Success;
++ ret = Success;
+ } else if (attribute == xvEncoding) {
+- if (value >= 0 && value < pPPriv->nenc) {
+- pPPriv->cenc = value;
+- chan.channel = pPPriv->input[value];
+- chan.norm = pPPriv->norm[value];
+- if (-1 == ioctl(V4L_FD,VIDIOCSCHAN,&chan))
+- perror("ioctl VIDIOCSCHAN");
+- } else {
+- ret = BadValue;
+- }
+- } else if (attribute == xvBrightness ||
+- attribute == xvContrast ||
+- attribute == xvSaturation ||
+- attribute == xvHue) {
+- ioctl(V4L_FD,VIDIOCGPICT,&pPPriv->pict);
+- if (attribute == xvBrightness) pPPriv->pict.brightness = xv_to_v4l(value);
+- if (attribute == xvContrast) pPPriv->pict.contrast = xv_to_v4l(value);
+- if (attribute == xvSaturation) pPPriv->pict.colour = xv_to_v4l(value);
+- if (attribute == xvHue) pPPriv->pict.hue = xv_to_v4l(value);
+- if (-1 == ioctl(V4L_FD,VIDIOCSPICT,&pPPriv->pict))
+- perror("ioctl VIDIOCSPICT");
+- } else if (attribute == xvMute ||
+- attribute == xvVolume) {
+- ioctl(V4L_FD,VIDIOCGAUDIO,&pPPriv->audio);
+- if (attribute == xvMute) {
+- if (value)
+- pPPriv->audio.flags |= VIDEO_AUDIO_MUTE;
+- else
+- pPPriv->audio.flags &= ~VIDEO_AUDIO_MUTE;
+- } else if (attribute == xvVolume) {
+- if (pPPriv->audio.flags & VIDEO_AUDIO_VOLUME)
+- pPPriv->audio.volume = xv_to_v4l(value);
+- } else {
+- ret = BadValue;
+- }
+- if (ret != BadValue)
+- if (-1 == ioctl(V4L_FD,VIDIOCSAUDIO,&pPPriv->audio))
+- perror("ioctl VIDIOCSAUDIO");
++ if (value < 0 || value >= pPPriv->nenc)
++ goto err;
++ if (ioctl(V4L_FD, VIDIOC_S_INPUT, &pPPriv->input[value]) == -1) {
++ xf86Msg(X_ERROR, "v4l: Error %d while setting input\n", errno);
++ goto err;
++ }
++ if (ioctl(V4L_FD, VIDIOC_S_STD, &pPPriv->norm[value]) == -1) {
++ xf86Msg(X_ERROR, "v4l: Error %d while setting standard\n", errno);
++ goto err;
++ }
++ pPPriv->cenc = value;
++ ret = Success;
+ } else if (attribute == xvFreq) {
+- unsigned long freq = value;
+- if (-1 == ioctl(V4L_FD,VIDIOCSFREQ,&freq))
+- perror("ioctl VIDIOCSFREQ");
+- } else if (0 != pPPriv->yuv_format &&
+- pPPriv->myfmt->setAttribute) {
+- /* not mine -> pass to yuv scaler driver */
+- ret = pPPriv->myfmt->setAttribute(pScrn, attribute, value);
++ struct v4l2_frequency freq;
++ memset(&freq, 0, sizeof(freq));
++ ioctl(V4L_FD, VIDIOC_G_FREQUENCY, &freq);
++ freq.frequency = value;
++ if (ioctl(V4L_FD, VIDIOC_S_FREQUENCY, &freq) == -1)
++ xf86Msg(X_ERROR, "v4l: Error %d while setting frequency\n", errno);
++ else
++ ret = Success;
+ } else {
+- ret = BadValue;
++ for (i = 0; i < pPPriv->n_qctrl; i++)
++ if (pPPriv->XvV4LCtrl[i].xv == attribute)
++ break;
++ if (i == pPPriv->n_qctrl) {
++ /* not mine -> pass to yuv scaler driver */
++ if (0 != pPPriv->yuv_format && pPPriv->myfmt->setAttribute)
++ ret = pPPriv->myfmt->setAttribute(pScrn, attribute, value);
++ else
++ ret = BadMatch;
++ goto err;
++ }
++ if (pPPriv->XvV4LCtrl[i].qctrl.flags & V4L2_CTRL_FLAG_DISABLED)
++ goto err;
++ ctrl.id = pPPriv->XvV4LCtrl[i].qctrl.id;
++ ctrl.value = value;
++ if (ioctl(V4L_FD, VIDIOC_S_CTRL, &ctrl) != 1)
++ ret = Success;
+ }
+
++err:
+ V4lCloseDevice(pPPriv,pScrn);
+ return ret;
+ }
+
+ static int
+-V4lGetPortAttribute(ScrnInfoPtr pScrn,
++V4lGetPortAttribute(ScrnInfoPtr pScrn,
+ Atom attribute, INT32 *value, pointer data)
+ {
++ struct v4l2_control ctrl;
+ PortPrivPtr pPPriv = (PortPrivPtr) data;
+- int ret = Success;
++ int i, ret = BadValue;
+
+ if (V4lOpenDevice(pPPriv, pScrn))
+- return Success;
++ return Success;
+
+ DEBUG(xf86DrvMsgVerb(pScrn->scrnIndex, X_INFO, 2, "Xv/GPA %d\n",
+- attribute));
++ (int)attribute));
+
+ if (-1 == V4L_FD) {
+- ret = Success;
++ ret = Success;
+ } else if (attribute == xvEncoding) {
+- *value = pPPriv->cenc;
+- } else if (attribute == xvBrightness ||
+- attribute == xvContrast ||
+- attribute == xvSaturation ||
+- attribute == xvHue) {
+- ioctl(V4L_FD,VIDIOCGPICT,&pPPriv->pict);
+- if (attribute == xvBrightness) *value = v4l_to_xv(pPPriv->pict.brightness);
+- if (attribute == xvContrast) *value = v4l_to_xv(pPPriv->pict.contrast);
+- if (attribute == xvSaturation) *value = v4l_to_xv(pPPriv->pict.colour);
+- if (attribute == xvHue) *value = v4l_to_xv(pPPriv->pict.hue);
+- } else if (attribute == xvMute ||
+- attribute == xvVolume) {
+- ioctl(V4L_FD,VIDIOCGAUDIO,&pPPriv->audio);
+- if (attribute == xvMute) {
+- *value = (pPPriv->audio.flags & VIDEO_AUDIO_MUTE) ? 1 : 0;
+- } else if (attribute == xvVolume) {
+- if (pPPriv->audio.flags & VIDEO_AUDIO_VOLUME)
+- *value = v4l_to_xv(pPPriv->audio.volume);
+- } else {
+- ret = BadValue;
+- }
++ *value = pPPriv->cenc;
++ ret = Success;
+ } else if (attribute == xvFreq) {
+- unsigned long freq;
+- ioctl(V4L_FD,VIDIOCGFREQ,&freq);
+- *value = freq;
+- } else if (0 != pPPriv->yuv_format &&
+- pPPriv->myfmt->getAttribute) {
+- /* not mine -> pass to yuv scaler driver */
+- ret = pPPriv->myfmt->getAttribute(pScrn, attribute, value);
++ struct v4l2_frequency freq;
++ memset(&freq, 0, sizeof(freq));
++ if (ioctl(V4L_FD, VIDIOC_G_FREQUENCY, &freq) != -1) {
++ *value = freq.frequency;
++ ret = Success;
++ }
+ } else {
+- ret = BadValue;
++ for (i = 0; i < pPPriv->n_qctrl; i++)
++ if (pPPriv->XvV4LCtrl[i].xv == attribute)
++ break;
++ if (i == pPPriv->n_qctrl) {
++ /* not mine -> pass to yuv scaler driver */
++ if (0 != pPPriv->yuv_format && pPPriv->myfmt->getAttribute)
++ ret = pPPriv->myfmt->getAttribute(pScrn, attribute, value);
++ else
++ ret = BadMatch;
++ goto err;
++ }
++ if (pPPriv->XvV4LCtrl[i].qctrl.flags & V4L2_CTRL_FLAG_DISABLED)
++ goto err;
++ ctrl.id = pPPriv->XvV4LCtrl[i].qctrl.id;
++ if (ioctl(V4L_FD, VIDIOC_G_CTRL, &ctrl) != -1) {
++ *value = ctrl.value;
++ ret = Success;
++ }
+ }
+-
+ DEBUG(xf86DrvMsgVerb(pScrn->scrnIndex, X_INFO, 2, "Xv/GPA %d, %d\n",
+- attribute, *value));
++ (int)attribute, (int)*value));
+
++err:
+ V4lCloseDevice(pPPriv,pScrn);
+ return ret;
+ }
+@@ -673,15 +875,15 @@ V4lQueryBestSize(ScrnInfoPtr pScrn, Bool motion,
+ int maxy = pPPriv->enc[pPPriv->cenc].height;
+
+ if (0 != pPPriv->yuv_format) {
+- *p_w = pPPriv->myfmt->max_width;
+- *p_h = pPPriv->myfmt->max_height;
++ *p_w = pPPriv->myfmt->max_width;
++ *p_h = pPPriv->myfmt->max_height;
+ } else {
+- *p_w = (drw_w < maxx) ? drw_w : maxx;
+- *p_h = (drw_h < maxy) ? drw_h : maxy;
++ *p_w = (drw_w < maxx) ? drw_w : maxx;
++ *p_h = (drw_h < maxy) ? drw_h : maxy;
+ }
+
+ DEBUG(xf86DrvMsgVerb(pScrn->scrnIndex, X_INFO, 2, "Xv/BS %d %dx%d %dx%d\n",
+- pPPriv->cenc,drw_w,drw_h,*p_w,*p_h));
++ pPPriv->cenc,drw_w,drw_h,*p_w,*p_h));
+ }
+
+ static const OptionInfoRec *
+@@ -693,132 +895,198 @@ V4LAvailableOptions(int chipid, int busid)
+ static void
+ V4LIdentify(int flags)
+ {
+- xf86Msg(X_INFO, "v4l driver for Video4Linux\n");
+-}
++ xf86Msg(X_INFO, "v4l driver for Video4Linux overlay mode (V4L2)\n");
++}
+
+ static char*
+ fixname(char *str)
+ {
+ int s,d;
+ for (s=0, d=0;; s++) {
+- if (str[s] == '-')
+- continue;
+- str[d++] = tolower(str[s]);
+- if (0 == str[s])
+- break;
++ if (str[s] == '-')
++ continue;
++ str[d++] = tolower(str[s]);
++ if (0 == str[s])
++ break;
+ }
+ return str;
+ }
+
+ static int
+-v4l_add_enc(XF86VideoEncodingPtr enc, int i,
+- char *norm, char *input, int width, int height, int n, int d)
++AddV4LEnc(XF86VideoEncodingPtr enc, int entry,
++ char *norm, char *input, int width, int height, int n, int d)
+ {
+- enc[i].id = i;
+- enc[i].name = xalloc(strlen(norm)+strlen(input)+2);
+- if (NULL == enc[i].name)
+- return -1;
+- enc[i].width = width;
+- enc[i].height = height;
+- enc[i].rate.numerator = n;
+- enc[i].rate.denominator = d;
+- sprintf(enc[i].name,"%s-%s",norm,fixname(input));
++ enc->id = entry;
++ enc->name = malloc(strlen(norm) + strlen(input) + 2);
++ if (!enc->name)
++ return -1;
++
++ enc->width = width;
++ enc->height = height;
++ enc->rate.numerator = n;
++ enc->rate.denominator = d * 2; /* Refresh rate is twice, due to interlace */
++ sprintf(enc->name,"%s-%s",norm,fixname(input));
++
++ xf86Msg(X_INFO, "v4l: adding input %s, %dx%d %d fps\n",
++ enc->name, enc->width, enc->height, (d + n - 1)/n);
++
+ return 0;
+ }
+
++static int
++V4LGetStd(PortPrivPtr p, int fd)
++{
++ struct v4l2_standard standard;
++ int entries = 0;
++
++ /*
++ * 128 is just an arbitrary large number. There aren't that many video stds
++ * The max value is there just to avoid an endless loop, if the driver is
++ * broken.
++ */
++ for (entries = 0; entries < 128; entries++) {
++ memset(&standard, 0, sizeof(standard));
++ standard.index = entries;
++ if (-1 == ioctl(fd,VIDIOC_ENUMSTD, &standard))
++ break;
++ p->standard = realloc(p->standard, sizeof(standard) * (entries + 1));
++ memcpy(&p->standard[entries], &standard, sizeof(standard));
++ }
++
++ /*
++ * Some webcam drivers don't implement VIDIOC_ENUMSTD. Fake it
++ * This is currently unused, as no webcam driver allows OVERLAY mode,
++ * but the code is here, in the case some webcam driver starts allowing
++ * overlay.
++ * FIXME: Webcam drivers may use VIDIOC_ENUM_FRAMESIZES and
++ * VIDIOC_ENUM_FRAMEINTERVALS ioctl's that may help to fine-tune
++ * their needs. Those ioctl's could be used here in order to better
++ * support webcams.
++ */
++ if (!entries) {
++ xf86Msg(X_INFO, "v4l: VIDIOC_ENUMSTD error %d.\n",errno);
++ p->standard = realloc(p->standard, sizeof(standard) * (entries + 1));
++ p->standard[0].id = V4L2_STD_ALL;
++ strcpy((char *)p->standard[0].name, "CAMERA");
++ p->standard[0].frameperiod.numerator = 1001;
++ p->standard[0].frameperiod.denominator = 300001;
++ p->standard[0].framelines = 480;
++ entries++;
++ }
++ return entries;
++}
++
+ static void
+-V4LBuildEncodings(PortPrivPtr p, int fd, int channels)
++V4LBuildEncodings(PortPrivPtr p, int fd)
+ {
+- static struct video_channel channel;
+- int i,entries,have_bttv,bttv_ver;
+-
+-#define BTTV_VERSION _IOR('v' , BASE_VIDIOCPRIVATE+6, int)
+- have_bttv = 0;
+- if (-1 != ioctl(fd,BTTV_VERSION,&bttv_ver))
+- have_bttv = 1;
+-
+- entries = (have_bttv ? 7 : 3) * channels;
+- p->enc = xalloc(sizeof(XF86VideoEncodingRec) * entries);
+- if (NULL == p->enc)
+- goto fail;
+- memset(p->enc,0,sizeof(XF86VideoEncodingRec) * entries);
+- p->norm = xalloc(sizeof(int) * entries);
+- if (NULL == p->norm)
+- goto fail;
+- memset(p->norm,0,sizeof(int) * entries);
+- p->input = xalloc(sizeof(int) * entries);
+- if (NULL == p->input)
+- goto fail;
+- memset(p->input,0,sizeof(int) * entries);
++ unsigned int inp, std, num_std;
++
++ num_std = V4LGetStd(p, fd);
+
+ p->nenc = 0;
+- for (i = 0; i < channels; i++) {
+- channel.channel = i;
+- if (-1 == ioctl(fd,VIDIOCGCHAN,&channel)) {
+- perror("ioctl VIDIOCGCHAN");
+- continue;
+- }
+-
+- v4l_add_enc(p->enc, p->nenc,"PAL", channel.name, 768,576, 1,50);
+- p->norm[p->nenc] = VIDEO_MODE_PAL;
+- p->input[p->nenc] = i;
+- p->nenc++;
+-
+- v4l_add_enc(p->enc,p->nenc,"NTSC", channel.name, 640,480, 1001,60000);
+- p->norm[p->nenc] = VIDEO_MODE_NTSC;
+- p->input[p->nenc] = i;
+- p->nenc++;
+-
+- v4l_add_enc(p->enc,p->nenc,"SECAM",channel.name, 768,576, 1,50);
+- p->norm[p->nenc] = VIDEO_MODE_SECAM;
+- p->input[p->nenc] = i;
+- p->nenc++;
+-
+- if (have_bttv) {
+- /* workaround for a v4l design flaw: The v4l API knows just pal,
+- ntsc and secam. But there are a few more norms (pal versions
+- with a different timings used in south america for example).
+- The bttv driver can handle these too. */
+- if (0 != v4l_add_enc(p->enc,p->nenc,"PAL-Nc",channel.name,
+- 640, 576, 1,50))
+- goto fail;
+- p->norm[p->nenc] = 3;
+- p->input[p->nenc] = i;
+- p->nenc++;
+-
+- if (0 != v4l_add_enc(p->enc,p->nenc,"PAL-M",channel.name,
+- 640, 576, 1,50))
+- goto fail;
+- p->norm[p->nenc] = 4;
+- p->input[p->nenc] = i;
+- p->nenc++;
+-
+- if (0 != v4l_add_enc(p->enc, p->nenc,"PAL-N", channel.name,
+- 768,576, 1,50))
+- goto fail;
+- p->norm[p->nenc] = 5;
+- p->input[p->nenc] = i;
+- p->nenc++;
+-
+- if (0 != v4l_add_enc(p->enc,p->nenc,"NTSC-JP", channel.name,
+- 640,480, 1001,60000))
+- goto fail;
+- p->norm[p->nenc] = 6;
+- p->input[p->nenc] = i;
+- p->nenc++;
+- }
++
++ /*
++ * 256 is just an arbitrary large number. There aren't that many video
++ * inputs on any driver. The max value is there just to avoid an endless
++ * loop, if the driver is broken.
++ */
++ for (inp = 0; inp < 256; inp++) {
++ struct v4l2_input input;
++
++ memset(&input, 0, sizeof(input));
++ input.index = inp;
++ if (ioctl(fd, VIDIOC_ENUMINPUT, &input) == -1)
++ break;
++
++ for (std = 0; std < num_std; std++) {
++ int width, height;
++
++ /*
++ * Currently, this code is not reliable, due to driver
++ * non-compliance on both saa7134 and bttv. So, instead,
++ * just use the video standard information
++ */
++#if 0
++ struct v4l2_framebuffer fbuf;
++
++ /* Some webcam drivers will fail here, but that's OK */
++ ioctl(fd, VIDIOC_S_STD, &p->standard[std].id);
++
++ memset(&fbuf, 0, sizeof(fbuf));
++ if (ioctl(fd, VIDIOC_G_FBUF, &fbuf) == -1) {
++ xf86Msg(X_INFO, "v4l: Error %d: Can't get FBUF\n", errno);
++ return;
++ }
++ height = fbuf.fmt.height;
++ width = fbuf.fmt.width;
++
++ /*
++ * If the overlay method fails, get the resolution
++ * via checking V4L2_BUF_TYPE_VIDEO_CAPTURE
++ */
++ if (!height || !width) {
++ struct v4l2_format format;
++
++ format.type = V4L2_BUF_TYPE_VIDEO_CAPTURE;
++ if (ioctl(fd, VIDIOC_G_FMT, &format) == -1) {
++ /* Hmm... device doesn't support capture. */
++ height = p->standard[std].framelines;
++ if (height == 480)
++ width = 640;
++ else if (height == 576)
++ width = 768;
++ else
++ continue;
++ } else {
++ height = format.fmt.pix.height;
++ width = format.fmt.pix.width;
++ }
++ }
++#else
++ if (p->standard[std].id & V4L2_STD_525_60) {
++ height = 480;
++ width = 640;
++ } else {
++ height = 576;
++ width = 768;
++ }
++
++#endif
++ /* Fixup for some driver bug */
++ if ((p->standard[std].id & V4L2_STD_525_60) && (height == 576))
++ height = 480;
++
++ p->enc = realloc(p->enc, sizeof(XF86VideoEncodingRec) * (p->nenc + 1));
++ p->norm = realloc(p->norm, sizeof(int) * (p->nenc + 1));
++ p->input = realloc(p->input, sizeof(int) * (p->nenc + 1));
++ if (!p->enc || !p->norm || !p->input)
++ goto fail;
++ if (AddV4LEnc(&p->enc[p->nenc], p->nenc,
++ (char *)p->standard[std].name,
++ (char *)input.name, width, height,
++ p->standard[std].frameperiod.numerator,
++ p->standard[std].frameperiod.denominator))
++ goto fail;
++ p->norm[p->nenc] = p->standard[std].id;
++ p->input[p->nenc] = inp;
++ p->nenc++;
++ }
+ }
++
++ if (!p->nenc)
++ xf86Msg(X_ERROR, "v4l: couldn't detect any valid input/standard\n");
+ return;
+-
+- fail:
++
++fail:
++ xf86Msg(X_ERROR, "v4l: Fail to get standards: %d\n", errno);
+ if (p->input)
+- xfree(p->input);
++ free(p->input);
+ p->input = NULL;
+ if (p->norm)
+- xfree(p->norm);
++ free(p->norm);
+ p->norm = NULL;
+ if (p->enc)
+- xfree(p->enc);
++ free(p->enc);
+ p->enc = NULL;
+ p->nenc = 0;
+ }
+@@ -826,73 +1094,33 @@ V4LBuildEncodings(PortPrivPtr p, int fd, int channels)
+ /* add a attribute a list */
+ static void
+ v4l_add_attr(XF86AttributeRec **list, int *count,
+- const XF86AttributeRec *attr)
++ const XF86AttributeRec *attr)
+ {
+ XF86AttributeRec *oldlist = *list;
+ int i;
++ Atom gpa;
+
+ for (i = 0; i < *count; i++) {
+- if (0 == strcmp((*list)[i].name,attr->name)) {
+- DEBUG(xf86Msg(X_INFO, "v4l: skip dup attr %s\n",attr->name));
+- return;
+- }
++ if (0 == strcmp((*list)[i].name,attr->name)) {
++ DEBUG(xf86Msg(X_INFO, "v4l: skip dup attr %s\n",attr->name));
++ return;
++ }
+ }
+-
+- DEBUG(xf86Msg(X_INFO, "v4l: add attr %s\n",attr->name));
+- *list = xalloc((*count + 1) * sizeof(XF86AttributeRec));
++
++ *list = malloc((*count + 1) * sizeof(XF86AttributeRec));
+ if (NULL == *list) {
+- *count = 0;
+- return;
++ *count = 0;
++ return;
+ }
+ if (*count)
+- memcpy(*list, oldlist, *count * sizeof(XF86AttributeRec));
++ memcpy(*list, oldlist, *count * sizeof(XF86AttributeRec));
+ memcpy(*list + *count, attr, sizeof(XF86AttributeRec));
+- (*count)++;
+-}
+
+-/* setup yuv overlay + hw scaling: look if we find some common video
+- format which both v4l driver and the X-Server can handle */
+-static void v4l_check_yuv(ScrnInfoPtr pScrn, PortPrivPtr pPPriv,
+- char *dev, int fd)
+-{
+- static const struct {
+- unsigned int v4l_palette;
+- unsigned int v4l_depth;
+- unsigned int xv_id;
+- unsigned int xv_format;
+- } yuvlist[] = {
+- { VIDEO_PALETTE_YUV422, 16, 0x32595559, XvPacked },
+- { VIDEO_PALETTE_UYVY, 16, 0x59565955, XvPacked },
+- { 0 /* end of list */ },
+- };
+- ScreenPtr pScreen = screenInfo.screens[pScrn->scrnIndex];
+- int fmt,i;
++ gpa = MAKE_ATOM((*list)[*count].name);
++ xf86Msg(X_INFO, "v4l: add attr %s (Xv/GPA %d) (%d to %d)\n",
++ attr->name, (int)gpa, attr->min_value, attr->max_value);
+
+- pPPriv->format = xf86XVQueryOffscreenImages(pScreen,&pPPriv->nformat);
+- for (fmt = 0; yuvlist[fmt].v4l_palette != 0; fmt++) {
+- /* check v4l ... */
+- ioctl(fd,VIDIOCGPICT,&pPPriv->pict);
+- pPPriv->pict.palette = yuvlist[fmt].v4l_palette;
+- pPPriv->pict.depth = yuvlist[fmt].v4l_depth;
+- if (-1 == ioctl(fd,VIDIOCSPICT,&pPPriv->pict))
+- continue;
+- ioctl(fd,VIDIOCGPICT,&pPPriv->pict);
+- if (pPPriv->pict.palette != yuvlist[fmt].v4l_palette)
+- continue;
+- /* ... works, check available offscreen image formats now ... */
+- for (i = 0; i < pPPriv->nformat; i++) {
+- if (pPPriv->format[i].image->id == yuvlist[fmt].xv_id &&
+- pPPriv->format[i].image->format == yuvlist[fmt].xv_format) {
+- /* ... match found, good. */
+- pPPriv->yuv_format = yuvlist[fmt].v4l_palette;
+- pPPriv->myfmt = pPPriv->format+i;
+- xf86DrvMsg(pScrn->scrnIndex, X_INFO,
+- "v4l[%s]: using hw video scaling [%4.4s].\n",
+- dev,(char*)&(pPPriv->format[i].image->id));
+- return;
+- }
+- }
+- }
++ (*count)++;
+ }
+
+ static int
+@@ -904,118 +1132,114 @@ V4LInit(ScrnInfoPtr pScrn, XF86VideoAdaptorPtr **adaptors)
+ char dev[18];
+ int fd,i,j,d;
+
+- DEBUG(xf86Msg(X_INFO, "v4l: init start\n"));
+-
+ for (i = 0, d = 0; d < MAX_V4L_DEVICES; d++) {
+- sprintf(dev, "/dev/video%d", d);
+- fd = open(dev, O_RDWR, 0);
+- if (fd == -1) {
+- sprintf(dev, "/dev/v4l/video%d", d);
+- fd = open(dev, O_RDWR, 0);
+- if (fd == -1)
+- break;
+- }
+- DEBUG(xf86Msg(X_INFO, "v4l: %s open ok\n",dev));
+-
+- /* our private data */
+- pPPriv = xalloc(sizeof(PortPrivRec));
+- if (!pPPriv)
+- return FALSE;
+- memset(pPPriv,0,sizeof(PortPrivRec));
+- pPPriv->nr = d;
+-
+- /* check device */
+- if (-1 == ioctl(fd,VIDIOCGCAP,&pPPriv->cap) ||
+- 0 == (pPPriv->cap.type & VID_TYPE_OVERLAY)) {
+- DEBUG(xf86Msg(X_INFO, "v4l: %s: no overlay support\n",dev));
+- xfree(pPPriv);
+- close(fd);
+- continue;
+- }
+- strncpy(V4L_NAME, dev, 16);
+- V4LBuildEncodings(pPPriv,fd,pPPriv->cap.channels);
+- if (NULL == pPPriv->enc)
+- return FALSE;
+- v4l_check_yuv(pScrn,pPPriv,dev,fd);
+-
+- /* alloc VideoAdaptorRec */
+- VAR = xrealloc(VAR,sizeof(XF86VideoAdaptorPtr)*(i+1));
+- VAR[i] = xalloc(sizeof(XF86VideoAdaptorRec));
+- if (!VAR[i])
+- return FALSE;
+- memset(VAR[i],0,sizeof(XF86VideoAdaptorRec));
+-
+-
+- /* build attribute list */
+- for (j = 0; j < V4L_ATTR; j++) {
+- /* video attributes */
+- v4l_add_attr(&VAR[i]->pAttributes, &VAR[i]->nAttributes,
+- &Attributes[j]);
+- }
+- if (0 == ioctl(fd,VIDIOCGAUDIO,&pPPriv->audio)) {
+- /* audio attributes */
+- if (pPPriv->audio.flags & VIDEO_AUDIO_VOLUME)
+- v4l_add_attr(&VAR[i]->pAttributes, &VAR[i]->nAttributes,
+- &VolumeAttr);
+- if (pPPriv->audio.flags & VIDEO_AUDIO_MUTABLE)
+- v4l_add_attr(&VAR[i]->pAttributes, &VAR[i]->nAttributes,
+- &MuteAttr);
+- }
+- if (pPPriv->cap.type & VID_TYPE_TUNER) {
+- /* tuner attributes */
+- v4l_add_attr(&VAR[i]->pAttributes, &VAR[i]->nAttributes,
+- &FreqAttr);
+- }
+- if (0 != pPPriv->yuv_format) {
+- /* pass throuth scaler attributes */
+- for (j = 0; j < pPPriv->myfmt->num_attributes; j++) {
+- v4l_add_attr(&VAR[i]->pAttributes, &VAR[i]->nAttributes,
+- pPPriv->myfmt->attributes+j);
+- }
+- }
+-
+-
+- /* hook in private data */
+- Private = xalloc(sizeof(DevUnion));
+- if (!Private)
+- return FALSE;
+- memset(Private,0,sizeof(DevUnion));
+- Private->ptr = (pointer)pPPriv;
+- VAR[i]->pPortPrivates = Private;
+- VAR[i]->nPorts = 1;
+-
+- /* init VideoAdaptorRec */
+- VAR[i]->type = XvInputMask | XvWindowMask | XvVideoMask;
+- VAR[i]->name = "video4linux";
+- VAR[i]->flags = VIDEO_INVERT_CLIPLIST;
+-
+- VAR[i]->PutVideo = V4lPutVideo;
+- VAR[i]->PutStill = V4lPutStill;
+- VAR[i]->StopVideo = V4lStopVideo;
+- VAR[i]->SetPortAttribute = V4lSetPortAttribute;
+- VAR[i]->GetPortAttribute = V4lGetPortAttribute;
+- VAR[i]->QueryBestSize = V4lQueryBestSize;
+-
+- VAR[i]->nEncodings = pPPriv->nenc;
+- VAR[i]->pEncodings = pPPriv->enc;
+- VAR[i]->nFormats =
+- sizeof(InputVideoFormats) / sizeof(InputVideoFormats[0]);
+- VAR[i]->pFormats = InputVideoFormats;
+-
+- if (fd != -1)
+- close(fd);
+- i++;
++ sprintf(dev, "/dev/video%d", d);
++ fd = open(dev, O_RDWR, 0);
++ if (fd == -1) {
++ sprintf(dev, "/dev/v4l/video%d", d);
++ fd = open(dev, O_RDWR, 0);
++ if (fd == -1)
++ break;
++ }
++ DEBUG(xf86Msg(X_INFO, "v4l: %s open ok\n",dev));
++
++ /* our private data */
++ pPPriv = malloc(sizeof(PortPrivRec));
++ if (!pPPriv)
++ return FALSE;
++ memset(pPPriv,0,sizeof(PortPrivRec));
++ pPPriv->nr = d;
++
++ /* check device capabilities */
++ memset(&pPPriv->cap, 0, sizeof(&pPPriv->cap));
++ if (-1 == ioctl(fd, VIDIOC_QUERYCAP, &pPPriv->cap) ||
++ 0 == (pPPriv->cap.capabilities & V4L2_CAP_VIDEO_OVERLAY)) {
++ xf86Msg(X_ERROR, "v4l: %s: no overlay support\n",dev);
++ free(pPPriv);
++ close(fd);
++ continue;
++ }
++
++ if (v4l_check_yuv(pScrn, pPPriv, dev, fd) == FALSE) {
++ xf86DrvMsgVerb(pScrn->scrnIndex, X_INFO, 2,
++ "Xv Overlay not supported. Can't use v4l driver\n");
++ free(pPPriv);
++ close(fd);
++ continue;
++ }
++
++ xf86Msg(X_INFO, "v4l: enabling overlay mode for %s.\n", dev);
++ strncpy(V4L_NAME, dev, 16);
++ V4LBuildEncodings(pPPriv, fd);
++ if (NULL == pPPriv->enc)
++ return FALSE;
++
++ /* alloc VideoAdaptorRec */
++ VAR = realloc(VAR,sizeof(XF86VideoAdaptorPtr)*(i+1));
++ VAR[i] = malloc(sizeof(XF86VideoAdaptorRec));
++ if (!VAR[i])
++ return FALSE;
++ memset(VAR[i],0,sizeof(XF86VideoAdaptorRec));
++
++ /* build attribute list */
++ AddAllV4LControls(pPPriv, &VAR[i]->pAttributes, &VAR[i]->nAttributes, fd);
++
++ for (j = 0; j < V4L_ATTR; j++) {
++ /* Other video attributes */
++ v4l_add_attr(&VAR[i]->pAttributes, &VAR[i]->nAttributes,
++ &Attributes[j]);
++ }
++ if (pPPriv->cap.capabilities & V4L2_CAP_TUNER) {
++ /* tuner attributes */
++ v4l_add_attr(&VAR[i]->pAttributes, &VAR[i]->nAttributes,
++ &FreqAttr);
++ }
++
++ /* Initialize yuv_format */
++ if (0 != pPPriv->yuv_format) {
++ /* pass throuth scaler attributes */
++ for (j = 0; j < pPPriv->myfmt->num_attributes; j++) {
++ v4l_add_attr(&VAR[i]->pAttributes, &VAR[i]->nAttributes,
++ pPPriv->myfmt->attributes+j);
++ }
++ }
++
++ DEBUG(xf86Msg(X_INFO, "v4l: saving config into driver data\n"));
++ /* hook in private data */
++ Private = malloc(sizeof(DevUnion));
++ if (!Private)
++ return FALSE;
++ memset(Private,0,sizeof(DevUnion));
++ Private->ptr = (pointer)pPPriv;
++ VAR[i]->pPortPrivates = Private;
++ VAR[i]->nPorts = 1;
++
++ /* init VideoAdaptorRec */
++ VAR[i]->type = XvInputMask | XvWindowMask | XvVideoMask;
++ VAR[i]->name = "video4linux";
++ VAR[i]->flags = VIDEO_INVERT_CLIPLIST;
++
++ VAR[i]->PutVideo = V4lPutVideo;
++ VAR[i]->PutStill = V4lPutStill;
++ VAR[i]->StopVideo = V4lStopVideo;
++ VAR[i]->SetPortAttribute = V4lSetPortAttribute;
++ VAR[i]->GetPortAttribute = V4lGetPortAttribute;
++ VAR[i]->QueryBestSize = V4lQueryBestSize;
++
++ VAR[i]->nEncodings = pPPriv->nenc;
++ VAR[i]->pEncodings = pPPriv->enc;
++ VAR[i]->nFormats = sizeof(InputVideoFormats) / sizeof(InputVideoFormats[0]);
++ VAR[i]->pFormats = InputVideoFormats;
++
++ if (fd != -1) {
++ DEBUG(xf86Msg(X_INFO, "v4l: %s init finished.\n",dev));
++ close(fd);
++ }
++ i++;
+ }
+
+ xvEncoding = MAKE_ATOM(XV_ENCODING);
+- xvHue = MAKE_ATOM(XV_HUE);
+- xvSaturation = MAKE_ATOM(XV_SATURATION);
+- xvBrightness = MAKE_ATOM(XV_BRIGHTNESS);
+- xvContrast = MAKE_ATOM(XV_CONTRAST);
+-
+ xvFreq = MAKE_ATOM(XV_FREQ);
+- xvMute = MAKE_ATOM(XV_MUTE);
+- xvVolume = MAKE_ATOM(XV_VOLUME);
+
+ DEBUG(xf86Msg(X_INFO, "v4l: init done, %d device(s) found\n",i));
+
+@@ -1024,10 +1248,43 @@ V4LInit(ScrnInfoPtr pScrn, XF86VideoAdaptorPtr **adaptors)
+ }
+
+ static Bool
++V4LDetect(void)
++{
++ struct v4l2_capability cap;
++ int fd, d, n = 0;
++ char dev[18];
++
++ for (d = 0; d < MAX_V4L_DEVICES; d++) {
++ sprintf(dev, "/dev/video%d", d);
++ fd = open(dev, O_RDWR, 0);
++ if (fd == -1) {
++ sprintf(dev, "/dev/v4l/video%d", d);
++ fd = open(dev, O_RDWR, 0);
++ if (fd == -1)
++ break;
++ }
++ close (fd);
++ memset(&cap, 0, sizeof(cap));
++ if (!ioctl(fd, VIDIOC_QUERYCAP, &cap) &&
++ (cap.capabilities & V4L2_CAP_VIDEO_OVERLAY))
++ n++;
++ }
++ xf86Msg(X_INFO, "v4l: %d video adapters with overlay support detected\n", n);
++
++ return (n > 0) ? TRUE : FALSE;
++}
++
++static Bool
+ V4LProbe(DriverPtr drv, int flags)
+ {
+- if (flags & PROBE_DETECT)
+- return TRUE;
++ /*
++ * Don't try to register adapter at the detection phase, as Xv
++ * extensions won't be there
++ */
++ if (flags == PROBE_DETECT)
++ return V4LDetect();
++
++ DEBUG(xf86Msg(X_INFO, "v4l: Initiating device probe\n"));
+
+ xf86XVRegisterGenericAdaptorDriver(V4LInit);
+ drv->refCount++;
+diff --git a/src/videodev.h b/src/videodev.h
+deleted file mode 100644
+index 3c9a7d8..0000000
+--- a/src/videodev.h
++++ /dev/null
+@@ -1,254 +0,0 @@
+-#ifndef __LINUX_VIDEODEV_H
+-#define __LINUX_VIDEODEV_H
+-
+-/* Linux V4L API, Version 1
+- * videodev.h from v4l driver in Linux 2.2.3
+- *
+- * Used here with the explicit permission of the original author, Alan Cox.
+- * <alan@lxorguk.ukuu.org.uk>
+- */
+-
+-#include <X11/Xmd.h>
+-
+-#define VID_TYPE_CAPTURE 1 /* Can capture */
+-#define VID_TYPE_TUNER 2 /* Can tune */
+-#define VID_TYPE_TELETEXT 4 /* Does teletext */
+-#define VID_TYPE_OVERLAY 8 /* Overlay onto frame buffer */
+-#define VID_TYPE_CHROMAKEY 16 /* Overlay by chromakey */
+-#define VID_TYPE_CLIPPING 32 /* Can clip */
+-#define VID_TYPE_FRAMERAM 64 /* Uses the frame buffer memory */
+-#define VID_TYPE_SCALES 128 /* Scalable */
+-#define VID_TYPE_MONOCHROME 256 /* Monochrome only */
+-#define VID_TYPE_SUBCAPTURE 512 /* Can capture subareas of the image */
+-
+-struct video_capability
+-{
+- char name[32];
+- int type;
+- int channels; /* Num channels */
+- int audios; /* Num audio devices */
+- int maxwidth; /* Supported width */
+- int maxheight; /* And height */
+- int minwidth; /* Supported width */
+- int minheight; /* And height */
+-};
+-
+-
+-struct video_channel
+-{
+- int channel;
+- char name[32];
+- int tuners;
+- CARD32 flags;
+-#define VIDEO_VC_TUNER 1 /* Channel has a tuner */
+-#define VIDEO_VC_AUDIO 2 /* Channel has audio */
+- CARD16 type;
+-#define VIDEO_TYPE_TV 1
+-#define VIDEO_TYPE_CAMERA 2
+- CARD16 norm; /* Norm set by channel */
+-};
+-
+-struct video_tuner
+-{
+- int tuner;
+- char name[32];
+- unsigned long rangelow, rangehigh; /* Tuner range */
+- CARD32 flags;
+-#define VIDEO_TUNER_PAL 1
+-#define VIDEO_TUNER_NTSC 2
+-#define VIDEO_TUNER_SECAM 4
+-#define VIDEO_TUNER_LOW 8 /* Uses KHz not MHz */
+-#define VIDEO_TUNER_NORM 16 /* Tuner can set norm */
+-#define VIDEO_TUNER_STEREO_ON 128 /* Tuner is seeing stereo */
+- CARD16 mode; /* PAL/NTSC/SECAM/OTHER */
+-#define VIDEO_MODE_PAL 0
+-#define VIDEO_MODE_NTSC 1
+-#define VIDEO_MODE_SECAM 2
+-#define VIDEO_MODE_AUTO 3
+- CARD16 signal; /* Signal strength 16bit scale */
+-};
+-
+-struct video_picture
+-{
+- CARD16 brightness;
+- CARD16 hue;
+- CARD16 colour;
+- CARD16 contrast;
+- CARD16 whiteness; /* Black and white only */
+- CARD16 depth; /* Capture depth */
+- CARD16 palette; /* Palette in use */
+-#define VIDEO_PALETTE_GREY 1 /* Linear greyscale */
+-#define VIDEO_PALETTE_HI240 2 /* High 240 cube (BT848) */
+-#define VIDEO_PALETTE_RGB565 3 /* 565 16 bit RGB */
+-#define VIDEO_PALETTE_RGB24 4 /* 24bit RGB */
+-#define VIDEO_PALETTE_RGB32 5 /* 32bit RGB */
+-#define VIDEO_PALETTE_RGB555 6 /* 555 15bit RGB */
+-#define VIDEO_PALETTE_YUV422 7 /* YUV422 capture */
+-#define VIDEO_PALETTE_YUYV 8
+-#define VIDEO_PALETTE_UYVY 9 /* The great thing about standards is ... */
+-#define VIDEO_PALETTE_YUV420 10
+-#define VIDEO_PALETTE_YUV411 11 /* YUV411 capture */
+-#define VIDEO_PALETTE_RAW 12 /* RAW capture (BT848) */
+-#define VIDEO_PALETTE_YUV422P 13 /* YUV 4:2:2 Planar */
+-#define VIDEO_PALETTE_YUV411P 14 /* YUV 4:1:1 Planar */
+-#define VIDEO_PALETTE_YUV420P 15 /* YUV 4:2:0 Planar */
+-#define VIDEO_PALETTE_YUV410P 16 /* YUV 4:1:0 Planar */
+-#define VIDEO_PALETTE_PLANAR 13 /* start of planar entries */
+-#define VIDEO_PALETTE_COMPONENT 7 /* start of component entries */
+-};
+-
+-struct video_audio
+-{
+- int audio; /* Audio channel */
+- CARD16 volume; /* If settable */
+- CARD16 bass, treble;
+- CARD32 flags;
+-#define VIDEO_AUDIO_MUTE 1
+-#define VIDEO_AUDIO_MUTABLE 2
+-#define VIDEO_AUDIO_VOLUME 4
+-#define VIDEO_AUDIO_BASS 8
+-#define VIDEO_AUDIO_TREBLE 16
+- char name[16];
+-#define VIDEO_SOUND_MONO 1
+-#define VIDEO_SOUND_STEREO 2
+-#define VIDEO_SOUND_LANG1 4
+-#define VIDEO_SOUND_LANG2 8
+- CARD16 mode;
+- CARD16 balance; /* Stereo balance */
+- CARD16 step; /* Step actual volume uses */
+-};
+-
+-struct video_clip
+-{
+- INT32 x,y;
+- INT32 width, height;
+- struct video_clip *next; /* For user use/driver use only */
+-};
+-
+-struct video_window
+-{
+- CARD32 x,y; /* Position of window */
+- CARD32 width,height; /* Its size */
+- CARD32 chromakey;
+- CARD32 flags;
+- struct video_clip *clips; /* Set only */
+- int clipcount;
+-#define VIDEO_WINDOW_INTERLACE 1
+-#define VIDEO_CLIP_BITMAP -1
+-/* bitmap is 1024x625, a '1' bit represents a clipped pixel */
+-#define VIDEO_CLIPMAP_SIZE (128 * 625)
+-};
+-
+-struct video_capture
+-{
+- CARD32 x,y; /* Offsets into image */
+- CARD32 width, height; /* Area to capture */
+- CARD16 decimation; /* Decimation divder */
+- CARD16 flags; /* Flags for capture */
+-#define VIDEO_CAPTURE_ODD 0 /* Temporal */
+-#define VIDEO_CAPTURE_EVEN 1
+-};
+-
+-struct video_buffer
+-{
+- void *base;
+- int height,width;
+- int depth;
+- int bytesperline;
+-};
+-
+-struct video_mmap
+-{
+- unsigned int frame; /* Frame (0 - n) for double buffer */
+- int height,width;
+- unsigned int format; /* should be VIDEO_PALETTE_* */
+-};
+-
+-struct video_key
+-{
+- CARD8 key[8];
+- CARD32 flags;
+-};
+-
+-
+-#define VIDEO_MAX_FRAME 32
+-
+-struct video_mbuf
+-{
+- int size; /* Total memory to map */
+- int frames; /* Frames */
+- int offsets[VIDEO_MAX_FRAME];
+-};
+-
+-
+-#define VIDEO_NO_UNIT (-1)
+-
+-
+-struct video_unit
+-{
+- int video; /* Video minor */
+- int vbi; /* VBI minor */
+- int radio; /* Radio minor */
+- int audio; /* Audio minor */
+- int teletext; /* Teletext minor */
+-};
+-
+-#define VIDIOCGCAP _IOR('v',1,struct video_capability) /* Get capabilities */
+-#define VIDIOCGCHAN _IOWR('v',2,struct video_channel) /* Get channel info (sources) */
+-#define VIDIOCSCHAN _IOW('v',3,struct video_channel) /* Set channel */
+-#define VIDIOCGTUNER _IOWR('v',4,struct video_tuner) /* Get tuner abilities */
+-#define VIDIOCSTUNER _IOW('v',5,struct video_tuner) /* Tune the tuner for the current channel */
+-#define VIDIOCGPICT _IOR('v',6,struct video_picture) /* Get picture properties */
+-#define VIDIOCSPICT _IOW('v',7,struct video_picture) /* Set picture properties */
+-#define VIDIOCCAPTURE _IOW('v',8,int) /* Start, end capture */
+-#define VIDIOCGWIN _IOR('v',9, struct video_window) /* Set the video overlay window */
+-#define VIDIOCSWIN _IOW('v',10, struct video_window) /* Set the video overlay window - passes clip list for hardware smarts , chromakey etc */
+-#define VIDIOCGFBUF _IOR('v',11, struct video_buffer) /* Get frame buffer */
+-#define VIDIOCSFBUF _IOW('v',12, struct video_buffer) /* Set frame buffer - root only */
+-#define VIDIOCKEY _IOR('v',13, struct video_key) /* Video key event - to dev 255 is to all - cuts capture on all DMA windows with this key (0xFFFFFFFF == all) */
+-#define VIDIOCGFREQ _IOR('v',14, unsigned long) /* Set tuner */
+-#define VIDIOCSFREQ _IOW('v',15, unsigned long) /* Set tuner */
+-#define VIDIOCGAUDIO _IOR('v',16, struct video_audio) /* Get audio info */
+-#define VIDIOCSAUDIO _IOW('v',17, struct video_audio) /* Audio source, mute etc */
+-#define VIDIOCSYNC _IOW('v',18, int) /* Sync with mmap grabbing */
+-#define VIDIOCMCAPTURE _IOW('v',19, struct video_mmap) /* Grab frames */
+-#define VIDIOCGMBUF _IOR('v', 20, struct video_mbuf) /* Memory map buffer info */
+-#define VIDIOCGUNIT _IOR('v', 21, struct video_unit) /* Get attached units */
+-#define VIDIOCGCAPTURE _IOR('v',22, struct video_capture) /* Get frame buffer */
+-#define VIDIOCSCAPTURE _IOW('v',23, struct video_capture) /* Set frame buffer - root only */
+-
+-#define BASE_VIDIOCPRIVATE 192 /* 192-255 are private */
+-
+-
+-#define VID_HARDWARE_BT848 1
+-#define VID_HARDWARE_QCAM_BW 2
+-#define VID_HARDWARE_PMS 3
+-#define VID_HARDWARE_QCAM_C 4
+-#define VID_HARDWARE_PSEUDO 5
+-#define VID_HARDWARE_SAA5249 6
+-#define VID_HARDWARE_AZTECH 7
+-#define VID_HARDWARE_SF16MI 8
+-#define VID_HARDWARE_RTRACK 9
+-#define VID_HARDWARE_ZOLTRIX 10
+-#define VID_HARDWARE_SAA7146 11
+-#define VID_HARDWARE_VIDEUM 12 /* Reserved for Winnov videum */
+-#define VID_HARDWARE_RTRACK2 13
+-#define VID_HARDWARE_PERMEDIA2 14 /* Reserved for Permedia2 */
+-#define VID_HARDWARE_RIVA128 15 /* Reserved for RIVA 128 */
+-#define VID_HARDWARE_PLANB 16 /* PowerMac motherboard video-in */
+-#define VID_HARDWARE_BROADWAY 17 /* Broadway project */
+-#define VID_HARDWARE_GEMTEK 18
+-#define VID_HARDWARE_TYPHOON 19
+-#define VID_HARDWARE_VINO 20 /* Reserved for SGI Indy Vino */
+-
+-/*
+- * Initialiser list
+- */
+-
+-struct video_init
+-{
+- char *name;
+- int (*init)(struct video_init *);
+-};
+-
+-#endif
+diff --git a/src/videodev2.h b/src/videodev2.h
+new file mode 100644
+index 0000000..bf6dde2
+--- /dev/null
++++ b/src/videodev2.h
+@@ -0,0 +1,1929 @@
++/*
++ * Video for Linux Two header file
++ *
++ * Copyright (C) 1999-2007 the contributors
++ *
++ * This program is free software; you can 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 of the License, or
++ * (at your option) any later version.
++ *
++ * This program 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.
++ *
++ * Alternatively you can redistribute this file under the terms of the
++ * BSD license as stated below:
++ *
++ * Redistribution and use in source and binary forms, with or without
++ * modification, are permitted provided that the following conditions
++ * are met:
++ * 1. Redistributions of source code must retain the above copyright
++ * notice, this list of conditions and the following disclaimer.
++ * 2. Redistributions in binary form must reproduce the above copyright
++ * notice, this list of conditions and the following disclaimer in
++ * the documentation and/or other materials provided with the
++ * distribution.
++ * 3. The names of its contributors may not be used to endorse or promote
++ * products derived from this software without specific prior written
++ * permission.
++ *
++ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
++ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
++ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
++ * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
++ * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
++ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
++ * TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
++ * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
++ * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
++ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
++ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
++ *
++ * Header file for v4l or V4L2 drivers and applications
++ * with public API.
++ * All kernel-specific stuff were moved to media/v4l2-dev.h, so
++ * no #if __KERNEL tests are allowed here
++ *
++ * See http://linuxtv.org for more info
++ *
++ * Author: Bill Dirks <bill@thedirks.org>
++ * Justin Schoeman
++ * Hans Verkuil <hverkuil@xs4all.nl>
++ * et al.
++ */
++#ifndef __LINUX_VIDEODEV2_H
++#define __LINUX_VIDEODEV2_H
++
++#include <linux/ioctl.h>
++#include <linux/types.h>
++#include <sys/time.h>
++
++/*
++ * Common stuff for both V4L1 and V4L2
++ * Moved from videodev.h
++ */
++#define VIDEO_MAX_FRAME 32
++#define VIDEO_MAX_PLANES 8
++
++/* These defines are V4L1 specific and should not be used with the V4L2 API!
++ They will be removed from this header in the future. */
++
++#define VID_TYPE_CAPTURE 1 /* Can capture */
++#define VID_TYPE_TUNER 2 /* Can tune */
++#define VID_TYPE_TELETEXT 4 /* Does teletext */
++#define VID_TYPE_OVERLAY 8 /* Overlay onto frame buffer */
++#define VID_TYPE_CHROMAKEY 16 /* Overlay by chromakey */
++#define VID_TYPE_CLIPPING 32 /* Can clip */
++#define VID_TYPE_FRAMERAM 64 /* Uses the frame buffer memory */
++#define VID_TYPE_SCALES 128 /* Scalable */
++#define VID_TYPE_MONOCHROME 256 /* Monochrome only */
++#define VID_TYPE_SUBCAPTURE 512 /* Can capture subareas of the image */
++#define VID_TYPE_MPEG_DECODER 1024 /* Can decode MPEG streams */
++#define VID_TYPE_MPEG_ENCODER 2048 /* Can encode MPEG streams */
++#define VID_TYPE_MJPEG_DECODER 4096 /* Can decode MJPEG streams */
++#define VID_TYPE_MJPEG_ENCODER 8192 /* Can encode MJPEG streams */
++
++/*
++ * M I S C E L L A N E O U S
++ */
++
++/* Four-character-code (FOURCC) */
++#define v4l2_fourcc(a, b, c, d)\
++ ((__u32)(a) | ((__u32)(b) << 8) | ((__u32)(c) << 16) | ((__u32)(d) << 24))
++
++/*
++ * E N U M S
++ */
++enum v4l2_field {
++ V4L2_FIELD_ANY = 0, /* driver can choose from none,
++ top, bottom, interlaced
++ depending on whatever it thinks
++ is approximate ... */
++ V4L2_FIELD_NONE = 1, /* this device has no fields ... */
++ V4L2_FIELD_TOP = 2, /* top field only */
++ V4L2_FIELD_BOTTOM = 3, /* bottom field only */
++ V4L2_FIELD_INTERLACED = 4, /* both fields interlaced */
++ V4L2_FIELD_SEQ_TB = 5, /* both fields sequential into one
++ buffer, top-bottom order */
++ V4L2_FIELD_SEQ_BT = 6, /* same as above + bottom-top order */
++ V4L2_FIELD_ALTERNATE = 7, /* both fields alternating into
++ separate buffers */
++ V4L2_FIELD_INTERLACED_TB = 8, /* both fields interlaced, top field
++ first and the top field is
++ transmitted first */
++ V4L2_FIELD_INTERLACED_BT = 9, /* both fields interlaced, top field
++ first and the bottom field is
++ transmitted first */
++};
++#define V4L2_FIELD_HAS_TOP(field) \
++ ((field) == V4L2_FIELD_TOP ||\
++ (field) == V4L2_FIELD_INTERLACED ||\
++ (field) == V4L2_FIELD_INTERLACED_TB ||\
++ (field) == V4L2_FIELD_INTERLACED_BT ||\
++ (field) == V4L2_FIELD_SEQ_TB ||\
++ (field) == V4L2_FIELD_SEQ_BT)
++#define V4L2_FIELD_HAS_BOTTOM(field) \
++ ((field) == V4L2_FIELD_BOTTOM ||\
++ (field) == V4L2_FIELD_INTERLACED ||\
++ (field) == V4L2_FIELD_INTERLACED_TB ||\
++ (field) == V4L2_FIELD_INTERLACED_BT ||\
++ (field) == V4L2_FIELD_SEQ_TB ||\
++ (field) == V4L2_FIELD_SEQ_BT)
++#define V4L2_FIELD_HAS_BOTH(field) \
++ ((field) == V4L2_FIELD_INTERLACED ||\
++ (field) == V4L2_FIELD_INTERLACED_TB ||\
++ (field) == V4L2_FIELD_INTERLACED_BT ||\
++ (field) == V4L2_FIELD_SEQ_TB ||\
++ (field) == V4L2_FIELD_SEQ_BT)
++
++enum v4l2_buf_type {
++ V4L2_BUF_TYPE_VIDEO_CAPTURE = 1,
++ V4L2_BUF_TYPE_VIDEO_OUTPUT = 2,
++ V4L2_BUF_TYPE_VIDEO_OVERLAY = 3,
++ V4L2_BUF_TYPE_VBI_CAPTURE = 4,
++ V4L2_BUF_TYPE_VBI_OUTPUT = 5,
++ V4L2_BUF_TYPE_SLICED_VBI_CAPTURE = 6,
++ V4L2_BUF_TYPE_SLICED_VBI_OUTPUT = 7,
++#if 1
++ /* Experimental */
++ V4L2_BUF_TYPE_VIDEO_OUTPUT_OVERLAY = 8,
++#endif
++ V4L2_BUF_TYPE_VIDEO_CAPTURE_MPLANE = 9,
++ V4L2_BUF_TYPE_VIDEO_OUTPUT_MPLANE = 10,
++ V4L2_BUF_TYPE_PRIVATE = 0x80,
++};
++
++#define V4L2_TYPE_IS_MULTIPLANAR(type) \
++ ((type) == V4L2_BUF_TYPE_VIDEO_CAPTURE_MPLANE \
++ || (type) == V4L2_BUF_TYPE_VIDEO_OUTPUT_MPLANE)
++
++#define V4L2_TYPE_IS_OUTPUT(type) \
++ ((type) == V4L2_BUF_TYPE_VIDEO_OUTPUT \
++ || (type) == V4L2_BUF_TYPE_VIDEO_OUTPUT_MPLANE \
++ || (type) == V4L2_BUF_TYPE_VIDEO_OVERLAY \
++ || (type) == V4L2_BUF_TYPE_VIDEO_OUTPUT_OVERLAY \
++ || (type) == V4L2_BUF_TYPE_VBI_OUTPUT \
++ || (type) == V4L2_BUF_TYPE_SLICED_VBI_OUTPUT)
++
++enum v4l2_tuner_type {
++ V4L2_TUNER_RADIO = 1,
++ V4L2_TUNER_ANALOG_TV = 2,
++ V4L2_TUNER_DIGITAL_TV = 3,
++};
++
++enum v4l2_memory {
++ V4L2_MEMORY_MMAP = 1,
++ V4L2_MEMORY_USERPTR = 2,
++ V4L2_MEMORY_OVERLAY = 3,
++};
++
++/* see also http://vektor.theorem.ca/graphics/ycbcr/ */
++enum v4l2_colorspace {
++ /* ITU-R 601 -- broadcast NTSC/PAL */
++ V4L2_COLORSPACE_SMPTE170M = 1,
++
++ /* 1125-Line (US) HDTV */
++ V4L2_COLORSPACE_SMPTE240M = 2,
++
++ /* HD and modern captures. */
++ V4L2_COLORSPACE_REC709 = 3,
++
++ /* broken BT878 extents (601, luma range 16-253 instead of 16-235) */
++ V4L2_COLORSPACE_BT878 = 4,
++
++ /* These should be useful. Assume 601 extents. */
++ V4L2_COLORSPACE_470_SYSTEM_M = 5,
++ V4L2_COLORSPACE_470_SYSTEM_BG = 6,
++
++ /* I know there will be cameras that send this. So, this is
++ * unspecified chromaticities and full 0-255 on each of the
++ * Y'CbCr components
++ */
++ V4L2_COLORSPACE_JPEG = 7,
++
++ /* For RGB colourspaces, this is probably a good start. */
++ V4L2_COLORSPACE_SRGB = 8,
++};
++
++enum v4l2_priority {
++ V4L2_PRIORITY_UNSET = 0, /* not initialized */
++ V4L2_PRIORITY_BACKGROUND = 1,
++ V4L2_PRIORITY_INTERACTIVE = 2,
++ V4L2_PRIORITY_RECORD = 3,
++ V4L2_PRIORITY_DEFAULT = V4L2_PRIORITY_INTERACTIVE,
++};
++
++struct v4l2_rect {
++ __s32 left;
++ __s32 top;
++ __s32 width;
++ __s32 height;
++};
++
++struct v4l2_fract {
++ __u32 numerator;
++ __u32 denominator;
++};
++
++/*
++ * D R I V E R C A P A B I L I T I E S
++ */
++struct v4l2_capability {
++ __u8 driver[16]; /* i.e. "bttv" */
++ __u8 card[32]; /* i.e. "Hauppauge WinTV" */
++ __u8 bus_info[32]; /* "PCI:" + pci_name(pci_dev) */
++ __u32 version; /* should use KERNEL_VERSION() */
++ __u32 capabilities; /* Device capabilities */
++ __u32 reserved[4];
++};
++
++/* Values for 'capabilities' field */
++#define V4L2_CAP_VIDEO_CAPTURE 0x00000001 /* Is a video capture device */
++#define V4L2_CAP_VIDEO_OUTPUT 0x00000002 /* Is a video output device */
++#define V4L2_CAP_VIDEO_OVERLAY 0x00000004 /* Can do video overlay */
++#define V4L2_CAP_VBI_CAPTURE 0x00000010 /* Is a raw VBI capture device */
++#define V4L2_CAP_VBI_OUTPUT 0x00000020 /* Is a raw VBI output device */
++#define V4L2_CAP_SLICED_VBI_CAPTURE 0x00000040 /* Is a sliced VBI capture device */
++#define V4L2_CAP_SLICED_VBI_OUTPUT 0x00000080 /* Is a sliced VBI output device */
++#define V4L2_CAP_RDS_CAPTURE 0x00000100 /* RDS data capture */
++#define V4L2_CAP_VIDEO_OUTPUT_OVERLAY 0x00000200 /* Can do video output overlay */
++#define V4L2_CAP_HW_FREQ_SEEK 0x00000400 /* Can do hardware frequency seek */
++#define V4L2_CAP_RDS_OUTPUT 0x00000800 /* Is an RDS encoder */
++
++/* Is a video capture device that supports multiplanar formats */
++#define V4L2_CAP_VIDEO_CAPTURE_MPLANE 0x00001000
++/* Is a video output device that supports multiplanar formats */
++#define V4L2_CAP_VIDEO_OUTPUT_MPLANE 0x00002000
++
++#define V4L2_CAP_TUNER 0x00010000 /* has a tuner */
++#define V4L2_CAP_AUDIO 0x00020000 /* has audio support */
++#define V4L2_CAP_RADIO 0x00040000 /* is a radio device */
++#define V4L2_CAP_MODULATOR 0x00080000 /* has a modulator */
++
++#define V4L2_CAP_READWRITE 0x01000000 /* read/write systemcalls */
++#define V4L2_CAP_ASYNCIO 0x02000000 /* async I/O */
++#define V4L2_CAP_STREAMING 0x04000000 /* streaming I/O ioctls */
++
++/*
++ * V I D E O I M A G E F O R M A T
++ */
++struct v4l2_pix_format {
++ __u32 width;
++ __u32 height;
++ __u32 pixelformat;
++ enum v4l2_field field;
++ __u32 bytesperline; /* for padding, zero if unused */
++ __u32 sizeimage;
++ enum v4l2_colorspace colorspace;
++ __u32 priv; /* private data, depends on pixelformat */
++};
++
++/* Pixel format FOURCC depth Description */
++
++/* RGB formats */
++#define V4L2_PIX_FMT_RGB332 v4l2_fourcc('R', 'G', 'B', '1') /* 8 RGB-3-3-2 */
++#define V4L2_PIX_FMT_RGB444 v4l2_fourcc('R', '4', '4', '4') /* 16 xxxxrrrr ggggbbbb */
++#define V4L2_PIX_FMT_RGB555 v4l2_fourcc('R', 'G', 'B', 'O') /* 16 RGB-5-5-5 */
++#define V4L2_PIX_FMT_RGB565 v4l2_fourcc('R', 'G', 'B', 'P') /* 16 RGB-5-6-5 */
++#define V4L2_PIX_FMT_RGB555X v4l2_fourcc('R', 'G', 'B', 'Q') /* 16 RGB-5-5-5 BE */
++#define V4L2_PIX_FMT_RGB565X v4l2_fourcc('R', 'G', 'B', 'R') /* 16 RGB-5-6-5 BE */
++#define V4L2_PIX_FMT_BGR666 v4l2_fourcc('B', 'G', 'R', 'H') /* 18 BGR-6-6-6 */
++#define V4L2_PIX_FMT_BGR24 v4l2_fourcc('B', 'G', 'R', '3') /* 24 BGR-8-8-8 */
++#define V4L2_PIX_FMT_RGB24 v4l2_fourcc('R', 'G', 'B', '3') /* 24 RGB-8-8-8 */
++#define V4L2_PIX_FMT_BGR32 v4l2_fourcc('B', 'G', 'R', '4') /* 32 BGR-8-8-8-8 */
++#define V4L2_PIX_FMT_RGB32 v4l2_fourcc('R', 'G', 'B', '4') /* 32 RGB-8-8-8-8 */
++
++/* Grey formats */
++#define V4L2_PIX_FMT_GREY v4l2_fourcc('G', 'R', 'E', 'Y') /* 8 Greyscale */
++#define V4L2_PIX_FMT_Y4 v4l2_fourcc('Y', '0', '4', ' ') /* 4 Greyscale */
++#define V4L2_PIX_FMT_Y6 v4l2_fourcc('Y', '0', '6', ' ') /* 6 Greyscale */
++#define V4L2_PIX_FMT_Y10 v4l2_fourcc('Y', '1', '0', ' ') /* 10 Greyscale */
++#define V4L2_PIX_FMT_Y16 v4l2_fourcc('Y', '1', '6', ' ') /* 16 Greyscale */
++
++/* Palette formats */
++#define V4L2_PIX_FMT_PAL8 v4l2_fourcc('P', 'A', 'L', '8') /* 8 8-bit palette */
++
++/* Luminance+Chrominance formats */
++#define V4L2_PIX_FMT_YVU410 v4l2_fourcc('Y', 'V', 'U', '9') /* 9 YVU 4:1:0 */
++#define V4L2_PIX_FMT_YVU420 v4l2_fourcc('Y', 'V', '1', '2') /* 12 YVU 4:2:0 */
++#define V4L2_PIX_FMT_YUYV v4l2_fourcc('Y', 'U', 'Y', 'V') /* 16 YUV 4:2:2 */
++#define V4L2_PIX_FMT_YYUV v4l2_fourcc('Y', 'Y', 'U', 'V') /* 16 YUV 4:2:2 */
++#define V4L2_PIX_FMT_YVYU v4l2_fourcc('Y', 'V', 'Y', 'U') /* 16 YVU 4:2:2 */
++#define V4L2_PIX_FMT_UYVY v4l2_fourcc('U', 'Y', 'V', 'Y') /* 16 YUV 4:2:2 */
++#define V4L2_PIX_FMT_VYUY v4l2_fourcc('V', 'Y', 'U', 'Y') /* 16 YUV 4:2:2 */
++#define V4L2_PIX_FMT_YUV422P v4l2_fourcc('4', '2', '2', 'P') /* 16 YVU422 planar */
++#define V4L2_PIX_FMT_YUV411P v4l2_fourcc('4', '1', '1', 'P') /* 16 YVU411 planar */
++#define V4L2_PIX_FMT_Y41P v4l2_fourcc('Y', '4', '1', 'P') /* 12 YUV 4:1:1 */
++#define V4L2_PIX_FMT_YUV444 v4l2_fourcc('Y', '4', '4', '4') /* 16 xxxxyyyy uuuuvvvv */
++#define V4L2_PIX_FMT_YUV555 v4l2_fourcc('Y', 'U', 'V', 'O') /* 16 YUV-5-5-5 */
++#define V4L2_PIX_FMT_YUV565 v4l2_fourcc('Y', 'U', 'V', 'P') /* 16 YUV-5-6-5 */
++#define V4L2_PIX_FMT_YUV32 v4l2_fourcc('Y', 'U', 'V', '4') /* 32 YUV-8-8-8-8 */
++#define V4L2_PIX_FMT_YUV410 v4l2_fourcc('Y', 'U', 'V', '9') /* 9 YUV 4:1:0 */
++#define V4L2_PIX_FMT_YUV420 v4l2_fourcc('Y', 'U', '1', '2') /* 12 YUV 4:2:0 */
++#define V4L2_PIX_FMT_HI240 v4l2_fourcc('H', 'I', '2', '4') /* 8 8-bit color */
++#define V4L2_PIX_FMT_HM12 v4l2_fourcc('H', 'M', '1', '2') /* 8 YUV 4:2:0 16x16 macroblocks */
++
++/* two planes -- one Y, one Cr + Cb interleaved */
++#define V4L2_PIX_FMT_NV12 v4l2_fourcc('N', 'V', '1', '2') /* 12 Y/CbCr 4:2:0 */
++#define V4L2_PIX_FMT_NV21 v4l2_fourcc('N', 'V', '2', '1') /* 12 Y/CrCb 4:2:0 */
++#define V4L2_PIX_FMT_NV16 v4l2_fourcc('N', 'V', '1', '6') /* 16 Y/CbCr 4:2:2 */
++#define V4L2_PIX_FMT_NV61 v4l2_fourcc('N', 'V', '6', '1') /* 16 Y/CrCb 4:2:2 */
++
++/* two non contiguous planes - one Y, one Cr + Cb interleaved */
++#define V4L2_PIX_FMT_NV12M v4l2_fourcc('N', 'M', '1', '2') /* 12 Y/CbCr 4:2:0 */
++#define V4L2_PIX_FMT_NV12MT v4l2_fourcc('T', 'M', '1', '2') /* 12 Y/CbCr 4:2:0 64x32 macroblocks */
++
++/* three non contiguous planes - Y, Cb, Cr */
++#define V4L2_PIX_FMT_YUV420M v4l2_fourcc('Y', 'M', '1', '2') /* 12 YUV420 planar */
++
++/* Bayer formats - see http://www.siliconimaging.com/RGB%20Bayer.htm */
++#define V4L2_PIX_FMT_SBGGR8 v4l2_fourcc('B', 'A', '8', '1') /* 8 BGBG.. GRGR.. */
++#define V4L2_PIX_FMT_SGBRG8 v4l2_fourcc('G', 'B', 'R', 'G') /* 8 GBGB.. RGRG.. */
++#define V4L2_PIX_FMT_SGRBG8 v4l2_fourcc('G', 'R', 'B', 'G') /* 8 GRGR.. BGBG.. */
++#define V4L2_PIX_FMT_SRGGB8 v4l2_fourcc('R', 'G', 'G', 'B') /* 8 RGRG.. GBGB.. */
++#define V4L2_PIX_FMT_SBGGR10 v4l2_fourcc('B', 'G', '1', '0') /* 10 BGBG.. GRGR.. */
++#define V4L2_PIX_FMT_SGBRG10 v4l2_fourcc('G', 'B', '1', '0') /* 10 GBGB.. RGRG.. */
++#define V4L2_PIX_FMT_SGRBG10 v4l2_fourcc('B', 'A', '1', '0') /* 10 GRGR.. BGBG.. */
++#define V4L2_PIX_FMT_SRGGB10 v4l2_fourcc('R', 'G', '1', '0') /* 10 RGRG.. GBGB.. */
++ /* 10bit raw bayer DPCM compressed to 8 bits */
++#define V4L2_PIX_FMT_SGRBG10DPCM8 v4l2_fourcc('B', 'D', '1', '0')
++ /*
++ * 10bit raw bayer, expanded to 16 bits
++ * xxxxrrrrrrrrrrxxxxgggggggggg xxxxggggggggggxxxxbbbbbbbbbb...
++ */
++#define V4L2_PIX_FMT_SBGGR16 v4l2_fourcc('B', 'Y', 'R', '2') /* 16 BGBG.. GRGR.. */
++
++/* compressed formats */
++#define V4L2_PIX_FMT_MJPEG v4l2_fourcc('M', 'J', 'P', 'G') /* Motion-JPEG */
++#define V4L2_PIX_FMT_JPEG v4l2_fourcc('J', 'P', 'E', 'G') /* JFIF JPEG */
++#define V4L2_PIX_FMT_DV v4l2_fourcc('d', 'v', 's', 'd') /* 1394 */
++#define V4L2_PIX_FMT_MPEG v4l2_fourcc('M', 'P', 'E', 'G') /* MPEG-1/2/4 */
++
++/* Vendor-specific formats */
++#define V4L2_PIX_FMT_CPIA1 v4l2_fourcc('C', 'P', 'I', 'A') /* cpia1 YUV */
++#define V4L2_PIX_FMT_WNVA v4l2_fourcc('W', 'N', 'V', 'A') /* Winnov hw compress */
++#define V4L2_PIX_FMT_SN9C10X v4l2_fourcc('S', '9', '1', '0') /* SN9C10x compression */
++#define V4L2_PIX_FMT_SN9C20X_I420 v4l2_fourcc('S', '9', '2', '0') /* SN9C20x YUV 4:2:0 */
++#define V4L2_PIX_FMT_PWC1 v4l2_fourcc('P', 'W', 'C', '1') /* pwc older webcam */
++#define V4L2_PIX_FMT_PWC2 v4l2_fourcc('P', 'W', 'C', '2') /* pwc newer webcam */
++#define V4L2_PIX_FMT_ET61X251 v4l2_fourcc('E', '6', '2', '5') /* ET61X251 compression */
++#define V4L2_PIX_FMT_SPCA501 v4l2_fourcc('S', '5', '0', '1') /* YUYV per line */
++#define V4L2_PIX_FMT_SPCA505 v4l2_fourcc('S', '5', '0', '5') /* YYUV per line */
++#define V4L2_PIX_FMT_SPCA508 v4l2_fourcc('S', '5', '0', '8') /* YUVY per line */
++#define V4L2_PIX_FMT_SPCA561 v4l2_fourcc('S', '5', '6', '1') /* compressed GBRG bayer */
++#define V4L2_PIX_FMT_PAC207 v4l2_fourcc('P', '2', '0', '7') /* compressed BGGR bayer */
++#define V4L2_PIX_FMT_MR97310A v4l2_fourcc('M', '3', '1', '0') /* compressed BGGR bayer */
++#define V4L2_PIX_FMT_SN9C2028 v4l2_fourcc('S', 'O', 'N', 'X') /* compressed GBRG bayer */
++#define V4L2_PIX_FMT_SQ905C v4l2_fourcc('9', '0', '5', 'C') /* compressed RGGB bayer */
++#define V4L2_PIX_FMT_PJPG v4l2_fourcc('P', 'J', 'P', 'G') /* Pixart 73xx JPEG */
++#define V4L2_PIX_FMT_OV511 v4l2_fourcc('O', '5', '1', '1') /* ov511 JPEG */
++#define V4L2_PIX_FMT_OV518 v4l2_fourcc('O', '5', '1', '8') /* ov518 JPEG */
++#define V4L2_PIX_FMT_STV0680 v4l2_fourcc('S', '6', '8', '0') /* stv0680 bayer */
++#define V4L2_PIX_FMT_TM6000 v4l2_fourcc('T', 'M', '6', '0') /* tm5600/tm60x0 */
++#define V4L2_PIX_FMT_CIT_YYVYUY v4l2_fourcc('C', 'I', 'T', 'V') /* one line of Y then 1 line of VYUY */
++#define V4L2_PIX_FMT_KONICA420 v4l2_fourcc('K', 'O', 'N', 'I') /* YUV420 planar in blocks of 256 pixels */
++
++/*
++ * F O R M A T E N U M E R A T I O N
++ */
++struct v4l2_fmtdesc {
++ __u32 index; /* Format number */
++ enum v4l2_buf_type type; /* buffer type */
++ __u32 flags;
++ __u8 description[32]; /* Description string */
++ __u32 pixelformat; /* Format fourcc */
++ __u32 reserved[4];
++};
++
++#define V4L2_FMT_FLAG_COMPRESSED 0x0001
++#define V4L2_FMT_FLAG_EMULATED 0x0002
++
++#if 1
++ /* Experimental Frame Size and frame rate enumeration */
++/*
++ * F R A M E S I Z E E N U M E R A T I O N
++ */
++enum v4l2_frmsizetypes {
++ V4L2_FRMSIZE_TYPE_DISCRETE = 1,
++ V4L2_FRMSIZE_TYPE_CONTINUOUS = 2,
++ V4L2_FRMSIZE_TYPE_STEPWISE = 3,
++};
++
++struct v4l2_frmsize_discrete {
++ __u32 width; /* Frame width [pixel] */
++ __u32 height; /* Frame height [pixel] */
++};
++
++struct v4l2_frmsize_stepwise {
++ __u32 min_width; /* Minimum frame width [pixel] */
++ __u32 max_width; /* Maximum frame width [pixel] */
++ __u32 step_width; /* Frame width step size [pixel] */
++ __u32 min_height; /* Minimum frame height [pixel] */
++ __u32 max_height; /* Maximum frame height [pixel] */
++ __u32 step_height; /* Frame height step size [pixel] */
++};
++
++struct v4l2_frmsizeenum {
++ __u32 index; /* Frame size number */
++ __u32 pixel_format; /* Pixel format */
++ __u32 type; /* Frame size type the device supports. */
++
++ union { /* Frame size */
++ struct v4l2_frmsize_discrete discrete;
++ struct v4l2_frmsize_stepwise stepwise;
++ };
++
++ __u32 reserved[2]; /* Reserved space for future use */
++};
++
++/*
++ * F R A M E R A T E E N U M E R A T I O N
++ */
++enum v4l2_frmivaltypes {
++ V4L2_FRMIVAL_TYPE_DISCRETE = 1,
++ V4L2_FRMIVAL_TYPE_CONTINUOUS = 2,
++ V4L2_FRMIVAL_TYPE_STEPWISE = 3,
++};
++
++struct v4l2_frmival_stepwise {
++ struct v4l2_fract min; /* Minimum frame interval [s] */
++ struct v4l2_fract max; /* Maximum frame interval [s] */
++ struct v4l2_fract step; /* Frame interval step size [s] */
++};
++
++struct v4l2_frmivalenum {
++ __u32 index; /* Frame format index */
++ __u32 pixel_format; /* Pixel format */
++ __u32 width; /* Frame width */
++ __u32 height; /* Frame height */
++ __u32 type; /* Frame interval type the device supports. */
++
++ union { /* Frame interval */
++ struct v4l2_fract discrete;
++ struct v4l2_frmival_stepwise stepwise;
++ };
++
++ __u32 reserved[2]; /* Reserved space for future use */
++};
++#endif
++
++/*
++ * T I M E C O D E
++ */
++struct v4l2_timecode {
++ __u32 type;
++ __u32 flags;
++ __u8 frames;
++ __u8 seconds;
++ __u8 minutes;
++ __u8 hours;
++ __u8 userbits[4];
++};
++
++/* Type */
++#define V4L2_TC_TYPE_24FPS 1
++#define V4L2_TC_TYPE_25FPS 2
++#define V4L2_TC_TYPE_30FPS 3
++#define V4L2_TC_TYPE_50FPS 4
++#define V4L2_TC_TYPE_60FPS 5
++
++/* Flags */
++#define V4L2_TC_FLAG_DROPFRAME 0x0001 /* "drop-frame" mode */
++#define V4L2_TC_FLAG_COLORFRAME 0x0002
++#define V4L2_TC_USERBITS_field 0x000C
++#define V4L2_TC_USERBITS_USERDEFINED 0x0000
++#define V4L2_TC_USERBITS_8BITCHARS 0x0008
++/* The above is based on SMPTE timecodes */
++
++struct v4l2_jpegcompression {
++ int quality;
++
++ int APPn; /* Number of APP segment to be written,
++ * must be 0..15 */
++ int APP_len; /* Length of data in JPEG APPn segment */
++ char APP_data[60]; /* Data in the JPEG APPn segment. */
++
++ int COM_len; /* Length of data in JPEG COM segment */
++ char COM_data[60]; /* Data in JPEG COM segment */
++
++ __u32 jpeg_markers; /* Which markers should go into the JPEG
++ * output. Unless you exactly know what
++ * you do, leave them untouched.
++ * Inluding less markers will make the
++ * resulting code smaller, but there will
++ * be fewer applications which can read it.
++ * The presence of the APP and COM marker
++ * is influenced by APP_len and COM_len
++ * ONLY, not by this property! */
++
++#define V4L2_JPEG_MARKER_DHT (1<<3) /* Define Huffman Tables */
++#define V4L2_JPEG_MARKER_DQT (1<<4) /* Define Quantization Tables */
++#define V4L2_JPEG_MARKER_DRI (1<<5) /* Define Restart Interval */
++#define V4L2_JPEG_MARKER_COM (1<<6) /* Comment segment */
++#define V4L2_JPEG_MARKER_APP (1<<7) /* App segment, driver will
++ * allways use APP0 */
++};
++
++/*
++ * M E M O R Y - M A P P I N G B U F F E R S
++ */
++struct v4l2_requestbuffers {
++ __u32 count;
++ enum v4l2_buf_type type;
++ enum v4l2_memory memory;
++ __u32 reserved[2];
++};
++
++/**
++ * struct v4l2_plane - plane info for multi-planar buffers
++ * @bytesused: number of bytes occupied by data in the plane (payload)
++ * @length: size of this plane (NOT the payload) in bytes
++ * @mem_offset: when memory in the associated struct v4l2_buffer is
++ * V4L2_MEMORY_MMAP, equals the offset from the start of
++ * the device memory for this plane (or is a "cookie" that
++ * should be passed to mmap() called on the video node)
++ * @userptr: when memory is V4L2_MEMORY_USERPTR, a userspace pointer
++ * pointing to this plane
++ * @data_offset: offset in the plane to the start of data; usually 0,
++ * unless there is a header in front of the data
++ *
++ * Multi-planar buffers consist of one or more planes, e.g. an YCbCr buffer
++ * with two planes can have one plane for Y, and another for interleaved CbCr
++ * components. Each plane can reside in a separate memory buffer, or even in
++ * a completely separate memory node (e.g. in embedded devices).
++ */
++struct v4l2_plane {
++ __u32 bytesused;
++ __u32 length;
++ union {
++ __u32 mem_offset;
++ unsigned long userptr;
++ } m;
++ __u32 data_offset;
++ __u32 reserved[11];
++};
++
++/**
++ * struct v4l2_buffer - video buffer info
++ * @index: id number of the buffer
++ * @type: buffer type (type == *_MPLANE for multiplanar buffers)
++ * @bytesused: number of bytes occupied by data in the buffer (payload);
++ * unused (set to 0) for multiplanar buffers
++ * @flags: buffer informational flags
++ * @field: field order of the image in the buffer
++ * @timestamp: frame timestamp
++ * @timecode: frame timecode
++ * @sequence: sequence count of this frame
++ * @memory: the method, in which the actual video data is passed
++ * @offset: for non-multiplanar buffers with memory == V4L2_MEMORY_MMAP;
++ * offset from the start of the device memory for this plane,
++ * (or a "cookie" that should be passed to mmap() as offset)
++ * @userptr: for non-multiplanar buffers with memory == V4L2_MEMORY_USERPTR;
++ * a userspace pointer pointing to this buffer
++ * @planes: for multiplanar buffers; userspace pointer to the array of plane
++ * info structs for this buffer
++ * @length: size in bytes of the buffer (NOT its payload) for single-plane
++ * buffers (when type != *_MPLANE); number of elements in the
++ * planes array for multi-plane buffers
++ * @input: input number from which the video data has has been captured
++ *
++ * Contains data exchanged by application and driver using one of the Streaming
++ * I/O methods.
++ */
++struct v4l2_buffer {
++ __u32 index;
++ enum v4l2_buf_type type;
++ __u32 bytesused;
++ __u32 flags;
++ enum v4l2_field field;
++ struct timeval timestamp;
++ struct v4l2_timecode timecode;
++ __u32 sequence;
++
++ /* memory location */
++ enum v4l2_memory memory;
++ union {
++ __u32 offset;
++ unsigned long userptr;
++ struct v4l2_plane *planes;
++ } m;
++ __u32 length;
++ __u32 input;
++ __u32 reserved;
++};
++
++/* Flags for 'flags' field */
++#define V4L2_BUF_FLAG_MAPPED 0x0001 /* Buffer is mapped (flag) */
++#define V4L2_BUF_FLAG_QUEUED 0x0002 /* Buffer is queued for processing */
++#define V4L2_BUF_FLAG_DONE 0x0004 /* Buffer is ready */
++#define V4L2_BUF_FLAG_KEYFRAME 0x0008 /* Image is a keyframe (I-frame) */
++#define V4L2_BUF_FLAG_PFRAME 0x0010 /* Image is a P-frame */
++#define V4L2_BUF_FLAG_BFRAME 0x0020 /* Image is a B-frame */
++/* Buffer is ready, but the data contained within is corrupted. */
++#define V4L2_BUF_FLAG_ERROR 0x0040
++#define V4L2_BUF_FLAG_TIMECODE 0x0100 /* timecode field is valid */
++#define V4L2_BUF_FLAG_INPUT 0x0200 /* input field is valid */
++
++/*
++ * O V E R L A Y P R E V I E W
++ */
++struct v4l2_framebuffer {
++ __u32 capability;
++ __u32 flags;
++/* FIXME: in theory we should pass something like PCI device + memory
++ * region + offset instead of some physical address */
++ void *base;
++ struct v4l2_pix_format fmt;
++};
++/* Flags for the 'capability' field. Read only */
++#define V4L2_FBUF_CAP_EXTERNOVERLAY 0x0001
++#define V4L2_FBUF_CAP_CHROMAKEY 0x0002
++#define V4L2_FBUF_CAP_LIST_CLIPPING 0x0004
++#define V4L2_FBUF_CAP_BITMAP_CLIPPING 0x0008
++#define V4L2_FBUF_CAP_LOCAL_ALPHA 0x0010
++#define V4L2_FBUF_CAP_GLOBAL_ALPHA 0x0020
++#define V4L2_FBUF_CAP_LOCAL_INV_ALPHA 0x0040
++#define V4L2_FBUF_CAP_SRC_CHROMAKEY 0x0080
++/* Flags for the 'flags' field. */
++#define V4L2_FBUF_FLAG_PRIMARY 0x0001
++#define V4L2_FBUF_FLAG_OVERLAY 0x0002
++#define V4L2_FBUF_FLAG_CHROMAKEY 0x0004
++#define V4L2_FBUF_FLAG_LOCAL_ALPHA 0x0008
++#define V4L2_FBUF_FLAG_GLOBAL_ALPHA 0x0010
++#define V4L2_FBUF_FLAG_LOCAL_INV_ALPHA 0x0020
++#define V4L2_FBUF_FLAG_SRC_CHROMAKEY 0x0040
++
++struct v4l2_clip {
++ struct v4l2_rect c;
++ struct v4l2_clip *next;
++};
++
++struct v4l2_window {
++ struct v4l2_rect w;
++ enum v4l2_field field;
++ __u32 chromakey;
++ struct v4l2_clip *clips;
++ __u32 clipcount;
++ void *bitmap;
++ __u8 global_alpha;
++};
++
++/*
++ * C A P T U R E P A R A M E T E R S
++ */
++struct v4l2_captureparm {
++ __u32 capability; /* Supported modes */
++ __u32 capturemode; /* Current mode */
++ struct v4l2_fract timeperframe; /* Time per frame in .1us units */
++ __u32 extendedmode; /* Driver-specific extensions */
++ __u32 readbuffers; /* # of buffers for read */
++ __u32 reserved[4];
++};
++
++/* Flags for 'capability' and 'capturemode' fields */
++#define V4L2_MODE_HIGHQUALITY 0x0001 /* High quality imaging mode */
++#define V4L2_CAP_TIMEPERFRAME 0x1000 /* timeperframe field is supported */
++
++struct v4l2_outputparm {
++ __u32 capability; /* Supported modes */
++ __u32 outputmode; /* Current mode */
++ struct v4l2_fract timeperframe; /* Time per frame in seconds */
++ __u32 extendedmode; /* Driver-specific extensions */
++ __u32 writebuffers; /* # of buffers for write */
++ __u32 reserved[4];
++};
++
++/*
++ * I N P U T I M A G E C R O P P I N G
++ */
++struct v4l2_cropcap {
++ enum v4l2_buf_type type;
++ struct v4l2_rect bounds;
++ struct v4l2_rect defrect;
++ struct v4l2_fract pixelaspect;
++};
++
++struct v4l2_crop {
++ enum v4l2_buf_type type;
++ struct v4l2_rect c;
++};
++
++/*
++ * A N A L O G V I D E O S T A N D A R D
++ */
++
++typedef __u64 v4l2_std_id;
++
++/* one bit for each */
++#define V4L2_STD_PAL_B ((v4l2_std_id)0x00000001)
++#define V4L2_STD_PAL_B1 ((v4l2_std_id)0x00000002)
++#define V4L2_STD_PAL_G ((v4l2_std_id)0x00000004)
++#define V4L2_STD_PAL_H ((v4l2_std_id)0x00000008)
++#define V4L2_STD_PAL_I ((v4l2_std_id)0x00000010)
++#define V4L2_STD_PAL_D ((v4l2_std_id)0x00000020)
++#define V4L2_STD_PAL_D1 ((v4l2_std_id)0x00000040)
++#define V4L2_STD_PAL_K ((v4l2_std_id)0x00000080)
++
++#define V4L2_STD_PAL_M ((v4l2_std_id)0x00000100)
++#define V4L2_STD_PAL_N ((v4l2_std_id)0x00000200)
++#define V4L2_STD_PAL_Nc ((v4l2_std_id)0x00000400)
++#define V4L2_STD_PAL_60 ((v4l2_std_id)0x00000800)
++
++#define V4L2_STD_NTSC_M ((v4l2_std_id)0x00001000)
++#define V4L2_STD_NTSC_M_JP ((v4l2_std_id)0x00002000)
++#define V4L2_STD_NTSC_443 ((v4l2_std_id)0x00004000)
++#define V4L2_STD_NTSC_M_KR ((v4l2_std_id)0x00008000)
++
++#define V4L2_STD_SECAM_B ((v4l2_std_id)0x00010000)
++#define V4L2_STD_SECAM_D ((v4l2_std_id)0x00020000)
++#define V4L2_STD_SECAM_G ((v4l2_std_id)0x00040000)
++#define V4L2_STD_SECAM_H ((v4l2_std_id)0x00080000)
++#define V4L2_STD_SECAM_K ((v4l2_std_id)0x00100000)
++#define V4L2_STD_SECAM_K1 ((v4l2_std_id)0x00200000)
++#define V4L2_STD_SECAM_L ((v4l2_std_id)0x00400000)
++#define V4L2_STD_SECAM_LC ((v4l2_std_id)0x00800000)
++
++/* ATSC/HDTV */
++#define V4L2_STD_ATSC_8_VSB ((v4l2_std_id)0x01000000)
++#define V4L2_STD_ATSC_16_VSB ((v4l2_std_id)0x02000000)
++
++/* FIXME:
++ Although std_id is 64 bits, there is an issue on PPC32 architecture that
++ makes switch(__u64) to break. So, there's a hack on v4l2-common.c rounding
++ this value to 32 bits.
++ As, currently, the max value is for V4L2_STD_ATSC_16_VSB (30 bits wide),
++ it should work fine. However, if needed to add more than two standards,
++ v4l2-common.c should be fixed.
++ */
++
++/* some merged standards */
++#define V4L2_STD_MN (V4L2_STD_PAL_M|V4L2_STD_PAL_N|V4L2_STD_PAL_Nc|V4L2_STD_NTSC)
++#define V4L2_STD_B (V4L2_STD_PAL_B|V4L2_STD_PAL_B1|V4L2_STD_SECAM_B)
++#define V4L2_STD_GH (V4L2_STD_PAL_G|V4L2_STD_PAL_H|V4L2_STD_SECAM_G|V4L2_STD_SECAM_H)
++#define V4L2_STD_DK (V4L2_STD_PAL_DK|V4L2_STD_SECAM_DK)
++
++/* some common needed stuff */
++#define V4L2_STD_PAL_BG (V4L2_STD_PAL_B |\
++ V4L2_STD_PAL_B1 |\
++ V4L2_STD_PAL_G)
++#define V4L2_STD_PAL_DK (V4L2_STD_PAL_D |\
++ V4L2_STD_PAL_D1 |\
++ V4L2_STD_PAL_K)
++#define V4L2_STD_PAL (V4L2_STD_PAL_BG |\
++ V4L2_STD_PAL_DK |\
++ V4L2_STD_PAL_H |\
++ V4L2_STD_PAL_I)
++#define V4L2_STD_NTSC (V4L2_STD_NTSC_M |\
++ V4L2_STD_NTSC_M_JP |\
++ V4L2_STD_NTSC_M_KR)
++#define V4L2_STD_SECAM_DK (V4L2_STD_SECAM_D |\
++ V4L2_STD_SECAM_K |\
++ V4L2_STD_SECAM_K1)
++#define V4L2_STD_SECAM (V4L2_STD_SECAM_B |\
++ V4L2_STD_SECAM_G |\
++ V4L2_STD_SECAM_H |\
++ V4L2_STD_SECAM_DK |\
++ V4L2_STD_SECAM_L |\
++ V4L2_STD_SECAM_LC)
++
++#define V4L2_STD_525_60 (V4L2_STD_PAL_M |\
++ V4L2_STD_PAL_60 |\
++ V4L2_STD_NTSC |\
++ V4L2_STD_NTSC_443)
++#define V4L2_STD_625_50 (V4L2_STD_PAL |\
++ V4L2_STD_PAL_N |\
++ V4L2_STD_PAL_Nc |\
++ V4L2_STD_SECAM)
++#define V4L2_STD_ATSC (V4L2_STD_ATSC_8_VSB |\
++ V4L2_STD_ATSC_16_VSB)
++
++#define V4L2_STD_UNKNOWN 0
++#define V4L2_STD_ALL (V4L2_STD_525_60 |\
++ V4L2_STD_625_50)
++
++struct v4l2_standard {
++ __u32 index;
++ v4l2_std_id id;
++ __u8 name[24];
++ struct v4l2_fract frameperiod; /* Frames, not fields */
++ __u32 framelines;
++ __u32 reserved[4];
++};
++
++/*
++ * V I D E O T I M I N G S D V P R E S E T
++ */
++struct v4l2_dv_preset {
++ __u32 preset;
++ __u32 reserved[4];
++};
++
++/*
++ * D V P R E S E T S E N U M E R A T I O N
++ */
++struct v4l2_dv_enum_preset {
++ __u32 index;
++ __u32 preset;
++ __u8 name[32]; /* Name of the preset timing */
++ __u32 width;
++ __u32 height;
++ __u32 reserved[4];
++};
++
++/*
++ * D V P R E S E T V A L U E S
++ */
++#define V4L2_DV_INVALID 0
++#define V4L2_DV_480P59_94 1 /* BT.1362 */
++#define V4L2_DV_576P50 2 /* BT.1362 */
++#define V4L2_DV_720P24 3 /* SMPTE 296M */
++#define V4L2_DV_720P25 4 /* SMPTE 296M */
++#define V4L2_DV_720P30 5 /* SMPTE 296M */
++#define V4L2_DV_720P50 6 /* SMPTE 296M */
++#define V4L2_DV_720P59_94 7 /* SMPTE 274M */
++#define V4L2_DV_720P60 8 /* SMPTE 274M/296M */
++#define V4L2_DV_1080I29_97 9 /* BT.1120/ SMPTE 274M */
++#define V4L2_DV_1080I30 10 /* BT.1120/ SMPTE 274M */
++#define V4L2_DV_1080I25 11 /* BT.1120 */
++#define V4L2_DV_1080I50 12 /* SMPTE 296M */
++#define V4L2_DV_1080I60 13 /* SMPTE 296M */
++#define V4L2_DV_1080P24 14 /* SMPTE 296M */
++#define V4L2_DV_1080P25 15 /* SMPTE 296M */
++#define V4L2_DV_1080P30 16 /* SMPTE 296M */
++#define V4L2_DV_1080P50 17 /* BT.1120 */
++#define V4L2_DV_1080P60 18 /* BT.1120 */
++
++/*
++ * D V B T T I M I N G S
++ */
++
++/* BT.656/BT.1120 timing data */
++struct v4l2_bt_timings {
++ __u32 width; /* width in pixels */
++ __u32 height; /* height in lines */
++ __u32 interlaced; /* Interlaced or progressive */
++ __u32 polarities; /* Positive or negative polarity */
++ __u64 pixelclock; /* Pixel clock in HZ. Ex. 74.25MHz->74250000 */
++ __u32 hfrontporch; /* Horizpontal front porch in pixels */
++ __u32 hsync; /* Horizontal Sync length in pixels */
++ __u32 hbackporch; /* Horizontal back porch in pixels */
++ __u32 vfrontporch; /* Vertical front porch in pixels */
++ __u32 vsync; /* Vertical Sync length in lines */
++ __u32 vbackporch; /* Vertical back porch in lines */
++ __u32 il_vfrontporch; /* Vertical front porch for bottom field of
++ * interlaced field formats
++ */
++ __u32 il_vsync; /* Vertical sync length for bottom field of
++ * interlaced field formats
++ */
++ __u32 il_vbackporch; /* Vertical back porch for bottom field of
++ * interlaced field formats
++ */
++ __u32 reserved[16];
++} __attribute__ ((packed));
++
++/* Interlaced or progressive format */
++#define V4L2_DV_PROGRESSIVE 0
++#define V4L2_DV_INTERLACED 1
++
++/* Polarities. If bit is not set, it is assumed to be negative polarity */
++#define V4L2_DV_VSYNC_POS_POL 0x00000001
++#define V4L2_DV_HSYNC_POS_POL 0x00000002
++
++
++/* DV timings */
++struct v4l2_dv_timings {
++ __u32 type;
++ union {
++ struct v4l2_bt_timings bt;
++ __u32 reserved[32];
++ };
++} __attribute__ ((packed));
++
++/* Values for the type field */
++#define V4L2_DV_BT_656_1120 0 /* BT.656/1120 timing type */
++
++/*
++ * V I D E O I N P U T S
++ */
++struct v4l2_input {
++ __u32 index; /* Which input */
++ __u8 name[32]; /* Label */
++ __u32 type; /* Type of input */
++ __u32 audioset; /* Associated audios (bitfield) */
++ __u32 tuner; /* Associated tuner */
++ v4l2_std_id std;
++ __u32 status;
++ __u32 capabilities;
++ __u32 reserved[3];
++};
++
++/* Values for the 'type' field */
++#define V4L2_INPUT_TYPE_TUNER 1
++#define V4L2_INPUT_TYPE_CAMERA 2
++
++/* field 'status' - general */
++#define V4L2_IN_ST_NO_POWER 0x00000001 /* Attached device is off */
++#define V4L2_IN_ST_NO_SIGNAL 0x00000002
++#define V4L2_IN_ST_NO_COLOR 0x00000004
++
++/* field 'status' - sensor orientation */
++/* If sensor is mounted upside down set both bits */
++#define V4L2_IN_ST_HFLIP 0x00000010 /* Frames are flipped horizontally */
++#define V4L2_IN_ST_VFLIP 0x00000020 /* Frames are flipped vertically */
++
++/* field 'status' - analog */
++#define V4L2_IN_ST_NO_H_LOCK 0x00000100 /* No horizontal sync lock */
++#define V4L2_IN_ST_COLOR_KILL 0x00000200 /* Color killer is active */
++
++/* field 'status' - digital */
++#define V4L2_IN_ST_NO_SYNC 0x00010000 /* No synchronization lock */
++#define V4L2_IN_ST_NO_EQU 0x00020000 /* No equalizer lock */
++#define V4L2_IN_ST_NO_CARRIER 0x00040000 /* Carrier recovery failed */
++
++/* field 'status' - VCR and set-top box */
++#define V4L2_IN_ST_MACROVISION 0x01000000 /* Macrovision detected */
++#define V4L2_IN_ST_NO_ACCESS 0x02000000 /* Conditional access denied */
++#define V4L2_IN_ST_VTR 0x04000000 /* VTR time constant */
++
++/* capabilities flags */
++#define V4L2_IN_CAP_PRESETS 0x00000001 /* Supports S_DV_PRESET */
++#define V4L2_IN_CAP_CUSTOM_TIMINGS 0x00000002 /* Supports S_DV_TIMINGS */
++#define V4L2_IN_CAP_STD 0x00000004 /* Supports S_STD */
++
++/*
++ * V I D E O O U T P U T S
++ */
++struct v4l2_output {
++ __u32 index; /* Which output */
++ __u8 name[32]; /* Label */
++ __u32 type; /* Type of output */
++ __u32 audioset; /* Associated audios (bitfield) */
++ __u32 modulator; /* Associated modulator */
++ v4l2_std_id std;
++ __u32 capabilities;
++ __u32 reserved[3];
++};
++/* Values for the 'type' field */
++#define V4L2_OUTPUT_TYPE_MODULATOR 1
++#define V4L2_OUTPUT_TYPE_ANALOG 2
++#define V4L2_OUTPUT_TYPE_ANALOGVGAOVERLAY 3
++
++/* capabilities flags */
++#define V4L2_OUT_CAP_PRESETS 0x00000001 /* Supports S_DV_PRESET */
++#define V4L2_OUT_CAP_CUSTOM_TIMINGS 0x00000002 /* Supports S_DV_TIMINGS */
++#define V4L2_OUT_CAP_STD 0x00000004 /* Supports S_STD */
++
++/*
++ * C O N T R O L S
++ */
++struct v4l2_control {
++ __u32 id;
++ __s32 value;
++};
++
++struct v4l2_ext_control {
++ __u32 id;
++ __u32 size;
++ __u32 reserved2[1];
++ union {
++ __s32 value;
++ __s64 value64;
++ char *string;
++ };
++} __attribute__ ((packed));
++
++struct v4l2_ext_controls {
++ __u32 ctrl_class;
++ __u32 count;
++ __u32 error_idx;
++ __u32 reserved[2];
++ struct v4l2_ext_control *controls;
++};
++
++/* Values for ctrl_class field */
++#define V4L2_CTRL_CLASS_USER 0x00980000 /* Old-style 'user' controls */
++#define V4L2_CTRL_CLASS_MPEG 0x00990000 /* MPEG-compression controls */
++#define V4L2_CTRL_CLASS_CAMERA 0x009a0000 /* Camera class controls */
++#define V4L2_CTRL_CLASS_FM_TX 0x009b0000 /* FM Modulator control class */
++
++#define V4L2_CTRL_ID_MASK (0x0fffffff)
++#define V4L2_CTRL_ID2CLASS(id) ((id) & 0x0fff0000UL)
++#define V4L2_CTRL_DRIVER_PRIV(id) (((id) & 0xffff) >= 0x1000)
++
++enum v4l2_ctrl_type {
++ V4L2_CTRL_TYPE_INTEGER = 1,
++ V4L2_CTRL_TYPE_BOOLEAN = 2,
++ V4L2_CTRL_TYPE_MENU = 3,
++ V4L2_CTRL_TYPE_BUTTON = 4,
++ V4L2_CTRL_TYPE_INTEGER64 = 5,
++ V4L2_CTRL_TYPE_CTRL_CLASS = 6,
++ V4L2_CTRL_TYPE_STRING = 7,
++};
++
++/* Used in the VIDIOC_QUERYCTRL ioctl for querying controls */
++struct v4l2_queryctrl {
++ __u32 id;
++ enum v4l2_ctrl_type type;
++ __u8 name[32]; /* Whatever */
++ __s32 minimum; /* Note signedness */
++ __s32 maximum;
++ __s32 step;
++ __s32 default_value;
++ __u32 flags;
++ __u32 reserved[2];
++};
++
++/* Used in the VIDIOC_QUERYMENU ioctl for querying menu items */
++struct v4l2_querymenu {
++ __u32 id;
++ __u32 index;
++ __u8 name[32]; /* Whatever */
++ __u32 reserved;
++};
++
++/* Control flags */
++#define V4L2_CTRL_FLAG_DISABLED 0x0001
++#define V4L2_CTRL_FLAG_GRABBED 0x0002
++#define V4L2_CTRL_FLAG_READ_ONLY 0x0004
++#define V4L2_CTRL_FLAG_UPDATE 0x0008
++#define V4L2_CTRL_FLAG_INACTIVE 0x0010
++#define V4L2_CTRL_FLAG_SLIDER 0x0020
++#define V4L2_CTRL_FLAG_WRITE_ONLY 0x0040
++
++/* Query flag, to be ORed with the control ID */
++#define V4L2_CTRL_FLAG_NEXT_CTRL 0x80000000
++
++/* User-class control IDs defined by V4L2 */
++#define V4L2_CID_BASE (V4L2_CTRL_CLASS_USER | 0x900)
++#define V4L2_CID_USER_BASE V4L2_CID_BASE
++/* IDs reserved for driver specific controls */
++#define V4L2_CID_PRIVATE_BASE 0x08000000
++
++#define V4L2_CID_USER_CLASS (V4L2_CTRL_CLASS_USER | 1)
++#define V4L2_CID_BRIGHTNESS (V4L2_CID_BASE+0)
++#define V4L2_CID_CONTRAST (V4L2_CID_BASE+1)
++#define V4L2_CID_SATURATION (V4L2_CID_BASE+2)
++#define V4L2_CID_HUE (V4L2_CID_BASE+3)
++#define V4L2_CID_AUDIO_VOLUME (V4L2_CID_BASE+5)
++#define V4L2_CID_AUDIO_BALANCE (V4L2_CID_BASE+6)
++#define V4L2_CID_AUDIO_BASS (V4L2_CID_BASE+7)
++#define V4L2_CID_AUDIO_TREBLE (V4L2_CID_BASE+8)
++#define V4L2_CID_AUDIO_MUTE (V4L2_CID_BASE+9)
++#define V4L2_CID_AUDIO_LOUDNESS (V4L2_CID_BASE+10)
++#define V4L2_CID_BLACK_LEVEL (V4L2_CID_BASE+11) /* Deprecated */
++#define V4L2_CID_AUTO_WHITE_BALANCE (V4L2_CID_BASE+12)
++#define V4L2_CID_DO_WHITE_BALANCE (V4L2_CID_BASE+13)
++#define V4L2_CID_RED_BALANCE (V4L2_CID_BASE+14)
++#define V4L2_CID_BLUE_BALANCE (V4L2_CID_BASE+15)
++#define V4L2_CID_GAMMA (V4L2_CID_BASE+16)
++#define V4L2_CID_WHITENESS (V4L2_CID_GAMMA) /* Deprecated */
++#define V4L2_CID_EXPOSURE (V4L2_CID_BASE+17)
++#define V4L2_CID_AUTOGAIN (V4L2_CID_BASE+18)
++#define V4L2_CID_GAIN (V4L2_CID_BASE+19)
++#define V4L2_CID_HFLIP (V4L2_CID_BASE+20)
++#define V4L2_CID_VFLIP (V4L2_CID_BASE+21)
++
++/* Deprecated; use V4L2_CID_PAN_RESET and V4L2_CID_TILT_RESET */
++#define V4L2_CID_HCENTER (V4L2_CID_BASE+22)
++#define V4L2_CID_VCENTER (V4L2_CID_BASE+23)
++
++#define V4L2_CID_POWER_LINE_FREQUENCY (V4L2_CID_BASE+24)
++enum v4l2_power_line_frequency {
++ V4L2_CID_POWER_LINE_FREQUENCY_DISABLED = 0,
++ V4L2_CID_POWER_LINE_FREQUENCY_50HZ = 1,
++ V4L2_CID_POWER_LINE_FREQUENCY_60HZ = 2,
++};
++#define V4L2_CID_HUE_AUTO (V4L2_CID_BASE+25)
++#define V4L2_CID_WHITE_BALANCE_TEMPERATURE (V4L2_CID_BASE+26)
++#define V4L2_CID_SHARPNESS (V4L2_CID_BASE+27)
++#define V4L2_CID_BACKLIGHT_COMPENSATION (V4L2_CID_BASE+28)
++#define V4L2_CID_CHROMA_AGC (V4L2_CID_BASE+29)
++#define V4L2_CID_COLOR_KILLER (V4L2_CID_BASE+30)
++#define V4L2_CID_COLORFX (V4L2_CID_BASE+31)
++enum v4l2_colorfx {
++ V4L2_COLORFX_NONE = 0,
++ V4L2_COLORFX_BW = 1,
++ V4L2_COLORFX_SEPIA = 2,
++ V4L2_COLORFX_NEGATIVE = 3,
++ V4L2_COLORFX_EMBOSS = 4,
++ V4L2_COLORFX_SKETCH = 5,
++ V4L2_COLORFX_SKY_BLUE = 6,
++ V4L2_COLORFX_GRASS_GREEN = 7,
++ V4L2_COLORFX_SKIN_WHITEN = 8,
++ V4L2_COLORFX_VIVID = 9,
++};
++#define V4L2_CID_AUTOBRIGHTNESS (V4L2_CID_BASE+32)
++#define V4L2_CID_BAND_STOP_FILTER (V4L2_CID_BASE+33)
++
++#define V4L2_CID_ROTATE (V4L2_CID_BASE+34)
++#define V4L2_CID_BG_COLOR (V4L2_CID_BASE+35)
++
++#define V4L2_CID_CHROMA_GAIN (V4L2_CID_BASE+36)
++
++#define V4L2_CID_ILLUMINATORS_1 (V4L2_CID_BASE+37)
++#define V4L2_CID_ILLUMINATORS_2 (V4L2_CID_BASE+38)
++
++/* last CID + 1 */
++#define V4L2_CID_LASTP1 (V4L2_CID_BASE+39)
++
++/* MPEG-class control IDs defined by V4L2 */
++#define V4L2_CID_MPEG_BASE (V4L2_CTRL_CLASS_MPEG | 0x900)
++#define V4L2_CID_MPEG_CLASS (V4L2_CTRL_CLASS_MPEG | 1)
++
++/* MPEG streams */
++#define V4L2_CID_MPEG_STREAM_TYPE (V4L2_CID_MPEG_BASE+0)
++enum v4l2_mpeg_stream_type {
++ V4L2_MPEG_STREAM_TYPE_MPEG2_PS = 0, /* MPEG-2 program stream */
++ V4L2_MPEG_STREAM_TYPE_MPEG2_TS = 1, /* MPEG-2 transport stream */
++ V4L2_MPEG_STREAM_TYPE_MPEG1_SS = 2, /* MPEG-1 system stream */
++ V4L2_MPEG_STREAM_TYPE_MPEG2_DVD = 3, /* MPEG-2 DVD-compatible stream */
++ V4L2_MPEG_STREAM_TYPE_MPEG1_VCD = 4, /* MPEG-1 VCD-compatible stream */
++ V4L2_MPEG_STREAM_TYPE_MPEG2_SVCD = 5, /* MPEG-2 SVCD-compatible stream */
++};
++#define V4L2_CID_MPEG_STREAM_PID_PMT (V4L2_CID_MPEG_BASE+1)
++#define V4L2_CID_MPEG_STREAM_PID_AUDIO (V4L2_CID_MPEG_BASE+2)
++#define V4L2_CID_MPEG_STREAM_PID_VIDEO (V4L2_CID_MPEG_BASE+3)
++#define V4L2_CID_MPEG_STREAM_PID_PCR (V4L2_CID_MPEG_BASE+4)
++#define V4L2_CID_MPEG_STREAM_PES_ID_AUDIO (V4L2_CID_MPEG_BASE+5)
++#define V4L2_CID_MPEG_STREAM_PES_ID_VIDEO (V4L2_CID_MPEG_BASE+6)
++#define V4L2_CID_MPEG_STREAM_VBI_FMT (V4L2_CID_MPEG_BASE+7)
++enum v4l2_mpeg_stream_vbi_fmt {
++ V4L2_MPEG_STREAM_VBI_FMT_NONE = 0, /* No VBI in the MPEG stream */
++ V4L2_MPEG_STREAM_VBI_FMT_IVTV = 1, /* VBI in private packets, IVTV format */
++};
++
++/* MPEG audio */
++#define V4L2_CID_MPEG_AUDIO_SAMPLING_FREQ (V4L2_CID_MPEG_BASE+100)
++enum v4l2_mpeg_audio_sampling_freq {
++ V4L2_MPEG_AUDIO_SAMPLING_FREQ_44100 = 0,
++ V4L2_MPEG_AUDIO_SAMPLING_FREQ_48000 = 1,
++ V4L2_MPEG_AUDIO_SAMPLING_FREQ_32000 = 2,
++};
++#define V4L2_CID_MPEG_AUDIO_ENCODING (V4L2_CID_MPEG_BASE+101)
++enum v4l2_mpeg_audio_encoding {
++ V4L2_MPEG_AUDIO_ENCODING_LAYER_1 = 0,
++ V4L2_MPEG_AUDIO_ENCODING_LAYER_2 = 1,
++ V4L2_MPEG_AUDIO_ENCODING_LAYER_3 = 2,
++ V4L2_MPEG_AUDIO_ENCODING_AAC = 3,
++ V4L2_MPEG_AUDIO_ENCODING_AC3 = 4,
++};
++#define V4L2_CID_MPEG_AUDIO_L1_BITRATE (V4L2_CID_MPEG_BASE+102)
++enum v4l2_mpeg_audio_l1_bitrate {
++ V4L2_MPEG_AUDIO_L1_BITRATE_32K = 0,
++ V4L2_MPEG_AUDIO_L1_BITRATE_64K = 1,
++ V4L2_MPEG_AUDIO_L1_BITRATE_96K = 2,
++ V4L2_MPEG_AUDIO_L1_BITRATE_128K = 3,
++ V4L2_MPEG_AUDIO_L1_BITRATE_160K = 4,
++ V4L2_MPEG_AUDIO_L1_BITRATE_192K = 5,
++ V4L2_MPEG_AUDIO_L1_BITRATE_224K = 6,
++ V4L2_MPEG_AUDIO_L1_BITRATE_256K = 7,
++ V4L2_MPEG_AUDIO_L1_BITRATE_288K = 8,
++ V4L2_MPEG_AUDIO_L1_BITRATE_320K = 9,
++ V4L2_MPEG_AUDIO_L1_BITRATE_352K = 10,
++ V4L2_MPEG_AUDIO_L1_BITRATE_384K = 11,
++ V4L2_MPEG_AUDIO_L1_BITRATE_416K = 12,
++ V4L2_MPEG_AUDIO_L1_BITRATE_448K = 13,
++};
++#define V4L2_CID_MPEG_AUDIO_L2_BITRATE (V4L2_CID_MPEG_BASE+103)
++enum v4l2_mpeg_audio_l2_bitrate {
++ V4L2_MPEG_AUDIO_L2_BITRATE_32K = 0,
++ V4L2_MPEG_AUDIO_L2_BITRATE_48K = 1,
++ V4L2_MPEG_AUDIO_L2_BITRATE_56K = 2,
++ V4L2_MPEG_AUDIO_L2_BITRATE_64K = 3,
++ V4L2_MPEG_AUDIO_L2_BITRATE_80K = 4,
++ V4L2_MPEG_AUDIO_L2_BITRATE_96K = 5,
++ V4L2_MPEG_AUDIO_L2_BITRATE_112K = 6,
++ V4L2_MPEG_AUDIO_L2_BITRATE_128K = 7,
++ V4L2_MPEG_AUDIO_L2_BITRATE_160K = 8,
++ V4L2_MPEG_AUDIO_L2_BITRATE_192K = 9,
++ V4L2_MPEG_AUDIO_L2_BITRATE_224K = 10,
++ V4L2_MPEG_AUDIO_L2_BITRATE_256K = 11,
++ V4L2_MPEG_AUDIO_L2_BITRATE_320K = 12,
++ V4L2_MPEG_AUDIO_L2_BITRATE_384K = 13,
++};
++#define V4L2_CID_MPEG_AUDIO_L3_BITRATE (V4L2_CID_MPEG_BASE+104)
++enum v4l2_mpeg_audio_l3_bitrate {
++ V4L2_MPEG_AUDIO_L3_BITRATE_32K = 0,
++ V4L2_MPEG_AUDIO_L3_BITRATE_40K = 1,
++ V4L2_MPEG_AUDIO_L3_BITRATE_48K = 2,
++ V4L2_MPEG_AUDIO_L3_BITRATE_56K = 3,
++ V4L2_MPEG_AUDIO_L3_BITRATE_64K = 4,
++ V4L2_MPEG_AUDIO_L3_BITRATE_80K = 5,
++ V4L2_MPEG_AUDIO_L3_BITRATE_96K = 6,
++ V4L2_MPEG_AUDIO_L3_BITRATE_112K = 7,
++ V4L2_MPEG_AUDIO_L3_BITRATE_128K = 8,
++ V4L2_MPEG_AUDIO_L3_BITRATE_160K = 9,
++ V4L2_MPEG_AUDIO_L3_BITRATE_192K = 10,
++ V4L2_MPEG_AUDIO_L3_BITRATE_224K = 11,
++ V4L2_MPEG_AUDIO_L3_BITRATE_256K = 12,
++ V4L2_MPEG_AUDIO_L3_BITRATE_320K = 13,
++};
++#define V4L2_CID_MPEG_AUDIO_MODE (V4L2_CID_MPEG_BASE+105)
++enum v4l2_mpeg_audio_mode {
++ V4L2_MPEG_AUDIO_MODE_STEREO = 0,
++ V4L2_MPEG_AUDIO_MODE_JOINT_STEREO = 1,
++ V4L2_MPEG_AUDIO_MODE_DUAL = 2,
++ V4L2_MPEG_AUDIO_MODE_MONO = 3,
++};
++#define V4L2_CID_MPEG_AUDIO_MODE_EXTENSION (V4L2_CID_MPEG_BASE+106)
++enum v4l2_mpeg_audio_mode_extension {
++ V4L2_MPEG_AUDIO_MODE_EXTENSION_BOUND_4 = 0,
++ V4L2_MPEG_AUDIO_MODE_EXTENSION_BOUND_8 = 1,
++ V4L2_MPEG_AUDIO_MODE_EXTENSION_BOUND_12 = 2,
++ V4L2_MPEG_AUDIO_MODE_EXTENSION_BOUND_16 = 3,
++};
++#define V4L2_CID_MPEG_AUDIO_EMPHASIS (V4L2_CID_MPEG_BASE+107)
++enum v4l2_mpeg_audio_emphasis {
++ V4L2_MPEG_AUDIO_EMPHASIS_NONE = 0,
++ V4L2_MPEG_AUDIO_EMPHASIS_50_DIV_15_uS = 1,
++ V4L2_MPEG_AUDIO_EMPHASIS_CCITT_J17 = 2,
++};
++#define V4L2_CID_MPEG_AUDIO_CRC (V4L2_CID_MPEG_BASE+108)
++enum v4l2_mpeg_audio_crc {
++ V4L2_MPEG_AUDIO_CRC_NONE = 0,
++ V4L2_MPEG_AUDIO_CRC_CRC16 = 1,
++};
++#define V4L2_CID_MPEG_AUDIO_MUTE (V4L2_CID_MPEG_BASE+109)
++#define V4L2_CID_MPEG_AUDIO_AAC_BITRATE (V4L2_CID_MPEG_BASE+110)
++#define V4L2_CID_MPEG_AUDIO_AC3_BITRATE (V4L2_CID_MPEG_BASE+111)
++enum v4l2_mpeg_audio_ac3_bitrate {
++ V4L2_MPEG_AUDIO_AC3_BITRATE_32K = 0,
++ V4L2_MPEG_AUDIO_AC3_BITRATE_40K = 1,
++ V4L2_MPEG_AUDIO_AC3_BITRATE_48K = 2,
++ V4L2_MPEG_AUDIO_AC3_BITRATE_56K = 3,
++ V4L2_MPEG_AUDIO_AC3_BITRATE_64K = 4,
++ V4L2_MPEG_AUDIO_AC3_BITRATE_80K = 5,
++ V4L2_MPEG_AUDIO_AC3_BITRATE_96K = 6,
++ V4L2_MPEG_AUDIO_AC3_BITRATE_112K = 7,
++ V4L2_MPEG_AUDIO_AC3_BITRATE_128K = 8,
++ V4L2_MPEG_AUDIO_AC3_BITRATE_160K = 9,
++ V4L2_MPEG_AUDIO_AC3_BITRATE_192K = 10,
++ V4L2_MPEG_AUDIO_AC3_BITRATE_224K = 11,
++ V4L2_MPEG_AUDIO_AC3_BITRATE_256K = 12,
++ V4L2_MPEG_AUDIO_AC3_BITRATE_320K = 13,
++ V4L2_MPEG_AUDIO_AC3_BITRATE_384K = 14,
++ V4L2_MPEG_AUDIO_AC3_BITRATE_448K = 15,
++ V4L2_MPEG_AUDIO_AC3_BITRATE_512K = 16,
++ V4L2_MPEG_AUDIO_AC3_BITRATE_576K = 17,
++ V4L2_MPEG_AUDIO_AC3_BITRATE_640K = 18,
++};
++
++/* MPEG video */
++#define V4L2_CID_MPEG_VIDEO_ENCODING (V4L2_CID_MPEG_BASE+200)
++enum v4l2_mpeg_video_encoding {
++ V4L2_MPEG_VIDEO_ENCODING_MPEG_1 = 0,
++ V4L2_MPEG_VIDEO_ENCODING_MPEG_2 = 1,
++ V4L2_MPEG_VIDEO_ENCODING_MPEG_4_AVC = 2,
++};
++#define V4L2_CID_MPEG_VIDEO_ASPECT (V4L2_CID_MPEG_BASE+201)
++enum v4l2_mpeg_video_aspect {
++ V4L2_MPEG_VIDEO_ASPECT_1x1 = 0,
++ V4L2_MPEG_VIDEO_ASPECT_4x3 = 1,
++ V4L2_MPEG_VIDEO_ASPECT_16x9 = 2,
++ V4L2_MPEG_VIDEO_ASPECT_221x100 = 3,
++};
++#define V4L2_CID_MPEG_VIDEO_B_FRAMES (V4L2_CID_MPEG_BASE+202)
++#define V4L2_CID_MPEG_VIDEO_GOP_SIZE (V4L2_CID_MPEG_BASE+203)
++#define V4L2_CID_MPEG_VIDEO_GOP_CLOSURE (V4L2_CID_MPEG_BASE+204)
++#define V4L2_CID_MPEG_VIDEO_PULLDOWN (V4L2_CID_MPEG_BASE+205)
++#define V4L2_CID_MPEG_VIDEO_BITRATE_MODE (V4L2_CID_MPEG_BASE+206)
++enum v4l2_mpeg_video_bitrate_mode {
++ V4L2_MPEG_VIDEO_BITRATE_MODE_VBR = 0,
++ V4L2_MPEG_VIDEO_BITRATE_MODE_CBR = 1,
++};
++#define V4L2_CID_MPEG_VIDEO_BITRATE (V4L2_CID_MPEG_BASE+207)
++#define V4L2_CID_MPEG_VIDEO_BITRATE_PEAK (V4L2_CID_MPEG_BASE+208)
++#define V4L2_CID_MPEG_VIDEO_TEMPORAL_DECIMATION (V4L2_CID_MPEG_BASE+209)
++#define V4L2_CID_MPEG_VIDEO_MUTE (V4L2_CID_MPEG_BASE+210)
++#define V4L2_CID_MPEG_VIDEO_MUTE_YUV (V4L2_CID_MPEG_BASE+211)
++
++/* MPEG-class control IDs specific to the CX2341x driver as defined by V4L2 */
++#define V4L2_CID_MPEG_CX2341X_BASE (V4L2_CTRL_CLASS_MPEG | 0x1000)
++#define V4L2_CID_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE (V4L2_CID_MPEG_CX2341X_BASE+0)
++enum v4l2_mpeg_cx2341x_video_spatial_filter_mode {
++ V4L2_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE_MANUAL = 0,
++ V4L2_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE_AUTO = 1,
++};
++#define V4L2_CID_MPEG_CX2341X_VIDEO_SPATIAL_FILTER (V4L2_CID_MPEG_CX2341X_BASE+1)
++#define V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE (V4L2_CID_MPEG_CX2341X_BASE+2)
++enum v4l2_mpeg_cx2341x_video_luma_spatial_filter_type {
++ V4L2_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_OFF = 0,
++ V4L2_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_1D_HOR = 1,
++ V4L2_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_1D_VERT = 2,
++ V4L2_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_2D_HV_SEPARABLE = 3,
++ V4L2_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_2D_SYM_NON_SEPARABLE = 4,
++};
++#define V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE (V4L2_CID_MPEG_CX2341X_BASE+3)
++enum v4l2_mpeg_cx2341x_video_chroma_spatial_filter_type {
++ V4L2_MPEG_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE_OFF = 0,
++ V4L2_MPEG_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE_1D_HOR = 1,
++};
++#define V4L2_CID_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER_MODE (V4L2_CID_MPEG_CX2341X_BASE+4)
++enum v4l2_mpeg_cx2341x_video_temporal_filter_mode {
++ V4L2_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER_MODE_MANUAL = 0,
++ V4L2_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER_MODE_AUTO = 1,
++};
++#define V4L2_CID_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER (V4L2_CID_MPEG_CX2341X_BASE+5)
++#define V4L2_CID_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE (V4L2_CID_MPEG_CX2341X_BASE+6)
++enum v4l2_mpeg_cx2341x_video_median_filter_type {
++ V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_OFF = 0,
++ V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_HOR = 1,
++ V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_VERT = 2,
++ V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_HOR_VERT = 3,
++ V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_DIAG = 4,
++};
++#define V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_BOTTOM (V4L2_CID_MPEG_CX2341X_BASE+7)
++#define V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_TOP (V4L2_CID_MPEG_CX2341X_BASE+8)
++#define V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_BOTTOM (V4L2_CID_MPEG_CX2341X_BASE+9)
++#define V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_TOP (V4L2_CID_MPEG_CX2341X_BASE+10)
++#define V4L2_CID_MPEG_CX2341X_STREAM_INSERT_NAV_PACKETS (V4L2_CID_MPEG_CX2341X_BASE+11)
++
++/* Camera class control IDs */
++#define V4L2_CID_CAMERA_CLASS_BASE (V4L2_CTRL_CLASS_CAMERA | 0x900)
++#define V4L2_CID_CAMERA_CLASS (V4L2_CTRL_CLASS_CAMERA | 1)
++
++#define V4L2_CID_EXPOSURE_AUTO (V4L2_CID_CAMERA_CLASS_BASE+1)
++enum v4l2_exposure_auto_type {
++ V4L2_EXPOSURE_AUTO = 0,
++ V4L2_EXPOSURE_MANUAL = 1,
++ V4L2_EXPOSURE_SHUTTER_PRIORITY = 2,
++ V4L2_EXPOSURE_APERTURE_PRIORITY = 3
++};
++#define V4L2_CID_EXPOSURE_ABSOLUTE (V4L2_CID_CAMERA_CLASS_BASE+2)
++#define V4L2_CID_EXPOSURE_AUTO_PRIORITY (V4L2_CID_CAMERA_CLASS_BASE+3)
++
++#define V4L2_CID_PAN_RELATIVE (V4L2_CID_CAMERA_CLASS_BASE+4)
++#define V4L2_CID_TILT_RELATIVE (V4L2_CID_CAMERA_CLASS_BASE+5)
++#define V4L2_CID_PAN_RESET (V4L2_CID_CAMERA_CLASS_BASE+6)
++#define V4L2_CID_TILT_RESET (V4L2_CID_CAMERA_CLASS_BASE+7)
++
++#define V4L2_CID_PAN_ABSOLUTE (V4L2_CID_CAMERA_CLASS_BASE+8)
++#define V4L2_CID_TILT_ABSOLUTE (V4L2_CID_CAMERA_CLASS_BASE+9)
++
++#define V4L2_CID_FOCUS_ABSOLUTE (V4L2_CID_CAMERA_CLASS_BASE+10)
++#define V4L2_CID_FOCUS_RELATIVE (V4L2_CID_CAMERA_CLASS_BASE+11)
++#define V4L2_CID_FOCUS_AUTO (V4L2_CID_CAMERA_CLASS_BASE+12)
++
++#define V4L2_CID_ZOOM_ABSOLUTE (V4L2_CID_CAMERA_CLASS_BASE+13)
++#define V4L2_CID_ZOOM_RELATIVE (V4L2_CID_CAMERA_CLASS_BASE+14)
++#define V4L2_CID_ZOOM_CONTINUOUS (V4L2_CID_CAMERA_CLASS_BASE+15)
++
++#define V4L2_CID_PRIVACY (V4L2_CID_CAMERA_CLASS_BASE+16)
++
++#define V4L2_CID_IRIS_ABSOLUTE (V4L2_CID_CAMERA_CLASS_BASE+17)
++#define V4L2_CID_IRIS_RELATIVE (V4L2_CID_CAMERA_CLASS_BASE+18)
++
++/* FM Modulator class control IDs */
++#define V4L2_CID_FM_TX_CLASS_BASE (V4L2_CTRL_CLASS_FM_TX | 0x900)
++#define V4L2_CID_FM_TX_CLASS (V4L2_CTRL_CLASS_FM_TX | 1)
++
++#define V4L2_CID_RDS_TX_DEVIATION (V4L2_CID_FM_TX_CLASS_BASE + 1)
++#define V4L2_CID_RDS_TX_PI (V4L2_CID_FM_TX_CLASS_BASE + 2)
++#define V4L2_CID_RDS_TX_PTY (V4L2_CID_FM_TX_CLASS_BASE + 3)
++#define V4L2_CID_RDS_TX_PS_NAME (V4L2_CID_FM_TX_CLASS_BASE + 5)
++#define V4L2_CID_RDS_TX_RADIO_TEXT (V4L2_CID_FM_TX_CLASS_BASE + 6)
++
++#define V4L2_CID_AUDIO_LIMITER_ENABLED (V4L2_CID_FM_TX_CLASS_BASE + 64)
++#define V4L2_CID_AUDIO_LIMITER_RELEASE_TIME (V4L2_CID_FM_TX_CLASS_BASE + 65)
++#define V4L2_CID_AUDIO_LIMITER_DEVIATION (V4L2_CID_FM_TX_CLASS_BASE + 66)
++
++#define V4L2_CID_AUDIO_COMPRESSION_ENABLED (V4L2_CID_FM_TX_CLASS_BASE + 80)
++#define V4L2_CID_AUDIO_COMPRESSION_GAIN (V4L2_CID_FM_TX_CLASS_BASE + 81)
++#define V4L2_CID_AUDIO_COMPRESSION_THRESHOLD (V4L2_CID_FM_TX_CLASS_BASE + 82)
++#define V4L2_CID_AUDIO_COMPRESSION_ATTACK_TIME (V4L2_CID_FM_TX_CLASS_BASE + 83)
++#define V4L2_CID_AUDIO_COMPRESSION_RELEASE_TIME (V4L2_CID_FM_TX_CLASS_BASE + 84)
++
++#define V4L2_CID_PILOT_TONE_ENABLED (V4L2_CID_FM_TX_CLASS_BASE + 96)
++#define V4L2_CID_PILOT_TONE_DEVIATION (V4L2_CID_FM_TX_CLASS_BASE + 97)
++#define V4L2_CID_PILOT_TONE_FREQUENCY (V4L2_CID_FM_TX_CLASS_BASE + 98)
++
++#define V4L2_CID_TUNE_PREEMPHASIS (V4L2_CID_FM_TX_CLASS_BASE + 112)
++enum v4l2_preemphasis {
++ V4L2_PREEMPHASIS_DISABLED = 0,
++ V4L2_PREEMPHASIS_50_uS = 1,
++ V4L2_PREEMPHASIS_75_uS = 2,
++};
++#define V4L2_CID_TUNE_POWER_LEVEL (V4L2_CID_FM_TX_CLASS_BASE + 113)
++#define V4L2_CID_TUNE_ANTENNA_CAPACITOR (V4L2_CID_FM_TX_CLASS_BASE + 114)
++
++/*
++ * T U N I N G
++ */
++struct v4l2_tuner {
++ __u32 index;
++ __u8 name[32];
++ enum v4l2_tuner_type type;
++ __u32 capability;
++ __u32 rangelow;
++ __u32 rangehigh;
++ __u32 rxsubchans;
++ __u32 audmode;
++ __s32 signal;
++ __s32 afc;
++ __u32 reserved[4];
++};
++
++struct v4l2_modulator {
++ __u32 index;
++ __u8 name[32];
++ __u32 capability;
++ __u32 rangelow;
++ __u32 rangehigh;
++ __u32 txsubchans;
++ __u32 reserved[4];
++};
++
++/* Flags for the 'capability' field */
++#define V4L2_TUNER_CAP_LOW 0x0001
++#define V4L2_TUNER_CAP_NORM 0x0002
++#define V4L2_TUNER_CAP_STEREO 0x0010
++#define V4L2_TUNER_CAP_LANG2 0x0020
++#define V4L2_TUNER_CAP_SAP 0x0020
++#define V4L2_TUNER_CAP_LANG1 0x0040
++#define V4L2_TUNER_CAP_RDS 0x0080
++#define V4L2_TUNER_CAP_RDS_BLOCK_IO 0x0100
++#define V4L2_TUNER_CAP_RDS_CONTROLS 0x0200
++
++/* Flags for the 'rxsubchans' field */
++#define V4L2_TUNER_SUB_MONO 0x0001
++#define V4L2_TUNER_SUB_STEREO 0x0002
++#define V4L2_TUNER_SUB_LANG2 0x0004
++#define V4L2_TUNER_SUB_SAP 0x0004
++#define V4L2_TUNER_SUB_LANG1 0x0008
++#define V4L2_TUNER_SUB_RDS 0x0010
++
++/* Values for the 'audmode' field */
++#define V4L2_TUNER_MODE_MONO 0x0000
++#define V4L2_TUNER_MODE_STEREO 0x0001
++#define V4L2_TUNER_MODE_LANG2 0x0002
++#define V4L2_TUNER_MODE_SAP 0x0002
++#define V4L2_TUNER_MODE_LANG1 0x0003
++#define V4L2_TUNER_MODE_LANG1_LANG2 0x0004
++
++struct v4l2_frequency {
++ __u32 tuner;
++ enum v4l2_tuner_type type;
++ __u32 frequency;
++ __u32 reserved[8];
++};
++
++struct v4l2_hw_freq_seek {
++ __u32 tuner;
++ enum v4l2_tuner_type type;
++ __u32 seek_upward;
++ __u32 wrap_around;
++ __u32 spacing;
++ __u32 reserved[7];
++};
++
++/*
++ * R D S
++ */
++
++struct v4l2_rds_data {
++ __u8 lsb;
++ __u8 msb;
++ __u8 block;
++} __attribute__ ((packed));
++
++#define V4L2_RDS_BLOCK_MSK 0x7
++#define V4L2_RDS_BLOCK_A 0
++#define V4L2_RDS_BLOCK_B 1
++#define V4L2_RDS_BLOCK_C 2
++#define V4L2_RDS_BLOCK_D 3
++#define V4L2_RDS_BLOCK_C_ALT 4
++#define V4L2_RDS_BLOCK_INVALID 7
++
++#define V4L2_RDS_BLOCK_CORRECTED 0x40
++#define V4L2_RDS_BLOCK_ERROR 0x80
++
++/*
++ * A U D I O
++ */
++struct v4l2_audio {
++ __u32 index;
++ __u8 name[32];
++ __u32 capability;
++ __u32 mode;
++ __u32 reserved[2];
++};
++
++/* Flags for the 'capability' field */
++#define V4L2_AUDCAP_STEREO 0x00001
++#define V4L2_AUDCAP_AVL 0x00002
++
++/* Flags for the 'mode' field */
++#define V4L2_AUDMODE_AVL 0x00001
++
++struct v4l2_audioout {
++ __u32 index;
++ __u8 name[32];
++ __u32 capability;
++ __u32 mode;
++ __u32 reserved[2];
++};
++
++/*
++ * M P E G S E R V I C E S
++ *
++ * NOTE: EXPERIMENTAL API
++ */
++#if 1
++#define V4L2_ENC_IDX_FRAME_I (0)
++#define V4L2_ENC_IDX_FRAME_P (1)
++#define V4L2_ENC_IDX_FRAME_B (2)
++#define V4L2_ENC_IDX_FRAME_MASK (0xf)
++
++struct v4l2_enc_idx_entry {
++ __u64 offset;
++ __u64 pts;
++ __u32 length;
++ __u32 flags;
++ __u32 reserved[2];
++};
++
++#define V4L2_ENC_IDX_ENTRIES (64)
++struct v4l2_enc_idx {
++ __u32 entries;
++ __u32 entries_cap;
++ __u32 reserved[4];
++ struct v4l2_enc_idx_entry entry[V4L2_ENC_IDX_ENTRIES];
++};
++
++
++#define V4L2_ENC_CMD_START (0)
++#define V4L2_ENC_CMD_STOP (1)
++#define V4L2_ENC_CMD_PAUSE (2)
++#define V4L2_ENC_CMD_RESUME (3)
++
++/* Flags for V4L2_ENC_CMD_STOP */
++#define V4L2_ENC_CMD_STOP_AT_GOP_END (1 << 0)
++
++struct v4l2_encoder_cmd {
++ __u32 cmd;
++ __u32 flags;
++ union {
++ struct {
++ __u32 data[8];
++ } raw;
++ };
++};
++
++#endif
++
++
++/*
++ * D A T A S E R V I C E S ( V B I )
++ *
++ * Data services API by Michael Schimek
++ */
++
++/* Raw VBI */
++struct v4l2_vbi_format {
++ __u32 sampling_rate; /* in 1 Hz */
++ __u32 offset;
++ __u32 samples_per_line;
++ __u32 sample_format; /* V4L2_PIX_FMT_* */
++ __s32 start[2];
++ __u32 count[2];
++ __u32 flags; /* V4L2_VBI_* */
++ __u32 reserved[2]; /* must be zero */
++};
++
++/* VBI flags */
++#define V4L2_VBI_UNSYNC (1 << 0)
++#define V4L2_VBI_INTERLACED (1 << 1)
++
++/* Sliced VBI
++ *
++ * This implements is a proposal V4L2 API to allow SLICED VBI
++ * required for some hardware encoders. It should change without
++ * notice in the definitive implementation.
++ */
++
++struct v4l2_sliced_vbi_format {
++ __u16 service_set;
++ /* service_lines[0][...] specifies lines 0-23 (1-23 used) of the first field
++ service_lines[1][...] specifies lines 0-23 (1-23 used) of the second field
++ (equals frame lines 313-336 for 625 line video
++ standards, 263-286 for 525 line standards) */
++ __u16 service_lines[2][24];
++ __u32 io_size;
++ __u32 reserved[2]; /* must be zero */
++};
++
++/* Teletext World System Teletext
++ (WST), defined on ITU-R BT.653-2 */
++#define V4L2_SLICED_TELETEXT_B (0x0001)
++/* Video Program System, defined on ETS 300 231*/
++#define V4L2_SLICED_VPS (0x0400)
++/* Closed Caption, defined on EIA-608 */
++#define V4L2_SLICED_CAPTION_525 (0x1000)
++/* Wide Screen System, defined on ITU-R BT1119.1 */
++#define V4L2_SLICED_WSS_625 (0x4000)
++
++#define V4L2_SLICED_VBI_525 (V4L2_SLICED_CAPTION_525)
++#define V4L2_SLICED_VBI_625 (V4L2_SLICED_TELETEXT_B | V4L2_SLICED_VPS | V4L2_SLICED_WSS_625)
++
++struct v4l2_sliced_vbi_cap {
++ __u16 service_set;
++ /* service_lines[0][...] specifies lines 0-23 (1-23 used) of the first field
++ service_lines[1][...] specifies lines 0-23 (1-23 used) of the second field
++ (equals frame lines 313-336 for 625 line video
++ standards, 263-286 for 525 line standards) */
++ __u16 service_lines[2][24];
++ enum v4l2_buf_type type;
++ __u32 reserved[3]; /* must be 0 */
++};
++
++struct v4l2_sliced_vbi_data {
++ __u32 id;
++ __u32 field; /* 0: first field, 1: second field */
++ __u32 line; /* 1-23 */
++ __u32 reserved; /* must be 0 */
++ __u8 data[48];
++};
++
++/*
++ * Sliced VBI data inserted into MPEG Streams
++ */
++
++/*
++ * V4L2_MPEG_STREAM_VBI_FMT_IVTV:
++ *
++ * Structure of payload contained in an MPEG 2 Private Stream 1 PES Packet in an
++ * MPEG-2 Program Pack that contains V4L2_MPEG_STREAM_VBI_FMT_IVTV Sliced VBI
++ * data
++ *
++ * Note, the MPEG-2 Program Pack and Private Stream 1 PES packet header
++ * definitions are not included here. See the MPEG-2 specifications for details
++ * on these headers.
++ */
++
++/* Line type IDs */
++#define V4L2_MPEG_VBI_IVTV_TELETEXT_B (1)
++#define V4L2_MPEG_VBI_IVTV_CAPTION_525 (4)
++#define V4L2_MPEG_VBI_IVTV_WSS_625 (5)
++#define V4L2_MPEG_VBI_IVTV_VPS (7)
++
++struct v4l2_mpeg_vbi_itv0_line {
++ __u8 id; /* One of V4L2_MPEG_VBI_IVTV_* above */
++ __u8 data[42]; /* Sliced VBI data for the line */
++} __attribute__ ((packed));
++
++struct v4l2_mpeg_vbi_itv0 {
++ __le32 linemask[2]; /* Bitmasks of VBI service lines present */
++ struct v4l2_mpeg_vbi_itv0_line line[35];
++} __attribute__ ((packed));
++
++struct v4l2_mpeg_vbi_ITV0 {
++ struct v4l2_mpeg_vbi_itv0_line line[36];
++} __attribute__ ((packed));
++
++#define V4L2_MPEG_VBI_IVTV_MAGIC0 "itv0"
++#define V4L2_MPEG_VBI_IVTV_MAGIC1 "ITV0"
++
++struct v4l2_mpeg_vbi_fmt_ivtv {
++ __u8 magic[4];
++ union {
++ struct v4l2_mpeg_vbi_itv0 itv0;
++ struct v4l2_mpeg_vbi_ITV0 ITV0;
++ };
++} __attribute__ ((packed));
++
++/*
++ * A G G R E G A T E S T R U C T U R E S
++ */
++
++/**
++ * struct v4l2_plane_pix_format - additional, per-plane format definition
++ * @sizeimage: maximum size in bytes required for data, for which
++ * this plane will be used
++ * @bytesperline: distance in bytes between the leftmost pixels in two
++ * adjacent lines
++ */
++struct v4l2_plane_pix_format {
++ __u32 sizeimage;
++ __u16 bytesperline;
++ __u16 reserved[7];
++} __attribute__ ((packed));
++
++/**
++ * struct v4l2_pix_format_mplane - multiplanar format definition
++ * @width: image width in pixels
++ * @height: image height in pixels
++ * @pixelformat: little endian four character code (fourcc)
++ * @field: field order (for interlaced video)
++ * @colorspace: supplemental to pixelformat
++ * @plane_fmt: per-plane information
++ * @num_planes: number of planes for this format
++ */
++struct v4l2_pix_format_mplane {
++ __u32 width;
++ __u32 height;
++ __u32 pixelformat;
++ enum v4l2_field field;
++ enum v4l2_colorspace colorspace;
++
++ struct v4l2_plane_pix_format plane_fmt[VIDEO_MAX_PLANES];
++ __u8 num_planes;
++ __u8 reserved[11];
++} __attribute__ ((packed));
++
++/**
++ * struct v4l2_format - stream data format
++ * @type: type of the data stream
++ * @pix: definition of an image format
++ * @pix_mp: definition of a multiplanar image format
++ * @win: definition of an overlaid image
++ * @vbi: raw VBI capture or output parameters
++ * @sliced: sliced VBI capture or output parameters
++ * @raw_data: placeholder for future extensions and custom formats
++ */
++struct v4l2_format {
++ enum v4l2_buf_type type;
++ union {
++ struct v4l2_pix_format pix; /* V4L2_BUF_TYPE_VIDEO_CAPTURE */
++ struct v4l2_pix_format_mplane pix_mp; /* V4L2_BUF_TYPE_VIDEO_CAPTURE_MPLANE */
++ struct v4l2_window win; /* V4L2_BUF_TYPE_VIDEO_OVERLAY */
++ struct v4l2_vbi_format vbi; /* V4L2_BUF_TYPE_VBI_CAPTURE */
++ struct v4l2_sliced_vbi_format sliced; /* V4L2_BUF_TYPE_SLICED_VBI_CAPTURE */
++ __u8 raw_data[200]; /* user-defined */
++ } fmt;
++};
++
++/* Stream type-dependent parameters
++ */
++struct v4l2_streamparm {
++ enum v4l2_buf_type type;
++ union {
++ struct v4l2_captureparm capture;
++ struct v4l2_outputparm output;
++ __u8 raw_data[200]; /* user-defined */
++ } parm;
++};
++
++/*
++ * E V E N T S
++ */
++
++#define V4L2_EVENT_ALL 0
++#define V4L2_EVENT_VSYNC 1
++#define V4L2_EVENT_EOS 2
++#define V4L2_EVENT_PRIVATE_START 0x08000000
++
++/* Payload for V4L2_EVENT_VSYNC */
++struct v4l2_event_vsync {
++ /* Can be V4L2_FIELD_ANY, _NONE, _TOP or _BOTTOM */
++ __u8 field;
++} __attribute__ ((packed));
++
++struct v4l2_event {
++ __u32 type;
++ union {
++ struct v4l2_event_vsync vsync;
++ __u8 data[64];
++ } u;
++ __u32 pending;
++ __u32 sequence;
++ struct timespec timestamp;
++ __u32 reserved[9];
++};
++
++struct v4l2_event_subscription {
++ __u32 type;
++ __u32 reserved[7];
++};
++
++/*
++ * A D V A N C E D D E B U G G I N G
++ *
++ * NOTE: EXPERIMENTAL API, NEVER RELY ON THIS IN APPLICATIONS!
++ * FOR DEBUGGING, TESTING AND INTERNAL USE ONLY!
++ */
++
++/* VIDIOC_DBG_G_REGISTER and VIDIOC_DBG_S_REGISTER */
++
++#define V4L2_CHIP_MATCH_HOST 0 /* Match against chip ID on host (0 for the host) */
++#define V4L2_CHIP_MATCH_I2C_DRIVER 1 /* Match against I2C driver name */
++#define V4L2_CHIP_MATCH_I2C_ADDR 2 /* Match against I2C 7-bit address */
++#define V4L2_CHIP_MATCH_AC97 3 /* Match against anciliary AC97 chip */
++
++struct v4l2_dbg_match {
++ __u32 type; /* Match type */
++ union { /* Match this chip, meaning determined by type */
++ __u32 addr;
++ char name[32];
++ };
++} __attribute__ ((packed));
++
++struct v4l2_dbg_register {
++ struct v4l2_dbg_match match;
++ __u32 size; /* register size in bytes */
++ __u64 reg;
++ __u64 val;
++} __attribute__ ((packed));
++
++/* VIDIOC_DBG_G_CHIP_IDENT */
++struct v4l2_dbg_chip_ident {
++ struct v4l2_dbg_match match;
++ __u32 ident; /* chip identifier as specified in <media/v4l2-chip-ident.h> */
++ __u32 revision; /* chip revision, chip specific */
++} __attribute__ ((packed));
++
++/*
++ * I O C T L C O D E S F O R V I D E O D E V I C E S
++ *
++ */
++#define VIDIOC_QUERYCAP _IOR('V', 0, struct v4l2_capability)
++#define VIDIOC_RESERVED _IO('V', 1)
++#define VIDIOC_ENUM_FMT _IOWR('V', 2, struct v4l2_fmtdesc)
++#define VIDIOC_G_FMT _IOWR('V', 4, struct v4l2_format)
++#define VIDIOC_S_FMT _IOWR('V', 5, struct v4l2_format)
++#define VIDIOC_REQBUFS _IOWR('V', 8, struct v4l2_requestbuffers)
++#define VIDIOC_QUERYBUF _IOWR('V', 9, struct v4l2_buffer)
++#define VIDIOC_G_FBUF _IOR('V', 10, struct v4l2_framebuffer)
++#define VIDIOC_S_FBUF _IOW('V', 11, struct v4l2_framebuffer)
++#define VIDIOC_OVERLAY _IOW('V', 14, int)
++#define VIDIOC_QBUF _IOWR('V', 15, struct v4l2_buffer)
++#define VIDIOC_DQBUF _IOWR('V', 17, struct v4l2_buffer)
++#define VIDIOC_STREAMON _IOW('V', 18, int)
++#define VIDIOC_STREAMOFF _IOW('V', 19, int)
++#define VIDIOC_G_PARM _IOWR('V', 21, struct v4l2_streamparm)
++#define VIDIOC_S_PARM _IOWR('V', 22, struct v4l2_streamparm)
++#define VIDIOC_G_STD _IOR('V', 23, v4l2_std_id)
++#define VIDIOC_S_STD _IOW('V', 24, v4l2_std_id)
++#define VIDIOC_ENUMSTD _IOWR('V', 25, struct v4l2_standard)
++#define VIDIOC_ENUMINPUT _IOWR('V', 26, struct v4l2_input)
++#define VIDIOC_G_CTRL _IOWR('V', 27, struct v4l2_control)
++#define VIDIOC_S_CTRL _IOWR('V', 28, struct v4l2_control)
++#define VIDIOC_G_TUNER _IOWR('V', 29, struct v4l2_tuner)
++#define VIDIOC_S_TUNER _IOW('V', 30, struct v4l2_tuner)
++#define VIDIOC_G_AUDIO _IOR('V', 33, struct v4l2_audio)
++#define VIDIOC_S_AUDIO _IOW('V', 34, struct v4l2_audio)
++#define VIDIOC_QUERYCTRL _IOWR('V', 36, struct v4l2_queryctrl)
++#define VIDIOC_QUERYMENU _IOWR('V', 37, struct v4l2_querymenu)
++#define VIDIOC_G_INPUT _IOR('V', 38, int)
++#define VIDIOC_S_INPUT _IOWR('V', 39, int)
++#define VIDIOC_G_OUTPUT _IOR('V', 46, int)
++#define VIDIOC_S_OUTPUT _IOWR('V', 47, int)
++#define VIDIOC_ENUMOUTPUT _IOWR('V', 48, struct v4l2_output)
++#define VIDIOC_G_AUDOUT _IOR('V', 49, struct v4l2_audioout)
++#define VIDIOC_S_AUDOUT _IOW('V', 50, struct v4l2_audioout)
++#define VIDIOC_G_MODULATOR _IOWR('V', 54, struct v4l2_modulator)
++#define VIDIOC_S_MODULATOR _IOW('V', 55, struct v4l2_modulator)
++#define VIDIOC_G_FREQUENCY _IOWR('V', 56, struct v4l2_frequency)
++#define VIDIOC_S_FREQUENCY _IOW('V', 57, struct v4l2_frequency)
++#define VIDIOC_CROPCAP _IOWR('V', 58, struct v4l2_cropcap)
++#define VIDIOC_G_CROP _IOWR('V', 59, struct v4l2_crop)
++#define VIDIOC_S_CROP _IOW('V', 60, struct v4l2_crop)
++#define VIDIOC_G_JPEGCOMP _IOR('V', 61, struct v4l2_jpegcompression)
++#define VIDIOC_S_JPEGCOMP _IOW('V', 62, struct v4l2_jpegcompression)
++#define VIDIOC_QUERYSTD _IOR('V', 63, v4l2_std_id)
++#define VIDIOC_TRY_FMT _IOWR('V', 64, struct v4l2_format)
++#define VIDIOC_ENUMAUDIO _IOWR('V', 65, struct v4l2_audio)
++#define VIDIOC_ENUMAUDOUT _IOWR('V', 66, struct v4l2_audioout)
++#define VIDIOC_G_PRIORITY _IOR('V', 67, enum v4l2_priority)
++#define VIDIOC_S_PRIORITY _IOW('V', 68, enum v4l2_priority)
++#define VIDIOC_G_SLICED_VBI_CAP _IOWR('V', 69, struct v4l2_sliced_vbi_cap)
++#define VIDIOC_LOG_STATUS _IO('V', 70)
++#define VIDIOC_G_EXT_CTRLS _IOWR('V', 71, struct v4l2_ext_controls)
++#define VIDIOC_S_EXT_CTRLS _IOWR('V', 72, struct v4l2_ext_controls)
++#define VIDIOC_TRY_EXT_CTRLS _IOWR('V', 73, struct v4l2_ext_controls)
++#if 1
++#define VIDIOC_ENUM_FRAMESIZES _IOWR('V', 74, struct v4l2_frmsizeenum)
++#define VIDIOC_ENUM_FRAMEINTERVALS _IOWR('V', 75, struct v4l2_frmivalenum)
++#define VIDIOC_G_ENC_INDEX _IOR('V', 76, struct v4l2_enc_idx)
++#define VIDIOC_ENCODER_CMD _IOWR('V', 77, struct v4l2_encoder_cmd)
++#define VIDIOC_TRY_ENCODER_CMD _IOWR('V', 78, struct v4l2_encoder_cmd)
++#endif
++
++#if 1
++/* Experimental, meant for debugging, testing and internal use.
++ Only implemented if CONFIG_VIDEO_ADV_DEBUG is defined.
++ You must be root to use these ioctls. Never use these in applications! */
++#define VIDIOC_DBG_S_REGISTER _IOW('V', 79, struct v4l2_dbg_register)
++#define VIDIOC_DBG_G_REGISTER _IOWR('V', 80, struct v4l2_dbg_register)
++
++/* Experimental, meant for debugging, testing and internal use.
++ Never use this ioctl in applications! */
++#define VIDIOC_DBG_G_CHIP_IDENT _IOWR('V', 81, struct v4l2_dbg_chip_ident)
++#endif
++
++#define VIDIOC_S_HW_FREQ_SEEK _IOW('V', 82, struct v4l2_hw_freq_seek)
++#define VIDIOC_ENUM_DV_PRESETS _IOWR('V', 83, struct v4l2_dv_enum_preset)
++#define VIDIOC_S_DV_PRESET _IOWR('V', 84, struct v4l2_dv_preset)
++#define VIDIOC_G_DV_PRESET _IOWR('V', 85, struct v4l2_dv_preset)
++#define VIDIOC_QUERY_DV_PRESET _IOR('V', 86, struct v4l2_dv_preset)
++#define VIDIOC_S_DV_TIMINGS _IOWR('V', 87, struct v4l2_dv_timings)
++#define VIDIOC_G_DV_TIMINGS _IOWR('V', 88, struct v4l2_dv_timings)
++#define VIDIOC_DQEVENT _IOR('V', 89, struct v4l2_event)
++#define VIDIOC_SUBSCRIBE_EVENT _IOW('V', 90, struct v4l2_event_subscription)
++#define VIDIOC_UNSUBSCRIBE_EVENT _IOW('V', 91, struct v4l2_event_subscription)
++
++#define BASE_VIDIOC_PRIVATE 192 /* 192-255 are private */
++
++#endif /* __LINUX_VIDEODEV2_H */
diff --git a/extra/xf86-video-vesa/PKGBUILD b/extra/xf86-video-vesa/PKGBUILD
index 91d85103c..95ee4a1ae 100644
--- a/extra/xf86-video-vesa/PKGBUILD
+++ b/extra/xf86-video-vesa/PKGBUILD
@@ -1,32 +1,39 @@
-# $Id: PKGBUILD 140592 2011-10-17 09:55:09Z jgc $
+# $Id: PKGBUILD 153382 2012-03-12 20:55:11Z andyrtr $
# Maintainer: Jan de Groot <jgc@archlinux.org>
pkgname=xf86-video-vesa
pkgver=2.3.0
-pkgrel=7
+pkgrel=8
+_gitver=4ba7306fd0c9533750d389829e2cbf0522e149b3
pkgdesc="X.org vesa video driver"
arch=(i686 x86_64)
license=('custom')
url="http://xorg.freedesktop.org/"
depends=('glibc')
-makedepends=('pkgconfig' 'xorg-server-devel>=1.10.99.902')
-conflicts=('xorg-server<1.10.99.902')
+makedepends=('pkgconfig' 'xorg-server-devel>=1.11.99.903')
+conflicts=('xorg-server<1.11.99.903')
groups=('xorg-drivers' 'xorg')
options=('!libtool')
-source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2
- git-fixes.patch
+source=(#${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2
+ http://cgit.freedesktop.org/xorg/driver/xf86-video-vesa/snapshot/xf86-video-vesa-${_gitver}.tar.gz
+ #git-fixes.patch
revert-kernelcheck.patch)
-sha1sums=('4689b7c295d7a8d7326302dafecb812739617134'
- '1e54ae50daa796ab0c29c8088f25e522dc6faa4a'
+sha1sums=('52f5bf577038c6fe7819743ceac787bb619b6d47'
'c14454521ac91aaa08aad8a6025d7720a613d54b')
build() {
- cd "${srcdir}/${pkgname}-${pkgver}"
- patch -Np1 -i "${srcdir}/git-fixes.patch"
+ #cd "${srcdir}/${pkgname}-${pkgver}"
+ cd ${srcdir}/${pkgname}*
+ #patch -Np1 -i "${srcdir}/git-fixes.patch"
patch -Np1 -R -i "${srcdir}/revert-kernelcheck.patch"
autoreconf -fi
./configure --prefix=/usr
make
+}
+
+package() {
+ #cd "${srcdir}/${pkgname}-${pkgver}"
+ cd ${srcdir}/${pkgname}*
make DESTDIR="${pkgdir}" install
install -d -m755 "${pkgdir}/usr/share/licenses/${pkgname}"
install -m644 COPYING "${pkgdir}/usr/share/licenses/${pkgname}/"
diff --git a/extra/xf86-video-voodoo/PKGBUILD b/extra/xf86-video-voodoo/PKGBUILD
index 2ee2775ef..61689bd1c 100644
--- a/extra/xf86-video-voodoo/PKGBUILD
+++ b/extra/xf86-video-voodoo/PKGBUILD
@@ -1,16 +1,16 @@
-# $Id: PKGBUILD 140284 2011-10-11 21:28:14Z jgc $
+# $Id: PKGBUILD 153386 2012-03-12 20:55:23Z andyrtr $
# Maintainer: Jan de Groot <jgc@archlinux.org>
pkgname=xf86-video-voodoo
pkgver=1.2.4
-pkgrel=5
+pkgrel=6
pkgdesc="X.org 3dfx Voodoo1/Voodoo2 2D video driver"
arch=(i686 x86_64)
url="http://xorg.freedesktop.org/"
license=('custom')
depends=('glibc')
-makedepends=('xorg-server-devel>=1.10.99.902' 'xf86dgaproto')
-conflicts=('xorg-server<1.10.99.902')
+makedepends=('xorg-server-devel>=1.11.99.903' 'xf86dgaproto')
+conflicts=('xorg-server<1.11.99.903')
groups=('xorg-drivers' 'xorg')
options=('!libtool')
source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2)
@@ -20,6 +20,10 @@ build() {
cd "${srcdir}/${pkgname}-${pkgver}"
./configure --prefix=/usr
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}/LICENSE"
diff --git a/extra/xf86-video-xgixp/PKGBUILD b/extra/xf86-video-xgixp/PKGBUILD
index c3dd3e706..c44223f1b 100644
--- a/extra/xf86-video-xgixp/PKGBUILD
+++ b/extra/xf86-video-xgixp/PKGBUILD
@@ -1,16 +1,16 @@
-# $Id: PKGBUILD 140282 2011-10-11 21:28:12Z jgc $
+# $Id: PKGBUILD 153388 2012-03-12 20:55:30Z andyrtr $
# Maintainer: Jan de Groot <jgc@archlinux.org>
pkgname=xf86-video-xgixp
pkgver=1.8.0
-pkgrel=4
+pkgrel=5
pkgdesc="X.org XGIXP video driver"
arch=(i686 x86_64)
url="http://xorg.freedesktop.org/"
license=('custom')
depends=('glibc')
-makedepends=('xorg-server-devel>=1.10.99.902' 'libdrm' 'xf86driproto' 'mesa' 'glproto')
-conflicts=('xorg-server<1.10.99.902')
+makedepends=('xorg-server-devel>=1.11.99.903' 'libdrm' 'xf86driproto' 'mesa') # 'glproto')
+conflicts=('xorg-server<1.11.99.903')
options=('!libtool')
groups=('xorg-drivers' 'xorg')
source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2
@@ -23,6 +23,10 @@ build() {
patch -Np1 -i "${srcdir}/api-compat-fix-for-DRAWABLE_BUFFER.patch"
./configure --prefix=/usr
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/extra/xorg-server/PKGBUILD b/extra/xorg-server/PKGBUILD
index 5d284ff3d..426450446 100644
--- a/extra/xorg-server/PKGBUILD
+++ b/extra/xorg-server/PKGBUILD
@@ -1,30 +1,31 @@
-# $Id: PKGBUILD 147993 2012-01-29 15:45:06Z andyrtr $
+# $Id: PKGBUILD 153390 2012-03-12 20:55:40Z 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.11.4
+pkgver=1.12.0
pkgrel=1
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' 'libgcrypt')
+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' 'libgcrypt')
options=('!libtool')
source=(${url}/releases/individual/xserver/${pkgbase}-${pkgver}.tar.bz2
autoconfig-nvidia.patch
autoconfig-sis.patch
- revert-trapezoids.patch
#git-fixes.patch
xvfb-run
xvfb-run.1
10-quirks.conf)
-md5sums=('256325e9b17dff479d92bed97f6b0adb'
- '6c7e87d63ac4b535e19a80c89d0cf091'
- 'f8194638ca4872c2b0a67862a70bcebf'
- 'f6c84f4936f8e00abdfbd9fb4eda83fb'
- '52fd3effd80d7bc6c1660d4ecf23d31c'
- '376c70308715cd2643f7bff936d9934b'
- 'd4f7dfc6be4ef4e2c6dd7632a9d88abe')
+sha1sums=('5f48db767f71e9f58ded6ff356f3b8340820e524'
+ 'f19658773d3fa4dc468bb28f9f01866acce71540'
+ '962fecc159c128728f14e8ba231c5b00391ff4ac'
+ 'c94f742d3f9cabf958ae58e4015d9dd185aabedc'
+ '6838fc00ef4618c924a77e0fb03c05346080908a'
+ '993798f3d22ad672d769dae5f48d1fa068d5578f')
build() {
cd "${srcdir}/${pkgbase}-${pkgver}"
@@ -35,9 +36,6 @@ build() {
# Use unofficial imedia SiS driver for supported SiS devices
patch -Np0 -i "${srcdir}/autoconfig-sis.patch"
- # Revert commit that causes huge slowdowns with binary nVidia driver
- patch -Np1 -i "${srcdir}/revert-trapezoids.patch"
-
# Add post-release patches from 1.11 branch
# patch -Np1 -i "${srcdir}/git-fixes.patch"
@@ -54,6 +52,9 @@ build() {
--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 \
@@ -99,6 +100,7 @@ package_xorg-server() {
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
diff --git a/extra/xorg-server/autoconfig-nvidia.patch b/extra/xorg-server/autoconfig-nvidia.patch
index baa2eb601..9ed9b7aee 100644
--- a/extra/xorg-server/autoconfig-nvidia.patch
+++ b/extra/xorg-server/autoconfig-nvidia.patch
@@ -1,29 +1,28 @@
---- a/hw/xfree86/common/xf86pciBus.c
-+++ b/hw/xfree86/common/xf86pciBus.c
-@@ -1123,7 +1123,25 @@ videoPtrToDriverList(struct pci_device *
+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
+@@ -1111,7 +1111,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;
- case 0x102b: driverList[0] = "mga"; break;
- case 0x10c8: driverList[0] = "neomagic"; break;
-- case 0x10de: case 0x12d2: driverList[0] = "nv"; break;
-+ case 0x10de: case 0x12d2:
-+ switch (dev->device_id) {
-+ /* NV1 */
-+ case 0x0008:
-+ case 0x0009:
-+ driverList[0] = "vesa";
-+ break;
-+ /* NV3 */
-+ case 0x0018:
-+ case 0x0019:
-+ driverList[0] = "nv";
-+ break;
-+ default:
-+ driverList[0] = "nouveau";
-+ driverList[1] = "nv";
-+ driverList[2] = "nvidia";
-+ break;
-+ }
-+ break;
- case 0x1106: driverList[0] = "openchrome"; break;
- case 0x1b36: driverList[0] = "qxl"; break;
- case 0x1163: driverList[0] = "rendition"; break;
diff --git a/extra/xorg-xinput/PKGBUILD b/extra/xorg-xinput/PKGBUILD
index e0c49d36e..da046eb76 100644
--- a/extra/xorg-xinput/PKGBUILD
+++ b/extra/xorg-xinput/PKGBUILD
@@ -1,23 +1,27 @@
-# $Id: PKGBUILD 113766 2011-03-10 15:27:48Z jgc $
+# $Id: PKGBUILD 153392 2012-03-12 20:55:45Z andyrtr $
# Maintainer: Jan de Groot <jgc@archlinux.org>
pkgname=xorg-xinput
-pkgver=1.5.3
-pkgrel=2
+pkgver=1.5.99.1
+pkgrel=1
pkgdesc="Small commandline tool to configure devices"
arch=(i686 x86_64)
url="http://xorg.freedesktop.org/"
license=('custom')
-depends=('libx11' 'libxi')
+depends=('libx11' 'libxi>=1.5.99.2' 'xorg-xrandr' 'libxinerama')
makedepends=('xorg-util-macros' 'inputproto')
groups=('xorg-apps' 'xorg')
source=(http://xorg.freedesktop.org/archive/individual/app/xinput-${pkgver}.tar.bz2)
-sha1sums=('70f258279acaa45fb77820ae3f8c2bee9f2d2235')
+sha1sums=('f979d9a4005d71db7e58064dff6ca6738bd9a345')
build() {
cd "${srcdir}/xinput-${pkgver}"
./configure --prefix=/usr
make
+}
+
+package() {
+ cd "${srcdir}/xinput-${pkgver}"
make DESTDIR="${pkgdir}" install
install -m755 -d "${pkgdir}/usr/share/licenses/${pkgname}"
install -m644 COPYING "${pkgdir}/usr/share/licenses/${pkgname}/"