Mercurial > vanilla
comparison x11/xorg-server/xorg-server.sh @ 268:bb7c444cc223
x11/xorg-server: initial import, closes #1339
author | David Demelier <markand@malikania.fr> |
---|---|
date | Thu, 21 Mar 2019 21:30:00 +0100 |
parents | |
children | ebca5f1df2e4 |
comparison
equal
deleted
inserted
replaced
267:b9b822d63c82 | 268:bb7c444cc223 |
---|---|
1 #!/bin/sh | |
2 # | |
3 # Copyright (c) 2019 David Demelier <markand@malikania.fr> | |
4 # | |
5 # Permission to use, copy, modify, and/or distribute this software for any | |
6 # purpose with or without fee is hereby granted, provided that the above | |
7 # copyright notice and this permission notice appear in all copies. | |
8 # | |
9 # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | |
10 # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | |
11 # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | |
12 # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | |
13 # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | |
14 # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | |
15 # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | |
16 # | |
17 | |
18 PKGNAME=xorg-server | |
19 PKGVERSION=1.20.4 | |
20 PKGREVISION=1 | |
21 PKGLICENSE="CUSTOM" | |
22 PKGSUMMARY="X.Org display server" | |
23 PKGDOWNLOAD="https://www.x.org/releases/individual/xserver/$PKGNAME-$PKGVERSION.tar.gz" | |
24 PKGDEPENDS="x11/libpciaccess x11/libdrm" | |
25 PKGOPTIONS="GLAMOR UDEV WAYLAND" | |
26 | |
27 : ${CHOST:=$(uname -m)-linux-musl} | |
28 : ${CBUILD:=$(uname -m)-linux-musl} | |
29 : ${CC:=gcc} | |
30 : ${CFLAGS:=-O2} | |
31 : ${LDFLAGS:=} | |
32 : ${LIBS:=} | |
33 : ${GLAMOR:=yes} | |
34 : ${UDEV:=yes} | |
35 : ${WAYLAND:=yes} | |
36 | |
37 if [ "$GLAMOR" = "yes" ]; then | |
38 PKGDEPENDS="graphics/mesa $PKGDEPENDS" | |
39 with_glamor="--enable-glamor" | |
40 else | |
41 with_glamor="--disable-glamor" | |
42 fi | |
43 | |
44 if [ "$UDEV" = "yes" ]; then | |
45 PKGDEPENDS="core/eudev $PKGDEPENDS" | |
46 with_udev="--enable-config-udev" | |
47 else | |
48 with_udev="--disable-config-udev" | |
49 fi | |
50 | |
51 if [ "$WAYLAND" = "yes" ]; then | |
52 PKGDEPENDS="graphics/wayland graphics/wayland-protocols:build $PKGDEPENDS" | |
53 with_wayland="--enable-xwayland" | |
54 else | |
55 with_wayland="--disable-xwayland" | |
56 fi | |
57 | |
58 build() | |
59 { | |
60 rm -rf $PKGNAME-$PKGVERSION | |
61 tar xvaf $PKGNAME-$PKGVERSION.tar.gz | |
62 pushd $PKGNAME-$PKGVERSION | |
63 | |
64 CC="$CC" \ | |
65 CFLAGS="$CFLAGS" \ | |
66 LDFLAGS="$LDFLAGS" \ | |
67 LIBS="$LIBS" \ | |
68 ./configure \ | |
69 --build=$CBUILD \ | |
70 --host=$CHOST \ | |
71 --prefix=/usr \ | |
72 --enable-pciaccess \ | |
73 --enable-libdrm \ | |
74 --disable-systemd-logind \ | |
75 $with_glamor \ | |
76 $with_udev \ | |
77 $with_wayland | |
78 make | |
79 make install DESTDIR=$DESTDIR | |
80 | |
81 popd | |
82 rm -rf $PKGNAME-$PKGVERSION | |
83 } |