changeset 1746:5f84cad1fdc9

Make the usr/ move only apply to native-compiler.sh and not cross-compiler.sh (which is a wrapper around native-compiler.sh).
author Rob Landley <rob@landley.net>
date Mon, 23 Feb 2015 01:00:31 -0600
parents 8d82dc711a93
children cb28b1d437b2
files native-compiler.sh
diffstat 1 files changed, 4 insertions(+), 5 deletions(-) [+]
line wrap: on
line diff
--- a/native-compiler.sh	Sun Feb 22 20:45:25 2015 -0600
+++ b/native-compiler.sh	Mon Feb 23 01:00:31 2015 -0600
@@ -12,11 +12,10 @@
 source sources/include.sh && load_target "$1" || exit 1
 check_for_base_arch || exit 0
 
-STAGE_DIR="$STAGE_DIR/usr"
-
 check_prerequisite "${ARCH}-cc"
 
-[ -z "$HOST_ARCH" ] && HOST_ARCH="$ARCH" || check_prerequisite "${HOST_ARCH}-cc"
+[ -z "$HOST_ARCH" ] && HOST_ARCH="$ARCH" && STAGE_DIR="$STAGE_DIR/usr" ||
+  check_prerequisite "${HOST_ARCH}-cc"
 
 mkdir -p "$STAGE_DIR/bin" || dienow
 
@@ -53,11 +52,11 @@
   build_section make
   build_section bash
   build_section distcc
-  cp "$SOURCES/toys/hdainit.sh" "$STAGE_DIR/../init"
+  cp "$SOURCES/toys/hdainit.sh" "$STAGE_DIR/../init" &&
+  mv "$STAGE_DIR"/{man,share/man} || dienow
 fi
 
 # Delete some unneeded files and strip everything else
-mv "$STAGE_DIR"/{man,share/man} &&
 rm -rf "$STAGE_DIR"/{info,libexec/gcc/*/*/install-tools} || dienow
 if [ -z "$SKIP_STRIP" ]
 then