# HG changeset patch # User kevinw # Date 1523464573 25200 # Node ID 5510b933fa58579ce163f845c22ac272c9eb05ac # Parent dd97daafa80b3750d90979f3d30db621ce22ae53 8035825: Warn instead of fail when calling the configure wrapper directly Reviewed-by: ihse, dholmes, tbell diff -r dd97daafa80b -r 5510b933fa58 common/autoconf/configure --- a/common/autoconf/configure Wed Apr 11 04:42:33 2018 -0700 +++ b/common/autoconf/configure Wed Apr 11 09:36:13 2018 -0700 @@ -23,22 +23,23 @@ # if test "x$1" != xCHECKME; then - echo "This script cannot be run directly." + echo "WARNING: Calling the wrapper script directly is deprecated and unsupported." + echo "Not all features of configure will be available." echo "Use the 'configure' script in the top-level directory instead." - exit 1 + TOPDIR=$(cd $(dirname $0)/../.. > /dev/null && pwd) +else + # Now the next argument is the absolute top-level directory path. + # The TOPDIR variable is passed on to configure.ac. + TOPDIR="$2" + # Remove these two arguments to get to the user supplied arguments + shift + shift fi # Force autoconf to use bash. This also means we must disable autoconf re-exec. export CONFIG_SHELL=$BASH export _as_can_reexec=no -# Now the next argument is the absolute top-level directory path. -# The TOPDIR variable is passed on to configure.ac. -TOPDIR="$2" -# Remove these two arguments to get to the user supplied arguments -shift -shift - conf_script_dir="$TOPDIR/common/autoconf" if [ "$CUSTOM_CONFIG_DIR" = "" ]; then diff -r dd97daafa80b -r 5510b933fa58 common/autoconf/configure.ac --- a/common/autoconf/configure.ac Wed Apr 11 04:42:33 2018 -0700 +++ b/common/autoconf/configure.ac Wed Apr 11 09:36:13 2018 -0700 @@ -33,7 +33,7 @@ AC_PREREQ([2.69]) AC_INIT(OpenJDK, jdk8, build-dev@openjdk.java.net,,http://openjdk.java.net) -AC_CONFIG_AUX_DIR([common/autoconf/build-aux]) +AC_CONFIG_AUX_DIR([$TOPDIR/common/autoconf/build-aux]) m4_include([build-aux/pkg.m4]) # Include these first... diff -r dd97daafa80b -r 5510b933fa58 common/autoconf/generated-configure.sh --- a/common/autoconf/generated-configure.sh Wed Apr 11 04:42:33 2018 -0700 +++ b/common/autoconf/generated-configure.sh Wed Apr 11 09:36:13 2018 -0700 @@ -3153,7 +3153,7 @@ ac_aux_dir= -for ac_dir in common/autoconf/build-aux "$srcdir"/common/autoconf/build-aux; do +for ac_dir in $TOPDIR/common/autoconf/build-aux "$srcdir"/$TOPDIR/common/autoconf/build-aux; do if test -f "$ac_dir/install-sh"; then ac_aux_dir=$ac_dir ac_install_sh="$ac_aux_dir/install-sh -c" @@ -3169,7 +3169,7 @@ fi done if test -z "$ac_aux_dir"; then - as_fn_error $? "cannot find install-sh, install.sh, or shtool in common/autoconf/build-aux \"$srcdir\"/common/autoconf/build-aux" "$LINENO" 5 + as_fn_error $? "cannot find install-sh, install.sh, or shtool in $TOPDIR/common/autoconf/build-aux \"$srcdir\"/$TOPDIR/common/autoconf/build-aux" "$LINENO" 5 fi # These three variables are undocumented and unsupported, @@ -4225,7 +4225,7 @@ #CUSTOM_AUTOCONF_INCLUDE # Do not change or remove the following line, it is needed for consistency checks: -DATE_WHEN_GENERATED=1523446931 +DATE_WHEN_GENERATED=1523447858 ############################################################################### #