blob: f5ad53c9c42582efbecf549830fb79fc2eb72d11 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
|
#!/bin/bash
# -*- mode: shell-script; coding: UTF-8 -*-
#
# Build Xvnc with Xorg 7.4
#
set -e
if [ "$PREFIX" = "" ]; then
PREFIX=`pwd`/xorg.build
fi
export ACLOCAL="aclocal -I ${PREFIX}/share/aclocal"
export PKG_CONFIG_PATH="${PREFIX}/lib/pkgconfig"
MAKE="make"
CFGFLAGS=
modules="dri2proto \
libpthread-stubs \
glproto \
xf86vidmodeproto \
xextproto \
xproto \
kbproto \
inputproto \
xcmiscproto \
bigreqsproto \
fixesproto \
damageproto \
xf86driproto \
randrproto \
renderproto \
scrnsaverproto \
resourceproto \
fontsproto \
videoproto \
compositeproto \
xineramaproto \
fontcacheproto \
libdrm \
libXau \
xtrans \
libXdmcp \
libX11 \
libXext \
libXxf86vm \
libICE \
libSM \
libXt \
libXmu \
libXfixes \
libXdamage \
libXi \
evieext \
libxkbfile \
libfontenc \
libXfont \
libpciaccess \
xkbcomp \
pixman"
init()
{
mkdir -p xorg
update_modules
pushd xorg
tar jxf util-macros.tar.bz2
pushd util-macros-*
echo "Building macros"
./configure ${1+"$@"} --prefix=${PREFIX}
($MAKE);
make install
popd
popd
pushd xserver
patch -p1 < ../xserver15.patch
popd
autoreconf -fiv
}
update_modules()
{
pushd xorg
../download-xorg
for module in ${modules}; do
tar jxf ${module}.tar.bz2
done
tar jxf Mesa.tar.bz2
tar jxf xorg-server.tar.bz2
cp -r xorg-server-1.*/* ../xserver
popd
}
build ()
{
# Build VNC
echo "*** Building VNC ***"
make distclean || true
./configure ${1+"$@"} --prefix=${PREFIX}
make
# Build Xorg
echo "*** Building Xorg ***"
pushd xorg
for module in ${modules}; do
extraoptions=""
cd ${module}-*
echo ======================
echo configuring ${module}
echo ======================
if [ "${module}" = "libX11" ]; then
extraoptions="${extraoptions} --without-xcb"
fi
if [ "${module}" = "libSM" ]; then
extraoptions="${extraoptions} --without-libuuid"
fi
./configure ${1+"$@"} --prefix="${PREFIX}" ${extraoptions}
echo ======================
echo building ${module}
echo ======================
if [ $? -ne 0 ]; then
echo "Failed to configure ${module}."
exit
fi
($MAKE);
make install
cd ..
done
# build mesa
echo "*** Building Mesa ***"
pushd Mesa-*
./configure ${1+"$@"} --prefix=${PREFIX} --with-driver=dri --disable-glut --without-demos
if [ $? -ne 0 ]; then
echo "Failed to configure Mesa."
exit
fi
($MAKE)
make install
popd
popd
# build xserver
echo "*** Building xserver ***"
cd xserver
autoreconf -fiv
./configure ${1+"$@"} --prefix=${PREFIX} --disable-xinerama --disable-xvfb --disable-xnest --disable-xorg
if [ $? -ne 0 ]; then
echo "Failed to configure X server."
exit
fi
($MAKE)
make install
cd ..
}
case "$1" in
init)
shift
init ${1+"$@"}
;;
build)
shift
build ${1+"$@"}
;;
update)
update_modules
;;
*)
echo "Usage: $0 init | build | update [additional configure flags]"
exit 3
esac
|