summaryrefslogtreecommitdiff
path: root/scripts/crosstool.sh
diff options
context:
space:
mode:
authorYann E. MORIN" <yann.morin.1998@anciens.enib.fr>2008-06-24 16:19:45 (GMT)
committerYann E. MORIN" <yann.morin.1998@anciens.enib.fr>2008-06-24 16:19:45 (GMT)
commit6180cc0ea5a9041868fd02600f678ecbc60c6c93 (patch)
treec49844cac475e74c3ba1e24a42ee056b71b2a435 /scripts/crosstool.sh
parentbf27958b7de5ff6099261ce885fd5e1e27d31b6b (diff)
Allow to store working files outside the build tree (eg. incase the working tree is on the network).
/trunk/scripts/crosstool.sh | 9 5 4 0 +++++---- /trunk/config/global/paths.in | 23 22 1 0 ++++++++++++++++++++++- 2 files changed, 27 insertions(+), 5 deletions(-)
Diffstat (limited to 'scripts/crosstool.sh')
-rwxr-xr-xscripts/crosstool.sh9
1 files changed, 5 insertions, 4 deletions
diff --git a/scripts/crosstool.sh b/scripts/crosstool.sh
index 62383fd..6002e44 100755
--- a/scripts/crosstool.sh
+++ b/scripts/crosstool.sh
@@ -86,15 +86,16 @@ CT_CC_FILE="${CT_CC}-${CT_CC_VERSION}"
CT_LIBC_FILE="${CT_LIBC}-${CT_LIBC_VERSION}"
# Where will we work?
-CT_TARBALLS_DIR="${CT_TOP_DIR}/targets/tarballs"
-CT_SRC_DIR="${CT_TOP_DIR}/targets/src"
-CT_BUILD_DIR="${CT_TOP_DIR}/targets/${CT_TARGET}/build"
+: "${CT_WORK_DIR:=${CT_TOP_DIR}/targets}"
+CT_TARBALLS_DIR="${CT_WORK_DIR}/tarballs"
+CT_SRC_DIR="${CT_WORK_DIR}/src"
+CT_BUILD_DIR="${CT_WORK_DIR}/${CT_TARGET}/build"
CT_DEBUG_INSTALL_DIR="${CT_INSTALL_DIR}/${CT_TARGET}/debug-root"
# Note: we'll always install the core compiler in its own directory, so as to
# not mix the two builds: core and final.
CT_CC_CORE_STATIC_PREFIX_DIR="${CT_BUILD_DIR}/${CT_CC}-core-static"
CT_CC_CORE_SHARED_PREFIX_DIR="${CT_BUILD_DIR}/${CT_CC}-core-shared"
-CT_STATE_DIR="${CT_TOP_DIR}/targets/${CT_TARGET}/state"
+CT_STATE_DIR="${CT_WORK_DIR}/${CT_TARGET}/state"
# We must ensure that we can restart if asked for!
if [ -n "${CT_RESTART}" -a ! -d "${CT_STATE_DIR}" ]; then