From 87c84a28d8a2bfe75f1c383728670f74c1517568 Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Thu, 14 Feb 2013 18:04:26 +0200 Subject: Make sure windows.hxx is always installed on Windows --- configure.ac | 11 +++++++++++ odb/Makefile.am | 15 +++++++++++---- odb/libodb-vc10.vcxproj | 2 +- odb/libodb-vc10.vcxproj.filters | 2 +- odb/libodb-vc11.vcxproj | 2 +- odb/libodb-vc11.vcxproj.filters | 2 +- odb/libodb-vc9.vcproj | 2 +- odb/makefile | 27 +++++++++++++++------------ 8 files changed, 42 insertions(+), 21 deletions(-) diff --git a/configure.ac b/configure.ac index a2daa10..2a71588 100644 --- a/configure.ac +++ b/configure.ac @@ -24,6 +24,17 @@ AC_LANG(C++) # LT_OUTPUT +# Check for Windows. +# +win32=no +case $host_os in + windows* | mingw*) + win32=yes + ;; +esac + +AM_CONDITIONAL([ODB_WIN32], [test x$win32 = xyes]) + # Check for threads. # THREADS diff --git a/odb/Makefile.am b/odb/Makefile.am index 1650e41..6f64ff0 100644 --- a/odb/Makefile.am +++ b/odb/Makefile.am @@ -11,14 +11,21 @@ nobase_nodist_odbinclude_HEADERS = details/config.h EXTRA_DIST = __file__(extra_dist) +# At the moment, DllMain() is only necessary if we are using Win32 +# threads. So keep win32_dll_sources in ODB_THREADS_WIN32. +# +if ODB_WIN32 +nobase_odbinclude_HEADERS += __path__(win32_headers) +endif + if ODB_THREADS_POSIX -libodb_la_SOURCES += __path__(posix_sources) -nobase_odbinclude_HEADERS += __path__(posix_headers) +libodb_la_SOURCES += __path__(posix_threads_sources) +nobase_odbinclude_HEADERS += __path__(posix_threads_headers) endif if ODB_THREADS_WIN32 -libodb_la_SOURCES += __path__(win32_sources) __path__(win32_dll_sources) -nobase_odbinclude_HEADERS += __path__(win32_headers) +libodb_la_SOURCES += __path__(win32_threads_sources) __path__(win32_dll_sources) +nobase_odbinclude_HEADERS += __path__(win32_threads_headers) endif AM_CPPFLAGS= -I'$(top_builddir)' -I'$(top_srcdir)' -DLIBODB_DYNAMIC_LIB diff --git a/odb/libodb-vc10.vcxproj b/odb/libodb-vc10.vcxproj index 18e5415..d3e2889 100644 --- a/odb/libodb-vc10.vcxproj +++ b/odb/libodb-vc10.vcxproj @@ -164,7 +164,7 @@ __header_entry__(details\config-vc.h) __source_entries__(sources) -__source_entries__(win32_sources) +__source_entries__(win32_threads_sources) __source_entries__(win32_dll_sources) diff --git a/odb/libodb-vc10.vcxproj.filters b/odb/libodb-vc10.vcxproj.filters index 1663f9d..da1d6b2 100644 --- a/odb/libodb-vc10.vcxproj.filters +++ b/odb/libodb-vc10.vcxproj.filters @@ -16,6 +16,6 @@ __header_filter_entry__(details\config-vc.h) __source_filter_entries__(sources) -__source_filter_entries__(win32_sources) +__source_filter_entries__(win32_threads_sources) diff --git a/odb/libodb-vc11.vcxproj b/odb/libodb-vc11.vcxproj index 52e6439..7da5af7 100644 --- a/odb/libodb-vc11.vcxproj +++ b/odb/libodb-vc11.vcxproj @@ -168,7 +168,7 @@ __header_entry__(details\config-vc.h) __source_entries__(sources) -__source_entries__(win32_sources) +__source_entries__(win32_threads_sources) __source_entries__(win32_dll_sources) diff --git a/odb/libodb-vc11.vcxproj.filters b/odb/libodb-vc11.vcxproj.filters index 1663f9d..da1d6b2 100644 --- a/odb/libodb-vc11.vcxproj.filters +++ b/odb/libodb-vc11.vcxproj.filters @@ -16,6 +16,6 @@ __header_filter_entry__(details\config-vc.h) __source_filter_entries__(sources) -__source_filter_entries__(win32_sources) +__source_filter_entries__(win32_threads_sources) diff --git a/odb/libodb-vc9.vcproj b/odb/libodb-vc9.vcproj index 73ead32..011e4f0 100644 --- a/odb/libodb-vc9.vcproj +++ b/odb/libodb-vc9.vcproj @@ -341,7 +341,7 @@ UniqueIdentifier="{4FC737F1-C7A5-4376-A066-2A32D752A2FF}" > __source_entries__(sources) -__source_entries__(win32_sources) +__source_entries__(win32_threads_sources) __source_entries__(win32_dll_sources)