summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFathi Boudra <fathi.boudra@linaro.org>2013-10-06 09:34:37 +0300
committerFathi Boudra <fathi.boudra@linaro.org>2013-10-06 09:34:37 +0300
commite70186802e2f61dbc641ea38e0226eac94a175c1 (patch)
tree93d9e833b4f8e46fb374375afc8f97da47d349aa
parent406b461704abd979566df4f17faa04889a33201c (diff)
Move PATH initialization earlier to fix gcc version detection
-rwxr-xr-xjenkins_kernel_build_inst21
1 files changed, 10 insertions, 11 deletions
diff --git a/jenkins_kernel_build_inst b/jenkins_kernel_build_inst
index 694ea9d..aa10e19 100755
--- a/jenkins_kernel_build_inst
+++ b/jenkins_kernel_build_inst
@@ -39,7 +39,6 @@ install_custom_toolchain()
test -f ${toolchain} || curl -sSO ${toolchain_url}
mkdir -p `dirname ${tcbindir}`
tar --strip-components=1 -C `dirname ${tcbindir}` -xf ${toolchain}
-
}
if [ "${ARCH}" = "arm" ]; then
@@ -86,6 +85,15 @@ fi
install_custom_toolchain
+if [ "${use_ccache}" = "true" ]; then
+ export CCACHE_DIR="${CCACHE_DIR:-$PWD/ccache}"
+ export PATH="/usr/lib/ccache:$tcbindir:$default_path"
+ export CROSS_COMPILE="ccache ${compiler_prefix}"
+else
+ export PATH="$tcbindir:$default_path"
+ export CROSS_COMPILE="${compiler_prefix}"
+fi
+
export silent
export make_deb
export conf_git
@@ -100,7 +108,7 @@ export git_web_url
export submit_job
export lava_test_plan
export conf_filenames
-export gcc_version=`sh $PWD/scripts/gcc-version.sh -p ${tcbindir}/${compiler_prefix}gcc`
+export gcc_version=`sh $PWD/scripts/gcc-version.sh -p ${compiler_prefix}gcc`
export bundle_stream_name=`echo $JOB_NAME | sed -e 's/_.*//' -e 's/\./_/g'`
if $git_reset = "true" ; then
@@ -112,15 +120,6 @@ export kernel_release=${kernel_version}-linaro-${kernel_flavour}
export KERNELVERSION=${kernel_version}
export KERNELRELEASE=${kernel_release}
-if [ "${use_ccache}" = "true" ]; then
- export CCACHE_DIR="${CCACHE_DIR:-$PWD/ccache}"
- export PATH="/usr/lib/ccache:$tcbindir:$default_path"
- export CROSS_COMPILE="ccache ${compiler_prefix}"
-else
- export PATH="$tcbindir:$default_path"
- export CROSS_COMPILE="${compiler_prefix}"
-fi
-
# Below is the list of values that will be used in the json files
export KERNEL_GIT=`git config remote.origin.url`
export KERNEL_COMMIT=`git log -n1 --pretty=format:%H`