APKBUILD 3.29 KB
Newer Older
Natanael Copa's avatar
Natanael Copa committed
1 2
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=xorg-server
3
pkgver=1.9.4
4
pkgrel=1
Natanael Copa's avatar
Natanael Copa committed
5 6
pkgdesc="X.Org X servers"
url="http://xorg.freedesktop.org"
7
arch="all"
Natanael Copa's avatar
Natanael Copa committed
8
license="custom"
9
subpackages="$pkgname-dev $pkgname-doc xfbdev xvfb"
10
depends="
11 12 13 14 15
	font-misc-misc
	font-cursor-misc
	xkeyboard-config
	xkbcomp
	xinit
16 17
	"
makedepends="
18 19 20 21 22 23
	autoconf
	automake
	bigreqsproto
	compositeproto
	damageproto
	dbus-dev
Natanael Copa's avatar
Natanael Copa committed
24
	dri2proto
25 26 27 28
	fixesproto
	glproto
	inputproto
	libdrm-dev
29
	libpciaccess-dev
30
	libtool
31 32 33
	libx11-dev
	libxdamage-dev
	libxfont-dev
34
	libxinerama-dev
35 36 37 38 39
	libxkbfile-dev
	libxkbui-dev	
	libxv-dev
	libxxf86dga-dev
	libxxf86misc-dev
40
	mesa-dev
41
	openssl-dev
42
	perl
43 44 45
	pixman-dev
	pkgconfig
	randrproto
46
	recordproto
47 48
	renderproto
	resourceproto
49 50 51
	scrnsaverproto
	udev-dev
	util-macros
52 53
	xcmiscproto
	xextproto
54
	xf86driproto
55
	xineramaproto
56 57 58
	xproto
	xtrans
	zlib-dev
Natanael Copa's avatar
Natanael Copa committed
59 60
	"

61 62 63
source="http://xorg.freedesktop.org/releases/individual/xserver/$pkgname-$pkgver.tar.bz2
	xorg-redhat-die-ugly-pattern-die-die-die.patch
"
Natanael Copa's avatar
Natanael Copa committed
64

65
depends_dev="pixman-dev libpciaccess-dev xproto randrproto renderproto
66 67
	xextproto inputproto kbproto fontsproto videoproto xineramaproto
	dri2proto"
68

69
prepare() {
Natanael Copa's avatar
Natanael Copa committed
70
	cd "$srcdir"/$pkgname-$pkgver
71 72 73 74 75 76 77
	
	for i in ../*.patch; do
		msg "Applying $i..."
		patch -Np1 -i "$i" || return 1
	done
	# Fix dbus config path
	sed -i -e 's/\$(sysconfdir)/\/etc/' config/Makefile.*  || return 1
78
}
79

80 81
build() {
	cd "$srcdir"/$pkgname-$pkgver
82 83 84
	# xorg modules does not work with the -z now and it seems like we
	# cannot pass over the linker flag to .so files. so we tweak the
	# gcc specs.
85
	export LDFLAGS="$LDFLAGS -Wl,-z,lazy"
86
	_fontroot="/usr/share/fonts"
87

Natanael Copa's avatar
Natanael Copa committed
88 89 90
	./configure --prefix=/usr \
		--sysconfdir=/etc/X11 \
		--localstatedir=/var \
91 92
		--with-fontrootdir=$_fontroot \
		--with-default-font-path=${_fontroot}/misc,${_fontroot}/100dpi:unscaled,${_fontroot}/75dpi:unscaled,${_fontroot}/TTF,${_fontroot}/Type1 \
93 94 95
		--with-xkb-path=/usr/share/X11/xkb \
		--with-xkb-output=/var/lib/xkb \
		--with-dri-driver-path=/usr/lib/xorg/modules/dri \
96
		--enable-composite \
97
		--enable-config-udev \
98
		--enable-dri \
Natanael Copa's avatar
Natanael Copa committed
99
		--enable-dri2 \
Natanael Copa's avatar
Natanael Copa committed
100 101 102
		--enable-ipv6 \
		--enable-xfbdev \
		--enable-kdrive \
103 104
		--enable-xorg \
		--enable-xv \
105
		--enable-xres \
106
		--enable-xace \
107
		--disable-xephyr \
Natanael Copa's avatar
Natanael Copa committed
108 109 110 111 112
		--disable-config-hal \
		--disable-dmx \
		--disable-tslib \
		--disable-xnest \
		--disable-aiglx \
113 114
		--disable-config-dbus \
		--enable-config-udev \
Natanael Copa's avatar
Natanael Copa committed
115 116
		|| return 1

117
	make || return 1
118
}
Natanael Copa's avatar
Natanael Copa committed
119

120 121
package() {
	cd "$srcdir"/$pkgname-$pkgver
122
	make -j1 DESTDIR="$pkgdir" install || return 1
123
	chmod u+s "$pkgdir"/usr/bin/Xorg
Natanael Copa's avatar
Natanael Copa committed
124 125 126 127 128

	install -m755 -d "$pkgdir"/etc/X11 || return 1
	install -m755 -d "$pkgdir"/var/lib/xkb || return 1
	install -m644 -D COPYING "$pkgdir"/usr/share/licenses/$pkgname/COPYING
}
129 130 131 132


xfbdev() {
	pkgdesc="X.org server for framebuffer"
133
	depends=
134 135 136 137
	mkdir -p "$subpkgdir"/usr/bin
	mv "$pkgdir"/usr/bin/Xfbdev "$subpkgdir"/usr/bin/
}

138 139 140 141 142 143
xvfb() {
	pkgdesc="Virtual Framebuffer 'fake' X server"
	mkdir -p "$subpkgdir"/usr/bin
	mv "$pkgdir"/usr/bin/Xvfb "$subpkgdir"/usr/bin/
}

144 145
xephyr() {
	pkgdesc="kdrive based X Server which targets a window on a host X Server as its framebuffer"
146
	depends=
147 148 149 150
	mkdir -p "$subpkgdir"/usr/bin
	mv "$pkgdir"/usr/bin/Xephyr "$subpkgdir"/usr/bin/
}

151
md5sums="040f091dfdfb4e335116eb0032cc690b  xorg-server-1.9.4.tar.bz2
152
222de594206d1148a90eddfda4f7a11a  xorg-redhat-die-ugly-pattern-die-die-die.patch"