Fixing up CCACHE variables.
This commit is contained in:
parent
e295f8f259
commit
f21c6cf3c1
2 changed files with 20 additions and 0 deletions
|
@ -110,6 +110,18 @@ if [ -f "${DOCKER_WORK_DIR}/.jelos/options" ]; then
|
|||
. "${DOCKER_WORK_DIR}/.jelos/options"
|
||||
fi
|
||||
|
||||
if [ "${LOCAL_CCACHE_SUPPORT}" = "yes" ] && [ -z "${CCACHE_DISABLE}" ]; then
|
||||
# like LOCAL_CC check for local ccache only on the very first
|
||||
# call to config/options, before toolchain has been added to the path,
|
||||
# otherwise we might pick up ccache from toolchain/bin here
|
||||
if [ -z "${LOCAL_CCACHE}" ] && [ "${LOCAL_CCACHE_CHECKED}" != "yes" ]; then
|
||||
export LOCAL_CCACHE="$(command -v ccache)"
|
||||
export LOCAL_CCACHE_CHECKED="yes"
|
||||
fi
|
||||
else
|
||||
export LOCAL_CCACHE=""
|
||||
fi
|
||||
|
||||
# overwrite OEM_SUPPORT via commandline
|
||||
if [ "${OEM}" = "yes" -o "${OEM}" = "no" ]; then
|
||||
OEM_SUPPORT="${OEM}"
|
||||
|
|
|
@ -75,6 +75,14 @@ if [ -z "${CCACHE_DIR}" ]; then
|
|||
export CCACHE_DIR=${BUILD_ROOT}/.ccache-${TARGET_ARCH}
|
||||
fi
|
||||
|
||||
# keep a copy of ccache dir used for toolchain ccache
|
||||
export BUILD_CCACHE_DIR="${CCACHE_DIR}"
|
||||
|
||||
# local ccache dir in case we build early packages with local ccache
|
||||
if [ -z "${LOCAL_CCACHE_DIR}" ]; then
|
||||
export LOCAL_CCACHE_DIR="${BUILD}/.ccache-local"
|
||||
fi
|
||||
|
||||
if [[ -z "$PATH" || ( "$PATH" != "${TOOLCHAIN}/bin:${TOOLCHAIN}/sbin" && "$PATH" = "${PATH#${TOOLCHAIN}/bin:${TOOLCHAIN}/sbin:}" ) ]]; then
|
||||
export PATH="${TOOLCHAIN}/bin:${TOOLCHAIN}/sbin${PATH:+":$PATH"}"
|
||||
fi
|
||||
|
|
Loading…
Reference in a new issue