|
|
@ -29,13 +29,11 @@ pkg_glibc_cross="" |
|
|
|
pkg_glibc_headers_only=0 |
|
|
|
pkg_glibc_cc="" |
|
|
|
|
|
|
|
if [ "$ROCKCFG_MULTILIB" = 1 ] ; then |
|
|
|
if [[ "$xpkg" = *-32bit ]] ; then |
|
|
|
pkg_glibc_cc="$BUILD32" |
|
|
|
pkg_glibc_host="$arch_target32" |
|
|
|
else |
|
|
|
pkg_glibc_cc="$BUILD64" |
|
|
|
fi |
|
|
|
if [[ "$xpkg" = *-32bit ]] ; then |
|
|
|
pkg_glibc_cc="$BUILD32" |
|
|
|
pkg_glibc_host="$arch_target32" |
|
|
|
elif [ "$BUILD64" ] ; then |
|
|
|
pkg_glibc_cc="$BUILD64" |
|
|
|
fi |
|
|
|
|
|
|
|
prefix="usr" |
|
|
@ -69,7 +67,10 @@ if [ $stagelevel -le 2 ]; then |
|
|
|
$confdir/glibc$pkg_glibc_version/*.patch.cross.$arch 2>/dev/null | tr '\n' ' '`" |
|
|
|
fi |
|
|
|
|
|
|
|
configscript="../glibc-*/configure" |
|
|
|
# Use absolute path to configure script as e.g. the path to |
|
|
|
# ports/sysdeps/unix/sysv/linux/mips/mips64/ldd-rewrite.sed is based on it |
|
|
|
# and will point to the wrong location otherwise. |
|
|
|
configscript="$builddir/glibc-*/configure" |
|
|
|
if [ $stagelevel -eq 0 ] ; then |
|
|
|
pkg_glibc_headers_only=1 |
|
|
|
|
|
|
@ -114,10 +115,18 @@ if [ "$pkg_glibc_cross" ] ; then |
|
|
|
fi |
|
|
|
fi |
|
|
|
|
|
|
|
# Fix for mips when building glibc headers. |
|
|
|
if [[ "$pkg_glibc_host" == mips* ]] ; then |
|
|
|
if [ $pkg_glibc_headers_only = 1 ] ; then |
|
|
|
var_append patchfiles " " "$confdir/glibc$pkg_glibc_version/glibc-*-mips-mabi-stage0.diff" |
|
|
|
# Fix for mips/mips64 when building glibc headers. |
|
|
|
if [ $pkg_glibc_headers_only = 1 ] ; then |
|
|
|
if [[ "$arch_machine" == mips* ]] ; then |
|
|
|
# don't pass mips specific options to build C compiler |
|
|
|
var_append BUILDCC_WRAPPER_REMOVE " " "-mabi=*" |
|
|
|
# installing headers fails if _MIPS_SZPTR (and thus _WORDSIZE) |
|
|
|
# is not defined, with: ./bits/types.h:129:3: error: #error |
|
|
|
if [[ "$arch_machine" == mips64* ]] ; then |
|
|
|
var_append BUILDCC_WRAPPER_APPEND " " "-D_MIPS_SZPTR=64" |
|
|
|
else |
|
|
|
var_append BUILDCC_WRAPPER_APPEND " " "-D_MIPS_SZPTR=32" |
|
|
|
fi |
|
|
|
fi |
|
|
|
fi |
|
|
|
|
|
|
|