Make extension loading more easily configurable. Fixes #2977 (CVS 4821)

FossilOrigin-Name: 2a2e8b64df3ff9ea5831b226984ab2c85771131e
This commit is contained in:
mlcreech 2008-03-06 04:14:17 +00:00
parent 9498491013
commit a4edab0e59
5 changed files with 69 additions and 36 deletions

View File

@ -73,6 +73,9 @@ TLIBS = @LIBS@
#
TEMP_STORE = -DTEMP_STORE=@TEMP_STORE@
# Enable/disable loadable extensions based on configuration
TCC += @LOADEXTENSION_FLAGS@
# Version numbers and release number for the SQLite being compiled.
#
VERSION = @VERSION@
@ -116,7 +119,6 @@ NAWK = @AWK@
# You should not have to change anything below this line
###############################################################################
TCC += -DSQLITE_OMIT_LOAD_EXTENSION=1
# Object files for the SQLite library (non-amalgamation).
#

69
configure vendored
View File

@ -873,6 +873,7 @@ TARGET_READLINE_INC
TARGET_HAVE_READLINE
TARGET_DEBUG
USE_AMALGAMATION
LOADEXTENSION_FLAGS
LIBOBJS
LTLIBOBJS'
ac_subst_files=''
@ -1482,6 +1483,7 @@ Optional Features:
--disable-amalgamation Disable the amalgamation and instead build all files
separately (currently needed to build the test
fixture)
--enable-load-extension Enable loading of external extensions
Optional Packages:
--with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
@ -1935,7 +1937,7 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu
# The following RCS revision string applies to configure.in
# $Revision: 1.46 $
# $Revision: 1.47 $
#########
# Programs needed
@ -3686,7 +3688,7 @@ ia64-*-hpux*)
;;
*-*-irix6*)
# Find out which ABI we are using.
echo '#line 3689 "configure"' > conftest.$ac_ext
echo '#line 3691 "configure"' > conftest.$ac_ext
if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
@ -6365,11 +6367,11 @@ else
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
(eval echo "\"\$as_me:6368: $lt_compile\"" >&5)
(eval echo "\"\$as_me:6370: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err)
ac_status=$?
cat conftest.err >&5
echo "$as_me:6372: \$? = $ac_status" >&5
echo "$as_me:6374: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings other than the usual output.
@ -6633,11 +6635,11 @@ else
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
(eval echo "\"\$as_me:6636: $lt_compile\"" >&5)
(eval echo "\"\$as_me:6638: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err)
ac_status=$?
cat conftest.err >&5
echo "$as_me:6640: \$? = $ac_status" >&5
echo "$as_me:6642: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings other than the usual output.
@ -6737,11 +6739,11 @@ else
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
(eval echo "\"\$as_me:6740: $lt_compile\"" >&5)
(eval echo "\"\$as_me:6742: $lt_compile\"" >&5)
(eval "$lt_compile" 2>out/conftest.err)
ac_status=$?
cat out/conftest.err >&5
echo "$as_me:6744: \$? = $ac_status" >&5
echo "$as_me:6746: \$? = $ac_status" >&5
if (exit $ac_status) && test -s out/conftest2.$ac_objext
then
# The compiler can only warn and ignore the option if not recognized
@ -9082,7 +9084,7 @@ else
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<EOF
#line 9085 "configure"
#line 9087 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
@ -9182,7 +9184,7 @@ else
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<EOF
#line 9185 "configure"
#line 9187 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
@ -11518,11 +11520,11 @@ else
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
(eval echo "\"\$as_me:11521: $lt_compile\"" >&5)
(eval echo "\"\$as_me:11523: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err)
ac_status=$?
cat conftest.err >&5
echo "$as_me:11525: \$? = $ac_status" >&5
echo "$as_me:11527: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings other than the usual output.
@ -11622,11 +11624,11 @@ else
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
(eval echo "\"\$as_me:11625: $lt_compile\"" >&5)
(eval echo "\"\$as_me:11627: $lt_compile\"" >&5)
(eval "$lt_compile" 2>out/conftest.err)
ac_status=$?
cat out/conftest.err >&5
echo "$as_me:11629: \$? = $ac_status" >&5
echo "$as_me:11631: \$? = $ac_status" >&5
if (exit $ac_status) && test -s out/conftest2.$ac_objext
then
# The compiler can only warn and ignore the option if not recognized
@ -13229,11 +13231,11 @@ else
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
(eval echo "\"\$as_me:13232: $lt_compile\"" >&5)
(eval echo "\"\$as_me:13234: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err)
ac_status=$?
cat conftest.err >&5
echo "$as_me:13236: \$? = $ac_status" >&5
echo "$as_me:13238: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings other than the usual output.
@ -13333,11 +13335,11 @@ else
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
(eval echo "\"\$as_me:13336: $lt_compile\"" >&5)
(eval echo "\"\$as_me:13338: $lt_compile\"" >&5)
(eval "$lt_compile" 2>out/conftest.err)
ac_status=$?
cat out/conftest.err >&5
echo "$as_me:13340: \$? = $ac_status" >&5
echo "$as_me:13342: \$? = $ac_status" >&5
if (exit $ac_status) && test -s out/conftest2.$ac_objext
then
# The compiler can only warn and ignore the option if not recognized
@ -15568,11 +15570,11 @@ else
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
(eval echo "\"\$as_me:15571: $lt_compile\"" >&5)
(eval echo "\"\$as_me:15573: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err)
ac_status=$?
cat conftest.err >&5
echo "$as_me:15575: \$? = $ac_status" >&5
echo "$as_me:15577: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings other than the usual output.
@ -15836,11 +15838,11 @@ else
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
(eval echo "\"\$as_me:15839: $lt_compile\"" >&5)
(eval echo "\"\$as_me:15841: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err)
ac_status=$?
cat conftest.err >&5
echo "$as_me:15843: \$? = $ac_status" >&5
echo "$as_me:15845: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings other than the usual output.
@ -15940,11 +15942,11 @@ else
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
(eval echo "\"\$as_me:15943: $lt_compile\"" >&5)
(eval echo "\"\$as_me:15945: $lt_compile\"" >&5)
(eval "$lt_compile" 2>out/conftest.err)
ac_status=$?
cat out/conftest.err >&5
echo "$as_me:15947: \$? = $ac_status" >&5
echo "$as_me:15949: \$? = $ac_status" >&5
if (exit $ac_status) && test -s out/conftest2.$ac_objext
then
# The compiler can only warn and ignore the option if not recognized
@ -19867,6 +19869,22 @@ else
fi
#########
# See whether we should allow loadable extensions
# Check whether --enable-load-extension was given.
if test "${enable_load_extension+set}" = set; then
enableval=$enable_load_extension; use_loadextension=$enableval
else
use_loadextension=no
fi
if test "${use_loadextension}" = "yes" ; then
LOADEXTENSION_FLAGS=""
else
LOADEXTENSION_FLAGS="-DSQLITE_OMIT_LOAD_EXTENSION=1"
fi
#########
# Figure out whether or not we have a "usleep()" function.
#
@ -20828,11 +20846,12 @@ TARGET_READLINE_INC!$TARGET_READLINE_INC$ac_delim
TARGET_HAVE_READLINE!$TARGET_HAVE_READLINE$ac_delim
TARGET_DEBUG!$TARGET_DEBUG$ac_delim
USE_AMALGAMATION!$USE_AMALGAMATION$ac_delim
LOADEXTENSION_FLAGS!$LOADEXTENSION_FLAGS$ac_delim
LIBOBJS!$LIBOBJS$ac_delim
LTLIBOBJS!$LTLIBOBJS$ac_delim
_ACEOF
if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 11; then
if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 12; then
break
elif $ac_last_try; then
{ { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5

View File

@ -92,7 +92,7 @@ AC_INIT(src/sqlite.h.in)
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.32 $
# $Revision: 1.33 $
#########
# Programs needed
@ -574,6 +574,18 @@ else
fi
AC_SUBST(USE_AMALGAMATION)
#########
# See whether we should allow loadable extensions
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=""
else
LOADEXTENSION_FLAGS="-DSQLITE_OMIT_LOAD_EXTENSION=1"
fi
AC_SUBST(LOADEXTENSION_FLAGS)
#########
# Figure out whether or not we have a "usleep()" function.
#

View File

@ -1,7 +1,7 @@
C Build\samalgamation\sby\sdefault\son\sautoconf-driven\sbuilds,\sadd\n--disable-amalgamation\soption\sto\sconfigure\sscript\s(CVS\s4820)
D 2008-03-04T19:03:08
C Make\sextension\sloading\smore\seasily\sconfigurable.\s\sFixes\s#2977\s(CVS\s4821)
D 2008-03-06T04:14:18
F Makefile.arm-wince-mingw32ce-gcc ac5f7b2cef0cd850d6f755ba6ee4ab961b1fadf7
F Makefile.in e18597f1f36c530260692d52a4e3785825265d60
F Makefile.in 334e3d1d47539d5a310d7cd956ac0aeed9968059
F Makefile.linux-gcc d53183f4aa6a9192d249731c90dbdffbd2c68654
F README 9c4e2d6706bdcc3efdd773ce752a8cdab4f90028
F VERSION 2e206fc9458bf10a8c3ba2d13bf521a04ef441c6
@ -16,8 +16,8 @@ F art/nocopy.gif 716aa07d4bb7250d4e75756073bf8ef9f56bec8f
F art/powered_by_sqlite.gif 7fbcd7d3675391fd3d21672c14c05f5999eb60d1
F config.guess dba2d1300ec8f8cd00c6fb44b9edde21c14e960c
F config.sub 9a842e7c332ed65cef3f2c20354e06dc998b2796
F configure f8b0454f30c4d3beb4b4978b97743381b51c6494 x
F configure.ac e39ab14107eb49ba9c342155e05f1d987f5b1a61
F configure e430b461770bdbc090f3a249189c3ca701024b92 x
F configure.ac 2ef55e74f130264d03d6704b04292dda936b9fee
F contrib/sqlitecon.tcl 210a913ad63f9f991070821e599d600bd913e0ad
F doc/lemon.html f0f682f50210928c07e562621c3b7e8ab912a538
F doc/report1.txt a031aaf37b185e4fa540223cb516d3bccec7eeac
@ -621,7 +621,7 @@ F www/tclsqlite.tcl 8be95ee6dba05eabcd27a9d91331c803f2ce2130
F www/vdbe.tcl 87a31ace769f20d3627a64fa1fade7fed47b90d0
F www/version3.tcl 890248cf7b70e60c383b0e84d77d5132b3ead42b
F www/whentouse.tcl fc46eae081251c3c181bd79c5faef8195d7991a5
P 9c6694bb61a8ecdbfb2d05e5e05a8cc97b792240
R f6b04bb89c3105668b926378100c262b
P f9391fa06f22aea5c6af9e1c76d7f5404483189a
R d067dc088f0abfde86142238a6e140db
U mlcreech
Z 19aacec2cb03987f02ce862f80a0df8d
Z cff6fb75208e02bf05a1eb4dc14e3304

View File

@ -1 +1 @@
f9391fa06f22aea5c6af9e1c76d7f5404483189a
2a2e8b64df3ff9ea5831b226984ab2c85771131e