20 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA |
20 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA |
21 # or visit www.oracle.com if you need additional information or have any |
21 # or visit www.oracle.com if you need additional information or have any |
22 # questions. |
22 # questions. |
23 # |
23 # |
24 |
24 |
25 if test "x$BASH_VERSION" = x; then |
25 if test "x$1" != xCHECKME; then |
26 echo This script needs bash to run. |
26 echo "This script cannot be run directly." |
27 echo It is recommended to use the configure script in the source tree root instead. |
27 echo "Use the 'configure' script in the top-level directory instead." |
28 exit 1 |
28 exit 1 |
29 fi |
29 fi |
30 |
30 |
31 conf_script_dir=`dirname $0` |
31 # Now the next argument is the absolute top-level directory path. |
|
32 # The TOPDIR variable is passed on to configure.ac. |
|
33 TOPDIR="$2" |
|
34 # Remove these two arguments to get to the user supplied arguments |
|
35 shift |
|
36 shift |
|
37 |
|
38 conf_script_dir="$TOPDIR/common/autoconf" |
32 |
39 |
33 if [ "$CUSTOM_CONFIG_DIR" = "" ]; then |
40 if [ "$CUSTOM_CONFIG_DIR" = "" ]; then |
34 conf_custom_script_dir="$conf_script_dir/../../closed/autoconf" |
41 conf_custom_script_dir="$TOPDIR/closed/autoconf" |
35 else |
42 else |
36 conf_custom_script_dir=$CUSTOM_CONFIG_DIR |
43 conf_custom_script_dir="$CUSTOM_CONFIG_DIR" |
37 fi |
44 fi |
38 |
45 |
39 ### |
46 ### |
40 ### Test that the generated configure is up-to-date |
47 ### Test that the generated configure is up-to-date |
41 ### |
48 ### |
224 ### |
231 ### |
225 ### Call the configure script |
232 ### Call the configure script |
226 ### |
233 ### |
227 if test -e $conf_custom_script_dir/generated-configure.sh; then |
234 if test -e $conf_custom_script_dir/generated-configure.sh; then |
228 # Custom source configure available; run that instead |
235 # Custom source configure available; run that instead |
229 echo Running custom generated-configure.sh |
236 echo "Running custom generated-configure.sh" |
230 conf_script_to_run=$conf_custom_script_dir/generated-configure.sh |
237 conf_script_to_run=$conf_custom_script_dir/generated-configure.sh |
231 else |
238 else |
232 echo Running generated-configure.sh |
239 echo "Running generated-configure.sh" |
233 conf_script_to_run=$conf_script_dir/generated-configure.sh |
240 conf_script_to_run=$conf_script_dir/generated-configure.sh |
234 fi |
241 fi |
235 |
242 |
236 if test "x$conf_debug_configure" != x; then |
243 if test "x$conf_debug_configure" != x; then |
237 # Turn on shell debug output if requested (initial or recursive) |
244 # Turn on shell debug output if requested (initial or recursive) |