File builders/links-2.29/builder.sh changed (mode: 100644) (index 62d4502..446906c) |
... |
... |
rm -Rf $build_dir |
16 |
16 |
mkdir -p $build_dir |
mkdir -p $build_dir |
17 |
17 |
cd $build_dir |
cd $build_dir |
18 |
18 |
|
|
19 |
|
PATH_SAVED=$PATH |
|
20 |
|
export PATH="\ |
|
21 |
|
/nyan/toolchains/binutils-2.36.1-gcc-4.7.4/current/bin:\ |
|
22 |
|
/nyan/make/current/bin:\ |
|
23 |
|
/nyan/pkgconf/current/bin:\ |
|
24 |
|
$PATH\ |
|
25 |
|
" |
|
26 |
|
target_gnu_triple=$(basename "$(ls -d /nyan/toolchains/binutils-2.36.1-gcc-4.7.4/current/bin/*-gcc)") |
|
27 |
|
target_gnu_triple=${target_gnu_triple%-gcc} |
|
28 |
|
|
|
29 |
|
export "PKG_CONFIG_LIBDIR=\ |
|
30 |
|
/nyan/expat/current/lib/pkgconfig:\ |
|
31 |
|
/nyan/nyanuuid/current/lib/pkgconfig:\ |
|
32 |
|
/nyan/fontconfig/current/lib/pkgconfig:\ |
|
33 |
|
/nyan/freetype/current/lib/pkgconfig:\ |
|
34 |
|
/nyan/libSM/current/lib/pkgconfig:\ |
|
35 |
|
/nyan/libICE/current/lib/pkgconfig:\ |
|
36 |
|
/nyan/libXt/current/lib/pkgconfig:\ |
|
37 |
|
/nyan/libXdmcp/current/lib/pkgconfig:\ |
|
38 |
|
/nyan/libXau/current/lib/pkgconfig:\ |
|
39 |
|
/nyan/libpthread-stubs/current/lib/pkgconfig:\ |
|
40 |
|
/nyan/libxcb/current/lib/pkgconfig:\ |
|
41 |
|
/nyan/xorgproto/current/share/pkgconfig:\ |
|
42 |
|
/nyan/libX11/current/lib/pkgconfig" |
|
43 |
|
|
|
44 |
|
export "CPPFLAGS=\ |
|
45 |
|
$(pkgconf --cflags-only-I x11 xt) \ |
|
|
19 |
|
mkdir -p $build_dir/bin |
|
20 |
|
cat >$build_dir/bin/cc <<EOF |
|
21 |
|
#!/bin/sh |
|
22 |
|
exec /opt/toolchains/x64/elf/binutils-gcc/current/bin/gcc \ |
|
23 |
|
\ |
|
24 |
|
-isystem /nyan/linux-headers/current/include \ |
|
25 |
|
-isystem /nyan/glibc/current/include \ |
|
26 |
|
\ |
46 |
27 |
-I/nyan/libjpeg-turbo/current/include \ |
-I/nyan/libjpeg-turbo/current/include \ |
47 |
28 |
-I/nyan/libpng/current/include \ |
-I/nyan/libpng/current/include \ |
48 |
29 |
-I/nyan/zlib/current/include \ |
-I/nyan/zlib/current/include \ |
49 |
30 |
-I/nyan/freetype/current/include/freetype2 \ |
-I/nyan/freetype/current/include/freetype2 \ |
50 |
31 |
-I/nyan/fontconfig/current/include \ |
-I/nyan/fontconfig/current/include \ |
51 |
|
-I/nyan/libressl/current/include" |
|
52 |
|
export "CFLAGS=-O2 -pipe -fPIC $(pkgconf --cflags-only-other x11)" |
|
53 |
|
export "CC=$target_gnu_triple-gcc \ |
|
54 |
|
-isystem /nyan/glibc/current/include \ |
|
55 |
|
-isystem /nyan/linux-headers/current/include \ |
|
56 |
|
-B/nyan/glibc/current/lib -L/nyan/glibc/current/lib -static-libgcc \ |
|
|
32 |
|
-I/nyan/libressl/current/include \ |
|
33 |
|
-I/nyan/xorgproto/current/include \ |
|
34 |
|
-I/nyan/libX11/current/include \ |
|
35 |
|
-I/nyan/libXt/current/include \ |
|
36 |
|
\ |
|
37 |
|
\ |
|
38 |
|
-O2 -pipe -fpic -fPIC -ftls-model=global-dynamic -static-libgcc \ |
|
39 |
|
\ |
|
40 |
|
\ |
|
41 |
|
-Wl,--as-needed \ |
|
42 |
|
-Wl,-s \ |
|
43 |
|
-B/nyan/glibc/current/lib \ |
|
44 |
|
\ |
|
45 |
|
-L/nyan/libressl/current/lib \ |
|
46 |
|
-L/nyan/zlib/current/lib \ |
|
47 |
|
-L/nyan/libX11/current/lib \ |
|
48 |
|
-L/nyan/fontconfig/current/lib \ |
|
49 |
|
-L/nyan/freetype/current/lib \ |
|
50 |
|
-L/nyan/libpng/current/lib \ |
|
51 |
|
-L/nyan/libjpeg-turbo/current/lib \ |
|
52 |
|
-L/nyan/libXt/current/lib \ |
|
53 |
|
\ |
57 |
54 |
-Wl,-rpath-link,\ |
-Wl,-rpath-link,\ |
58 |
55 |
/nyan/freetype/current/lib:\ |
/nyan/freetype/current/lib:\ |
59 |
56 |
/nyan/fontconfig/current/lib:\ |
/nyan/fontconfig/current/lib:\ |
|
... |
... |
export "CC=$target_gnu_triple-gcc \ |
63 |
60 |
/nyan/libxcb/current/lib:\ |
/nyan/libxcb/current/lib:\ |
64 |
61 |
/nyan/libX11/current/lib:\ |
/nyan/libX11/current/lib:\ |
65 |
62 |
/nyan/zlib/current/lib:\ |
/nyan/zlib/current/lib:\ |
66 |
|
/nyan/glibc/current/lib" |
|
67 |
|
export "LDFLAGS=\ |
|
68 |
|
$(pkgconf --libs-only-L x11 xau xcb xdmcp xt) \ |
|
69 |
|
-L/nyan/libjpeg-turbo/current/lib \ |
|
70 |
|
-L/nyan/libpng/current/lib \ |
|
71 |
|
-L/nyan/zlib/current/lib \ |
|
72 |
|
-L/nyan/libressl/current/lib \ |
|
73 |
|
-L/nyan/freetype/current/lib \ |
|
74 |
|
-L/nyan/fontconfig/current/lib \ |
|
75 |
|
-Wl,-s" |
|
76 |
|
export "LIBS=-lpthread -lfreetype -lfontconfig" |
|
|
63 |
|
/nyan/glibc/current/lib \ |
|
64 |
|
\ |
|
65 |
|
"\$@" |
|
66 |
|
EOF |
|
67 |
|
chmod +x $build_dir/bin/cc |
|
68 |
|
|
|
69 |
|
cat >$build_dir/bin/egrep <<EOF |
|
70 |
|
#!/bin/sh |
|
71 |
|
# links configure script is expecting egrep which is being removed |
|
72 |
|
exec grep -E "\$@" |
|
73 |
|
EOF |
|
74 |
|
chmod +x $build_dir/bin/egrep |
|
75 |
|
|
|
76 |
|
PATH_SAVED=$PATH |
|
77 |
|
export PATH="\ |
|
78 |
|
$build_dir/bin:\ |
|
79 |
|
/nyan/make/current/bin:\ |
|
80 |
|
$PATH\ |
|
81 |
|
" |
|
82 |
|
|
|
83 |
|
export CC=cc |
|
84 |
|
export LIBS="\ |
|
85 |
|
-lpthread \ |
|
86 |
|
" |
77 |
87 |
$pkg_dir/configure \ |
$pkg_dir/configure \ |
78 |
88 |
--prefix=/nyan/$src_name/$slot \ |
--prefix=/nyan/$src_name/$slot \ |
79 |
89 |
--enable-graphics |
--enable-graphics |
80 |
|
unset PKG_CONFIG_LIBDIR |
|
81 |
|
unset CPPFLAGS |
|
82 |
|
unset CFLAGS |
|
83 |
90 |
unset CC |
unset CC |
84 |
|
unset LDFLAGS |
|
85 |
91 |
unset LIBS |
unset LIBS |
86 |
92 |
|
|
87 |
93 |
make -j $threads_n |
make -j $threads_n |
|
... |
... |
rm -Rf /nyan/$src_name/$slot/man |
91 |
97 |
|
|
92 |
98 |
export PATH=$PATH_SAVED |
export PATH=$PATH_SAVED |
93 |
99 |
unset PATH_SAVED |
unset PATH_SAVED |
94 |
|
unset target_gnu_triple |
|
95 |
100 |
rm -f $pkgs_dir_root/$archive_name |
rm -f $pkgs_dir_root/$archive_name |
96 |
101 |
rm -Rf $build_dir $pkg_dir |
rm -Rf $build_dir $pkg_dir |