From: Tor Lillqvist Date: Tue, 24 May 2005 06:50:21 +0000 (+0000) Subject: Make libdb as included in e-d-s build on Win32 with mingw. (The official X-Git-Tag: upstream/3.7.4~7411 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=5a20ee20c63a4d088aad83c71f02ae70feadbca9;p=platform%2Fupstream%2Fevolution-data-server.git Make libdb as included in e-d-s build on Win32 with mingw. (The official 2005-05-24 Tor Lillqvist Make libdb as included in e-d-s build on Win32 with mingw. (The official build setup for libdb uses MSVC.) * libdb/dist/Makefile.in: Use EXEEXT for Win32 portability. Use the MAKEFILE_MAYBE_WIN32 variable (which configure.ac sets to empty on Unix, "_win32" on Win32) to use those source files that have an own copy in os_win32 from there. * libdb/dist/config.hin: Add DB_WIN32 flag. Insert stuff from the libdb/build_win32_db_config.h file. * libdb/dist/configure.ac: Changes for mingw builds. AC_SUBST some more variables. * libdb/dist/configure: Manually make corresponding changes as in configure.ac. (Yuck! But we don't run autogen in libdb/dost, so what else to do?) * libdb/os_win32/os_type.c: Include db_int_def.h here, too. --- diff --git a/ChangeLog b/ChangeLog index 80a5049..188cf92 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,25 @@ +2005-05-24 Tor Lillqvist + + Make libdb as included in e-d-s build on Win32 with mingw. (The + official build setup for libdb uses MSVC.) + + * libdb/dist/Makefile.in: Use EXEEXT for Win32 portability. Use + the MAKEFILE_MAYBE_WIN32 variable (which configure.ac sets to + empty on Unix, "_win32" on Win32) to use those source files that + have an own copy in os_win32 from there. + + * libdb/dist/config.hin: Add DB_WIN32 flag. Insert stuff from the + libdb/build_win32_db_config.h file. + + * libdb/dist/configure.ac: Changes for mingw builds. AC_SUBST some + more variables. + + * libdb/dist/configure: Manually make corresponding changes as in + configure.ac. (Yuck! But we don't run autogen in libdb/dost, so + what else to do?) + + * libdb/os_win32/os_type.c: Include db_int_def.h here, too. + 2005-05-19 Tor Lillqvist * configure.in: Check for regexec in a separate -lregex. Add diff --git a/libdb/dist/Makefile.in b/libdb/dist/Makefile.in index 99ee057..260c13d 100644 --- a/libdb/dist/Makefile.in +++ b/libdb/dist/Makefile.in @@ -364,8 +364,9 @@ RPC_JAVASRV_SRCS=\ UTIL_PROGS=\ @ADDITIONAL_PROGS@ \ - db_archive db_checkpoint db_deadlock \ - db_dump db_load db_printlog db_recover db_stat db_upgrade db_verify + db_archive@EXEEXT@ db_checkpoint@EXEEXT@ db_deadlock@EXEEXT@ \ + db_dump@EXEEXT@ db_load@EXEEXT@ db_printlog@EXEEXT@ \ + db_recover@EXEEXT@ db_stat@EXEEXT@ db_upgrade@EXEEXT@ db_verify@EXEEXT@ ################################################## # List of files installed into the library directory. @@ -482,53 +483,53 @@ berkeley_db_javasvc: $(rpc_jarfile) echo >> $@ exec java com.sleepycat.db.rpcserver.DbServer \$$@ chmod +x $@ -db_archive: db_archive@o@ util_sig@o@ $(DEF_LIB) +db_archive@EXEEXT@: db_archive@o@ util_sig@o@ $(DEF_LIB) $(CCLINK) -o $@ $(LDFLAGS) \ db_archive@o@ util_sig@o@ $(DEF_LIB) $(LIBS) $(POSTLINK) $@ -db_checkpoint: db_checkpoint@o@ util_log@o@ util_sig@o@ $(DEF_LIB) +db_checkpoint@EXEEXT@: db_checkpoint@o@ util_log@o@ util_sig@o@ $(DEF_LIB) $(CCLINK) -o $@ $(LDFLAGS) \ db_checkpoint@o@ util_log@o@ util_sig@o@ $(DEF_LIB) $(LIBS) $(POSTLINK) $@ -db_deadlock: db_deadlock@o@ util_log@o@ util_sig@o@ $(DEF_LIB) +db_deadlock@EXEEXT@: db_deadlock@o@ util_log@o@ util_sig@o@ $(DEF_LIB) $(CCLINK) -o $@ $(LDFLAGS) \ db_deadlock@o@ util_log@o@ util_sig@o@ $(DEF_LIB) $(LIBS) $(POSTLINK) $@ -db_dump: db_dump@o@ util_cache@o@ util_sig@o@ $(DEF_LIB) +db_dump@EXEEXT@: db_dump@o@ util_cache@o@ util_sig@o@ $(DEF_LIB) $(CCLINK) -o $@ $(LDFLAGS) db_dump@o@ util_cache@o@ util_sig@o@ $(DEF_LIB) $(LIBS) $(POSTLINK) $@ -db_dump185: db_dump185@o@ @LTLIBOBJS@ +db_dump185@EXEEXT@: db_dump185@o@ @LTLIBOBJS@ $(CCLINK) -o $@ $(LDFLAGS) db_dump185@o@ @LTLIBOBJS@ $(DB185LIB) $(POSTLINK) $@ -db_load: db_load@o@ util_cache@o@ util_sig@o@ $(DEF_LIB) +db_load@EXEEXT@: db_load@o@ util_cache@o@ util_sig@o@ $(DEF_LIB) $(CCLINK) -o $@ $(LDFLAGS) db_load@o@ util_cache@o@ util_sig@o@ $(DEF_LIB) $(LIBS) $(POSTLINK) $@ -db_printlog: db_printlog@o@ util_sig@o@ $(DEF_LIB) +db_printlog@EXEEXT@: db_printlog@o@ util_sig@o@ $(DEF_LIB) $(CCLINK) -o $@ $(LDFLAGS) \ db_printlog@o@ util_sig@o@ $(DEF_LIB) $(LIBS) $(POSTLINK) $@ -db_recover: db_recover@o@ util_sig@o@ $(DEF_LIB) +db_recover@EXEEXT@: db_recover@o@ util_sig@o@ $(DEF_LIB) $(CCLINK) -o $@ $(LDFLAGS) \ db_recover@o@ util_sig@o@ $(DEF_LIB) $(LIBS) $(POSTLINK) $@ -db_stat: db_stat@o@ util_cache@o@ util_sig@o@ $(DEF_LIB) +db_stat@EXEEXT@: db_stat@o@ util_cache@o@ util_sig@o@ $(DEF_LIB) $(CCLINK) -o $@ $(LDFLAGS) db_stat@o@ util_cache@o@ util_sig@o@ $(DEF_LIB) $(LIBS) $(POSTLINK) $@ -db_upgrade: db_upgrade@o@ util_sig@o@ $(DEF_LIB) +db_upgrade@EXEEXT@: db_upgrade@o@ util_sig@o@ $(DEF_LIB) $(CCLINK) -o $@ $(LDFLAGS) \ db_upgrade@o@ util_sig@o@ $(DEF_LIB) $(LIBS) $(POSTLINK) $@ -db_verify: db_verify@o@ util_cache@o@ util_sig@o@ $(DEF_LIB) +db_verify@EXEEXT@: db_verify@o@ util_cache@o@ util_sig@o@ $(DEF_LIB) $(CCLINK) -o $@ $(LDFLAGS) \ db_verify@o@ util_cache@o@ util_sig@o@ $(DEF_LIB) $(LIBS) $(POSTLINK) $@ @@ -1119,54 +1120,56 @@ mut_tas@o@: $(srcdir)/mutex/mut_tas.c $(CC) $(CFLAGS) $? mutex@o@: $(srcdir)/mutex/mutex.c $(CC) $(CFLAGS) $? -os_abs@o@: $(srcdir)/os/os_abs.c +os_abs@o@: $(srcdir)/os@MAKEFILE_MAYBE_WIN32@/os_abs.c $(CC) $(CFLAGS) $? os_alloc@o@: $(srcdir)/os/os_alloc.c $(CC) $(CFLAGS) $? -os_clock@o@: $(srcdir)/os/os_clock.c +os_clock@o@: $(srcdir)/os@MAKEFILE_MAYBE_WIN32@/os_clock.c $(CC) $(CFLAGS) $? -os_config@o@: $(srcdir)/os/os_config.c +os_config@o@: $(srcdir)/os@MAKEFILE_MAYBE_WIN32@/os_config.c $(CC) $(CFLAGS) $? -os_dir@o@: $(srcdir)/os/os_dir.c +os_dir@o@: $(srcdir)/os@MAKEFILE_MAYBE_WIN32@/os_dir.c $(CC) $(CFLAGS) $? -os_errno@o@: $(srcdir)/os/os_errno.c +os_errno@o@: $(srcdir)/os@MAKEFILE_MAYBE_WIN32@/os_errno.c $(CC) $(CFLAGS) $? -os_fid@o@: $(srcdir)/os/os_fid.c +os_fid@o@: $(srcdir)/os@MAKEFILE_MAYBE_WIN32@/os_fid.c $(CC) $(CFLAGS) $? -os_fsync@o@: $(srcdir)/os/os_fsync.c +os_fsync@o@: $(srcdir)/os@MAKEFILE_MAYBE_WIN32@/os_fsync.c $(CC) $(CFLAGS) $? os_id@o@: $(srcdir)/os/os_id.c $(CC) $(CFLAGS) $? -os_handle@o@: $(srcdir)/os/os_handle.c +os_handle@o@: $(srcdir)/os@MAKEFILE_MAYBE_WIN32@/os_handle.c $(CC) $(CFLAGS) $? -os_map@o@: $(srcdir)/os/os_map.c +os_map@o@: $(srcdir)/os@MAKEFILE_MAYBE_WIN32@/os_map.c $(CC) $(CFLAGS) $? os_method@o@: $(srcdir)/os/os_method.c $(CC) $(CFLAGS) $? os_oflags@o@: $(srcdir)/os/os_oflags.c $(CC) $(CFLAGS) $? -os_open@o@: $(srcdir)/os/os_open.c +os_open@o@: $(srcdir)/os@MAKEFILE_MAYBE_WIN32@/os_open.c $(CC) $(CFLAGS) $? os_region@o@: $(srcdir)/os/os_region.c $(CC) $(CFLAGS) $? -os_rename@o@: $(srcdir)/os/os_rename.c +os_rename@o@: $(srcdir)/os@MAKEFILE_MAYBE_WIN32@/os_rename.c $(CC) $(CFLAGS) $? os_root@o@: $(srcdir)/os/os_root.c $(CC) $(CFLAGS) $? os_rpath@o@: $(srcdir)/os/os_rpath.c $(CC) $(CFLAGS) $? -os_rw@o@: $(srcdir)/os/os_rw.c +os_rw@o@: $(srcdir)/os@MAKEFILE_MAYBE_WIN32@/os_rw.c $(CC) $(CFLAGS) $? -os_seek@o@: $(srcdir)/os/os_seek.c +os_seek@o@: $(srcdir)/os@MAKEFILE_MAYBE_WIN32@/os_seek.c $(CC) $(CFLAGS) $? -os_sleep@o@: $(srcdir)/os/os_sleep.c +os_sleep@o@: $(srcdir)/os@MAKEFILE_MAYBE_WIN32@/os_sleep.c $(CC) $(CFLAGS) $? -os_spin@o@: $(srcdir)/os/os_spin.c +os_spin@o@: $(srcdir)/os@MAKEFILE_MAYBE_WIN32@/os_spin.c $(CC) $(CFLAGS) $? -os_stat@o@: $(srcdir)/os/os_stat.c +os_stat@o@: $(srcdir)/os@MAKEFILE_MAYBE_WIN32@/os_stat.c $(CC) $(CFLAGS) $? os_tmpdir@o@: $(srcdir)/os/os_tmpdir.c $(CC) $(CFLAGS) $? +os_type@o@: $(srcdir)/os@MAKEFILE_MAYBE_WIN32@/os_type.c + $(CC) $(CFLAGS) $? os_unlink@o@: $(srcdir)/os/os_unlink.c $(CC) $(CFLAGS) $? qam@o@: $(srcdir)/qam/qam.c diff --git a/libdb/dist/config.hin b/libdb/dist/config.hin index abdbf6f..9b65cfa 100644 --- a/libdb/dist/config.hin +++ b/libdb/dist/config.hin @@ -353,6 +353,9 @@ /* Define to 1 to mask harmless unitialized memory read/writes. */ #undef UMRW +/* Define to 1 to if building for Win32. */ +#undef DB_WIN32 + /* Number of bits in a file offset, on hosts where this is settable. */ #undef _FILE_OFFSET_BITS @@ -403,3 +406,54 @@ #ifndef HAVE_VSNPRINTF #define vsnprintf __db_Cvsnprintf #endif + +#ifdef DB_WIN32 + +/* This part copied from build_win32/db_config.h */ + +/* + * XXX + * The following is not part of the automatic configuration setup, but + * provides the information necessary to build Berkeley DB on Windows. + */ +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +/* + * To build Tcl interface libraries, the include path must be configured to + * use the directory containing , usually the include directory in + * the Tcl distribution. + */ +#ifdef DB_TCL_SUPPORT +#include +#endif + +#define WIN32_LEAN_AND_MEAN +#include + +/* + * All of the necessary includes have been included, ignore the #includes + * in the Berkeley DB source files. + */ +#define NO_SYSTEM_INCLUDES + +/* + * Win32 has getcwd, snprintf and vsnprintf, but under different names. + */ +#define getcwd(buf, size) _getcwd(buf, size) +#define snprintf _snprintf +#define vsnprintf _vsnprintf + +#endif /* DB_WIN32 */ diff --git a/libdb/dist/configure b/libdb/dist/configure index 7b9de59..c346e54 100755 --- a/libdb/dist/configure +++ b/libdb/dist/configure @@ -470,7 +470,7 @@ ac_includes_default="\ # include #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 build build_cpu build_vendor build_os host host_cpu host_vendor host_os ADDITIONAL_INCS ADDITIONAL_LANG ADDITIONAL_OBJS ADDITIONAL_PROGS BUILD_TARGET CFLAGS CONFIGURATION_ARGS CONFIGURATION_PATH CPPFLAGS CXX CXXFLAGS DEFAULT_LIB DEFAULT_LIB_CXX EMBEDIX_ECD_CXX EMBEDIX_ECD_RPC EMBEDIX_ROOT INSTALLER INSTALL_LIBS INSTALL_TARGET JAR JAVACFLAGS LDFLAGS LIBJSO_LIBS LIBSO_LIBS LIBTOOL LIBTSO_LIBS LIBXSO_LIBS LOAD_LIBS MAKEFILE_CC MAKEFILE_CCLINK MAKEFILE_CXX MAKEFILE_CXXLINK MAKEFILE_SOLINK MAKEFILE_XSOLINK POSTLINK RPC_CLIENT_OBJS RPM_POST_INSTALL RPM_POST_UNINSTALL SOFLAGS db_cv_path_embedix_install db_cv_path_rpm_archive db_int_def o DB_VERSION_MAJOR DB_VERSION_MINOR DB_VERSION_PATCH DB_VERSION_UNIQUE_NAME DB_VERSION_STRING db_cv_path_ar ac_ct_db_cv_path_ar db_cv_path_chmod ac_ct_db_cv_path_chmod db_cv_path_cp ac_ct_db_cv_path_cp path_ldconfig ac_ct_path_ldconfig db_cv_path_ldconfig db_cv_path_ln ac_ct_db_cv_path_ln db_cv_path_mkdir ac_ct_db_cv_path_mkdir path_ranlib ac_ct_path_ranlib db_cv_path_ranlib db_cv_path_rm ac_ct_db_cv_path_rm db_cv_path_rpm ac_ct_db_cv_path_rpm path_sh ac_ct_path_sh db_cv_path_sh path_strip ac_ct_path_strip db_cv_path_strip db_cv_path_kill ac_ct_db_cv_path_kill INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA CC ac_ct_CC EXEEXT OBJEXT CCC ac_ct_CCC ac_ct_CXX cxx_have_stdheaders LN_S ECHO RANLIB ac_ct_RANLIB STRIP ac_ct_STRIP CPP EGREP SOSUFFIX MODSUFFIX JMODSUFFIX JAVAC _ACJNI_JAVAC TCFLAGS TCL_BIN_DIR TCL_SRC_DIR TCL_LIB_FILE TCL_TCLSH u_char_decl u_short_decl u_int_decl u_long_decl u_int8_decl u_int16_decl int16_decl u_int32_decl int32_decl ssize_t_decl db_align_t_decl db_alignp_t_decl 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 build build_cpu build_vendor build_os host host_cpu host_vendor host_os ADDITIONAL_INCS ADDITIONAL_LANG ADDITIONAL_OBJS ADDITIONAL_PROGS BUILD_TARGET CFLAGS CONFIGURATION_ARGS CONFIGURATION_PATH CPPFLAGS CXX CXXFLAGS DEFAULT_LIB DEFAULT_LIB_CXX EMBEDIX_ECD_CXX EMBEDIX_ECD_RPC EMBEDIX_ROOT INSTALLER INSTALL_LIBS INSTALL_TARGET JAR JAVACFLAGS LDFLAGS LIBJSO_LIBS LIBSO_LIBS LIBTOOL LIBTSO_LIBS LIBXSO_LIBS LOAD_LIBS MAKEFILE_CC MAKEFILE_CCLINK MAKEFILE_CXX MAKEFILE_CXXLINK MAKEFILE_MAYBE_WIN32 MAKEFILE_SOLINK MAKEFILE_XSOLINK POSTLINK RPC_CLIENT_OBJS RPM_POST_INSTALL RPM_POST_UNINSTALL SOFLAGS db_cv_path_embedix_install db_cv_path_rpm_archive db_int_def o DB_VERSION_MAJOR DB_VERSION_MINOR DB_VERSION_PATCH DB_VERSION_UNIQUE_NAME DB_VERSION_STRING db_cv_path_ar ac_ct_db_cv_path_ar db_cv_path_chmod ac_ct_db_cv_path_chmod db_cv_path_cp ac_ct_db_cv_path_cp path_ldconfig ac_ct_path_ldconfig db_cv_path_ldconfig db_cv_path_ln ac_ct_db_cv_path_ln db_cv_path_mkdir ac_ct_db_cv_path_mkdir path_ranlib ac_ct_path_ranlib db_cv_path_ranlib db_cv_path_rm ac_ct_db_cv_path_rm db_cv_path_rpm ac_ct_db_cv_path_rpm path_sh ac_ct_path_sh db_cv_path_sh path_strip ac_ct_path_strip db_cv_path_strip db_cv_path_kill ac_ct_db_cv_path_kill INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA CC ac_ct_CC EXEEXT OBJEXT CCC ac_ct_CCC ac_ct_CXX cxx_have_stdheaders LN_S ECHO RANLIB ac_ct_RANLIB STRIP ac_ct_STRIP CPP EGREP SOSUFFIX MODSUFFIX JMODSUFFIX JAVAC _ACJNI_JAVAC TCFLAGS TCL_BIN_DIR TCL_SRC_DIR TCL_LIB_FILE TCL_TCLSH u_char_decl u_short_decl u_int_decl u_long_decl u_int8_decl u_int16_decl int16_decl u_int32_decl int32_decl ssize_t_decl db_align_t_decl db_alignp_t_decl LIBOBJS LTLIBOBJS' ac_subst_files='' # Initialize some variables set by options. @@ -3341,6 +3341,8 @@ fi # XXX # Don't override anything if it's already set from the environment. optimize_def="-O" +MAKEFILE_MAYBE_WIN32="" +SOFLAGS="" case "$host_os" in aix4.3.*|aix5*) optimize_def="-O2" @@ -3360,6 +3362,16 @@ irix*) optimize_def="-O2" CPPFLAGS="$CPPFLAGS -D_SGI_MP_SOURCE";; linux*) optimize_def="-O2" CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE -D_REENTRANT";; +mingw*) optimize_def="-O2" + SOFLAGS="-no-undefined" + ADDITIONAL_OBJS="os_type.lo $ADDITIONAL_OBJS" + MAKEFILE_MAYBE_WIN32="_win32" + cat >>confdefs.h <<\_ACEOF +#define DB_WIN32 1 +_ACEOF + + +;; mpeix*) CPPFLAGS="$CPPFLAGS -D_POSIX_SOURCE -D_SOCKET_SOURCE" LIBS="$LIBS -lsocket -lsvipc";; osf*) CPPFLAGS="$CPPFLAGS -D_REENTRANT" @@ -9775,7 +9787,6 @@ LIBTOOL='$(SHELL) $(top_builddir)/libtool' LIBTOOL="\$(SHELL) ./libtool" -SOFLAGS="" # Set SOSUFFIX and friends @@ -10655,6 +10666,13 @@ echo "${ECHO_T}file not found" >&6 TCFLAGS="-I$TCL_PREFIX/include" fi + case "$host" in + *-mingw*) + # To include tcl.h when compiling tcl_*.o + TCFLAGS="$TCFLAGS -DDB_TCL_SUPPORT" + ;; + esac + INSTALL_LIBS="${INSTALL_LIBS} \$(libtso_target)" fi @@ -20732,6 +20750,7 @@ s,@MAKEFILE_CC@,$MAKEFILE_CC,;t t s,@MAKEFILE_CCLINK@,$MAKEFILE_CCLINK,;t t s,@MAKEFILE_CXX@,$MAKEFILE_CXX,;t t s,@MAKEFILE_CXXLINK@,$MAKEFILE_CXXLINK,;t t +s,@MAKEFILE_MAYBE_WIN32@,$MAKEFILE_MAYBE_WIN32,;t t s,@MAKEFILE_SOLINK@,$MAKEFILE_SOLINK,;t t s,@MAKEFILE_XSOLINK@,$MAKEFILE_XSOLINK,;t t s,@POSTLINK@,$POSTLINK,;t t diff --git a/libdb/dist/configure.ac b/libdb/dist/configure.ac index 1d998c5..fce2b3d 100644 --- a/libdb/dist/configure.ac +++ b/libdb/dist/configure.ac @@ -34,6 +34,7 @@ AC_SUBST(DEFAULT_LIB_CXX) AC_SUBST(EMBEDIX_ECD_CXX) AC_SUBST(EMBEDIX_ECD_RPC) AC_SUBST(EMBEDIX_ROOT) +AC_SUBST(EXEEXT) AC_SUBST(INSTALLER) AC_SUBST(INSTALL_LIBS) AC_SUBST(INSTALL_TARGET) @@ -51,6 +52,7 @@ AC_SUBST(MAKEFILE_CC) AC_SUBST(MAKEFILE_CCLINK) AC_SUBST(MAKEFILE_CXX) AC_SUBST(MAKEFILE_CXXLINK) +AC_SUBST(MAKEFILE_MAYBE_WIN32) AC_SUBST(MAKEFILE_SOLINK) AC_SUBST(MAKEFILE_XSOLINK) AC_SUBST(POSTLINK) @@ -145,6 +147,9 @@ fi # XXX # Don't override anything if it's already set from the environment. optimize_def="-O" +MAKEFILE_MAYBE_WIN32="" +EXEEXT="" +SOFLAGS="" case "$host_os" in aix4.3.*|aix5*) optimize_def="-O2" @@ -164,6 +169,14 @@ irix*) optimize_def="-O2" CPPFLAGS="$CPPFLAGS -D_SGI_MP_SOURCE";; linux*) optimize_def="-O2" CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE -D_REENTRANT";; +mingw*) optimize_def="-O2" + EXEEXT=".exe" + SOFLAGS="-no-undefined" + ADDITIONAL_OBJS="os_type.lo $ADDITIONAL_OBJS" + MAKEFILE_MAYBE_WIN32="_win32" + AC_DEFINE(DB_WIN32) + AH_TEMPLATE(DB_WIN32, + [Define to 1 to if building for Win32.]);; mpeix*) CPPFLAGS="$CPPFLAGS -D_POSIX_SOURCE -D_SOCKET_SOURCE" LIBS="$LIBS -lsocket -lsvipc";; osf*) CPPFLAGS="$CPPFLAGS -D_REENTRANT" @@ -257,7 +270,6 @@ CCC=CXX AC_PROG_LIBTOOL LIBTOOL="\$(SHELL) ./libtool" -SOFLAGS="" # Set SOSUFFIX and friends SOSUFFIX_CONFIG diff --git a/libdb/os_win32/os_type.c b/libdb/os_win32/os_type.c index 5df19b7..da51a5c 100644 --- a/libdb/os_win32/os_type.c +++ b/libdb/os_win32/os_type.c @@ -6,6 +6,7 @@ */ #include "db_config.h" +#include "db_int_def.h" #ifndef lint static const char revid[] = "$Id$";