From 73a53c48901e120a06d221c8cb4f02076e3b9888 Mon Sep 17 00:00:00 2001 From: Joseph Hunkeler Date: Tue, 29 Jan 2019 14:38:49 -0500 Subject: Introduce real toolchain --- scripts/build.sh | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'scripts/build.sh') diff --git a/scripts/build.sh b/scripts/build.sh index 23d0ea1..f7c7a2d 100755 --- a/scripts/build.sh +++ b/scripts/build.sh @@ -1,6 +1,7 @@ #!/bin/bash -e taskdir=${TOOLCHAIN_BUILD}/etc/tasks +export _maxjobs=$(getconf _NPROCESSORS_ONLN) if [[ ! -d ${taskdir} ]]; then echo "No tasks. ${taskdir} does not exist." @@ -16,4 +17,9 @@ do fi echo "Executing: ${task}" ${task} + retval=$? + if [[ ${retval} != 0 ]]; then + echo "TASK FAILED: ${task}" + exit ${retval} + fi done -- cgit From 11f358cafab2da28692fdaa837dfbcc3cc163736 Mon Sep 17 00:00:00 2001 From: Joseph Hunkeler Date: Thu, 31 Jan 2019 14:12:13 -0500 Subject: Refactor all --- scripts/build.sh | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'scripts/build.sh') diff --git a/scripts/build.sh b/scripts/build.sh index f7c7a2d..63f0a00 100755 --- a/scripts/build.sh +++ b/scripts/build.sh @@ -1,13 +1,22 @@ -#!/bin/bash -e +#!/bin/bash -x +prefix="${TOOLCHAIN}" taskdir=${TOOLCHAIN_BUILD}/etc/tasks + export _maxjobs=$(getconf _NPROCESSORS_ONLN) +export PATH="${prefix}/bin:${PATH}" +export CFLAGS="-I${prefix}/include" +export LDFLAGS="-L${prefix}/lib -Wl,-rpath=${prefix}/lib" +export PKG_CONFIG_PATH="${prefix}/lib/pkgconfig" +export PREFIX="${prefix}" if [[ ! -d ${taskdir} ]]; then echo "No tasks. ${taskdir} does not exist." exit 1 fi +printenv | sort + for task in ${taskdir}/* do # Check for execution permission -- cgit