"configure" support updated. Removed unused features. Added parsing of CFLAGS and CPPFLAGS to extract OMIT options to pass to lemon and mkkeywordhash. (CVS 5446)

FossilOrigin-Name: c67aa5057deda6419e1f205118bf09957d599c15
This commit is contained in:
shane 2008-07-22 05:05:01 +00:00
parent 3514b6f759
commit fbededef48
6 changed files with 128 additions and 171 deletions

View File

@ -75,8 +75,13 @@ TLIBS = @LIBS@
#
TEMP_STORE = -DSQLITE_TEMP_STORE=@TEMP_STORE@
# Enable/disable loadable extensions based on configuration
TCC += @LOADEXTENSION_FLAGS@
# Enable/disable loadable extensions, and other optional features
# based on configuration. (-DSQLITE_OMIT*). The same set of OMIT
# flags should be passed to the LEMON parser generator and the
# mkkeywordhash tool as well.
OPT_FEATURE_FLAGS = @OPT_FEATURE_FLAGS@
TCC += $(OPT_FEATURE_FLAGS)
# Version numbers and release number for the SQLite being compiled.
#
@ -593,7 +598,7 @@ parse.h: parse.c
parse.c: $(TOP)/src/parse.y lemon$(BEXE) $(TOP)/addopcodes.awk
cp $(TOP)/src/parse.y .
./lemon$(BEXE) $(OPTS) parse.y
./lemon$(BEXE) $(OPTS) $(OPT_FEATURE_FLAGS) parse.y
mv parse.h parse.h.temp
$(NAWK) -f $(TOP)/addopcodes.awk parse.h.temp >parse.h
@ -629,7 +634,7 @@ tokenize.lo: $(TOP)/src/tokenize.c keywordhash.h $(HDR)
$(LTCOMPILE) -c $(TOP)/src/tokenize.c
keywordhash.h: $(TOP)/tool/mkkeywordhash.c
$(BCC) -o mkkeywordhash$(BEXE) $(OPTS) $(TOP)/tool/mkkeywordhash.c
$(BCC) -o mkkeywordhash$(BEXE) $(OPTS) $(OPT_FEATURE_FLAGS) $(TOP)/tool/mkkeywordhash.c
./mkkeywordhash$(BEXE) >keywordhash.h
trigger.lo: $(TOP)/src/trigger.c $(HDR)

View File

@ -11,7 +11,7 @@
*************************************************************************
** Configuration header template to be filled in by 'configure' script
**
** @(#) $Id: config.h.in,v 1.2 2008/05/06 02:28:06 mlcreech Exp $
** @(#) $Id: config.h.in,v 1.3 2008/07/22 05:05:02 shane Exp $
*/
#ifndef _CONFIG_H_
#define _CONFIG_H_
@ -33,9 +33,6 @@
/* Define as 1 if you have the int64_t type */
#undef HAVE_INT64_T
/* Define as 1 if you have the intptr_t type */
#undef HAVE_INTPTR_T
/* Define as 1 if you have the uint8_t type */
#undef HAVE_UINT8_T
@ -48,9 +45,6 @@
/* Define as 1 if you have the uint64_t type */
#undef HAVE_UINT64_T
/* Define as 1 if you have the uintptr_t type */
#undef HAVE_UINTPTR_T
/*****************************
** Header Files
@ -85,6 +79,9 @@
/* Define as 1 if you have the localtime_r() function */
#undef HAVE_LOCALTIME_R
/* Define as 1 if you have the localtime_s() function */
#undef HAVE_LOCALTIME_S
/*****************************
** Large file support

195
configure vendored
View File

@ -423,9 +423,6 @@ PACKAGE_BUGREPORT=''
# Factoring default headers for most tests.
ac_includes_default="\
#include <stdio.h>
#if HAVE_SYS_TYPES_H
# include <sys/types.h>
#endif
#if HAVE_SYS_STAT_H
# include <sys/stat.h>
#endif
@ -433,9 +430,6 @@ ac_includes_default="\
# include <stdlib.h>
# include <stddef.h>
#else
# if HAVE_STDLIB_H
# include <stdlib.h>
# endif
#endif
#if HAVE_STRING_H
# if !STDC_HEADERS && HAVE_MEMORY_H
@ -457,7 +451,7 @@ ac_includes_default="\
# include <unistd.h>
#endif"
ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS LIBTOOL build build_cpu build_vendor build_os host host_cpu host_vendor host_os CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT SED EGREP FGREP GREP LD DUMPBIN ac_ct_DUMPBIN NM LN_S AR ac_ct_AR STRIP ac_ct_STRIP RANLIB ac_ct_RANLIB lt_ECHO DSYMUTIL ac_ct_DSYMUTIL NMEDIT ac_ct_NMEDIT LIPO ac_ct_LIPO OTOOL ac_ct_OTOOL OTOOL64 ac_ct_OTOOL64 CPP INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA AWK TCLSH_CMD program_prefix VERSION RELEASE VERSION_NUMBER BUILD_CC SQLITE_THREADSAFE XTHREADCONNECT THREADSOVERRIDELOCKS ALLOWRELEASE TEMP_STORE BUILD_EXEEXT SQLITE_OS_UNIX SQLITE_OS_WIN SQLITE_OS_OS2 TARGET_EXEEXT TCL_VERSION TCL_BIN_DIR TCL_SRC_DIR TCL_LIBS TCL_INCLUDE_SPEC TCL_LIB_FILE TCL_LIB_FLAG TCL_LIB_SPEC TCL_STUB_LIB_FILE TCL_STUB_LIB_FLAG TCL_STUB_LIB_SPEC HAVE_TCL TARGET_READLINE_LIBS TARGET_READLINE_INC TARGET_HAVE_READLINE TARGET_DEBUG USE_AMALGAMATION LOADEXTENSION_FLAGS USE_GCOV BUILD_CFLAGS LIBOBJS LTLIBOBJS'
ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS LIBTOOL build build_cpu build_vendor build_os host host_cpu host_vendor host_os CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT SED EGREP FGREP GREP LD DUMPBIN ac_ct_DUMPBIN NM LN_S AR ac_ct_AR STRIP ac_ct_STRIP RANLIB ac_ct_RANLIB lt_ECHO DSYMUTIL ac_ct_DSYMUTIL NMEDIT ac_ct_NMEDIT LIPO ac_ct_LIPO OTOOL ac_ct_OTOOL OTOOL64 ac_ct_OTOOL64 CPP INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA AWK TCLSH_CMD program_prefix VERSION RELEASE VERSION_NUMBER BUILD_CC SQLITE_THREADSAFE XTHREADCONNECT THREADSOVERRIDELOCKS ALLOWRELEASE TEMP_STORE BUILD_EXEEXT SQLITE_OS_UNIX SQLITE_OS_WIN SQLITE_OS_OS2 TARGET_EXEEXT TCL_VERSION TCL_BIN_DIR TCL_SRC_DIR TCL_LIBS TCL_INCLUDE_SPEC TCL_LIB_FILE TCL_LIB_FLAG TCL_LIB_SPEC TCL_STUB_LIB_FILE TCL_STUB_LIB_FLAG TCL_STUB_LIB_SPEC HAVE_TCL TARGET_READLINE_LIBS TARGET_READLINE_INC TARGET_HAVE_READLINE TARGET_DEBUG USE_AMALGAMATION OPT_FEATURE_FLAGS USE_GCOV BUILD_CFLAGS LIBOBJS LTLIBOBJS'
ac_subst_files=''
# Initialize some variables set by options.
@ -1489,7 +1483,7 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu
# The following RCS revision string applies to configure.in
# $Revision: 1.61 $
# $Revision: 1.62 $
#########
# Programs needed
@ -10131,70 +10125,7 @@ _ACEOF
fi
echo "$as_me:$LINENO: checking for intptr_t" >&5
echo $ECHO_N "checking for intptr_t... $ECHO_C" >&6
if test "${ac_cv_type_intptr_t+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
$ac_includes_default
int
main ()
{
if ((intptr_t *) 0)
return 0;
if (sizeof (intptr_t))
return 0;
;
return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
(eval $ac_compile) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } &&
{ ac_try='test -z "$ac_c_werror_flag"
|| test ! -s conftest.err'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
{ ac_try='test -s conftest.$ac_objext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
ac_cv_type_intptr_t=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
ac_cv_type_intptr_t=no
fi
rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
fi
echo "$as_me:$LINENO: result: $ac_cv_type_intptr_t" >&5
echo "${ECHO_T}$ac_cv_type_intptr_t" >&6
if test $ac_cv_type_intptr_t = yes; then
cat >>confdefs.h <<_ACEOF
#define HAVE_INTPTR_T 1
_ACEOF
fi
echo "$as_me:$LINENO: checking for uint8_t" >&5
echo $ECHO_N "checking for uint8_t... $ECHO_C" >&6
if test "${ac_cv_type_uint8_t+set}" = set; then
@ -10451,70 +10382,8 @@ _ACEOF
fi
echo "$as_me:$LINENO: checking for uintptr_t" >&5
echo $ECHO_N "checking for uintptr_t... $ECHO_C" >&6
if test "${ac_cv_type_uintptr_t+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
$ac_includes_default
int
main ()
{
if ((uintptr_t *) 0)
return 0;
if (sizeof (uintptr_t))
return 0;
;
return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
(eval $ac_compile) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } &&
{ ac_try='test -z "$ac_c_werror_flag"
|| test ! -s conftest.err'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
{ ac_try='test -s conftest.$ac_objext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
ac_cv_type_uintptr_t=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
ac_cv_type_uintptr_t=no
fi
rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
fi
echo "$as_me:$LINENO: result: $ac_cv_type_uintptr_t" >&5
echo "${ECHO_T}$ac_cv_type_uintptr_t" >&6
if test $ac_cv_type_uintptr_t = yes; then
cat >>confdefs.h <<_ACEOF
#define HAVE_UINTPTR_T 1
_ACEOF
fi
#########
@ -10680,7 +10549,7 @@ done
for ac_func in usleep fdatasync localtime_r gmtime_r
for ac_func in usleep fdatasync localtime_r gmtime_r localtime_s
do
as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
echo "$as_me:$LINENO: checking for $ac_func" >&5
@ -11273,14 +11142,12 @@ if test "$TARGET_EXEEXT" = ".exe"; then
SQLITE_OS_UNIX=0
SQLITE_OS_WIN=1
SQLITE_OS_OS2=0
tclsubdir=win
CFLAGS="$CFLAGS -DSQLITE_OS_WIN=1"
fi
else
SQLITE_OS_UNIX=1
SQLITE_OS_WIN=0
SQLITE_OS_OS2=0
tclsubdir=unix
CFLAGS="$CFLAGS -DSQLITE_OS_UNIX=1"
fi
@ -12066,14 +11933,59 @@ else
use_loadextension=no
fi;
if test "${use_loadextension}" = "yes" ; then
LOADEXTENSION_FLAGS=""
OPT_FEATURE_FLAGS=""
else
LOADEXTENSION_FLAGS="-DSQLITE_OMIT_LOAD_EXTENSION=1"
OPT_FEATURE_FLAGS="-DSQLITE_OMIT_LOAD_EXTENSION=1"
fi
#########
# See whether we should allow loadable extensions
# attempt to duplicate any OMITS into the $(OPT_FEATURE_FLAGS) parameter
for option in $CFLAGS $CPPFLAGS
do
case $option in
-DSQLITE_OMIT*) OPT_FEATURE_FLAGS+=" $option";;
esac
done
# attempt to remove any OMITS from the $(CFLAGS) parameter
ac_temp_CFLAGS=""
for option in $CFLAGS
do
case $option in
-DSQLITE_OMIT*) ;;
*) ac_temp_CFLAGS+=" $option";;
esac
done
CFLAGS=$ac_temp_CFLAGS
# attempt to remove any OMITS from the $(CPPFLAGS) parameter
ac_temp_CPPFLAGS=""
for option in $CPPFLAGS
do
case $option in
-DSQLITE_OMIT*) ;;
*) ac_temp_CPPFLAGS+=" $option";;
esac
done
CPPFLAGS=$ac_temp_CPPFLAGS
# attempt to remove any OMITS from the $(BUILD_CFLAGS) parameter
ac_temp_BUILD_CFLAGS=""
for option in $BUILD_CFLAGS
do
case $option in
-DSQLITE_OMIT*) ;;
*) ac_temp_BUILD_CFLAGS+=" $option";;
esac
done
BUILD_CFLAGS=$ac_temp_BUILD_CFLAGS
#########
# See whether we should use GCOV
# Check whether --enable-gcov or --disable-gcov was given.
if test "${enable_gcov+set}" = set; then
enableval="$enable_gcov"
@ -12088,7 +12000,6 @@ else
fi
#########
# Output the config header
ac_config_headers="$ac_config_headers config.h"
@ -13055,7 +12966,7 @@ s,@TARGET_READLINE_INC@,$TARGET_READLINE_INC,;t t
s,@TARGET_HAVE_READLINE@,$TARGET_HAVE_READLINE,;t t
s,@TARGET_DEBUG@,$TARGET_DEBUG,;t t
s,@USE_AMALGAMATION@,$USE_AMALGAMATION,;t t
s,@LOADEXTENSION_FLAGS@,$LOADEXTENSION_FLAGS,;t t
s,@OPT_FEATURE_FLAGS@,$OPT_FEATURE_FLAGS,;t t
s,@USE_GCOV@,$USE_GCOV,;t t
s,@BUILD_CFLAGS@,$BUILD_CFLAGS,;t t
s,@LIBOBJS@,$LIBOBJS,;t t

View File

@ -92,7 +92,7 @@ AC_INIT(sqlite, m4_esyscmd([cat VERSION | tr -d '\n']))
dnl Put the RCS revision string after AC_INIT so that it will also
dnl show in in configure.
# The following RCS revision string applies to configure.in
# $Revision: 1.46 $
# $Revision: 1.47 $
#########
# Programs needed
@ -118,7 +118,7 @@ AC_CHECK_HEADERS([sys/types.h stdlib.h stdint.h inttypes.h])
#########
# Figure out whether or not we have these functions
#
AC_CHECK_FUNCS([usleep fdatasync localtime_r gmtime_r])
AC_CHECK_FUNCS([usleep fdatasync localtime_r gmtime_r localtime_s])
#########
# By default, we use the amalgamation (this may be changed below...)
@ -352,14 +352,12 @@ if test "$TARGET_EXEEXT" = ".exe"; then
SQLITE_OS_UNIX=0
SQLITE_OS_WIN=1
SQLITE_OS_OS2=0
tclsubdir=win
CFLAGS="$CFLAGS -DSQLITE_OS_WIN=1"
fi
else
SQLITE_OS_UNIX=1
SQLITE_OS_WIN=0
SQLITE_OS_OS2=0
tclsubdir=unix
CFLAGS="$CFLAGS -DSQLITE_OS_UNIX=1"
fi
@ -611,14 +609,60 @@ AC_ARG_ENABLE(load-extension, AC_HELP_STRING([--enable-load-extension],
[Enable loading of external extensions]),
[use_loadextension=$enableval],[use_loadextension=no])
if test "${use_loadextension}" = "yes" ; then
LOADEXTENSION_FLAGS=""
OPT_FEATURE_FLAGS=""
else
LOADEXTENSION_FLAGS="-DSQLITE_OMIT_LOAD_EXTENSION=1"
OPT_FEATURE_FLAGS="-DSQLITE_OMIT_LOAD_EXTENSION=1"
fi
AC_SUBST(LOADEXTENSION_FLAGS)
#########
# See whether we should allow loadable extensions
# attempt to duplicate any OMITS into the $(OPT_FEATURE_FLAGS) parameter
for option in $CFLAGS $CPPFLAGS
do
case $option in
-DSQLITE_OMIT*) OPT_FEATURE_FLAGS+=" $option";;
esac
done
AC_SUBST(OPT_FEATURE_FLAGS)
# attempt to remove any OMITS from the $(CFLAGS) parameter
ac_temp_CFLAGS=""
for option in $CFLAGS
do
case $option in
-DSQLITE_OMIT*) ;;
*) ac_temp_CFLAGS+=" $option";;
esac
done
CFLAGS=$ac_temp_CFLAGS
# attempt to remove any OMITS from the $(CPPFLAGS) parameter
ac_temp_CPPFLAGS=""
for option in $CPPFLAGS
do
case $option in
-DSQLITE_OMIT*) ;;
*) ac_temp_CPPFLAGS+=" $option";;
esac
done
CPPFLAGS=$ac_temp_CPPFLAGS
# attempt to remove any OMITS from the $(BUILD_CFLAGS) parameter
ac_temp_BUILD_CFLAGS=""
for option in $BUILD_CFLAGS
do
case $option in
-DSQLITE_OMIT*) ;;
*) ac_temp_BUILD_CFLAGS+=" $option";;
esac
done
BUILD_CFLAGS=$ac_temp_BUILD_CFLAGS
#########
# See whether we should use GCOV
AC_ARG_ENABLE(gcov, AC_HELP_STRING([--enable-gcov],
[Enable coverage testing using gcov]),
[use_gcov=$enableval],[use_gcov=no])

View File

@ -1,7 +1,7 @@
C flattenSubquery()\sneeded\sif\seither\sSQLITE_OMIT_SUBQUERY\sor\sSQLITE_OMIT_VIEW\snot\sdefined.\s(CVS\s5445)
D 2008-07-22T05:00:56
C "configure"\ssupport\supdated.\s\sRemoved\sunused\sfeatures.\s\sAdded\sparsing\sof\sCFLAGS\sand\sCPPFLAGS\sto\sextract\sOMIT\soptions\sto\spass\sto\slemon\sand\smkkeywordhash.\s(CVS\s5446)
D 2008-07-22T05:05:02
F Makefile.arm-wince-mingw32ce-gcc fcd5e9cd67fe88836360bb4f9ef4cb7f8e2fb5a0
F Makefile.in a03f7cb4f7ad50bc53a788c6c544430e81f95de4
F Makefile.in 77ff156061bb870aa0a8b3d545c670d08070f7e6
F Makefile.linux-gcc d53183f4aa6a9192d249731c90dbdffbd2c68654
F README b974cdc3f9f12b87e851b04e75996d720ebf81ac
F VERSION d739ba532eddc5c09ef9a55151328cd6a8a102c6
@ -15,10 +15,10 @@ F art/SQLite_big.gif 2b8e4603b91ba2a2c7062a82ff570d945034bb30
F art/nocopy.gif 716aa07d4bb7250d4e75756073bf8ef9f56bec8f
F art/powered_by_sqlite.gif 7fbcd7d3675391fd3d21672c14c05f5999eb60d1
F config.guess 226d9a188c6196f3033ffc651cbc9dcee1a42977
F config.h.in 7940ca68451e949b9b4c83814a7c719721eea6e1
F config.h.in 3fda160d9a0ebbd6c22c0391354fa0036474680f
F config.sub 9ebe4c3b3dab6431ece34f16828b594fb420da55
F configure 300a0748b8c5cb10195e11c70f23cfe19fc455ce x
F configure.ac 732bfbb23e2ea8c6c79012d3a0f0f83e855ecbb1
F configure f405735e08411da80388439bed86941981da5b94 x
F configure.ac eebaa620c2c9a7c3be0fedfbca8c2e8dd673e586
F contrib/sqlitecon.tcl 210a913ad63f9f991070821e599d600bd913e0ad
F doc/lemon.html f0f682f50210928c07e562621c3b7e8ab912a538
F doc/report1.txt a031aaf37b185e4fa540223cb516d3bccec7eeac
@ -608,7 +608,7 @@ F tool/speedtest16.c c8a9c793df96db7e4933f0852abb7a03d48f2e81
F tool/speedtest2.tcl ee2149167303ba8e95af97873c575c3e0fab58ff
F tool/speedtest8.c 1dbced29de5f59ba2ebf877edcadf171540374d1
F tool/speedtest8inst1.c 293327bc76823f473684d589a8160bde1f52c14e
P a560c61849cb669ab03ba4a63b23369db234f329
R bb01765ac02861b7422c0d62644cf8f1
P 1ffe7a995733fe91534a3ed81d2640fd7e6ebaa6
R 0e73a5ae402dd55fe613de24133abe43
U shane
Z 506b42d114c5c88a2082fc56151910b6
Z a770b6ac41943e4c9632defd47535f79

View File

@ -1 +1 @@
1ffe7a995733fe91534a3ed81d2640fd7e6ebaa6
c67aa5057deda6419e1f205118bf09957d599c15