llvm.org GIT mirror llvm / f881ae0
* Install crosstool in /usr/local/crosstool * Updated LLVM and LLVM-GCC to newer revisions * Allow separate revisions per SVN module * Allow user to override MAKE_OPTS * Removed unused function verifyNotDir() git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@75134 91177308-0d34-0410-b5e6-96231b3b80d8 Misha Brukman 10 years ago
1 changed file(s) with 10 addition(s) and 20 deletion(s). Raw diff Collapse all Expand all
88 echo -n "Welcome to LLVM Linux/X86_64 -> Linux/ARM crosstool "
99 echo "builder/installer; some steps will require sudo privileges."
1010
11 readonly INSTALL_ROOT="${INSTALL_ROOT:-/usr/local}"
11 readonly INSTALL_ROOT="${INSTALL_ROOT:-/usr/local/crosstool}"
1212 # Both $USER and root *must* have read/write access to this dir.
1313 readonly SCRATCH_ROOT=$(mktemp -d "${TMPDIR:-/tmp}/llvm-project.XXXXXX")
1414 readonly SRC_ROOT="${SCRATCH_ROOT}/src"
3232
3333 readonly SYSROOT="${CODE_SOURCERY_ROOT}/${CROSS_TARGET}/libc"
3434
35 readonly LLVM_PROJECT="${INSTALL_ROOT}/llvm-project"
36 readonly LLVM_INSTALL_ROOT="${LLVM_PROJECT}/${CROSS_HOST}/${CROSS_TARGET}"
3735 readonly LLVM_PKG_PATH="${LLVM_PKG_PATH:-${HOME}/llvm-project/snapshots}"
3836
39 # Latest SVN revision known to be working in this configuration.
40 readonly LLVM_DEFAULT_REV="70786"
37 # Latest SVN revisions known to be working in this configuration.
38 readonly LLVM_DEFAULT_REV="74530"
39 readonly LLVMGCC_DEFAULT_REV="74535"
4140
4241 readonly LLVM_PKG="llvm-${LLVM_SVN_REV:-${LLVM_DEFAULT_REV}}.tar.bz2"
4342 readonly LLVM_SRC_DIR="${SRC_ROOT}/llvm"
4443 readonly LLVM_OBJ_DIR="${OBJ_ROOT}/llvm"
45 readonly LLVM_INSTALL_DIR="${LLVM_INSTALL_ROOT}/llvm"
46
47 readonly LLVMGCC_PKG="llvm-gcc-4.2-${LLVMGCC_SVN_REV:-${LLVM_DEFAULT_REV}}.tar.bz2"
44 readonly LLVM_INSTALL_DIR="${INSTALL_ROOT}/${CROSS_TARGET}/llvm"
45
46 readonly LLVMGCC_PKG="llvm-gcc-4.2-${LLVMGCC_SVN_REV:-${LLVMGCC_DEFAULT_REV}}.tar.bz2"
4847 readonly LLVMGCC_SRC_DIR="${SRC_ROOT}/llvm-gcc-4.2"
4948 readonly LLVMGCC_OBJ_DIR="${OBJ_ROOT}/llvm-gcc-4.2"
50 readonly LLVMGCC_INSTALL_DIR="${LLVM_INSTALL_ROOT}/llvm-gcc-4.2"
51
52 readonly MAKE_OPTS="-j2"
53
54 # Verify we aren't going to install into an existing directory as this might
55 # create problems as we won't have a clean install.
56 verifyNotDir() {
57 if [[ -d $1 ]]; then
58 echo "Install dir $1 already exists; remove it to continue."
59 exit
60 fi
61 }
49 readonly LLVMGCC_INSTALL_DIR="${INSTALL_ROOT}/${CROSS_TARGET}/llvm-gcc-4.2"
50
51 readonly MAKE_OPTS="${MAKE_OPTS:--j2}"
6252
6353 # Params:
6454 # $1: directory to be created