diff --git a/package/base/binutils/binutils.conf b/package/base/binutils/binutils.conf index b783136ca..eaa511af9 100644 --- a/package/base/binutils/binutils.conf +++ b/package/base/binutils/binutils.conf @@ -48,7 +48,8 @@ if [ $stagelevel -eq 0 ] ; then makeinstopt="install" confopt="--prefix=$root/$cross_tools \ - --host=${CLFS_HOST} --target=${CLFS_TARGET} --with-sysroot=$CLFS \ + --host=${CLFS_HOST} --target=${CLFS_TARGET} \$extraconfopt" + var_append extraconfopt " " "--with-sysroot=$CLFS \ --disable-nls" fi if [ $stagelevel -ge 3 ] ; then @@ -62,8 +63,6 @@ if [ -z "$pkg_binutils_cross" ] ; then fi if [ "$ROCKCFG_MULTILIB" = 0 ] ; then var_append extraconfopt " " "--disable-multilib" -else - var_append extraconfopt " " "--enable-multilib" fi # var_append extraconfopt " " "--enable-64-bit-bfd" # Don't treat warnings as errors. diff --git a/package/base/gcc/gcc.conf b/package/base/gcc/gcc.conf index 38c7e44b2..1056c328d 100644 --- a/package/base/gcc/gcc.conf +++ b/package/base/gcc/gcc.conf @@ -83,7 +83,8 @@ if [ "$pkg_gcc_cross" ] ; then elif [ $stagelevel -eq 0 ] ; then configprefix="" confopt="--prefix=${CLFS}/$cross_tools \ - --host=${CLFS_HOST} --target=${CLFS_TARGET} \ + --host=${CLFS_HOST} --target=${CLFS_TARGET} \$extraconfopt" + var_append extraconfopt " \ --with-sysroot=${CLFS} --disable-nls --disable-shared \ --enable-languages=c" makeopt="all-gcc" @@ -91,7 +92,8 @@ elif [ $stagelevel -eq 0 ] ; then elif [ $stagelevel -eq 1 ] ; then configprefix="" confopt="--prefix=${CLFS}/$cross_tools \ - --host=${CLFS_HOST} --target=${CLFS_TARGET} \ + --host=${CLFS_HOST} --target=${CLFS_TARGET} \$extraconfopt" + var_append extraconfopt " \ --with-sysroot=${CLFS} --disable-nls --enable-shared \ --enable-languages=c,c++ --enable-__cxa_atexit \ --enable-c99 --enable-long-long --enable-threads=posix" @@ -119,7 +121,7 @@ elif [ $stagelevel -ge 2 ] ; then # directories so we can rename them (adding version suffix) before # moving them to their final directories. # - var_append makeopt " " "prefix=/$prefix libdir=/$prefix/lib" + var_append makeopt " " "prefix=/$prefix" var_append makeinstopt " " "prefix=$root/$prefix" for x in bin info man data ; do mkdir -p $builddir/inst_$x @@ -135,8 +137,6 @@ fi if [ "$ROCKCFG_MULTILIB" = 0 ] ; then var_append extraconfopt " " "--disable-multilib" -else - var_append extraconfopt " " "--enable-multilib" fi custmain="custmain" diff --git a/package/base/gcc/parse-config b/package/base/gcc/parse-config index cf6491c3b..c3ddc85d8 100644 --- a/package/base/gcc/parse-config +++ b/package/base/gcc/parse-config @@ -20,7 +20,7 @@ # file for details. # # --- ROCK-COPYRIGHT-NOTE-END --- -if [ $stagelevel -ge 2 -o $stagelevel -eq 1 -a $pkg = glibc ] +if [ $stagelevel -ge 2 -o $stagelevel -eq 1 -a $pkg != gcc ] then # set CC, CXX and F77 environment variables @@ -46,10 +46,10 @@ for x in CC CXX F77 ; do done unset x y z -if [ "$ROCKCFG_MULTILIB" = 1 -a $stagelevel -ge 1 ] ; then +if [ $stagelevel -ge 1 ] ; then if [[ "$xpkg" = *-32bit ]] ; then export CC="${CC} ${BUILD32}" CXX="${CXX} ${BUILD32}" - else + elif [ "$ROCKCFG_MULTILIB" = 1 ] ; then export CC="${CC} ${BUILD64}" CXX="${CXX} ${BUILD64}" fi fi diff --git a/scripts/Build-Pkg b/scripts/Build-Pkg index 3a9ab0a76..c212145dc 100755 --- a/scripts/Build-Pkg +++ b/scripts/Build-Pkg @@ -523,7 +523,7 @@ else fi # -if [[ "$ROCKCFG_MULTILIB" = 0 || "$xpkg" = *-32bit ]] ; then +if [[ -z "$arch_target32" || "$xpkg" = *-32bit ]] ; then multilib="lib" else multilib="lib64"