aboutsummaryrefslogtreecommitdiffstats
path: root/otp_build
diff options
context:
space:
mode:
Diffstat (limited to 'otp_build')
-rwxr-xr-xotp_build55
1 files changed, 55 insertions, 0 deletions
diff --git a/otp_build b/otp_build
index 747cadd483..0222e4923b 100755
--- a/otp_build
+++ b/otp_build
@@ -256,9 +256,59 @@ create_lib_configure_in()
}
}
+find_sum()
+{
+ candidates="sum cksum md5sum sha1sum"
+ SUM_CMD="wc"
+ for x in $candidates; do
+ if (echo foo | $x > /dev/null 2>&1); then
+ SUM_CMD=$x
+ break
+ fi
+ done
+}
+
+chk_eq()
+{
+ master=$1
+ shift
+ slaves="$@"
+ master_sum=`$SUM_CMD $master | awk '{print $1}'`
+ for x in $slaves; do
+ s=`$SUM_CMD $x | awk '{print $1}'`
+ if test "$s" != "$master_sum"; then
+ echo "Error: $master and $x are not equal, make sure they are!" >&2
+ exit 1
+ fi
+ done
+}
+
+check_config_helpers ()
+{
+
+ aclocals="./aclocal.m4 ./lib/erl_interface/aclocal.m4 ./lib/odbc/aclocal.m4 ./lib/wx/aclocal.m4"
+ install_shs="./lib/common_test/priv/auxdir/install-sh ./lib/erl_interface/src/auxdir/install-sh ./lib/test_server/src/install-sh"
+ config_guesses="./lib/common_test/priv/auxdir/config.guess ./lib/erl_interface/src/auxdir/config.guess ./lib/test_server/src/config.guess"
+ config_subs="./lib/common_test/priv/auxdir/config.sub ./lib/erl_interface/src/auxdir/config.sub ./lib/test_server/src/config.sub"
+
+ aclocal_master="./erts/aclocal.m4"
+ install_sh_master="./erts/autoconf/install-sh"
+ config_guess_master="./erts/autoconf/config.guess"
+ config_sub_master="./erts/autoconf/config.sub"
+
+ find_sum
+
+ chk_eq $aclocal_master $aclocals
+ chk_eq $install_sh_master $install_shs
+ chk_eq $config_guess_master $config_guesses
+ chk_eq $config_sub_master $config_subs
+
+}
+
do_autoconf ()
{
create_lib_configure_in
+ check_config_helpers
if target_contains win32; then
# Select the correct autoconf on cygwin
@@ -482,6 +532,7 @@ maybe_copy_static_cache ()
{
if [ '!' -z "$OVERRIDE_CONFIG_CACHE_STATIC" ]; then
if [ '!' -z "$OVERRIDE_CONFIG_CACHE" ]; then
+ echo "Copying static configure cache $OVERRIDE_CONFIG_CACHE_STATIC to $OVERRIDE_CONFIG_CACHE"
cp -f "$OVERRIDE_CONFIG_CACHE_STATIC" "$OVERRIDE_CONFIG_CACHE"
fi
fi
@@ -874,6 +925,10 @@ echo_env_msys64 ()
echo_setenv CXX cc.sh ';'
echo_setenv AR ar.sh ';'
echo_setenv RANLIB true ';'
+ if [ -f "$ERL_TOP/erts/autoconf/win64.config.cache.static" ]; then
+ echo_setenv OVERRIDE_CONFIG_CACHE_STATIC "$ERL_TOP/erts/autoconf/win64.config.cache.static" ';'
+ fi
+
echo_setenv OVERRIDE_CONFIG_CACHE "$ERL_TOP/erts/autoconf/win64.config.cache" ';'
echo_setenv WIN32_WRAPPER_PATH "$WIN32_WRAPPER_PATH" ';'
echo_setenv PATH "$WIN32_WRAPPER_PATH:$P3" ';'