3 # Look for "unset", you'll find the values you can override in $1 or
4 # $build_dir/local_conf.sh file, that in order to tune the script for your
5 # specific distro/needs.
7 # Usage, drop the script at the top of mesa source tree, create somewhere else
8 # a build directory, cd into it, and call from there this script.
10 # XXX: the defaults are for our custom distro
11 #===================================================================================================
12 # build dir and src dir
13 build_dir
=$
(realpath .
)
14 echo "build_dir=$build_dir"
16 src_dir
=$
(realpath $
(dirname $0)/..
)
17 echo "src_dir=$src_dir"
18 #===================================================================================================
19 # the current configur-able variables may be individually overridden with the
20 # content of the file in $1 or $build_dir/local_conf.sh. Look for "unset"
21 # in those scripts to find what you can override to tune the build.
25 if test -f $build_dir/local_conf.sh
; then
26 .
$build_dir/local_conf.sh
29 #===================================================================================================
30 if test "${xorgproto_inc_dir-unset}" = unset; then
31 xorgproto_inc_dir
=/nyan
/xorgproto
/current
/include
33 xorgproto_cppflags
="-I$xorgproto_inc_dir"
34 #===================================================================================================
35 if test "${cpp-unset}" = unset; then
37 -isystem /nyan/glibc/current/include \
38 -isystem /nyan/linux-headers/current/include \
41 #===================================================================================================
42 if test "${slib_cc-unset}" = unset; then
44 -isystem /nyan/glibc/current/include \
45 -isystem /nyan/linux-headers/current/include \
47 -pipe -fPIC -O2 -ftls-model=global-dynamic -fpic \
50 #===================================================================================================
51 # we are still using the compiler driver, very bad idea
52 if test "${slib_ccld-unset}" = unset; then
56 -B/nyan/glibc/current/lib \
57 -L/nyan/glibc/current/lib \
58 -Wl,-soname=libXau.so.6 \
63 #===================================================================================================
67 -DHAVE_EXPLICIT_BZERO=1 \
76 -DHAVE_SYS_TYPES_H=1 \
80 #===================================================================================================
82 $src_dir/AuDispose.c \
83 $src_dir/AuFileName.c \
84 $src_dir/AuGetAddr.c \
85 $src_dir/AuGetBest.c \
91 #===================================================================================================
94 cpp_file
=$
(basename $f .c
).cpp.c
95 printf "CPP $f -> $build_dir/$cpp_file\n"
96 $cpp -o $build_dir/$cpp_file $f \
103 #===================================================================================================
105 #===================================================================================================
109 cpp_file
=$
(basename $f .c
).cpp.c
110 o_file
=$
(basename $f .c
).o
112 printf "SLIB_CC $build_dir/$cpp_file -> $build_dir/$o_file\n"
113 $slib_cc -o $build_dir/$o_file $build_dir/$cpp_file &
115 #===================================================================================================
117 #===================================================================================================
118 # see $archive/src/Makefile.am for the libtool version
119 printf "SLIB_CCLD $build_dir/libXau.so.6.0.0\n"
120 $slib_ccld -o $build_dir/libXau.so
.6.0.0 $os
121 #===================================================================================================