aboutsummaryrefslogtreecommitdiffstats
path: root/kerl
diff options
context:
space:
mode:
authorJoseph Wayne Norton <[email protected]>2013-10-23 22:32:32 -0500
committerJoseph Wayne Norton <[email protected]>2013-10-23 22:52:47 -0500
commit8e7deb76ef61143714c96be71b9c47902de69e61 (patch)
treec2a292c4eec8216c812f690c0ad67727f9e333f4 /kerl
parent6cd7d5764b75efc27a53beae7c887240087e9849 (diff)
downloadkerl-8e7deb76ef61143714c96be71b9c47902de69e61.tar.gz
kerl-8e7deb76ef61143714c96be71b9c47902de69e61.tar.bz2
kerl-8e7deb76ef61143714c96be71b9c47902de69e61.zip
Add support for disabling apps to build via KERL_CONFIGURE_DISABLE_APPLICATIONS
If non-empty, you can specify the subset of applications to disable when building (and subsequent installing) Erlang/OTOP with the KERL_CONFIGURE_DISABLE_APPLICATIONS variable, either in your $HOME/.kerlrc file or prepending it to the command line. e.g. KERL_CONFIGURE_DISABLE_APPLICATIONS="odbc"
Diffstat (limited to 'kerl')
-rwxr-xr-xkerl25
1 files changed, 25 insertions, 0 deletions
diff --git a/kerl b/kerl
index 7af030f..2560571 100755
--- a/kerl
+++ b/kerl
@@ -34,6 +34,9 @@ fi
if [ -n "$KERL_CONFIGURE_APPLICATIONS" ]; then
_KCA="$KERL_CONFIGURE_APPLICATIONS"
fi
+if [ -n "$KERL_CONFIGURE_DISABLE_APPLICATIONS" ]; then
+ _KCDA="$KERL_CONFIGURE_DISABLE_APPLICATIONS"
+fi
if [ -n "$KERL_SASL_STARTUP" ]; then
_KSS="$KERL_SASL_STARTUP"
fi
@@ -45,6 +48,7 @@ if [ -n "$KERL_DEPLOY_RSYNC_OPTIONS" ]; then
fi
KERL_CONFIGURE_OPTIONS=
KERL_CONFIGURE_APPLICATIONS=
+KERL_CONFIGURE_DISABLE_APPLICATIONS=
KERL_SASL_STARTUP=
KERL_INSTALL_MANPAGES=
@@ -60,6 +64,9 @@ fi
if [ -n "$_KCA" ]; then
KERL_CONFIGURE_APPLICATIONS="$_KCA"
fi
+if [ -n "$_KCDA" ]; then
+ KERL_CONFIGURE_DISABLE_APPLICATIONS="$_KCDA"
+fi
if [ -n "$_KSS" ]; then
KERL_SASL_STARTUP="$_KSS"
fi
@@ -292,6 +299,15 @@ do_git_build()
fi
done
fi
+ if [ -n "$KERL_CONFIGURE_DISABLE_APPLICATIONS" ]; then
+ for i in $KERL_CONFIGURE_DISABLE_APPLICATIONS; do
+ touch -f ./lib/$i/SKIP
+ if [ $? -ne 0 ]; then
+ echo "Couldn't disable '$i' application for building"
+ exit 1
+ fi
+ done
+ fi
./otp_build boot -a $KERL_CONFIGURE_OPTIONS > "$LOGFILE" 2>&1
if [ $? -ne 0 ]; then
echo "Build error, see $LOGFILE"
@@ -366,6 +382,15 @@ do_build()
fi
done
fi
+ if [ -n "$KERL_CONFIGURE_DISABLE_APPLICATIONS" ]; then
+ for i in $KERL_CONFIGURE_DISABLE_APPLICATIONS; do
+ touch -f ./lib/$i/SKIP
+ if [ $? -ne 0 ]; then
+ echo "Couldn't disable '$i' application for building"
+ exit 1
+ fi
+ done
+ fi
./otp_build boot -a $KERL_CONFIGURE_OPTIONS > "$LOGFILE" 2>&1
if [ $? -ne 0 ]; then
echo "Build failed, see $LOGFILE"