mesa-gl:moved to "simplified /usr" and towards RCS
[nyanlinux.git] / builders / mesa-gl-amd-sh-c8c354d9c3a2e79230723f1c8b0571b20d034fee / contrib / loader.sh
blobbffeccb7d03d5f3cb42e4c6c27328dea7f9b6d06
1 echo "building loader components-->"
2 #===============================================================================
3 mkdir -p $build_dir/src/loader
4 #-------------------------------------------------------------------------------
5 # XXX: see below
6 loader_c_pathnames="\
7 $src_dir/src/loader/loader.c \
8 $src_dir/src/loader/loader_dri_helper.c \
9 $src_dir/src/x11/loader_x11.c \
11 #-------------------------------------------------------------------------------
12 for src_pathname in $loader_c_pathnames
14 cpp_filename=$(basename $src_pathname .c).cpp.c
15 printf "CPP $src_pathname --> $build_dir/src/loader/$cpp_filename\n"
16 $cpp $src_pathname -o $build_dir/src/loader/$cpp_filename \
17 -DUSE_DRICONF=1 \
18 -DDEFAULT_DRIVER_DIR=\"$dri_driver_search_dir\" \
20 -I$cc_internal_fixed_incdir \
21 -I$cc_internal_incdir \
22 -I$linux_incdir \
23 -I$syslib_incdir \
25 -I$build_dir/src/gallium/frontends/dri \
26 -I$src_dir/src/gallium/frontends/dri \
27 -I$build_dir/src/gallium/include \
28 -I$src_dir/src/gallium/include \
29 -I$build_dir/src/mesa \
30 -I$src_dir/src/mesa \
31 -I$build_dir/src/util \
32 -I$src_dir/src/util \
33 -I$build_dir/src/loader \
34 -I$src_dir/src/loader \
35 -I$build_dir/src \
36 -I$src_dir/src \
37 -I$build_dir/include \
38 -I$src_dir/include \
40 $syslib_cpp_flags_defs \
41 $linux_cpp_flags_defs \
42 $cc_builtins_cpp_flags_defs \
43 $cc_attributes_cpp_flags_defs \
44 $mesa_cpp_flags_defs \
46 $external_deps_cpp_flags &
47 done
48 #-------------------------------------------------------------------------------
49 wait
50 #------------------------------------------------------------------------------
51 for src_pathname in $loader_c_pathnames
53 cpp_filename=$(basename $src_pathname .c).cpp.c
54 asm_filename=$(basename $src_pathname .c).cpp.c.s
55 printf "CC_S $build_dir/src/loader/$cpp_filename --> $build_dir/src/loader/$asm_filename\n"
56 $cc_s $build_dir/src/loader/$cpp_filename -o $build_dir/src/loader/$asm_filename &
57 done
58 #------------------------------------------------------------------------------
59 wait
60 #------------------------------------------------------------------------------
61 for src_pathname in $loader_c_pathnames
63 asm_filename=$(basename $src_pathname .c).cpp.c.s
64 o_filename=$(basename $src_pathname .c).cpp.c.s.o
65 printf "AS $build_dir/src/loader/$asm_filename --> $build_dir/src/loader/$o_filename\n"
66 $as $build_dir/src/loader/$asm_filename -o $build_dir/src/loader/$o_filename &
67 done
68 #------------------------------------------------------------------------------
69 wait
70 #------------------------------------------------------------------------------
71 # this is for a loader on x11/dri platform to go in the generic loader archive
72 printf "AR RCS $build_dir/libloader.a $build_dir/src/loader/loader.cpp.c.s.o $build_dir/src/loader/loader_dri_helper.cpp.c.s.o\n"
73 $ar_rcs $build_dir/libloader.a $build_dir/src/loader/loader.cpp.c.s.o $build_dir/src/loader/loader_dri_helper.cpp.c.s.o &
74 #------------------------------------------------------------------------------
75 printf "AR RCS $build_dir/libloader_x11.a $build_dir/src/loader/loader_x11.cpp.c.s.o\n"
76 $ar_rcs $build_dir/libloader_x11.a $build_dir/src/loader/loader_x11.cpp.c.s.o
77 #------------------------------------------------------------------------------
78 wait
79 #===============================================================================
80 echo "<--loader components built"