From 956f53a4f58385d161db4acf134a2117ff7af5c2 Mon Sep 17 00:00:00 2001 From: Rene Rebe Date: Thu, 14 Aug 2003 18:16:11 +0000 Subject: [PATCH] -cross work git-svn-id: http://www.rocklinux.org/svn/rock-linux/trunk@1063 c5f82cb5-29bc-0310-9cd0-bff59a50e3bc --- package/base/gcc3-cross/cross.conf | 13 ++++++++----- package/base/gcc3-cross/gcc3-cross.conf | 16 +++++++++------- 2 files changed, 17 insertions(+), 12 deletions(-) diff --git a/package/base/gcc3-cross/cross.conf b/package/base/gcc3-cross/cross.conf index a241fd672..19c6de6f8 100644 --- a/package/base/gcc3-cross/cross.conf +++ b/package/base/gcc3-cross/cross.conf @@ -21,18 +21,16 @@ # # --- ROCK-COPYRIGHT-NOTE-END --- -# common prefix - -if [ $prefix_auto = 1 ] ; then +# common prefix if not used as stage0 cross-cross-compiler ... +if [ "$stagelevel" -gt 0 -a $prefix_auto = 1 ] ; then if [ "$ROCKCFG_CROSS_PREFIX" ] ; then prefix="$ROCKCFG_CROSS_PREFIX" else prefix="opt/cross-tools" fi + set_confopt fi -set_confopt - archdir="${archdir/-cross/}" realpkg="${pkg/-cross/}" @@ -52,3 +50,8 @@ done arch_target="$ROCKCFG_PKG_CROSSCC_ARCH_TARGET" arch_machine="${arch_target/-*/}" +# # the gcc needs the target binutils during the compilation +# # but can not find it if they are installed in a extraordinary +# # location, like the one used for the stage0 build ... +# var_append PATH ':' "$root/$prefix/bin" + diff --git a/package/base/gcc3-cross/gcc3-cross.conf b/package/base/gcc3-cross/gcc3-cross.conf index 9688b291d..da803402d 100644 --- a/package/base/gcc3-cross/gcc3-cross.conf +++ b/package/base/gcc3-cross/gcc3-cross.conf @@ -24,18 +24,20 @@ . $base/package/base/gcc3-cross/cross.conf gcc_cross_pi(){ - mv -fv $root/$prefix/crosscc/* $root/$prefix/bin - rmdir $root/$prefix/crosscc + if [ $stagelevel = 0 ] ; then + mv -fv $root/$prefix/crosscc/* $root/$prefix/bin + rmdir $root/$prefix/crosscc + fi } -# overwrite some confopt variables ... -confopt="--preifx=$root/$prefix --target=\$arch_target --host=\$arch_build \ - --disable-nls" - # do the same as gcc3 . $base/package/base/gcc3/gcc3.conf -# but always do a cross build ... +# overwrite some confopt variables ... +confopt="--prefix=$root/$prefix --target=\$arch_target --host=\$arch_build \ + --disable-nls" + +# but always do a cross build and some postinstall adaptions ... custmain="gcc_stage0" hook_add postinstall 3 gcc_cross_pi