2 dnl This file is an input file used by the GNU "autoconf" program to
3 dnl generate the file "configure", which is run during Tcl installation
4 dnl to configure the system for the local environment.
6 #-----------------------------------------------------------------------
7 # Sample configure.ac for Tcl Extensions. The only places you should
8 # need to modify this file are marked by the string __CHANGE__
9 #-----------------------------------------------------------------------
11 #-----------------------------------------------------------------------
13 # Set your package name and version numbers here.
15 # This initializes the environment with PACKAGE_NAME and PACKAGE_VERSION
16 # set as provided. These will also be added as -D defs in your Makefile
17 # so you can encode the package version directly into the source files.
18 # This will also define a special symbol for Windows (BUILD_<PACKAGE_NAME>
19 # so that we create the export library with the dll.
20 #-----------------------------------------------------------------------
22 AC_INIT([tdbcsqlite3],[1.1.3])
24 #--------------------------------------------------------------------
25 # Call TEA_INIT as the first TEA_ macro to set up initial vars.
26 # This will define a ${TEA_PLATFORM} variable == "unix" or "windows"
27 # as well as PKG_LIB_FILE and PKG_STUB_LIB_FILE.
28 #--------------------------------------------------------------------
32 AC_CONFIG_AUX_DIR(tclconfig)
34 #--------------------------------------------------------------------
35 # Load the tclConfig.sh file
36 #--------------------------------------------------------------------
41 #--------------------------------------------------------------------
42 # Load the tkConfig.sh file if necessary (Tk extension)
43 #--------------------------------------------------------------------
48 #----------------------------------------------------------------------
49 # Load the tdbcConfig.sh file
50 #----------------------------------------------------------------------
54 # The next bit probably ought to be in TEA_LOAD_CONFIG
55 AC_MSG_WARN([Looking for "${tdbc_BIN_DIR}/Makefile"])
56 if test -f "${tdbc_BIN_DIR}/Makefile" ; then
57 AC_MSG_WARN([Found Makefile - using build include spec and lib specs for tdbc])
58 tdbc_INCLUDE_SPEC=${tdbc_BUILD_INCLUDE_SPEC}
59 tdbc_LIBRARY_PATH=${tdbc_BUILD_LIBRARY_PATH}
61 AC_SUBST(tdbc_LIBRARY_PATH)
62 AC_SUBST(TDBC_VERSION)
63 AC_SUBST(tdbc_BIN_DIR)
64 AC_SUBST(TDBC_LIB_FILE)
66 #-----------------------------------------------------------------------
67 # Handle the --prefix=... option by defaulting to what Tcl gave.
68 # Must be called after TEA_LOAD_TCLCONFIG and before TEA_SETUP_COMPILER.
69 #-----------------------------------------------------------------------
73 #-----------------------------------------------------------------------
74 # Standard compiler checks.
75 # This sets up CC by using the CC env var, or looks for gcc otherwise.
76 # This also calls AC_PROG_CC and a few others to create the basic setup
77 # necessary to compile executables.
78 #-----------------------------------------------------------------------
82 #-----------------------------------------------------------------------
84 # Specify the C source files to compile in TEA_ADD_SOURCES,
85 # public headers that need to be installed in TEA_ADD_HEADERS,
86 # stub library C source files to compile in TEA_ADD_STUB_SOURCES,
87 # and runtime Tcl library files in TEA_ADD_TCL_SOURCES.
88 # This defines PKG(_STUB)_SOURCES, PKG(_STUB)_OBJECTS, PKG_HEADERS
89 # and PKG_TCL_SOURCES.
90 #-----------------------------------------------------------------------
97 #TEA_ADD_STUB_SOURCES([])
98 TEA_ADD_TCL_SOURCES([library/tdbcsqlite3.tcl])
100 #--------------------------------------------------------------------
103 # You can add more files to clean if your extension creates any extra
104 # files by extending CLEANFILES.
105 # Add pkgIndex.tcl if it is generated in the Makefile instead of ./configure
106 # and change Makefile.in to move it from CONFIG_CLEAN_FILES to BINARIES var.
108 # A few miscellaneous platform-specific items:
109 # TEA_ADD_* any platform specific compiler/build info here.
110 #--------------------------------------------------------------------
112 #CLEANFILES="$CLEANFILES pkgIndex.tcl"
113 if test "${TEA_PLATFORM}" = "windows" ; then
114 # Ensure no empty if clauses
116 #TEA_ADD_SOURCES([win/winFile.c])
117 #TEA_ADD_INCLUDES([-I\"$(${CYGPATH} ${srcdir}/win)\"])
119 # Ensure no empty else clauses
121 #TEA_ADD_SOURCES([unix/unixFile.c])
122 #TEA_ADD_LIBS([-lsuperfly])
125 #--------------------------------------------------------------------
127 # Choose which headers you need. Extension authors should try very
128 # hard to only rely on the Tcl public header files. Internal headers
129 # contain private data structures and are subject to change without
131 # This MUST be called after TEA_LOAD_TCLCONFIG / TEA_LOAD_TKCONFIG
132 #--------------------------------------------------------------------
134 #TEA_PUBLIC_TCL_HEADERS
135 #TEA_PRIVATE_TCL_HEADERS
137 #TEA_PUBLIC_TK_HEADERS
138 #TEA_PRIVATE_TK_HEADERS
141 #--------------------------------------------------------------------
142 # Check whether --enable-threads or --disable-threads was given.
143 # This auto-enables if Tcl was compiled threaded.
144 #--------------------------------------------------------------------
148 #--------------------------------------------------------------------
149 # The statement below defines a collection of symbols related to
150 # building as a shared library instead of a static library.
151 #--------------------------------------------------------------------
155 #--------------------------------------------------------------------
156 # This macro figures out what flags to use with the compiler/linker
157 # when building shared/static debug/optimized objects. This information
158 # can be taken from the tclConfig.sh file, but this figures it all out.
159 #--------------------------------------------------------------------
163 #--------------------------------------------------------------------
164 # Set the default compiler switches based on the --enable-symbols option.
165 #--------------------------------------------------------------------
169 #--------------------------------------------------------------------
170 # This macro generates a line to use when building a library. It
171 # depends on values set by the TEA_ENABLE_SHARED, TEA_ENABLE_SYMBOLS,
172 # and TEA_LOAD_TCLCONFIG macros above.
173 #--------------------------------------------------------------------
177 #--------------------------------------------------------------------
178 # Determine the name of the tclsh and/or wish executables in the
179 # Tcl and Tk build directories or the location they were installed
180 # into. These paths are used to support running test cases only,
181 # the Makefile should not be making use of these paths to generate
182 # a pkgIndex.tcl file or anything else at extension build time.
183 #--------------------------------------------------------------------
188 #--------------------------------------------------------------------
189 # Substitute variables needed for .tm install.
190 #--------------------------------------------------------------------
192 AC_SUBST(TCL_VERSION)
193 AC_SUBST(TCL_MAJOR_VERSION)
194 AC_SUBST(TCL_MINOR_VERSION)
196 #--------------------------------------------------------------------
197 # Finally, substitute all of the various values into the Makefile.
198 # You may alternatively have a special pkgIndex.tcl.in or other files
199 # which require substituting the AC variables in. Include these here.
200 #--------------------------------------------------------------------
202 AC_CONFIG_FILES([Makefile pkgIndex.tcl])