15 |
|
|
16 |
cflags= |
cflags= |
17 |
ldflags= |
ldflags= |
18 |
|
rpath= |
19 |
|
|
20 |
for arg in $*; do |
for arg in $*; do |
21 |
optarg=`echo $arg | sed 's/[-a-z]*=//'` |
optarg=`echo $arg | sed 's/[-a-z]*=//'` |
76 |
done |
done |
77 |
|
|
78 |
|
|
|
# Platform-specific options |
|
|
|
|
|
need_runpath=no |
|
|
|
|
|
case `uname -s` in |
|
|
SunOS) |
|
|
ldflags="$ldflags -lsocket -lnsl" |
|
|
need_runpath=yes |
|
|
;; |
|
|
esac |
|
|
|
|
|
|
|
79 |
# Find X installation |
# Find X installation |
80 |
|
|
81 |
xdirs="$extraxdir /usr/X11R6 /usr/X11 /usr/openwin /usr /usr/local/X11R6 /usr/local/X11 /usr/local" |
xdirs="$extraxdir /usr/X11R6 /usr/X11 /usr/openwin /usr /usr/local/X11R6 /usr/local/X11 /usr/local" |
108 |
if [ $xdir != "/usr" ]; then |
if [ $xdir != "/usr" ]; then |
109 |
cflags="$cflags -I$xdir/include" |
cflags="$cflags -I$xdir/include" |
110 |
ldflags="$ldflags -L$xdir/lib" |
ldflags="$ldflags -L$xdir/lib" |
111 |
if [ $need_runpath = "yes" ]; then |
rpath="$rpath:$xdir/lib" |
|
ldflags="$ldflags -R$xdir/lib" |
|
|
fi |
|
112 |
fi |
fi |
113 |
|
|
114 |
ldflags="$ldflags -lX11" |
ldflags="$ldflags -lX11" |
141 |
if [ $ssldir != "/usr" ]; then |
if [ $ssldir != "/usr" ]; then |
142 |
cflags="$cflags -I$ssldir/include" |
cflags="$cflags -I$ssldir/include" |
143 |
ldflags="$ldflags -L$ssldir/lib" |
ldflags="$ldflags -L$ssldir/lib" |
144 |
if [ $need_runpath = "yes" ]; then |
rpath="$rpath:$ssldir/lib" |
|
ldflags="$ldflags -R$ssldir/lib" |
|
|
fi |
|
145 |
fi |
fi |
146 |
|
|
147 |
cflags="$cflags -DWITH_OPENSSL" |
cflags="$cflags -DWITH_OPENSSL" |
150 |
|
|
151 |
|
|
152 |
# Find EGD socket if we don't have /dev/urandom or /dev/random |
# Find EGD socket if we don't have /dev/urandom or /dev/random |
153 |
|
|
154 |
if [ ! -c /dev/random -a ! -c /dev/urandom ]; then |
if [ ! -c /dev/random -a ! -c /dev/urandom ]; then |
155 |
egdpaths="$extraegdpath /var/run/egd-pool /dev/egd-pool /etc/egd-pool /etc/entropy" |
egdpaths="$extraegdpath /var/run/egd-pool /dev/egd-pool /etc/egd-pool /etc/entropy" |
156 |
|
|
175 |
fi |
fi |
176 |
fi |
fi |
177 |
|
|
178 |
|
|
179 |
|
# Platform-specific options |
180 |
|
|
181 |
|
# strip leading colon from rpath |
182 |
|
rpath=`echo $rpath |sed 's/^://'` |
183 |
|
|
184 |
|
case `uname -s` in |
185 |
|
SunOS) |
186 |
|
ldflags="$ldflags -lsocket -lnsl -R$rpath" |
187 |
|
;; |
188 |
|
OSF1) |
189 |
|
ldflags="$ldflags -Wl,-rpath,$rpath" |
190 |
|
;; |
191 |
|
esac |
192 |
|
|
193 |
|
|
194 |
echo "CFLAGS += $cflags" >>Makeconf |
echo "CFLAGS += $cflags" >>Makeconf |
195 |
echo "LDFLAGS += $ldflags" >>Makeconf |
echo "LDFLAGS += $ldflags" >>Makeconf |
196 |
|
|
197 |
echo "configure complete - now run make" |
echo "configure complete - now run make" |
198 |
|
|