[eggheads-patches] PATCH: configure-changes.diff
Tothwolf
tothwolf at concentric.net
Sat Oct 9 20:56:29 CST 1999
configure-changes.diff:
Yet another configure patch...this one adds many sanity checks that were
needed. Both TCLLIB and TCLINC must be set in the environment, or both
--with-tcllib and --with-tclinc specified. If not, configure will
attempt to autodetect both the Tcl library and header files.
``echo "Text" >&2'' have all been converted to AC_MSG_* or
``cat << 'EOF' >&2 now. ./configure --quiet works now :)
Probably other minor changes that I can't think of right now as well...
-Toth
-------------- next part --------------
Index: configure
===================================================================
RCS file: /usr/local/cvsroot/eggdrop1.3/configure,v
retrieving revision 1.22
diff -u -r1.22 configure
--- configure 1999/10/09 17:22:05 1.22
+++ configure 1999/10/10 01:32:25
@@ -528,11 +528,11 @@
ac_default_prefix=\${HOME}/eggdrop
-echo ""
-echo "This is eggdrop's GNU configure script."
-echo "It's going to run a bunch of strange tests to hopefully make"
-echo "your compile work without much twiddling."
-echo ""
+echo "$ac_t""" 1>&6
+echo "$ac_t""This is eggdrop's GNU configure script." 1>&6
+echo "$ac_t""It's going to run a bunch of strange tests to hopefully" 1>&6
+echo "$ac_t""make your compile work without much twiddling." 1>&6
+echo "$ac_t""" 1>&6
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
echo "configure:539: checking whether ${MAKE-make} sets \${MAKE}" >&5
@@ -786,15 +786,18 @@
if test ! "x${cross_compiling}" = "xno"
then
- echo "" >&2
- echo "This system does not appear to have a working C compiler." >&2
- echo "A working C compiler is required to compile eggdrop." >&2
- echo "" >&2
+ cat << 'EOF' >&2
+configure: error:
+
+ This system does not appear to have a working C compiler.
+ A working C compiler is required to compile eggdrop.
+
+EOF
exit 1
fi
echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
-echo "configure:798: checking how to run the C preprocessor" >&5
+echo "configure:801: checking how to run the C preprocessor" >&5
# On Suns, sometimes $CPP names a directory.
if test -n "$CPP" && test -d "$CPP"; then
CPP=
@@ -809,13 +812,13 @@
# On the NeXT, cc -E runs the code through the compiler's parser,
# not just through cpp.
cat > conftest.$ac_ext <<EOF
-#line 813 "configure"
+#line 816 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:819: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:822: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
@@ -826,13 +829,13 @@
rm -rf conftest*
CPP="${CC-cc} -E -traditional-cpp"
cat > conftest.$ac_ext <<EOF
-#line 830 "configure"
+#line 833 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:836: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:839: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
@@ -843,13 +846,13 @@
rm -rf conftest*
CPP="${CC-cc} -nologo -E"
cat > conftest.$ac_ext <<EOF
-#line 847 "configure"
+#line 850 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:853: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:856: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
@@ -874,9 +877,9 @@
echo "$ac_t""$CPP" 1>&6
echo $ac_n "checking for AIX""... $ac_c" 1>&6
-echo "configure:878: checking for AIX" >&5
+echo "configure:881: checking for AIX" >&5
cat > conftest.$ac_ext <<EOF
-#line 880 "configure"
+#line 883 "configure"
#include "confdefs.h"
#ifdef _AIX
yes
@@ -898,7 +901,7 @@
echo $ac_n "checking for POSIXized ISC""... $ac_c" 1>&6
-echo "configure:902: checking for POSIXized ISC" >&5
+echo "configure:905: checking for POSIXized ISC" >&5
if test -d /etc/conf/kconfig.d &&
grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1
then
@@ -920,17 +923,17 @@
ac_safe=`echo "minix/config.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for minix/config.h""... $ac_c" 1>&6
-echo "configure:924: checking for minix/config.h" >&5
+echo "configure:927: checking for minix/config.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 929 "configure"
+#line 932 "configure"
#include "confdefs.h"
#include <minix/config.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:934: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:937: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -971,7 +974,7 @@
# Extract the first word of "ranlib", so it can be a program name with args.
set dummy ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:975: checking for $ac_word" >&5
+echo "configure:978: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1001,7 +1004,7 @@
# Extract the first word of "strip", so it can be a program name with args.
set dummy strip; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1005: checking for $ac_word" >&5
+echo "configure:1008: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_STRIP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1030,7 +1033,7 @@
# Extract the first word of "uname", so it can be a program name with args.
set dummy uname; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1034: checking for $ac_word" >&5
+echo "configure:1037: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_UNAME'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1062,7 +1065,7 @@
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1066: checking for $ac_word" >&5
+echo "configure:1069: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_AWK'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1093,13 +1096,20 @@
if test "x${AWK}" = "x"
then
- { echo "configure: error: This system seems to lack a working 'awk' command." 1>&2; exit 1; }
+ cat << 'EOF' >&2
+configure: error:
+
+ This system seems to lack a working 'awk' command.
+ A working 'awk' command is required to compile eggdrop.
+
+EOF
+ exit 1
fi
# Extract the first word of "basename", so it can be a program name with args.
set dummy basename; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1103: checking for $ac_word" >&5
+echo "configure:1113: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_BASENAME'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1127,13 +1137,20 @@
if test "x${BASENAME}" = "x"
then
- { echo "configure: error: This system seems to lack a working 'basename' command." 1>&2; exit 1; }
+ cat << 'EOF' >&2
+configure: error:
+
+ This system seems to lack a working 'basename' command.
+ A working 'basename' command is required to compile eggdrop.
+
+EOF
+ exit 1
fi
# Extract the first word of "dirname", so it can be a program name with args.
set dummy dirname; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1137: checking for $ac_word" >&5
+echo "configure:1154: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_DIRNAME'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1161,11 +1178,18 @@
if test "x${DIRNAME}" = "x"
then
- { echo "configure: error: This system seems to lack a working 'dirname' command." 1>&2; exit 1; }
+ cat << 'EOF' >&2
+configure: error:
+
+ This system seems to lack a working 'dirname' command.
+ A working 'dirname' command is required to compile eggdrop.
+
+EOF
+ exit 1
fi
echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
-echo "configure:1169: checking whether ln -s works" >&5
+echo "configure:1193: checking whether ln -s works" >&5
if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1187,12 +1211,12 @@
echo $ac_n "checking whether cp -f works""... $ac_c" 1>&6
-echo "configure:1191: checking whether cp -f works" >&5
+echo "configure:1215: checking whether cp -f works" >&5
ac_file1=beldin1
ac_file2=beldin2
ac_cp="cp -f $ac_file1 $ac_file2"
-cat > $ac_file1 <<EOF
+cat > $ac_file1 << 'EOF'
Beldin is a llama. :P
EOF
if { (eval echo configure: \"$ac_cp\") 1>&5; (eval $ac_cp) 2>&5; } && test -s $ac_file2
@@ -1223,7 +1247,7 @@
if test "x${STRIP}" = "x"
then
- STRIP="touch"
+ STRIP=touch
fi
IRIX=no
LINUX=no
@@ -1237,7 +1261,7 @@
SHLIB_LD="${CC}"
SHLIB_STRIP="${STRIP}"
echo $ac_n "checking your OS""... $ac_c" 1>&6
-echo "configure:1241: checking your OS" >&5
+echo "configure:1265: checking your OS" >&5
system=`${UNAME}`
case $system in
Linux)
@@ -1260,11 +1284,11 @@
DEFAULT_MAKE=static
else
echo "$ac_t""BSD/OS 3+! ok I spose" 1>&6
- BEL_MOD_CC="shlicc"
- BEL_MOD_LD="shlicc"
+ BEL_MOD_CC=shlicc
+ BEL_MOD_LD=shlicc
BEL_MOD_STRIP="${STRIP} -d"
SHLIB_LD="shlicc -r"
- SHLIB_STRIP="touch"
+ SHLIB_STRIP=touch
cat >> confdefs.h <<\EOF
#define MODULES_OK 1
EOF
@@ -1273,7 +1297,7 @@
# Extract the first word of "gmake", so it can be a program name with args.
set dummy gmake; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1277: checking for $ac_word" >&5
+echo "configure:1301: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_GMAKE'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1301,10 +1325,13 @@
if test "x${GMAKE}" = "x"
then
- echo "" >&2
- echo "Yoicks! you have BSD/OS & you dont have 'gmake', you may" >&2
- echo "not be able to compile the bot successfully :(" >&2
- echo "" >&2
+ cat << 'EOF' >&2
+configure: warning:
+
+ Yoicks! You have BSD/OS and you dont have 'gmake'.
+ You may not be able to compile the bot successfully :(
+
+EOF
fi
;;
*BSD)
@@ -1323,8 +1350,8 @@
SHLIB_LD="/usr/ccs/bin/ld -G -z text"
else
echo "$ac_t""SunOS 4 :/" 1>&6
- SHLIB_LD="ld"
- SHLIB_STRIP="touch"
+ SHLIB_LD=ld
+ SHLIB_STRIP=touch
fi
SHLIB_CC="${CC} -fPIC"
BEL_MOD_CC="${CC} -fPIC"
@@ -1347,7 +1374,7 @@
;;
1.0|1.1|1.2)
echo "$ac_t""pre 1.3" 1>&6
- SHLIB_LD='ld -R -export $@:'
+ SHLIB_LD="ld -R -export $@:"
cat >> confdefs.h <<\EOF
#define OSF1_HACKS 1
EOF
@@ -1360,7 +1387,7 @@
1.*)
echo "$ac_t""1.3+" 1>&6
SHLIB_CFL="${CC} -fpic"
- SHLIB_LD='ld -shared'
+ SHLIB_LD="ld -shared"
cat >> confdefs.h <<\EOF
#define OSF1_HACKS 1
EOF
@@ -1384,7 +1411,7 @@
HP-UX)
echo "$ac_t""HP-UX, just shoot yourself now" 1>&6
echo $ac_n "checking for shl_load in -ldld""... $ac_c" 1>&6
-echo "configure:1388: checking for shl_load in -ldld" >&5
+echo "configure:1415: checking for shl_load in -ldld" >&5
ac_lib_var=`echo dld'_'shl_load | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -1392,7 +1419,7 @@
ac_save_LIBS="$LIBS"
LIBS="-ldld $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 1396 "configure"
+#line 1423 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@@ -1403,7 +1430,7 @@
shl_load()
; return 0; }
EOF
-if { (eval echo configure:1407: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1434: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@@ -1453,7 +1480,7 @@
IRIX|IRIX64)
echo "$ac_t""you are cursed with IRIX" 1>&6
IRIX=yes
- STRIP=
+ SHLIB_STRIP=touch
need_dl=0
DEFAULT_MAKE=static
;;
@@ -1481,7 +1508,7 @@
echo "configure: warning: Skipping library tests because they *confuse* IRIX." 1>&2
else
echo $ac_n "checking for socket in -lsocket""... $ac_c" 1>&6
-echo "configure:1485: checking for socket in -lsocket" >&5
+echo "configure:1512: checking for socket in -lsocket" >&5
ac_lib_var=`echo socket'_'socket | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -1489,7 +1516,7 @@
ac_save_LIBS="$LIBS"
LIBS="-lsocket $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 1493 "configure"
+#line 1520 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@@ -1500,7 +1527,7 @@
socket()
; return 0; }
EOF
-if { (eval echo configure:1504: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1531: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@@ -1528,7 +1555,7 @@
fi
echo $ac_n "checking for connect in -lnsl""... $ac_c" 1>&6
-echo "configure:1532: checking for connect in -lnsl" >&5
+echo "configure:1559: checking for connect in -lnsl" >&5
ac_lib_var=`echo nsl'_'connect | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -1536,7 +1563,7 @@
ac_save_LIBS="$LIBS"
LIBS="-lnsl $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 1540 "configure"
+#line 1567 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@@ -1547,7 +1574,7 @@
connect()
; return 0; }
EOF
-if { (eval echo configure:1551: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1578: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@@ -1575,7 +1602,7 @@
fi
echo $ac_n "checking for gethostbyname in -ldns""... $ac_c" 1>&6
-echo "configure:1579: checking for gethostbyname in -ldns" >&5
+echo "configure:1606: checking for gethostbyname in -ldns" >&5
ac_lib_var=`echo dns'_'gethostbyname | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -1583,7 +1610,7 @@
ac_save_LIBS="$LIBS"
LIBS="-ldns $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 1587 "configure"
+#line 1614 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@@ -1594,7 +1621,7 @@
gethostbyname()
; return 0; }
EOF
-if { (eval echo configure:1598: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1625: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@@ -1622,7 +1649,7 @@
fi
echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6
-echo "configure:1626: checking for dlopen in -ldl" >&5
+echo "configure:1653: checking for dlopen in -ldl" >&5
ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -1630,7 +1657,7 @@
ac_save_LIBS="$LIBS"
LIBS="-ldl $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 1634 "configure"
+#line 1661 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@@ -1641,7 +1668,7 @@
dlopen()
; return 0; }
EOF
-if { (eval echo configure:1645: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1672: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@@ -1671,14 +1698,14 @@
if test "x`${UNAME}`" = "xSunOS"
then
echo $ac_n "checking for SunOS 4""... $ac_c" 1>&6
-echo "configure:1675: checking for SunOS 4" >&5
+echo "configure:1702: checking for SunOS 4" >&5
if test "x`${UNAME} -r | cut -d . -f 1`" = "x5"
then
echo "$ac_t""Solaris -- "*bollocks*" zarni " 1>&6
else
echo "$ac_t""SunOS -- sigh" 1>&6
echo $ac_n "checking for main in -ldl""... $ac_c" 1>&6
-echo "configure:1682: checking for main in -ldl" >&5
+echo "configure:1709: checking for main in -ldl" >&5
ac_lib_var=`echo dl'_'main | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -1686,14 +1713,14 @@
ac_save_LIBS="$LIBS"
LIBS="-ldl $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 1690 "configure"
+#line 1717 "configure"
#include "confdefs.h"
int main() {
main()
; return 0; }
EOF
-if { (eval echo configure:1697: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1724: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@@ -1725,14 +1752,14 @@
fi
echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6
-echo "configure:1729: checking whether byte ordering is bigendian" >&5
+echo "configure:1756: checking whether byte ordering is bigendian" >&5
if eval "test \"`echo '$''{'ac_cv_c_bigendian'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_cv_c_bigendian=unknown
# See if sys/param.h defines the BYTE_ORDER macro.
cat > conftest.$ac_ext <<EOF
-#line 1736 "configure"
+#line 1763 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <sys/param.h>
@@ -1743,11 +1770,11 @@
#endif
; return 0; }
EOF
-if { (eval echo configure:1747: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1774: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
# It does; now see whether it defined to BIG_ENDIAN or not.
cat > conftest.$ac_ext <<EOF
-#line 1751 "configure"
+#line 1778 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <sys/param.h>
@@ -1758,7 +1785,7 @@
#endif
; return 0; }
EOF
-if { (eval echo configure:1762: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1789: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_c_bigendian=yes
else
@@ -1778,7 +1805,7 @@
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 1782 "configure"
+#line 1809 "configure"
#include "confdefs.h"
main () {
/* Are we little or big endian? From Harbison&Steele. */
@@ -1791,7 +1818,7 @@
exit (u.c[sizeof (long) - 1] == 1);
}
EOF
-if { (eval echo configure:1795: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:1822: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_c_bigendian=no
else
@@ -1815,7 +1842,7 @@
fi
echo $ac_n "checking size of long""... $ac_c" 1>&6
-echo "configure:1819: checking size of long" >&5
+echo "configure:1846: checking size of long" >&5
if eval "test \"`echo '$''{'ac_cv_sizeof_long'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1823,7 +1850,7 @@
ac_cv_sizeof_long=0
else
cat > conftest.$ac_ext <<EOF
-#line 1827 "configure"
+#line 1854 "configure"
#include "confdefs.h"
#include <stdio.h>
main()
@@ -1834,7 +1861,7 @@
exit(0);
}
EOF
-if { (eval echo configure:1838: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:1865: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_sizeof_long=`cat conftestval`
else
@@ -1854,7 +1881,7 @@
echo $ac_n "checking size of int""... $ac_c" 1>&6
-echo "configure:1858: checking size of int" >&5
+echo "configure:1885: checking size of int" >&5
if eval "test \"`echo '$''{'ac_cv_sizeof_int'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1862,7 +1889,7 @@
ac_cv_sizeof_int=0
else
cat > conftest.$ac_ext <<EOF
-#line 1866 "configure"
+#line 1893 "configure"
#include "confdefs.h"
#include <stdio.h>
main()
@@ -1873,7 +1900,7 @@
exit(0);
}
EOF
-if { (eval echo configure:1877: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:1904: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_sizeof_int=`cat conftestval`
else
@@ -1898,12 +1925,12 @@
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr that defines DIR""... $ac_c" 1>&6
-echo "configure:1902: checking for $ac_hdr that defines DIR" >&5
+echo "configure:1929: checking for $ac_hdr that defines DIR" >&5
if eval "test \"`echo '$''{'ac_cv_header_dirent_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 1907 "configure"
+#line 1934 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <$ac_hdr>
@@ -1911,7 +1938,7 @@
DIR *dirp = 0;
; return 0; }
EOF
-if { (eval echo configure:1915: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1942: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
eval "ac_cv_header_dirent_$ac_safe=yes"
else
@@ -1936,7 +1963,7 @@
# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
if test $ac_header_dirent = dirent.h; then
echo $ac_n "checking for opendir in -ldir""... $ac_c" 1>&6
-echo "configure:1940: checking for opendir in -ldir" >&5
+echo "configure:1967: checking for opendir in -ldir" >&5
ac_lib_var=`echo dir'_'opendir | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -1944,7 +1971,7 @@
ac_save_LIBS="$LIBS"
LIBS="-ldir $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 1948 "configure"
+#line 1975 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@@ -1955,7 +1982,7 @@
opendir()
; return 0; }
EOF
-if { (eval echo configure:1959: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1986: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@@ -1977,7 +2004,7 @@
else
echo $ac_n "checking for opendir in -lx""... $ac_c" 1>&6
-echo "configure:1981: checking for opendir in -lx" >&5
+echo "configure:2008: checking for opendir in -lx" >&5
ac_lib_var=`echo x'_'opendir | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -1985,7 +2012,7 @@
ac_save_LIBS="$LIBS"
LIBS="-lx $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 1989 "configure"
+#line 2016 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@@ -1996,7 +2023,7 @@
opendir()
; return 0; }
EOF
-if { (eval echo configure:2000: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2027: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@@ -2019,12 +2046,12 @@
fi
echo $ac_n "checking for sys/wait.h that is POSIX.1 compatible""... $ac_c" 1>&6
-echo "configure:2023: checking for sys/wait.h that is POSIX.1 compatible" >&5
+echo "configure:2050: checking for sys/wait.h that is POSIX.1 compatible" >&5
if eval "test \"`echo '$''{'ac_cv_header_sys_wait_h'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2028 "configure"
+#line 2055 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <sys/wait.h>
@@ -2040,7 +2067,7 @@
s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
; return 0; }
EOF
-if { (eval echo configure:2044: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:2071: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_header_sys_wait_h=yes
else
@@ -2064,17 +2091,17 @@
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:2068: checking for $ac_hdr" >&5
+echo "configure:2095: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2073 "configure"
+#line 2100 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2078: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2105: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -2102,12 +2129,12 @@
echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
-echo "configure:2106: checking for ANSI C header files" >&5
+echo "configure:2133: checking for ANSI C header files" >&5
if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2111 "configure"
+#line 2138 "configure"
#include "confdefs.h"
#include <stdlib.h>
#include <stdarg.h>
@@ -2115,7 +2142,7 @@
#include <float.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2119: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2146: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -2132,7 +2159,7 @@
if test $ac_cv_header_stdc = yes; then
# SunOS 4.x string.h does not declare mem*, contrary to ANSI.
cat > conftest.$ac_ext <<EOF
-#line 2136 "configure"
+#line 2163 "configure"
#include "confdefs.h"
#include <string.h>
EOF
@@ -2150,7 +2177,7 @@
if test $ac_cv_header_stdc = yes; then
# ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
cat > conftest.$ac_ext <<EOF
-#line 2154 "configure"
+#line 2181 "configure"
#include "confdefs.h"
#include <stdlib.h>
EOF
@@ -2171,7 +2198,7 @@
:
else
cat > conftest.$ac_ext <<EOF
-#line 2175 "configure"
+#line 2202 "configure"
#include "confdefs.h"
#include <ctype.h>
#define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
@@ -2182,7 +2209,7 @@
exit (0); }
EOF
-if { (eval echo configure:2186: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:2213: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
:
else
@@ -2206,12 +2233,12 @@
fi
echo $ac_n "checking for pid_t""... $ac_c" 1>&6
-echo "configure:2210: checking for pid_t" >&5
+echo "configure:2237: checking for pid_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_pid_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2215 "configure"
+#line 2242 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
@@ -2239,12 +2266,12 @@
fi
echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6
-echo "configure:2243: checking whether time.h and sys/time.h may both be included" >&5
+echo "configure:2270: checking whether time.h and sys/time.h may both be included" >&5
if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2248 "configure"
+#line 2275 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <sys/time.h>
@@ -2253,7 +2280,7 @@
struct tm *tp;
; return 0; }
EOF
-if { (eval echo configure:2257: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:2284: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_header_time=yes
else
@@ -2274,21 +2301,21 @@
fi
echo $ac_n "checking for inline""... $ac_c" 1>&6
-echo "configure:2278: checking for inline" >&5
+echo "configure:2305: checking for inline" >&5
if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_cv_c_inline=no
for ac_kw in inline __inline__ __inline; do
cat > conftest.$ac_ext <<EOF
-#line 2285 "configure"
+#line 2312 "configure"
#include "confdefs.h"
int main() {
} $ac_kw foo() {
; return 0; }
EOF
-if { (eval echo configure:2292: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:2319: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_c_inline=$ac_kw; break
else
@@ -2317,12 +2344,12 @@
for ac_func in rename getrusage getdtablesize srandom random sigaction
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:2321: checking for $ac_func" >&5
+echo "configure:2348: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2326 "configure"
+#line 2353 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -2345,7 +2372,7 @@
; return 0; }
EOF
-if { (eval echo configure:2349: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2376: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -2372,12 +2399,12 @@
for ac_func in sigemptyset vsprintf strcasecmp setpgid clock dlopen
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:2376: checking for $ac_func" >&5
+echo "configure:2403: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2381 "configure"
+#line 2408 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -2400,7 +2427,7 @@
; return 0; }
EOF
-if { (eval echo configure:2404: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2431: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -2427,12 +2454,12 @@
for ac_func in dprintf bzero uname vsnprintf
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:2431: checking for $ac_func" >&5
+echo "configure:2458: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2436 "configure"
+#line 2463 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -2455,7 +2482,7 @@
; return 0; }
EOF
-if { (eval echo configure:2459: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2486: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -2482,46 +2509,56 @@
if test "x${ac_cv_func_vsprintf}" = "xno"
then
- echo "" >&2
- echo "Your system does not have the sprintf/vsprintf libraries." >&2
- echo "These are required to compile almost anything. Sorry." >&2
- echo "" >&2
+ cat << 'EOF' >&2
+configure: error:
+
+ Your system does not have the sprintf/vsprintf libraries.
+ These are required to compile almost anything. Sorry.
+
+EOF
exit 1
fi
if test "x${ac_cv_header_stdc}" = "xno"
then
- echo "" >&2
- echo "Your system must support ANSI C Header files." >&2
- echo "These are required for the language support. Sorry." >&2
- echo "" >&2
+ cat << 'EOF' >&2
+configure: error:
+
+ Your system must support ANSI C Header files.
+ These are required for the language support. Sorry.
+
+EOF
exit 1
fi
echo $ac_n "checking space left in file database struct""... $ac_c" 1>&6
-echo "configure:2503: checking space left in file database struct" >&5
-cat > abacab.c <<'EOF'
+echo "configure:2536: checking space left in file database struct" >&5
+cat > abacab.c << 'EOF'
#include <stdio.h>
#include <sys/time.h>
#include "src/mod/filesys.mod/files.h"
main() {
- fprintf(stderr, "%d/%d", 512-sizeof(struct filler), sizeof(filedb));
+ fprintf(stdout, "%d/%d", 512-sizeof(struct filler), sizeof(filedb));
}
EOF
${CC} -o abacab abacab.c
FILEDB_SPACE=`./abacab`
echo "$ac_t""$FILEDB_SPACE bytes" 1>&6
rm -f abacab abacab.o abacab.c
-echo " (standard is currently 48/512 bytes)"
+echo "$ac_t"" (standard is currently 48/512 bytes)" 1>&6
# ---------- begin robey's tcl thingies
# (well, what used to be robey's tcl thingies...)
+
+tclversions="8.3 8.2 8.1 8.0 7.6 7.5"
-tclnames="tcl tcl8.3 tcl83 tcl8.2 tcl82 tcl8.1 tcl81 \
+tcllibnames="tcl tcl8.3 tcl83 tcl8.2 tcl82 tcl8.1 tcl81 \
tcl8.0 tcl80 tcl7.6 tcl76 tcl7.5 tcl75"
tcllibextensions=".so .so.1 .so.1.0 .so.1.2 .a"
+tclheadernames="tcl.h"
+
tcllibpaths="/usr/local/lib /usr/local/pkgs/tcl/lib \
/usr/lib /lib /usr/i486-linuxaout/lib \
$HOME/lib $HOME/tcl/lib $HOME"
@@ -2529,30 +2566,6 @@
tclheaderpaths="/usr/local/include /usr/local/pkgs/tcl/include \
/usr/include $HOME/include $HOME/tcl/include $HOME"
-# sanity checking to make sure either both or neither TCLLIB and TCLINC are set
-if test ! "x${TCLLIB}" = "x"
-then
- if test "x${TCLINC}" = "x"
- then
- echo "" >&2
- echo "Environment variable TCLLIB was set, but I did not detect TCLINC." >&2
- echo "Please set both TCLLIB and TCLINC correctly if you wish to use them." >&2
- echo "configure will now attempt to autodetect both libtcl and tcl.h..." >&2
- echo "" >&2
- unset TCLLIB
- fi
-else
- if test ! "x${TCLINC}" = "x"
- then
- echo "" >&2
- echo "Environment variable TCLINC was set, but I did not detect TCLLIB." >&2
- echo "Please set both TCLLIB and TCLINC correctly if you wish to use them." >&2
- echo "configure will now attempt to autodetect both libtcl and tcl.h..." >&2
- echo "" >&2
- unset TCLINC
- fi
-fi
-
# Check whether --with-tcllib or --without-tcllib was given.
if test "${with_tcllib+set}" = set; then
withval="$with_tcllib"
@@ -2565,184 +2578,287 @@
tclincname=$withval
fi
+
+# make sure either both or neither $tcllibname and $tclincname are set
+if test ! "x${tcllibname}" = "x"
+then
+ if test "x${tclincname}" = "x"
+ then
+ cat << 'EOF' >&2
+configure: warning:
+
+ You must specify both --with-tcllib and --with-tclinc for them to work.
+ configure will now attempt to autodetect both the Tcl library and header...
+
+EOF
+ tcllibname=""
+ TCLLIB=""
+ TCLINC=""
+ fi
+else
+ if test ! "x${tclincname}" = "x"
+ then
+ cat << 'EOF' >&2
+configure: warning:
+
+ You must specify both --with-tcllib and --with-tclinc for them to work.
+ configure will now attempt to autodetect both the Tcl library and header...
-if test -r "$tcllibname"
+EOF
+ tclincname=""
+ TCLLIB=""
+ TCLINC=""
+ fi
+fi
+
+# make sure either both or neither $TCLLIB and $TCLINC are set
+if test ! "x${TCLLIB}" = "x"
then
- TCLLIB=`$DIRNAME $tcllibname`
- TCLLIBEXT=".`echo $tcllibname | $AWK '{j=split($1, i, "."); k=i[j]; print k}'`"
- TCLLIBFN=`$BASENAME $tcllibname $TCLLIBEXT | cut -c4-`
- echo "Using Tcl library: $TCLLIB/lib$TCLLIBFN$TCLLIBEXT"
+ if test "x${TCLINC}" = "x"
+ then
+ cat << 'EOF' >&2
+configure: warning:
+
+ Environment variable TCLLIB was set, but I did not detect TCLINC.
+ Please set both TCLLIB and TCLINC correctly if you wish to use them.
+ configure will now attempt to autodetect both the Tcl library and header...
+
+EOF
+ TCLLIB=""
+ fi
else
+ if test ! "x${TCLINC}" = "x"
+ then
+ cat << 'EOF' >&2
+configure: warning:
+
+ Environment variable TCLINC was set, but I did not detect TCLLIB.
+ Please set both TCLLIB and TCLINC correctly if you wish to use them.
+ configure will now attempt to autodetect both the Tcl library and header...
+
+EOF
+ TCLINC=""
+ fi
+fi
+
+# look for $TCLLIBFN: if $tcllibname is set, check there first
+if test ! "x${tcllibname}" = "x"
+then
+ if test -f "$tcllibname" && test -r "$tcllibname"
+ then
+ TCLLIB=`$DIRNAME $tcllibname`
+ TCLLIBEXT=".`echo $tcllibname | $AWK '{j=split($1, i, "."); k=i[j]; print k}'`"
+ TCLLIBFN=`$BASENAME $tcllibname $TCLLIBEXT | cut -c4-`
+ else
+ cat << 'EOF' >&2
+configure: warning:
+
+ The filename given to option --with-tcllib is not valid.
+ configure will now attempt to autodetect both the Tcl library and header...
+
+EOF
+ tclincname=""
+ fi
+fi
+
+# look for $TCLINCFN: if $tclincname is set, check there first
+if test ! "x${tclincname}" = "x"
+then
+ if test -f "$tclincname" && test -r "$tclincname"
+ then
+ TCLINC=`$DIRNAME $tclincname`
+ TCLINCFN=`$BASENAME $tclincname`
+ else
+ cat << 'EOF' >&2
+configure: warning:
+
+ The filename given to option --with-tclinc is not valid.
+ configure will now attempt to autodetect both the Tcl library and header...
+
+EOF
+ TCLLIB=""
+ TCLLIBFN=""
+ fi
+fi
- # look for libtcl: if TCLLIB is set, check there first
- if test ! "x${TCLLIB}" = "x"
+# look for $TCLLIBFN: if $TCLLIB is set, check there first
+if test ! "x${TCLLIB}" = "x"
+then
+ if test -d "${TCLLIB}"
then
- for tcllibfn in $tclnames
+ for tcllibfn in $tcllibnames
do
for tcllibext in $tcllibextensions
do
if test -r "$TCLLIB/lib$tcllibfn$tcllibext"
then
- if test "x${TCLLIBFN}" = "x"
- then
- TCLLIBFN=$tcllibfn
- TCLLIBEXT=$tcllibext
- break 2
- fi
+ TCLLIBFN=$tcllibfn
+ TCLLIBEXT=$tcllibext
+ break 2
fi
done
done
- if test "x${TCLLIBFN}" = "x"
- then
- echo "" >&2
- echo "Environment variable TCLLIB was set, but incorrect." >&2
- echo "Please set both TCLLIB and TCLINC correctly if you wish to use them." >&2
- echo "configure will now attempt to autodetect both libtcl and tcl.h..." >&2
- echo "" >&2
- unset TCLLIB
- unset TCLINC
- fi
fi
+ if test "x${TCLLIBFN}" = "x"
+ then
+ cat << 'EOF' >&2
+configure: warning:
+
+ Environment variable TCLLIB was set, but incorrect.
+ Please set both TCLLIB and TCLINC correctly if you wish to use them.
+ configure will now attempt to autodetect both the Tcl library and header...
- # check in common places now
- echo $ac_n "checking for libtcl""... $ac_c" 1>&6
-echo "configure:2610: checking for libtcl" >&5
- if test ! "x${TCLLIB}" = "x"
+EOF
+ TCLLIB=""
+ TCLLIBFN=""
+ TCLINC=""
+ TCLINCFN=""
+ fi
+fi
+
+# look for $TCLINCFN: if $TCLINC is set, check there first
+if test ! "x${TCLINC}" = "x"
+then
+ if test -d "${TCLINC}"
then
- echo "$ac_t""found in $TCLLIB/lib$TCLLIBFN$TCLLIBEXT" 1>&6
- else
- for tcllibfn in $tclnames
+ for tclheaderfn in $tclheadernames
do
- for tcllibext in $tcllibextensions
- do
- for tcllibpath in $tcllibpaths
- do
- if test -r "$tcllibpath/lib$tcllibfn$tcllibext"
- then
- if test "x${TCLLIB}" = "x"
- then
- echo "$ac_t""found in $tcllibpath/lib$tcllibfn$tcllibext" 1>&6
- TCLLIB=$tcllibpath
- TCLLIBFN=$tcllibfn
- TCLLIBEXT=$tcllibext
- break 3
- fi
- fi
- done
- done
+ if test -r "$TCLINC/$tclheaderfn"
+ then
+ TCLINCFN=$tclheaderfn
+ fi
done
fi
+ if test "x${TCLINCFN}" = "x"
+ then
+ cat << 'EOF' >&2
+configure: warning:
-fi # test tcllibname
+ Environment variable TCLINC was set, but incorrect.
+ Please set both TCLLIB and TCLINC correctly if you wish to use them.
+ configure will now attempt to autodetect both the Tcl library and header...
-# give up if they don't even have that
-if test "x${TCLLIB}" = "x"
-then
- echo "$ac_t""not found" 1>&6
+EOF
+ TCLLIB=""
+ TCLLIBFN=""
+ TCLINC=""
+ TCLINCFN=""
+ fi
fi
+
+echo $ac_n "checking for Tcl library""... $ac_c" 1>&6
+echo "configure:2751: checking for Tcl library" >&5
-# now look for pesky $TCLINCFN file
-if test -r "$tclincname"
+# attempt autodetect for $TCLLIBFN if not set
+if test ! "x${TCLLIBFN}" = "x"
then
- TCLINC=`$DIRNAME $tclincname`
- TCLINCFN=`$BASENAME $tclincname`
- echo "Using Tcl header: $TCLINC/$TCLINCFN"
+ echo "$ac_t""using $TCLLIB/lib$TCLLIBFN$TCLLIBEXT" 1>&6
else
+ for tcllibfn in $tcllibnames
+ do
+ for tcllibext in $tcllibextensions
+ do
+ for tcllibpath in $tcllibpaths
+ do
+ if test -r "$tcllibpath/lib$tcllibfn$tcllibext"
+ then
+ echo "$ac_t""found $tcllibpath/lib$tcllibfn$tcllibext" 1>&6
+ TCLLIB=$tcllibpath
+ TCLLIBFN=$tcllibfn
+ TCLLIBEXT=$tcllibext
+ break 3
+ fi
+ done
+ done
+ done
+fi
- TCLINCFN=tcl.h
+# show if $TCLLIBFN wasn't found
+if test "x${TCLLIBFN}" = "x"
+then
+ echo "$ac_t""not found" 1>&6
+fi
- if test ! "x${TCLINC}" = "x"
- then
- if test ! -r "$TCLINC/$TCLINCFN"
- then
- echo "" >&2
- echo "Environment variable TCLINC was set, but incorrect." >&2
- echo "Please set both TCLLIB and TCLINC correctly if you wish to use them." >&2
- echo "configure cannot safely continue now..." >&2
- echo "" >&2
- exit 1
- fi
- fi
+echo $ac_n "checking for Tcl header""... $ac_c" 1>&6
+echo "configure:2784: checking for Tcl header" >&5
- # check in common places now
- echo $ac_n "checking for $TCLINCFN""... $ac_c" 1>&6
-echo "configure:2670: checking for $TCLINCFN" >&5
- if test ! "x${TCLINC}" = "x"
- then
- echo "$ac_t""found in $TCLINC/$TCLINCFN" 1>&6
- else
- for headerpath in $tclheaderpaths
+# attempt autodetect for $TCLINCFN if not set
+if test ! "x${TCLINCFN}" = "x"
+then
+ echo "$ac_t""using $TCLINC/$TCLINCFN" 1>&6
+else
+ for headerpath in $tclheaderpaths
+ do
+ for tclheaderfn in $tclheadernames
do
- if test -r "$headerpath/$TCLINCFN"
+ if test -r "$headerpath/$tclheaderfn"
then
- if test "x${TCLINC}" = "x"
- then
- echo "$ac_t""found in $headerpath/$TCLINCFN" 1>&6
- TCLINC=$headerpath
- break
- fi
+ echo "$ac_t""found $headerpath/$tclheaderfn" 1>&6
+ TCLINC=$headerpath
+ TCLINCFN=$tclheaderfn
+ break 2
fi
done
- if test "x${TCLINC}" = "x"
- then
- for tcllibfn in $tclnames
+ done
+ # FreeBSD hack ...
+ if test "x${TCLINCFN}" = "x"
+ then
+ for tclversion in $tclversions
+ do
+ for headerpath in $tclheaderpaths
do
- for headerpath in $tclheaderpaths
+ for tclheaderfn in $tclheadernames
do
- if test -r "$headerpath/$tcllibfn/$TCLINCFN"
+ if test -r "$headerpath/tcl$tclversion/$tclheaderfn"
then
- echo "$ac_t""found in $headerpath/$TCLINCFN" 1>&6
- TCLINC=$headerpath/$tcllibfn
- break 2
+ echo "$ac_t""found $headerpath/tcl$tclversion/$tclheaderfn" 1>&6
+ TCLINC=$headerpath/tcl$tclversion
+ TCLINCFN=$tclheaderfn
+ break 3
fi
done
done
- fi
+ done
fi
+fi
- # had TCLLIB but not TCLINC? so close... :(
- if test "x${TCLINC}" = "x"
- then
- echo "$ac_t""not found" 1>&6
- unset TCLLIB
- unset TCLLIBFN
- unset TCLLIBEXT
- fi
-
-fi # test tclincname
-
-# done looking, now either TCLLIB & TCLINC are both set, or neither is set
-if test "x${TCLLIB}" = "x"
-then
- echo "" >&2
- echo "I can't find Tcl on this system." >&2
- echo "" >&2
- echo "Eggdrop now requires Tcl to compile. If you already have Tcl" >&2
- echo "installed on this system, and I just wasn't looking in the right" >&2
- echo "place for it, set the environment variables TCLLIB and TCLINC so" >&2
- echo "I will know where to find 'libtcl.a' (or 'libtcl.so') and 'tcl.h'" >&2
- echo "(respectively). Then run 'configure' again." >&2
- echo "" >&2
- echo "Read the README file if you don't know what Tcl is or how to get" >&2
- echo "it and install it." >&2
- echo "" >&2
+# show if $TCLINCFN wasn't found
+if test "x${TCLINCFN}" = "x"
+then
+ echo "$ac_t""not found" 1>&6
+fi
+
+# done looking, now either TCLLIBFN & TCLINCFN are both set, or we bail
+if test "x${TCLLIBFN}" = "x" || test "x${TCLINCFN}" = "x"
+then
+ cat << 'EOF' >&2
+configure: error:
+
+ I can't find Tcl on this system.
+
+ Eggdrop now requires Tcl to compile. If you already have Tcl
+ installed on this system, and I just wasn't looking in the right
+ place for it, set the environment variables TCLLIB and TCLINC so
+ I will know where to find 'libtcl.a' (or 'libtcl.so') and 'tcl.h'
+ (respectively). Then run 'configure' again.
+
+ Read the README file if you don't know what Tcl is or how to get
+ it and install it.
+
+EOF
exit 1
else
echo $ac_n "checking for Tcl version""... $ac_c" 1>&6
-echo "configure:2734: checking for Tcl version" >&5
+echo "configure:2854: checking for Tcl version" >&5
- for ver in $tclnames
+ for ver in $tclversions
do
- ver=`echo $ver | cut -c4-`
- if test ! "x${ver}" = "x"
+ TCLFOUND=`grep TCL_VERSION $TCLINC/$TCLINCFN | grep $ver | wc -l`
+ if test ! $TCLFOUND = 0
then
- TCLFOUND=`grep TCL_VERSION $TCLINC/$TCLINCFN | grep $ver | wc -l`
- if test ! $TCLFOUND = 0
- then
- TCLVER=$ver
- break
- fi
+ TCLVER=$ver
+ break
fi
done
@@ -2758,20 +2874,26 @@
TCL_REQS="$TCLLIB/lib$TCLLIBFN$TCLLIBEXT"
TCL_LIBS="-L$TCLLIB -l$TCLLIBFN -lm"
else
- echo "" >&2
- echo "Your Tcl version is much too old for eggdrop to use." >&2
- echo "I suggest you download and complie a more recent version." >&2
- echo "The most reliable current version is 8.2.1" >&2
- echo "" >&2
+ cat << 'EOF' >&2
+configure: error:
+
+ Your Tcl version is much too old for eggdrop to use.
+ I suggest you download and complie a more recent version.
+ The most reliable current version is 8.2.1
+
+EOF
exit 1
fi
if test "x${TCLLIBEXT}" = "x.a"
then
- echo "" >&2
- echo "Your libtcl is not a shared library." >&2
- echo "configure will set default make type to static..." >&2
- echo "" >&2
+ cat << 'EOF' >&2
+configure: warning:
+
+ Your libtcl is not a shared library.
+ configure will set default make type to static...
+
+EOF
DEFAULT_MAKE=static
fi
@@ -2789,33 +2911,47 @@
then
if test "$LINUX" = "yes"
then
- echo "Since you are on a Linux system, this has a known problem," >&2
+ cat << 'EOF' >&2
+configure: warning:
+
+ Since you are on a Linux system, this has a known problem,
+ I know a kludge for it,
+EOF
+
if test -r "/lib/libdl.so.1"
then
- echo "and you seem to have it, I know a kludge for it," >&2
- echo "so we'll do that..." >&2
- echo "" >&2
+ cat << 'EOF' >&2
+ and you seem to have it, so we'll do that...
+
+EOF
cat >> confdefs.h <<\EOF
#define HAVE_DLOPEN 1
EOF
LIBS="/lib/libdl.so.1 $LIBS"
- got_dl=1
else
- echo "which you DONT seem to have... doh!" >&2
- echo "perhaps you may still have the stuff lying around somewhere" >&2
- echo "if you work out where it is, add it to your XLIBS= lines" >&2
- echo "and #define HAVE_DLOPEN in config.h" >&2
- echo "" >&2
- echo "we'll proceed on anyway, but you probably won't be able" >&2
- echo "to 'make eggdrop' but you might be able to make the" >&2
- echo "static bot (I'll default your make to this version)." >&2
+ cat << 'EOF' >&2
+ which you DONT seem to have... doh!
+ perhaps you may still have the stuff lying around somewhere
+ if you work out where it is, add it to your XLIBS= lines
+ and #define HAVE_DLOPEN in config.h
+
+ we'll proceed on anyway, but you probably won't be able
+ to 'make eggdrop' but you might be able to make the
+ static bot (I'll default your make to this version).
+
+EOF
DEFAULT_MAKE=static
fi
else
- echo "You don't seem to have libdl anywhere I can find it, this will" >&2
- echo "prevent you from doing dynamic modules, I'll set your default" >&2
- echo "make to static linking." >&2
+ cat << 'EOF' >&2
+configure: warning:
+
+ You don't seem to have libdl anywhere I can find it, this will
+ prevent you from doing dynamic modules, I'll set your default
+ make to static linking.
+
+EOF
DEFAULT_MAKE=static
fi
fi
@@ -3220,13 +3356,13 @@
test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
-echo ""
-echo "Configure is done."
-echo ""
+echo "$ac_t""" 1>&6
+echo "$ac_t""Configure is done." 1>&6
+echo "$ac_t""" 1>&6
if test -f "./eggdrop"
then
- echo "Type 'make clean' and then 'make' to create the bot."
+ echo "$ac_t""Type 'make clean' and then 'make' to create the bot." 1>&6
else
- echo "Type 'make' to create the bot."
+ echo "$ac_t""Type 'make' to create the bot." 1>&6
fi
-echo ""
+echo "$ac_t""" 1>&6
Index: configure.in
===================================================================
RCS file: /usr/local/cvsroot/eggdrop1.3/configure.in,v
retrieving revision 1.22
diff -u -r1.22 configure.in
--- configure.in 1999/10/09 17:22:05 1.22
+++ configure.in 1999/10/10 01:32:26
@@ -3,11 +3,11 @@
ac_default_prefix=\${HOME}/eggdrop
AC_CONFIG_HEADER(config.h)
-echo ""
-echo "This is eggdrop's GNU configure script."
-echo "It's going to run a bunch of strange tests to hopefully make"
-echo "your compile work without much twiddling."
-echo ""
+AC_MSG_RESULT()
+AC_MSG_RESULT(This is eggdrop's GNU configure script.)
+AC_MSG_RESULT(It's going to run a bunch of strange tests to hopefully)
+AC_MSG_RESULT(make your compile work without much twiddling.)
+AC_MSG_RESULT()
AC_PROG_MAKE_SET
AC_PROG_CC
@@ -15,10 +15,13 @@
dnl no cross-compiling!
if test ! "x${cross_compiling}" = "xno"
then
- echo "" >&2
- echo "This system does not appear to have a working C compiler." >&2
- echo "A working C compiler is required to compile eggdrop." >&2
- echo "" >&2
+ cat << 'EOF' >&2
+configure: error:
+
+ This system does not appear to have a working C compiler.
+ A working C compiler is required to compile eggdrop.
+
+EOF
exit 1
fi
@@ -35,19 +38,40 @@
AC_PROG_AWK
if test "x${AWK}" = "x"
then
- AC_MSG_ERROR(This system seems to lack a working 'awk' command.)
+ cat << 'EOF' >&2
+configure: error:
+
+ This system seems to lack a working 'awk' command.
+ A working 'awk' command is required to compile eggdrop.
+
+EOF
+ exit 1
fi
AC_CHECK_PROG(BASENAME,basename,basename)
if test "x${BASENAME}" = "x"
then
- AC_MSG_ERROR(This system seems to lack a working 'basename' command.)
+ cat << 'EOF' >&2
+configure: error:
+
+ This system seems to lack a working 'basename' command.
+ A working 'basename' command is required to compile eggdrop.
+
+EOF
+ exit 1
fi
AC_CHECK_PROG(DIRNAME,dirname,dirname)
if test "x${DIRNAME}" = "x"
then
- AC_MSG_ERROR(This system seems to lack a working 'dirname' command.)
+ cat << 'EOF' >&2
+configure: error:
+
+ This system seems to lack a working 'dirname' command.
+ A working 'dirname' command is required to compile eggdrop.
+
+EOF
+ exit 1
fi
AC_PROG_LN_S
@@ -58,7 +82,7 @@
ac_file2=beldin2
ac_cp="cp -f $ac_file1 $ac_file2"
-cat > $ac_file1 <<EOF
+cat > $ac_file1 << 'EOF'
Beldin is a llama. :P
EOF
if { (eval echo configure: \"$ac_cp\") 1>&5; (eval $ac_cp) 2>&5; } && test -s $ac_file2
@@ -91,7 +115,7 @@
dnl test the os and set the module linking settings
if test "x${STRIP}" = "x"
then
- STRIP="touch"
+ STRIP=touch
fi
IRIX=no
LINUX=no
@@ -124,20 +148,23 @@
DEFAULT_MAKE=static
else
AC_MSG_RESULT(BSD/OS 3+! ok I spose)
- BEL_MOD_CC="shlicc"
- BEL_MOD_LD="shlicc"
+ BEL_MOD_CC=shlicc
+ BEL_MOD_LD=shlicc
BEL_MOD_STRIP="${STRIP} -d"
SHLIB_LD="shlicc -r"
- SHLIB_STRIP="touch"
+ SHLIB_STRIP=touch
AC_DEFINE(MODULES_OK)
fi
AC_CHECK_PROG(GMAKE,gmake,gmake)
if test "x${GMAKE}" = "x"
then
- echo "" >&2
- echo "Yoicks! you have BSD/OS & you dont have 'gmake', you may" >&2
- echo "not be able to compile the bot successfully :(" >&2
- echo "" >&2
+ cat << 'EOF' >&2
+configure: warning:
+
+ Yoicks! You have BSD/OS and you dont have 'gmake'.
+ You may not be able to compile the bot successfully :(
+
+EOF
fi
;;
*BSD)
@@ -153,8 +180,8 @@
SHLIB_LD="/usr/ccs/bin/ld -G -z text"
else
AC_MSG_RESULT(SunOS 4 :/)
- SHLIB_LD="ld"
- SHLIB_STRIP="touch"
+ SHLIB_LD=ld
+ SHLIB_STRIP=touch
fi
SHLIB_CC="${CC} -fPIC"
BEL_MOD_CC="${CC} -fPIC"
@@ -171,14 +198,14 @@
;;
1.0|1.1|1.2)
AC_MSG_RESULT(pre 1.3)
- SHLIB_LD='ld -R -export $@:'
+ SHLIB_LD="ld -R -export $@:"
AC_DEFINE(OSF1_HACKS)
AC_DEFINE(MODULES_OK)
;;
1.*)
AC_MSG_RESULT(1.3+)
SHLIB_CFL="${CC} -fpic"
- SHLIB_LD='ld -shared'
+ SHLIB_LD="ld -shared"
AC_DEFINE(OSF1_HACKS)
AC_DEFINE(MODULES_OK)
;;
@@ -207,7 +234,7 @@
IRIX|IRIX64)
AC_MSG_RESULT(you are cursed with IRIX)
IRIX=yes
- STRIP=
+ SHLIB_STRIP=touch
need_dl=0
DEFAULT_MAKE=static
;;
@@ -271,256 +298,345 @@
if test "x${ac_cv_func_vsprintf}" = "xno"
then
- echo "" >&2
- echo "Your system does not have the sprintf/vsprintf libraries." >&2
- echo "These are required to compile almost anything. Sorry." >&2
- echo "" >&2
+ cat << 'EOF' >&2
+configure: error:
+
+ Your system does not have the sprintf/vsprintf libraries.
+ These are required to compile almost anything. Sorry.
+
+EOF
exit 1
fi
if test "x${ac_cv_header_stdc}" = "xno"
then
- echo "" >&2
- echo "Your system must support ANSI C Header files." >&2
- echo "These are required for the language support. Sorry." >&2
- echo "" >&2
+ cat << 'EOF' >&2
+configure: error:
+
+ Your system must support ANSI C Header files.
+ These are required for the language support. Sorry.
+
+EOF
exit 1
fi
dnl check how much space is left in filedb (informational purposes)
AC_MSG_CHECKING(space left in file database struct)
-cat > abacab.c <<'EOF'
+cat > abacab.c << 'EOF'
#include <stdio.h>
#include <sys/time.h>
#include "src/mod/filesys.mod/files.h"
main() {
- fprintf(stderr, "%d/%d", 512-sizeof(struct filler), sizeof(filedb));
+ fprintf(stdout, "%d/%d", 512-sizeof(struct filler), sizeof(filedb));
}
EOF
${CC} -o abacab abacab.c
FILEDB_SPACE=`./abacab`
AC_MSG_RESULT($FILEDB_SPACE bytes)
rm -f abacab abacab.o abacab.c
-echo " (standard is currently 48/512 bytes)"
+AC_MSG_RESULT([ (standard is currently 48/512 bytes)])
dnl where is tcl? is it here?
# ---------- begin robey's tcl thingies
# (well, what used to be robey's tcl thingies...)
+
+tclversions="8.3 8.2 8.1 8.0 7.6 7.5"
-tclnames="tcl tcl8.3 tcl83 tcl8.2 tcl82 tcl8.1 tcl81 \
+tcllibnames="tcl tcl8.3 tcl83 tcl8.2 tcl82 tcl8.1 tcl81 \
tcl8.0 tcl80 tcl7.6 tcl76 tcl7.5 tcl75"
tcllibextensions=".so .so.1 .so.1.0 .so.1.2 .a"
+tclheadernames="tcl.h"
+
tcllibpaths="/usr/local/lib /usr/local/pkgs/tcl/lib \
/usr/lib /lib /usr/i486-linuxaout/lib \
$HOME/lib $HOME/tcl/lib $HOME"
tclheaderpaths="/usr/local/include /usr/local/pkgs/tcl/include \
/usr/include $HOME/include $HOME/tcl/include $HOME"
+
+dnl oohh new configure --variables for those with multiple tcl libs
+AC_ARG_WITH(tcllib, [ --with-tcllib=PATH full path to tcl library], tcllibname=$withval)
+AC_ARG_WITH(tclinc, [ --with-tclinc=PATH full path to tcl header], tclincname=$withval)
+
+# make sure either both or neither $tcllibname and $tclincname are set
+if test ! "x${tcllibname}" = "x"
+then
+ if test "x${tclincname}" = "x"
+ then
+ cat << 'EOF' >&2
+configure: warning:
+
+ You must specify both --with-tcllib and --with-tclinc for them to work.
+ configure will now attempt to autodetect both the Tcl library and header...
+
+EOF
+ tcllibname=""
+ TCLLIB=""
+ TCLINC=""
+ fi
+else
+ if test ! "x${tclincname}" = "x"
+ then
+ cat << 'EOF' >&2
+configure: warning:
+
+ You must specify both --with-tcllib and --with-tclinc for them to work.
+ configure will now attempt to autodetect both the Tcl library and header...
-# sanity checking to make sure either both or neither TCLLIB and TCLINC are set
+EOF
+ tclincname=""
+ TCLLIB=""
+ TCLINC=""
+ fi
+fi
+
+# make sure either both or neither $TCLLIB and $TCLINC are set
if test ! "x${TCLLIB}" = "x"
then
if test "x${TCLINC}" = "x"
then
- echo "" >&2
- echo "Environment variable TCLLIB was set, but I did not detect TCLINC." >&2
- echo "Please set both TCLLIB and TCLINC correctly if you wish to use them." >&2
- echo "configure will now attempt to autodetect both libtcl and tcl.h..." >&2
- echo "" >&2
- unset TCLLIB
+ cat << 'EOF' >&2
+configure: warning:
+
+ Environment variable TCLLIB was set, but I did not detect TCLINC.
+ Please set both TCLLIB and TCLINC correctly if you wish to use them.
+ configure will now attempt to autodetect both the Tcl library and header...
+
+EOF
+ TCLLIB=""
fi
else
if test ! "x${TCLINC}" = "x"
then
- echo "" >&2
- echo "Environment variable TCLINC was set, but I did not detect TCLLIB." >&2
- echo "Please set both TCLLIB and TCLINC correctly if you wish to use them." >&2
- echo "configure will now attempt to autodetect both libtcl and tcl.h..." >&2
- echo "" >&2
- unset TCLINC
+ cat << 'EOF' >&2
+configure: warning:
+
+ Environment variable TCLINC was set, but I did not detect TCLLIB.
+ Please set both TCLLIB and TCLINC correctly if you wish to use them.
+ configure will now attempt to autodetect both the Tcl library and header...
+
+EOF
+ TCLINC=""
fi
fi
-dnl oohh new configure --variables for those with multiple tcl libs
-AC_ARG_WITH(tcllib, [ --with-tcllib=PATH full path to tcl library], tcllibname=$withval)
-AC_ARG_WITH(tclinc, [ --with-tclinc=PATH full path to tcl header], tclincname=$withval)
+# look for $TCLLIBFN: if $tcllibname is set, check there first
+if test ! "x${tcllibname}" = "x"
+then
+ if test -f "$tcllibname" && test -r "$tcllibname"
+ then
+ TCLLIB=`$DIRNAME $tcllibname`
+ TCLLIBEXT=".`echo $tcllibname | $AWK '{j=split($1, i, "."); k=i[[j]]; print k}'`"
+ TCLLIBFN=`$BASENAME $tcllibname $TCLLIBEXT | cut -c4-`
+ else
+ cat << 'EOF' >&2
+configure: warning:
+
+ The filename given to option --with-tcllib is not valid.
+ configure will now attempt to autodetect both the Tcl library and header...
+
+EOF
+ tclincname=""
+ fi
+fi
-if test -r "$tcllibname"
+# look for $TCLINCFN: if $tclincname is set, check there first
+if test ! "x${tclincname}" = "x"
then
- TCLLIB=`$DIRNAME $tcllibname`
- TCLLIBEXT=".`echo $tcllibname | $AWK '{j=split($1, i, "."); k=i[[j]]; print k}'`"
- TCLLIBFN=`$BASENAME $tcllibname $TCLLIBEXT | cut -c4-`
- echo "Using Tcl library: $TCLLIB/lib$TCLLIBFN$TCLLIBEXT"
-else
+ if test -f "$tclincname" && test -r "$tclincname"
+ then
+ TCLINC=`$DIRNAME $tclincname`
+ TCLINCFN=`$BASENAME $tclincname`
+ else
+ cat << 'EOF' >&2
+configure: warning:
+
+ The filename given to option --with-tclinc is not valid.
+ configure will now attempt to autodetect both the Tcl library and header...
- # look for libtcl: if TCLLIB is set, check there first
- if test ! "x${TCLLIB}" = "x"
+EOF
+ TCLLIB=""
+ TCLLIBFN=""
+ fi
+fi
+
+# look for $TCLLIBFN: if $TCLLIB is set, check there first
+if test ! "x${TCLLIB}" = "x"
+then
+ if test -d "${TCLLIB}"
then
- for tcllibfn in $tclnames
+ for tcllibfn in $tcllibnames
do
for tcllibext in $tcllibextensions
do
if test -r "$TCLLIB/lib$tcllibfn$tcllibext"
then
- if test "x${TCLLIBFN}" = "x"
- then
- TCLLIBFN=$tcllibfn
- TCLLIBEXT=$tcllibext
- break 2
- fi
+ TCLLIBFN=$tcllibfn
+ TCLLIBEXT=$tcllibext
+ break 2
fi
done
done
- if test "x${TCLLIBFN}" = "x"
- then
- echo "" >&2
- echo "Environment variable TCLLIB was set, but incorrect." >&2
- echo "Please set both TCLLIB and TCLINC correctly if you wish to use them." >&2
- echo "configure will now attempt to autodetect both libtcl and tcl.h..." >&2
- echo "" >&2
- unset TCLLIB
- unset TCLINC
- fi
fi
+ if test "x${TCLLIBFN}" = "x"
+ then
+ cat << 'EOF' >&2
+configure: warning:
+
+ Environment variable TCLLIB was set, but incorrect.
+ Please set both TCLLIB and TCLINC correctly if you wish to use them.
+ configure will now attempt to autodetect both the Tcl library and header...
+
+EOF
+ TCLLIB=""
+ TCLLIBFN=""
+ TCLINC=""
+ TCLINCFN=""
+ fi
+fi
- # check in common places now
- AC_MSG_CHECKING(for libtcl)
- if test ! "x${TCLLIB}" = "x"
+# look for $TCLINCFN: if $TCLINC is set, check there first
+if test ! "x${TCLINC}" = "x"
+then
+ if test -d "${TCLINC}"
then
- AC_MSG_RESULT(found in $TCLLIB/lib$TCLLIBFN$TCLLIBEXT)
- else
- for tcllibfn in $tclnames
+ for tclheaderfn in $tclheadernames
do
- for tcllibext in $tcllibextensions
- do
- for tcllibpath in $tcllibpaths
- do
- if test -r "$tcllibpath/lib$tcllibfn$tcllibext"
- then
- if test "x${TCLLIB}" = "x"
- then
- AC_MSG_RESULT(found in $tcllibpath/lib$tcllibfn$tcllibext)
- TCLLIB=$tcllibpath
- TCLLIBFN=$tcllibfn
- TCLLIBEXT=$tcllibext
- break 3
- fi
- fi
- done
- done
+ if test -r "$TCLINC/$tclheaderfn"
+ then
+ TCLINCFN=$tclheaderfn
+ fi
done
fi
+ if test "x${TCLINCFN}" = "x"
+ then
+ cat << 'EOF' >&2
+configure: warning:
-fi # test tcllibname
+ Environment variable TCLINC was set, but incorrect.
+ Please set both TCLLIB and TCLINC correctly if you wish to use them.
+ configure will now attempt to autodetect both the Tcl library and header...
-# give up if they don't even have that
-if test "x${TCLLIB}" = "x"
-then
- AC_MSG_RESULT(not found)
+EOF
+ TCLLIB=""
+ TCLLIBFN=""
+ TCLINC=""
+ TCLINCFN=""
+ fi
fi
+
+AC_MSG_CHECKING(for Tcl library)
-# now look for pesky $TCLINCFN file
-if test -r "$tclincname"
+# attempt autodetect for $TCLLIBFN if not set
+if test ! "x${TCLLIBFN}" = "x"
then
- TCLINC=`$DIRNAME $tclincname`
- TCLINCFN=`$BASENAME $tclincname`
- echo "Using Tcl header: $TCLINC/$TCLINCFN"
+ AC_MSG_RESULT(using $TCLLIB/lib$TCLLIBFN$TCLLIBEXT)
else
+ for tcllibfn in $tcllibnames
+ do
+ for tcllibext in $tcllibextensions
+ do
+ for tcllibpath in $tcllibpaths
+ do
+ if test -r "$tcllibpath/lib$tcllibfn$tcllibext"
+ then
+ AC_MSG_RESULT(found $tcllibpath/lib$tcllibfn$tcllibext)
+ TCLLIB=$tcllibpath
+ TCLLIBFN=$tcllibfn
+ TCLLIBEXT=$tcllibext
+ break 3
+ fi
+ done
+ done
+ done
+fi
- TCLINCFN=tcl.h
+# show if $TCLLIBFN wasn't found
+if test "x${TCLLIBFN}" = "x"
+then
+ AC_MSG_RESULT(not found)
+fi
- if test ! "x${TCLINC}" = "x"
- then
- if test ! -r "$TCLINC/$TCLINCFN"
- then
- echo "" >&2
- echo "Environment variable TCLINC was set, but incorrect." >&2
- echo "Please set both TCLLIB and TCLINC correctly if you wish to use them." >&2
- echo "configure cannot safely continue now..." >&2
- echo "" >&2
- exit 1
- fi
- fi
+AC_MSG_CHECKING(for Tcl header)
- # check in common places now
- AC_MSG_CHECKING(for $TCLINCFN)
- if test ! "x${TCLINC}" = "x"
- then
- AC_MSG_RESULT(found in $TCLINC/$TCLINCFN)
- else
- for headerpath in $tclheaderpaths
+# attempt autodetect for $TCLINCFN if not set
+if test ! "x${TCLINCFN}" = "x"
+then
+ AC_MSG_RESULT(using $TCLINC/$TCLINCFN)
+else
+ for headerpath in $tclheaderpaths
+ do
+ for tclheaderfn in $tclheadernames
do
- if test -r "$headerpath/$TCLINCFN"
+ if test -r "$headerpath/$tclheaderfn"
then
- if test "x${TCLINC}" = "x"
- then
- AC_MSG_RESULT(found in $headerpath/$TCLINCFN)
- TCLINC=$headerpath
- break
- fi
+ AC_MSG_RESULT(found $headerpath/$tclheaderfn)
+ TCLINC=$headerpath
+ TCLINCFN=$tclheaderfn
+ break 2
fi
done
- if test "x${TCLINC}" = "x"
- then
- for tcllibfn in $tclnames
+ done
+ # FreeBSD hack ...
+ if test "x${TCLINCFN}" = "x"
+ then
+ for tclversion in $tclversions
+ do
+ for headerpath in $tclheaderpaths
do
- for headerpath in $tclheaderpaths
+ for tclheaderfn in $tclheadernames
do
- if test -r "$headerpath/$tcllibfn/$TCLINCFN"
+ if test -r "$headerpath/tcl$tclversion/$tclheaderfn"
then
- AC_MSG_RESULT(found in $headerpath/$TCLINCFN)
- TCLINC=$headerpath/$tcllibfn
- break 2
+ AC_MSG_RESULT(found $headerpath/tcl$tclversion/$tclheaderfn)
+ TCLINC=$headerpath/tcl$tclversion
+ TCLINCFN=$tclheaderfn
+ break 3
fi
done
done
- fi
+ done
fi
+fi
- # had TCLLIB but not TCLINC? so close... :(
- if test "x${TCLINC}" = "x"
- then
- AC_MSG_RESULT(not found)
- unset TCLLIB
- unset TCLLIBFN
- unset TCLLIBEXT
- fi
-
-fi # test tclincname
-
-# done looking, now either TCLLIB & TCLINC are both set, or neither is set
-if test "x${TCLLIB}" = "x"
-then
- echo "" >&2
- echo "I can't find Tcl on this system." >&2
- echo "" >&2
- echo "Eggdrop now requires Tcl to compile. If you already have Tcl" >&2
- echo "installed on this system, and I just wasn't looking in the right" >&2
- echo "place for it, set the environment variables TCLLIB and TCLINC so" >&2
- echo "I will know where to find 'libtcl.a' (or 'libtcl.so') and 'tcl.h'" >&2
- echo "(respectively). Then run 'configure' again." >&2
- echo "" >&2
- echo "Read the README file if you don't know what Tcl is or how to get" >&2
- echo "it and install it." >&2
- echo "" >&2
+# show if $TCLINCFN wasn't found
+if test "x${TCLINCFN}" = "x"
+then
+ AC_MSG_RESULT(not found)
+fi
+
+# done looking, now either TCLLIBFN & TCLINCFN are both set, or we bail
+if test "x${TCLLIBFN}" = "x" || test "x${TCLINCFN}" = "x"
+then
+ cat << 'EOF' >&2
+configure: error:
+
+ I can't find Tcl on this system.
+
+ Eggdrop now requires Tcl to compile. If you already have Tcl
+ installed on this system, and I just wasn't looking in the right
+ place for it, set the environment variables TCLLIB and TCLINC so
+ I will know where to find 'libtcl.a' (or 'libtcl.so') and 'tcl.h'
+ (respectively). Then run 'configure' again.
+
+ Read the README file if you don't know what Tcl is or how to get
+ it and install it.
+
+EOF
exit 1
else
AC_MSG_CHECKING(for Tcl version)
- for ver in $tclnames
+ for ver in $tclversions
do
- ver=`echo $ver | cut -c4-`
- if test ! "x${ver}" = "x"
+ TCLFOUND=`grep TCL_VERSION $TCLINC/$TCLINCFN | grep $ver | wc -l`
+ if test ! $TCLFOUND = 0
then
- TCLFOUND=`grep TCL_VERSION $TCLINC/$TCLINCFN | grep $ver | wc -l`
- if test ! $TCLFOUND = 0
- then
- TCLVER=$ver
- break
- fi
+ TCLVER=$ver
+ break
fi
done
@@ -536,20 +652,26 @@
TCL_REQS="$TCLLIB/lib$TCLLIBFN$TCLLIBEXT"
TCL_LIBS="-L$TCLLIB -l$TCLLIBFN -lm"
else
- echo "" >&2
- echo "Your Tcl version is much too old for eggdrop to use." >&2
- echo "I suggest you download and complie a more recent version." >&2
- echo "The most reliable current version is 8.2.1" >&2
- echo "" >&2
+ cat << 'EOF' >&2
+configure: error:
+
+ Your Tcl version is much too old for eggdrop to use.
+ I suggest you download and complie a more recent version.
+ The most reliable current version is 8.2.1
+
+EOF
exit 1
fi
if test "x${TCLLIBEXT}" = "x.a"
then
- echo "" >&2
- echo "Your libtcl is not a shared library." >&2
- echo "configure will set default make type to static..." >&2
- echo "" >&2
+ cat << 'EOF' >&2
+configure: warning:
+
+ Your libtcl is not a shared library.
+ configure will set default make type to static...
+
+EOF
DEFAULT_MAKE=static
fi
@@ -567,30 +689,44 @@
then
if test "$LINUX" = "yes"
then
- echo "Since you are on a Linux system, this has a known problem," >&2
+ cat << 'EOF' >&2
+configure: warning:
+
+ Since you are on a Linux system, this has a known problem,
+ I know a kludge for it,
+EOF
+
if test -r "/lib/libdl.so.1"
then
- echo "and you seem to have it, I know a kludge for it," >&2
- echo "so we'll do that..." >&2
- echo "" >&2
+ cat << 'EOF' >&2
+ and you seem to have it, so we'll do that...
+
+EOF
AC_DEFINE(HAVE_DLOPEN)
LIBS="/lib/libdl.so.1 $LIBS"
- got_dl=1
else
- echo "which you DONT seem to have... doh!" >&2
- echo "perhaps you may still have the stuff lying around somewhere" >&2
- echo "if you work out where it is, add it to your XLIBS= lines" >&2
- echo "and #define HAVE_DLOPEN in config.h" >&2
- echo "" >&2
- echo "we'll proceed on anyway, but you probably won't be able" >&2
- echo "to 'make eggdrop' but you might be able to make the" >&2
- echo "static bot (I'll default your make to this version)." >&2
+ cat << 'EOF' >&2
+ which you DONT seem to have... doh!
+ perhaps you may still have the stuff lying around somewhere
+ if you work out where it is, add it to your XLIBS= lines
+ and #define HAVE_DLOPEN in config.h
+
+ we'll proceed on anyway, but you probably won't be able
+ to 'make eggdrop' but you might be able to make the
+ static bot (I'll default your make to this version).
+
+EOF
DEFAULT_MAKE=static
fi
else
- echo "You don't seem to have libdl anywhere I can find it, this will" >&2
- echo "prevent you from doing dynamic modules, I'll set your default" >&2
- echo "make to static linking." >&2
+ cat << 'EOF' >&2
+configure: warning:
+
+ You don't seem to have libdl anywhere I can find it, this will
+ prevent you from doing dynamic modules, I'll set your default
+ make to static linking.
+
+EOF
DEFAULT_MAKE=static
fi
fi
@@ -621,13 +757,13 @@
AC_SUBST(DEFAULT_MAKE)
AC_OUTPUT(Makefile lush.h)
-echo ""
-echo "Configure is done."
-echo ""
+AC_MSG_RESULT()
+AC_MSG_RESULT(Configure is done.)
+AC_MSG_RESULT()
if test -f "./eggdrop"
then
- echo "Type 'make clean' and then 'make' to create the bot."
+ AC_MSG_RESULT(Type 'make clean' and then 'make' to create the bot.)
else
- echo "Type 'make' to create the bot."
+ AC_MSG_RESULT(Type 'make' to create the bot.)
fi
-echo ""
+AC_MSG_RESULT()
More information about the Patches
mailing list