* updated kmbox (21.12.1 -> 21.12.2), untested
[t2-trunk.git] / package / base / glibc32 / glibc32.conf
blob8753a5cb93afb756ca72752e75411be098648dff
1 # --- T2-COPYRIGHT-NOTE-BEGIN ---
2 # T2 SDE: package/*/glibc32/glibc32.conf
3 # Copyright (C) 2004 - 2021 The T2 SDE Project
4
5 # This Copyright note is generated by scripts/Create-CopyPatch,
6 # more information can be found in the files COPYING and README.
7
8 # This program is free software; you can redistribute it and/or modify
9 # it under the terms of the GNU General Public License version 2.
10 # --- T2-COPYRIGHT-NOTE-END ---
12 # TODO: ppc64le currently does not support any 32-bit/big-endian
13 if [ "$SDECFG_POWERPC64_ENDIANESS" = "le" ]; then
14         custmain=true
15 else
17 # force 32 bit code
18 if [[ $arch_target = *mips* ]]; then
19         var_insert GCC_WRAPPER_INSERT " " "-mabi=32"
20         var_append GCC_WRAPPER_INSERT " " " -modd-spreg"
21 else
22         var_insert GCC_WRAPPER_INSERT " " "-m32"
25 arch_target="`echo $arch_target | arch2arch32`"
26 echo_status "Set arch_target to $arch_target"
27 set_confopt
29 # force minimal optimization due TLS
30 [ "$SDECFG_X8664_OPT" = "generic" ] && var_append GCC_WRAPPER_INSERT " " "-march=i686"
31 [ "$SDECFG_SPARC64_OPT" = "generic" ] && var_append GCC_WRAPPER_INSERT " " "-mcpu=v9"
33 # do what glibc does
34 . $base/package/*/glibc/glibc.conf
36 # a bit hacky - might need/get a cleanup ...
37 var_append patchfiles " " "`ls $confdir/../glibc/*.patch`"
38 if ! atstage native; then
39         var_append patchfiles " " "`ls $confdir/../glibc/*.patch.cross 2>/dev/null`"
42 # do not build the programs
43 hook_add premake 5 "cat > configparms <<-EOT
44 build-programs=no
45 EOT
48 var_remove makeinstopt ' ' 'install'
49 var_append makeinstopt ' ' 'install-lib-all'
51 libdir="${libdir%/*}/lib"
52 slibdir=lib
54 # and last overwrite the postmake function to do less stuff
55 glibc_postmake() {
56         ln -sfv ../lib64/locale $root$libdir/locale
57         cp -avf gnu/lib-names-*.h $root$includedir/gnu/
59         # Create /lib/ld-lsb.so.1 symlink
60         #
61         if [ -f $root$slibdir/ld-linux-$arch_machine.so.2 ]; then
62                 ln -vfs ld-linux-$arch_machine.so.2 $root$slibdir/ld-lsb.so.1
63         elif [ -f $root$slibdir/ld-linux.so.2 ]; then
64                 ln -vfs ld-linux.so.2 $root$slibdir/ld-lsb.so.1
65         fi