configure: Use /bin/dash as JAMSHELL if available.
On platforms (such as Haiku) where dash is available or can be installed but is not the default /bin/sh, this can provide a significant improvement to compile times vs. /bin/bash or other more complex shells. At least under Haiku, this is around a ~10% "real" time gain for builds. This also allows one to specify a JAMSHELL by passing that environ to ./configure.
This commit is contained in:
parent
d309d94089
commit
7d72ed0184
17
configure
vendored
17
configure
vendored
@ -541,7 +541,7 @@ configurePath=$0
|
|||||||
configureEnvirons=
|
configureEnvirons=
|
||||||
for var in `env`; do
|
for var in `env`; do
|
||||||
case "$var" in
|
case "$var" in
|
||||||
CC\=*|HAIKU*\=*)
|
CC\=*|HAIKU*\=*|JAMSHELL\=*)
|
||||||
configureEnvirons="$configureEnvirons $var"
|
configureEnvirons="$configureEnvirons $var"
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
@ -824,6 +824,19 @@ if [ $HOST_PLATFORM = "darwin" ]; then
|
|||||||
HOST_EXTENDED_REGEX_SED="sed -E"
|
HOST_EXTENDED_REGEX_SED="sed -E"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# pick a JAMSHELL
|
||||||
|
if [ "$JAMSHELL" = "" ]; then
|
||||||
|
if check_file_exists /bin/dash; then
|
||||||
|
JAMSHELL=/bin/dash
|
||||||
|
else
|
||||||
|
JAMSHELL=/bin/sh
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
if ! $JAMSHELL -c true; then
|
||||||
|
echo "$JAMSHELL does not work! Please specify a working JAMSHELL."
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
# locate python
|
# locate python
|
||||||
if python3 --version < /dev/null > /dev/null 2>&1; then
|
if python3 --version < /dev/null > /dev/null 2>&1; then
|
||||||
HOST_PYTHON="python3"
|
HOST_PYTHON="python3"
|
||||||
@ -1068,6 +1081,8 @@ HAIKU_HOST_USE_XATTR ?= "${HAIKU_HOST_USE_XATTR}" ;
|
|||||||
HAIKU_HOST_USE_XATTR_REF ?= "${HAIKU_HOST_USE_XATTR_REF}" ;
|
HAIKU_HOST_USE_XATTR_REF ?= "${HAIKU_HOST_USE_XATTR_REF}" ;
|
||||||
HAIKU_HOST_BUILD_ONLY ?= "${HAIKU_HOST_BUILD_ONLY}" ;
|
HAIKU_HOST_BUILD_ONLY ?= "${HAIKU_HOST_BUILD_ONLY}" ;
|
||||||
|
|
||||||
|
JAMSHELL ?= ${JAMSHELL} -c ;
|
||||||
|
|
||||||
HOST_CC ?= ${CC} ;
|
HOST_CC ?= ${CC} ;
|
||||||
HOST_GCC_RAW_VERSION ?= ${HOST_GCC_RAW_VERSION} ;
|
HOST_GCC_RAW_VERSION ?= ${HOST_GCC_RAW_VERSION} ;
|
||||||
HOST_GCC_MACHINE ?= ${HOST_GCC_MACHINE} ;
|
HOST_GCC_MACHINE ?= ${HOST_GCC_MACHINE} ;
|
||||||
|
Loading…
Reference in New Issue
Block a user