clarify the purpose of this project
[nyanglibc.git] / make / resolv-libanl.sh
blob54c3d3239ea41ae5cec8245924c80faa55260692
1 printf "\
2 RESOLV LIBANL*******************************************************************\n"
3 mkdir -p $build_dir/resolv/libanl
4 fns_pie_shared="\
5 gai_cancel \
6 gai_error \
7 gai_misc \
8 gai_notify \
9 gai_suspend \
10 getaddrinfo_a \
12 fns_pie="\
13 $fns_pie_shared \
15 fns_shared="\
16 $fns_pie_shared \
18 for fn in $fns_pie
20 printf "ASSEMBLING PIE $fn\n"
21 $as $src_dir/resolv/libanl/$fn.s -o $build_dir/resolv/libanl/$fn.o
22 done
23 for fn in $fns_shared
25 printf "ASSEMBLING SHARED $fn\n"
26 $as $src_dir/resolv/libanl/$fn.shared.s -o $build_dir/resolv/libanl/$fn.os
27 done
28 printf 'CREATING LIBANL.A\n'
29 cd $build_dir/resolv/libanl
30 $ar cruv libanl.a gai_cancel.o gai_error.o gai_misc.o gai_notify.o gai_suspend.o getaddrinfo_a.o
31 printf 'CREATING LIBANL_PIC.A\n'
32 $ar cruv libanl_pic.a gai_cancel.os gai_error.os gai_misc.os gai_notify.os gai_suspend.os getaddrinfo_a.os
33 printf 'CREATING LIBANL.SO.1\n'
34 $ld \
35 -s \
36 -shared \
37 -O1 \
38 -z defs \
39 --dynamic-linker=/lib64/ld-linux-x86-64.so.2 \
40 -L$build_dir/csu/ \
41 --version-script=$src_dir/libanl.versions.map \
42 -soname=libanl.so.1 \
43 -z combreloc \
44 -z relro \
45 --hash-style=both \
46 -L$build_dir \
47 -L$build_dir/math \
48 -L$build_dir/elf \
49 -L$build_dir/dlfcn \
50 -L$build_dir/nss \
51 -L$build_dir/nis \
52 -L$build_dir/rt \
53 -L$build_dir/resolv \
54 -L$build_dir/mathvec \
55 -L$build_dir/support \
56 -L$build_dir/crypt \
57 -L$build_dir/nptl \
58 -rpath-link=$build_dir:$build_dir/math:$build_dir/elf:$build_dir/dlfcn:$build_dir/nss:$build_dir/nis:$build_dir/rt:$build_dir/resolv:$build_dir/mathvec:$build_dir/support:$build_dir/crypt:$build_dir/nptl \
59 -o $build_dir/resolv/libanl/libanl.so \
60 -T $src_dir/shlib.lds \
61 $build_dir/csu/abi-note.o \
62 --whole-archive \
63 $build_dir/resolv/libanl/libanl_pic.a \
64 --no-whole-archive \
65 $build_dir/nptl/libpthread.so \
66 --start-group \
67 $build_dir/libc.so \
68 $build_dir/libc_nonshared.a \
69 --as-needed \
70 $build_dir/elf/ld-linux-x86-64.so.2 \
71 --no-as-needed \
72 --end-group