From ed5640d8b587fbcfed7dd7967f3de04b37a76f26 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Sun, 7 Apr 2024 11:06:44 +0200 Subject: Adding upstream version 4:7.4.7. Signed-off-by: Daniel Baumann --- external/cppunit/CPPUNIT_PLUGIN_EXPORT.patch.0 | 11 + external/cppunit/ExternalProject_cppunit.mk | 62 ++ external/cppunit/Makefile | 7 + external/cppunit/Module_cppunit.mk | 17 + external/cppunit/README | 3 + external/cppunit/UnpackedTarball_cppunit.mk | 33 ++ external/cppunit/disable-dynloading.patch | 25 + external/cppunit/enable-win32-debug.patch | 34 ++ external/cppunit/order.patch.0 | 25 + external/cppunit/rtti.patch.0 | 15 + external/cppunit/unix.patch | 10 + external/cppunit/windows-arm64.patch.1 | 786 +++++++++++++++++++++++++ external/cppunit/windows.patch | 50 ++ 13 files changed, 1078 insertions(+) create mode 100644 external/cppunit/CPPUNIT_PLUGIN_EXPORT.patch.0 create mode 100644 external/cppunit/ExternalProject_cppunit.mk create mode 100644 external/cppunit/Makefile create mode 100644 external/cppunit/Module_cppunit.mk create mode 100644 external/cppunit/README create mode 100644 external/cppunit/UnpackedTarball_cppunit.mk create mode 100644 external/cppunit/disable-dynloading.patch create mode 100644 external/cppunit/enable-win32-debug.patch create mode 100644 external/cppunit/order.patch.0 create mode 100644 external/cppunit/rtti.patch.0 create mode 100644 external/cppunit/unix.patch create mode 100644 external/cppunit/windows-arm64.patch.1 create mode 100644 external/cppunit/windows.patch (limited to 'external/cppunit') diff --git a/external/cppunit/CPPUNIT_PLUGIN_EXPORT.patch.0 b/external/cppunit/CPPUNIT_PLUGIN_EXPORT.patch.0 new file mode 100644 index 000000000..a764be95a --- /dev/null +++ b/external/cppunit/CPPUNIT_PLUGIN_EXPORT.patch.0 @@ -0,0 +1,11 @@ +--- include/cppunit/plugin/TestPlugIn.h ++++ include/cppunit/plugin/TestPlugIn.h +@@ -111,7 +111,7 @@ + /*! \brief Type of the function exported by a plug-in. + * \ingroup WritingTestPlugIn + */ +-typedef CppUnitTestPlugIn *(*TestPlugInSignature)(); ++extern "C" { typedef CppUnitTestPlugIn *(*TestPlugInSignature)(); } + + + /*! \brief Implements the function exported by the test plug-in diff --git a/external/cppunit/ExternalProject_cppunit.mk b/external/cppunit/ExternalProject_cppunit.mk new file mode 100644 index 000000000..f0b4ff06a --- /dev/null +++ b/external/cppunit/ExternalProject_cppunit.mk @@ -0,0 +1,62 @@ +# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*- +# +# This file is part of the LibreOffice project. +# +# This Source Code Form is subject to the terms of the Mozilla Public +# License, v. 2.0. If a copy of the MPL was not distributed with this +# file, You can obtain one at http://mozilla.org/MPL/2.0/. +# + +$(eval $(call gb_ExternalProject_ExternalProject,cppunit)) + +$(eval $(call gb_ExternalProject_register_targets,cppunit,\ + build \ +)) + +ifeq ($(OS),WNT) +$(call gb_ExternalProject_get_state_target,cppunit,build) : + $(call gb_Trace_StartRange,cppunit,EXTERNAL) + $(call gb_ExternalProject_run,build,\ + PROFILEFLAGS="$(gb_MSBUILD_CONFIG) \ + /p:Platform=$(gb_MSBUILD_PLATFORM) \ + /p:PlatformToolset=$(VCTOOLSET) /p:VisualStudioVersion=$(VCVER) /ToolsVersion:Current \ + $(if $(filter 10,$(WINDOWS_SDK_VERSION)),/p:WindowsTargetPlatformVersion=$(UCRTVERSION))" \ + && msbuild.exe cppunit_dll.vcxproj /p:Configuration=$${PROFILEFLAGS} \ + && cd ../DllPlugInTester \ + && msbuild.exe DllPlugInTester.vcxproj /p:Configuration=$${PROFILEFLAGS} \ + ,src/cppunit) + $(call gb_Trace_EndRange,cppunit,EXTERNAL) +else + +cppunit_CXXFLAGS=$(CXXFLAGS) $(gb_EMSCRIPTEN_CXXFLAGS) + +cppunit_CXXFLAGS+=$(gb_COMPILERDEFS_STDLIB_DEBUG) + +ifneq (,$(call gb_LinkTarget__symbols_enabled,cppunit)) +cppunit_CXXFLAGS+=-g +endif + +$(call gb_ExternalProject_get_state_target,cppunit,build) : + $(call gb_Trace_StartRange,cppunit,EXTERNAL) + $(call gb_ExternalProject_run,build,\ + $(gb_RUN_CONFIGURE) ./configure \ + --disable-dependency-tracking \ + $(if $(filter TRUE,$(DISABLE_DYNLOADING)),--disable-shared,--disable-static) \ + --disable-doxygen \ + --disable-html-docs \ + --disable-latex-docs \ + --disable-werror \ + $(gb_CONFIGURE_PLATFORMS) \ + $(if $(filter MACOSX,$(OS)),--prefix=/@.__________________________________________________NONE) \ + $(if $(filter WNT,$(OS)),LDFLAGS="-Wl$(COMMA)--enable-runtime-pseudo-reloc-v2") \ + $(if $(filter SOLARIS,$(OS)),LIBS="-lm") \ + $(if $(filter ANDROID,$(OS)),LIBS="$(gb_STDLIBS)") \ + $(if $(verbose),--disable-silent-rules,--enable-silent-rules) \ + CXXFLAGS="$(cppunit_CXXFLAGS)" \ + && cd src \ + && $(MAKE) \ + ) + $(call gb_Trace_EndRange,cppunit,EXTERNAL) +endif + +# vim: set noet sw=4 ts=4: diff --git a/external/cppunit/Makefile b/external/cppunit/Makefile new file mode 100644 index 000000000..e4968cf85 --- /dev/null +++ b/external/cppunit/Makefile @@ -0,0 +1,7 @@ +# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*- + +module_directory:=$(dir $(realpath $(firstword $(MAKEFILE_LIST)))) + +include $(module_directory)/../../solenv/gbuild/partial_build.mk + +# vim: set noet sw=4 ts=4: diff --git a/external/cppunit/Module_cppunit.mk b/external/cppunit/Module_cppunit.mk new file mode 100644 index 000000000..296feeb74 --- /dev/null +++ b/external/cppunit/Module_cppunit.mk @@ -0,0 +1,17 @@ +# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*- +# +# This file is part of the LibreOffice project. +# +# This Source Code Form is subject to the terms of the Mozilla Public +# License, v. 2.0. If a copy of the MPL was not distributed with this +# file, You can obtain one at http://mozilla.org/MPL/2.0/. +# + +$(eval $(call gb_Module_Module,cppunit)) + +$(eval $(call gb_Module_add_targets,cppunit,\ + UnpackedTarball_cppunit \ + ExternalProject_cppunit \ +)) + +# vim: set noet sw=4 ts=4: diff --git a/external/cppunit/README b/external/cppunit/README new file mode 100644 index 000000000..e1d4e82a5 --- /dev/null +++ b/external/cppunit/README @@ -0,0 +1,3 @@ +C++ port of the JUnit framework for unit testing. + +From [http://www.freedesktop.org/wiki/Software/cppunit/] diff --git a/external/cppunit/UnpackedTarball_cppunit.mk b/external/cppunit/UnpackedTarball_cppunit.mk new file mode 100644 index 000000000..5dc750bbd --- /dev/null +++ b/external/cppunit/UnpackedTarball_cppunit.mk @@ -0,0 +1,33 @@ +# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*- +# +# This file is part of the LibreOffice project. +# +# This Source Code Form is subject to the terms of the Mozilla Public +# License, v. 2.0. If a copy of the MPL was not distributed with this +# file, You can obtain one at http://mozilla.org/MPL/2.0/. +# + +$(eval $(call gb_UnpackedTarball_UnpackedTarball,cppunit)) + +$(eval $(call gb_UnpackedTarball_set_tarball,cppunit,$(CPPUNIT_TARBALL),,cppunit)) + +$(eval $(call gb_UnpackedTarball_update_autoconf_configs,cppunit)) + +# * external/cppunit/order.patch.0 upstreamed at +# "Run tests in deterministic order": +$(eval $(call gb_UnpackedTarball_add_patches,cppunit,\ + external/cppunit/windows.patch \ + external/cppunit/unix.patch \ + external/cppunit/CPPUNIT_PLUGIN_EXPORT.patch.0 \ + external/cppunit/enable-win32-debug.patch \ + external/cppunit/rtti.patch.0 \ + external/cppunit/order.patch.0 \ + external/cppunit/windows-arm64.patch.1 \ +)) +ifeq ($(DISABLE_DYNLOADING),TRUE) +$(eval $(call gb_UnpackedTarball_add_patches,cppunit,\ + external/cppunit/disable-dynloading.patch \ +)) +endif + +# vim: set noet sw=4 ts=4: diff --git a/external/cppunit/disable-dynloading.patch b/external/cppunit/disable-dynloading.patch new file mode 100644 index 000000000..62ed1deeb --- /dev/null +++ b/external/cppunit/disable-dynloading.patch @@ -0,0 +1,25 @@ +--- build/cppunit-1.13.1/include/cppunit/plugin/TestPlugIn.h ++++ misc/build/cppunit-1.13.1/include/cppunit/plugin/TestPlugIn.h +@@ -106,7 +106,9 @@ + * CppUnitTestPlugIn *CPPUNIT_PLUGIN_EXPORTED_NAME(void); + * \endcode + */ ++#ifndef CPPUNIT_PLUGIN_EXPORTED_NAME + #define CPPUNIT_PLUGIN_EXPORTED_NAME cppunitTestPlugIn ++#endif + + /*! \brief Type of the function exported by a plug-in. + * \ingroup WritingTestPlugIn +@@ -143,6 +143,12 @@ + #define CPPUNIT_PLUGIN_IMPLEMENT_MAIN() \ + typedef char __CppUnitPlugInImplementMainDummyTypeDef + ++// Actually this is for iOS and Android where we build the cppunit tests libraries ++// as plain archives and just link them statically into test fixture programs, ++// and don't want any stinking duplicate main(), but shouldn't hurt for MacOSX either. ++#elif defined(__APPLE__) || defined(__ANDROID__) || defined(__EMSCRIPTEN__) ++#define CPPUNIT_PLUGIN_IMPLEMENT_MAIN() \ ++ typedef char __CppUnitPlugInImplementMainDummyTypeDef + // Unix + #elif defined(CPPUNIT_HAVE_UNIX_DLL_LOADER) || defined(CPPUNIT_HAVE_UNIX_SHL_LOADER) + #define CPPUNIT_PLUGIN_IMPLEMENT_MAIN() \ diff --git a/external/cppunit/enable-win32-debug.patch b/external/cppunit/enable-win32-debug.patch new file mode 100644 index 000000000..2c7f4f956 --- /dev/null +++ b/external/cppunit/enable-win32-debug.patch @@ -0,0 +1,34 @@ +--- misc/cppunit-1.14.0/src/cppunit/cppunit_dll.vcxproj ++++ misc/build/cppunit-1.14.0/src/cppunit/cppunit_dll.vcxproj +@@ -190,7 +190,6 @@ + true + Level3 + true +- OldStyle + ..\..\include;%(AdditionalIncludeDirectories) + WIN32;NDEBUG;_WINDOWS;_USRDLL;CPPUNIT_BUILD_DLL;%(PreprocessorDefinitions) + .\ReleaseDll\ +@@ -222,6 +221,7 @@ + + true + true ++ true + Console + .\ReleaseDll\cppunit_dll.dll + .\ReleaseDll\cppunit_dll.lib +@@ -237,7 +237,6 @@ + true + Level3 + true +- OldStyle + ..\..\include;%(AdditionalIncludeDirectories) + WIN32;NDEBUG;_WINDOWS;_USRDLL;CPPUNIT_BUILD_DLL;%(PreprocessorDefinitions) + .\ReleaseDll\ +@@ -266,6 +266,7 @@ + + true + true ++ true + Console + .\ReleaseDll\cppunit_dll.dll + .\ReleaseDll\cppunit_dll.lib diff --git a/external/cppunit/order.patch.0 b/external/cppunit/order.patch.0 new file mode 100644 index 000000000..523b3cd70 --- /dev/null +++ b/external/cppunit/order.patch.0 @@ -0,0 +1,25 @@ +--- src/cppunit/TestFactoryRegistry.cpp ++++ src/cppunit/TestFactoryRegistry.cpp +@@ -143,13 +143,21 @@ + void + TestFactoryRegistry::addTestToSuite( TestSuite *suite ) + { ++ std::multimap sorted; + for ( Factories::iterator it = m_factories.begin(); + it != m_factories.end(); + ++it ) + { + TestFactory *factory = *it; +- suite->addTest( factory->makeTest() ); ++ Test *test = factory->makeTest(); ++ sorted.insert({test->getName(), test}); + } ++ // In the unlikely case of multiple Tests with identical names, those will ++ // still be added in random order: ++ for (auto const &i: sorted) ++ { ++ suite->addTest( i.second ); ++ } + } + + diff --git a/external/cppunit/rtti.patch.0 b/external/cppunit/rtti.patch.0 new file mode 100644 index 000000000..38d2e6a90 --- /dev/null +++ b/external/cppunit/rtti.patch.0 @@ -0,0 +1,15 @@ +--- include/cppunit/config/CppUnitApi.h ++++ include/cppunit/config/CppUnitApi.h +@@ -20,6 +20,12 @@ + #define CPPUNIT_NEED_DLL_DECL 1 + #endif + ++#elif defined __GNUC__ //TODO: actually only works for modern enough GCC ++ ++#define CPPUNIT_API __attribute__ ((visibility("default"))) ++#undef CPPUNIT_NEED_DLL_DECL ++#define CPPUNIT_NEED_DLL_DECL 0 ++ + #endif + + diff --git a/external/cppunit/unix.patch b/external/cppunit/unix.patch new file mode 100644 index 000000000..e75e72c6f --- /dev/null +++ b/external/cppunit/unix.patch @@ -0,0 +1,10 @@ +--- misc/cppunit-1.13.1/src/cppunit/UnixDynamicLibraryManager.cpp ++++ misc/build/cppunit-1.13.1/src/cppunit/UnixDynamicLibraryManager.cpp +@@ -20,7 +20,6 @@ + void + DynamicLibraryManager::doReleaseLibrary() + { +- ::dlclose( m_libraryHandle); + } + + diff --git a/external/cppunit/windows-arm64.patch.1 b/external/cppunit/windows-arm64.patch.1 new file mode 100644 index 000000000..0e41fa005 --- /dev/null +++ b/external/cppunit/windows-arm64.patch.1 @@ -0,0 +1,786 @@ +diff -ur cppunit-1.15.1.orig/src/cppunit/cppunit_dll.vcxproj cppunit-1.15.1/src/cppunit/cppunit_dll.vcxproj +--- cppunit-1.15.1.orig/src/cppunit/cppunit_dll.vcxproj 2019-11-28 20:35:43.000000000 +0100 ++++ cppunit-1.15.1/src/cppunit/cppunit_dll.vcxproj 2020-08-03 03:04:20.181281900 +0200 +@@ -1,6 +1,10 @@ +  + + ++ ++ Debug ++ ARM64 ++ + + Debug + Win32 +@@ -9,6 +13,10 @@ + Debug + x64 + ++ ++ Release ++ ARM64 ++ + + Release + Win32 +@@ -34,6 +42,11 @@ + false + MultiByte + ++ ++ DynamicLibrary ++ false ++ MultiByte ++ + + DynamicLibrary + false +@@ -44,6 +57,11 @@ + false + MultiByte + ++ ++ DynamicLibrary ++ false ++ MultiByte ++ + + + +@@ -55,6 +73,10 @@ + + + ++ ++ ++ ++ + + + +@@ -63,6 +85,10 @@ + + + ++ ++ ++ ++ + + + .\DebugDll\ +@@ -76,6 +102,12 @@ + true + cppunitd_dll + ++ ++ .\DebugDll\ ++ .\DebugDll\ ++ true ++ cppunitd_dll ++ + + .\ReleaseDll\ + .\ReleaseDll\ +@@ -86,6 +116,11 @@ + .\ReleaseDll\ + false + ++ ++ .\ReleaseDll\ ++ .\ReleaseDll\ ++ false ++ + + + MultiThreadedDebugDLL +@@ -180,6 +213,52 @@ + odbc32.lib;odbccp32.lib;%(AdditionalDependencies) + + ++ ++ ++ MultiThreadedDebugDLL ++ Default ++ false ++ Disabled ++ true ++ Level3 ++ true ++ ..\..\include;%(AdditionalIncludeDirectories) ++ WIN32;_DEBUG;_WINDOWS;_USRDLL;CPPUNIT_BUILD_DLL;%(PreprocessorDefinitions) ++ .\DebugDll\ ++ .\DebugDll\cppunit_dll.pch ++ .\DebugDll\ ++ .\DebugDll\ ++ EnableFastChecks ++ ++ ++ copy "$(TargetPath)" ..\..\lib\$(TargetName).dll ++copy "$(TargetDir)$(TargetName).lib" ..\..\lib\$(TargetName).lib ++ Copying target to lib/ ++ ++ ++ true ++ _DEBUG;%(PreprocessorDefinitions) ++ .\DebugDll\cppunit_dll.tlb ++ true ++ ++ ++ 0x040c ++ _DEBUG;%(PreprocessorDefinitions) ++ ++ ++ true ++ .\DebugDll\cppunit_dll.bsc ++ ++ ++ true ++ true ++ true ++ Console ++ DebugDll\cppunitd_dll.dll ++ .\DebugDll\cppunitd_dll.lib ++ odbc32.lib;odbccp32.lib;%(AdditionalDependencies) ++ ++ + + + MultiThreadedDLL +@@ -267,6 +345,52 @@ + true + true + true ++ Console ++ .\ReleaseDll\cppunit_dll.dll ++ .\ReleaseDll\cppunit_dll.lib ++ odbc32.lib;odbccp32.lib;%(AdditionalDependencies) ++ ++ ++ ++ ++ MultiThreadedDLL ++ OnlyExplicitInline ++ true ++ true ++ MaxSpeed ++ true ++ Level3 ++ true ++ ..\..\include;%(AdditionalIncludeDirectories) ++ WIN32;NDEBUG;_WINDOWS;_USRDLL;CPPUNIT_BUILD_DLL;%(PreprocessorDefinitions) ++ .\ReleaseDll\ ++ .\ReleaseDll\cppunit_dll.pch ++ .\ReleaseDll\ ++ .\ReleaseDll\ ++ ++ ++ copy "$(TargetPath)" ..\..\lib\$(TargetName).dll ++copy "$(TargetDir)$(TargetName).lib" ..\..\lib\$(TargetName).lib ++ Copying target to lib/ ++ ++ ++ true ++ NDEBUG;%(PreprocessorDefinitions) ++ .\ReleaseDll\cppunit_dll.tlb ++ true ++ ++ ++ 0x040c ++ NDEBUG;%(PreprocessorDefinitions) ++ ++ ++ true ++ .\ReleaseDll\cppunit_dll.bsc ++ ++ ++ true ++ true ++ true + Console + .\ReleaseDll\cppunit_dll.dll + .\ReleaseDll\cppunit_dll.lib +diff -ur cppunit-1.15.1.orig/src/DllPlugInTester/DllPlugInTester.vcxproj cppunit-1.15.1/src/DllPlugInTester/DllPlugInTester.vcxproj +--- cppunit-1.15.1.orig/src/DllPlugInTester/DllPlugInTester.vcxproj 2019-11-28 20:35:43.000000000 +0100 ++++ cppunit-1.15.1/src/DllPlugInTester/DllPlugInTester.vcxproj 2020-08-03 03:05:06.310642100 +0200 +@@ -1,6 +1,10 @@ +  + + ++ ++ Debug Static ++ ARM64 ++ + + Debug Static + Win32 +@@ -9,6 +13,10 @@ + Debug Static + x64 + ++ ++ Debug Unicode ++ ARM64 ++ + + Debug Unicode + Win32 +@@ -17,6 +25,10 @@ + Debug Unicode + x64 + ++ ++ Debug ++ ARM64 ++ + + Debug + Win32 +@@ -25,6 +37,10 @@ + Debug + x64 + ++ ++ Release Static ++ ARM64 ++ + + Release Static + Win32 +@@ -33,6 +49,10 @@ + Release Static + x64 + ++ ++ Release Unicode ++ ARM64 ++ + + Release Unicode + Win32 +@@ -41,6 +61,10 @@ + Release Unicode + x64 + ++ ++ Release ++ ARM64 ++ + + Release + Win32 +@@ -66,6 +90,11 @@ + false + MultiByte + ++ ++ Application ++ false ++ MultiByte ++ + + Application + false +@@ -76,6 +105,11 @@ + false + MultiByte + ++ ++ Application ++ false ++ MultiByte ++ + + Application + false +@@ -86,6 +120,11 @@ + false + MultiByte + ++ ++ Application ++ false ++ MultiByte ++ + + Application + false +@@ -96,6 +135,11 @@ + false + MultiByte + ++ ++ Application ++ false ++ MultiByte ++ + + Application + false +@@ -106,6 +150,11 @@ + false + MultiByte + ++ ++ Application ++ false ++ MultiByte ++ + + Application + false +@@ -116,6 +165,11 @@ + false + MultiByte + ++ ++ Application ++ false ++ MultiByte ++ + + + +@@ -127,6 +181,10 @@ + + + ++ ++ ++ ++ + + + +@@ -135,6 +193,10 @@ + + + ++ ++ ++ ++ + + + +@@ -143,6 +205,10 @@ + + + ++ ++ ++ ++ + + + +@@ -151,6 +217,10 @@ + + + ++ ++ ++ ++ + + + +@@ -159,6 +229,10 @@ + + + ++ ++ ++ ++ + + + +@@ -167,6 +241,10 @@ + + + ++ ++ ++ ++ + + + .\ReleaseUnicode\ +@@ -180,6 +258,12 @@ + false + $(ProjectName)u + ++ ++ .\Release\ ++ .\Release\ ++ false ++ $(ProjectName)u ++ + + .\Debug\ + .\Debug\ +@@ -192,6 +274,12 @@ + false + $(ProjectName)d + ++ ++ .\DebugDll\ ++ .\DebugDll\ ++ false ++ $(ProjectName)d ++ + + .\Release\ + .\Release\ +@@ -202,6 +288,11 @@ + .\Release\ + false + ++ ++ .\Release\ ++ .\Release\ ++ false ++ + + .\DebugDll\ + .\DebugDll\ +@@ -214,6 +303,12 @@ + false + DllPlugInTesterd_dll + ++ ++ .\DebugDll\ ++ .\DebugDll\ ++ false ++ DllPlugInTesterd_dll ++ + + .\ReleaseDll\ + .\ReleaseDll\ +@@ -226,6 +319,12 @@ + false + $(ProjectName)_dll + ++ ++ .\ReleaseDll\ ++ .\ReleaseDll\ ++ false ++ $(ProjectName)_dll ++ + + .\DebugUnicode\ + .\DebugUnicode\ +@@ -238,6 +335,12 @@ + false + $(ProjectName)ud + ++ ++ .\DebugDll\ ++ .\DebugDll\ ++ false ++ $(ProjectName)ud ++ + + + MultiThreadedDLL +@@ -324,6 +425,49 @@ + odbc32.lib;odbccp32.lib;cppunit.lib;%(AdditionalDependencies) + + ++ ++ ++ MultiThreadedDLL ++ OnlyExplicitInline ++ true ++ true ++ MinSpace ++ true ++ Level3 ++ true ++ OldStyle ++ ..\..\include;%(AdditionalIncludeDirectories) ++ WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions) ++ .\ReleaseUnicode\ ++ .\ReleaseUnicode\DllPlugInTester.pch ++ ++ ++ .\ReleaseUnicode\ ++ .\ReleaseUnicode\ ++ ++ ++ copy "$(TargetPath)" ..\..\lib\$(TargetName).exe ++ Copying target to lib/ ++ ++ ++ .\ReleaseUnicode\DllPlugInTester.tlb ++ ++ ++ 0x040c ++ NDEBUG;%(PreprocessorDefinitions) ++ ++ ++ true ++ .\ReleaseUnicode\DllPlugInTester.bsc ++ ++ ++ true ++ Console ++ ReleaseUnicode\DllPlugInTesteru.exe ++ ../../lib;%(AdditionalLibraryDirectories) ++ odbc32.lib;odbccp32.lib;cppunit.lib;%(AdditionalDependencies) ++ ++ + + + MultiThreadedDebugDLL +@@ -411,6 +555,49 @@ + odbc32.lib;odbccp32.lib;cppunitd.lib;%(AdditionalDependencies) + + ++ ++ ++ MultiThreadedDebugDLL ++ Default ++ false ++ Disabled ++ true ++ Level3 ++ true ++ ..\..\include;%(AdditionalIncludeDirectories) ++ WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions) ++ .\Debug\ ++ .\Debug\DllPlugInTester.pch ++ ++ ++ .\Debug\ ++ .\Debug\ ++ EnableFastChecks ++ ++ ++ copy $(TargetPath) ..\..\lib\$(TargetName).exe ++ Copying target to lib/ ++ ++ ++ .\Debug\DllPlugInTester.tlb ++ ++ ++ 0x040c ++ _DEBUG;%(PreprocessorDefinitions) ++ ++ ++ true ++ .\Debug\DllPlugInTester.bsc ++ ++ ++ true ++ true ++ Console ++ Debug\DllPlugInTesterd.exe ++ ../../lib;%(AdditionalLibraryDirectories) ++ odbc32.lib;odbccp32.lib;cppunitd.lib;%(AdditionalDependencies) ++ ++ + + + MultiThreadedDLL +@@ -497,6 +684,49 @@ + odbc32.lib;odbccp32.lib;cppunit.lib;%(AdditionalDependencies) + + ++ ++ ++ MultiThreadedDLL ++ OnlyExplicitInline ++ true ++ true ++ MinSpace ++ true ++ Level3 ++ true ++ OldStyle ++ ..\..\include;%(AdditionalIncludeDirectories) ++ WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions) ++ .\Release\ ++ .\Release\DllPlugInTester.pch ++ ++ ++ .\Release\ ++ .\Release\ ++ ++ ++ copy $(TargetPath) ..\..\lib\$(TargetName).exe ++ Copying target to lib/ ++ ++ ++ .\Release\DllPlugInTester.tlb ++ ++ ++ 0x040c ++ NDEBUG;%(PreprocessorDefinitions) ++ ++ ++ true ++ .\Release\DllPlugInTester.bsc ++ ++ ++ true ++ Console ++ .\Release\DllPlugInTester.exe ++ ../../lib;%(AdditionalLibraryDirectories) ++ odbc32.lib;odbccp32.lib;cppunit.lib;%(AdditionalDependencies) ++ ++ + + + MultiThreadedDebugDLL +@@ -584,6 +814,49 @@ + odbc32.lib;odbccp32.lib;cppunitd_dll.lib;%(AdditionalDependencies) + + ++ ++ ++ MultiThreadedDebugDLL ++ Default ++ false ++ Disabled ++ true ++ Level3 ++ true ++ ..\..\include;%(AdditionalIncludeDirectories) ++ WIN32;_DEBUG;_CONSOLE;CPPUNIT_DLL;%(PreprocessorDefinitions) ++ .\DebugDll\ ++ .\DebugDll\DllPlugInTester.pch ++ ++ ++ .\DebugDll\ ++ .\DebugDll\ ++ EnableFastChecks ++ ++ ++ copy "$(TargetPath)" ..\..\lib\$(TargetName).exe ++ Copying target to lib/ ++ ++ ++ .\DebugDll\DllPlugInTester.tlb ++ ++ ++ 0x040c ++ _DEBUG;%(PreprocessorDefinitions) ++ ++ ++ true ++ .\DebugDll\DllPlugInTester.bsc ++ ++ ++ true ++ true ++ Console ++ DebugDll\DllPlugInTesterd_dll.exe ++ ../../lib;%(AdditionalLibraryDirectories) ++ odbc32.lib;odbccp32.lib;cppunitd_dll.lib;%(AdditionalDependencies) ++ ++ + + + MultiThreadedDLL +@@ -670,6 +943,49 @@ + odbc32.lib;odbccp32.lib;cppunit_dll.lib;%(AdditionalDependencies) + + ++ ++ ++ MultiThreadedDLL ++ OnlyExplicitInline ++ true ++ true ++ MinSpace ++ true ++ Level3 ++ true ++ OldStyle ++ ..\..\include;%(AdditionalIncludeDirectories) ++ WIN32;NDEBUG;_CONSOLE;CPPUNIT_DLL;%(PreprocessorDefinitions) ++ .\ReleaseDll\ ++ .\ReleaseDll\DllPlugInTester.pch ++ ++ ++ .\ReleaseDll\ ++ .\ReleaseDll\ ++ ++ ++ copy "$(TargetPath)" ..\..\lib\$(TargetName).exe ++ Copying target to lib/ ++ ++ ++ .\ReleaseDll\DllPlugInTester.tlb ++ ++ ++ 0x040c ++ NDEBUG;%(PreprocessorDefinitions) ++ ++ ++ true ++ .\ReleaseDll\DllPlugInTester.bsc ++ ++ ++ true ++ Console ++ ReleaseDll\DllPlugInTester_dll.exe ++ ../../lib;%(AdditionalLibraryDirectories) ++ odbc32.lib;odbccp32.lib;cppunit_dll.lib;%(AdditionalDependencies) ++ ++ + + + MultiThreadedDebugDLL +@@ -718,6 +1034,49 @@ + + MultiThreadedDebugDLL + Default ++ false ++ Disabled ++ true ++ Level3 ++ true ++ ..\..\include;%(AdditionalIncludeDirectories) ++ WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions) ++ .\DebugUnicode\ ++ .\DebugUnicode\DllPlugInTester.pch ++ ++ ++ .\DebugUnicode\ ++ .\DebugUnicode\ ++ EnableFastChecks ++ ++ ++ copy "$(TargetPath)" ..\..\lib\$(TargetName).exe ++ Copying target to lib/ ++ ++ ++ .\DebugUnicode\DllPlugInTester.tlb ++ ++ ++ 0x040c ++ _DEBUG;%(PreprocessorDefinitions) ++ ++ ++ true ++ .\DebugUnicode\DllPlugInTester.bsc ++ ++ ++ true ++ true ++ Console ++ DebugUnicode\DllPlugInTesterud.exe ++ ../../lib;%(AdditionalLibraryDirectories) ++ odbc32.lib;odbccp32.lib;cppunitd.lib;%(AdditionalDependencies) ++ ++ ++ ++ ++ MultiThreadedDebugDLL ++ Default + false + Disabled + true diff --git a/external/cppunit/windows.patch b/external/cppunit/windows.patch new file mode 100644 index 000000000..e6ca26cbb --- /dev/null +++ b/external/cppunit/windows.patch @@ -0,0 +1,50 @@ +--- misc/cppunit-1.15.0/include/cppunit/plugin/TestPlugIn.h 2010-01-11 14:42:25.084658287 +0100 ++++ misc/build/cppunit-1.15.0/include/cppunit/plugin/TestPlugIn.h 2010-01-11 14:42:18.660706180 +0100 +@@ -133,9 +133,8 @@ + /*! \def CPPUNIT_PLUGIN_IMPLEMENT_MAIN() + * \brief Implements the 'main' function for the plug-in. + * +- * This macros implements the main() function for dynamic library. +- * For example, WIN32 requires a DllMain function, while some Unix +- * requires a main() function. This macros takes care of the implementation. ++ * This macro implements the main() function for dynamic library ++ * on Unix for some weird reason. + */ + + // Win32 +@@ -149,23 +149,7 @@ + + // Win32 + #if defined(CPPUNIT_HAVE_WIN32_DLL_LOADER) +-#if !defined(APIENTRY) +-#define WIN32_LEAN_AND_MEAN +-#define NOGDI +-#define NOUSER +-#define NOKERNEL +-#define NOSOUND +-#ifndef NOMINMAX +-#define NOMINMAX +-#endif +-#define BLENDFUNCTION void // for mingw & gcc +-#include +-#endif + #define CPPUNIT_PLUGIN_IMPLEMENT_MAIN() \ +- BOOL APIENTRY DllMain( HANDLE, DWORD, LPVOID ) \ +- { \ +- return TRUE; \ +- } \ + typedef char __CppUnitPlugInImplementMainDummyTypeDef + + // Unix +--- misc/cppunit-1.15.0/include/cppunit/TestAssert.h ++++ misc/build/cppunit-1.15.0/include/cppunit/TestAssert.h +@@ -76,7 +76,7 @@ + const int precision = 15; + #endif // #ifdef DBL_DIG + char buffer[128]; +-#ifdef __STDC_SECURE_LIB__ // Use secure version with visual studio 2005 to avoid warning. ++#if defined(_MSC_VER) && defined(__STDC_SECURE_LIB__) // Use secure version with visual studio 2005 to avoid warning. + sprintf_s(buffer, sizeof(buffer), "%.*g", precision, x); + #else + sprintf(buffer, "%.*g", precision, x); + -- cgit v1.2.3