summaryrefslogtreecommitdiffstats
path: root/cppunit
diff options
context:
space:
mode:
authorKhaled Hosny <khaledhosny@eglug.org>2013-10-17 01:32:29 +0200
committerBjörn Michaelsen <bjoern.michaelsen@canonical.com>2013-10-17 17:17:22 +0000
commit7223027a3a7e6599e387559d85f1eaebf3bbbd6c (patch)
tree10017f4f62c300eef573e6ac73dba9271c824855 /cppunit
parentfdo#70393: move clucene to a subdir of external (diff)
downloadcore-7223027a3a7e6599e387559d85f1eaebf3bbbd6c.tar.gz
core-7223027a3a7e6599e387559d85f1eaebf3bbbd6c.zip
fdo#70393: move cppunit to a subdir of external
Change-Id: I96ab796757af0c6c6741059b35fcaeefc2bf4507 Reviewed-on: https://gerrit.libreoffice.org/6286 Tested-by: LibreOffice gerrit bot <gerrit@libreoffice.org> Reviewed-by: Björn Michaelsen <bjoern.michaelsen@canonical.com> Tested-by: Björn Michaelsen <bjoern.michaelsen@canonical.com>
Diffstat (limited to 'cppunit')
-rw-r--r--cppunit/ExternalPackage_cppunit.mk50
-rw-r--r--cppunit/ExternalProject_cppunit.mk63
-rw-r--r--cppunit/Makefile7
-rw-r--r--cppunit/Module_cppunit.mk24
-rw-r--r--cppunit/README3
-rw-r--r--cppunit/UnpackedTarball_cppunit.mk34
-rw-r--r--cppunit/android.patch33
-rw-r--r--cppunit/disable-dynloading.patch25
-rw-r--r--cppunit/ios.patch18
-rw-r--r--cppunit/unix.patch15
-rw-r--r--cppunit/windows.patch48
-rw-r--r--cppunit/wundef.patch12
12 files changed, 0 insertions, 332 deletions
diff --git a/cppunit/ExternalPackage_cppunit.mk b/cppunit/ExternalPackage_cppunit.mk
deleted file mode 100644
index d900e22a1fd2..000000000000
--- a/cppunit/ExternalPackage_cppunit.mk
+++ /dev/null
@@ -1,50 +0,0 @@
-# -*- 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_ExternalPackage_ExternalPackage,cppunit,cppunit))
-$(eval $(call gb_ExternalPackage_use_external_project,cppunit,cppunit))
-
-ifeq ($(OS),WNT)
-ifeq ($(COM),MSC)
-$(eval $(call gb_ExternalPackage_add_file,cppunit,bin/$(if $(MSVC_USE_DEBUG_RUNTIME),cppunitd_dll.dll,cppunit_dll.dll),src/cppunit/$(if $(MSVC_USE_DEBUG_RUNTIME),DebugDll/cppunitd_dll.dll,ReleaseDll/cppunit_dll.dll)))
-$(eval $(call gb_ExternalPackage_add_file,cppunit,lib/icppunit_dll.lib,src/cppunit/$(if $(MSVC_USE_DEBUG_RUNTIME),DebugDll/cppunitd_dll.lib,ReleaseDll/cppunit_dll.lib)))
-$(eval $(call gb_ExternalPackage_add_file,cppunit,bin/DllPlugInTester_dll.exe,src/DllPlugInTester/$(if $(MSVC_USE_DEBUG_RUNTIME),DebugDll/DllPlugInTesterd_dll.exe,ReleaseDll/DllPlugInTester_dll.exe)))
-else
-$(eval $(call gb_ExternalPackage_add_file,cppunit,bin/libcppunit-1-13-0.dll,src/cppunit/.libs/libcppunit-1-13-0.dll))
-$(eval $(call gb_ExternalPackage_add_file,cppunit,lib/libcppunit.dll.a,src/cppunit/.libs/libcppunit.dll.a))
-$(eval $(call gb_ExternalPackage_add_file,cppunit,bin/DllPlugInTester.exe,src/DllPlugInTester/.libs/DllPlugInTester.exe))
-endif
-else
-ifneq ($(DISABLE_DYNLOADING),TRUE)
-$(eval $(call gb_ExternalPackage_add_file,cppunit,bin/DllPlugInTester,src/DllPlugInTester/.libs/DllPlugInTester))
-else
-ifneq ($(filter DESKTOP,$(BUILD_TYPE)),)
-$(eval $(call gb_ExternalPackage_add_file,cppunit,bin/DllPlugInTester,src/DllPlugInTester/DllPlugInTester))
-endif
-endif
-ifeq ($(OS),MACOSX)
-$(eval $(call gb_ExternalPackage_add_file,cppunit,lib/libcppunit-1.13.0.dylib,src/cppunit/.libs/libcppunit-1.13.0.dylib))
-$(eval $(call gb_ExternalPackage_add_file,cppunit,lib/libcppunit.dylib,src/cppunit/.libs/libcppunit.dylib))
-else ifeq ($(OS),AIX)
-$(eval $(call gb_ExternalPackage_add_file,cppunit,lib/libcppunit-1.13.a,src/cppunit/.libs/libcppunit-1.13.a))
-else ifeq ($(OS),OPENBSD)
-$(eval $(call gb_ExternalPackage_add_file,cppunit,lib/libcppunit-1.13.so.0.0,src/cppunit/.libs/libcppunit-1.13.so.0.0))
-$(eval $(call gb_ExternalPackage_add_file,cppunit,lib/libcppunit.so,src/cppunit/.libs/libcppunit-1.13.so.0.0))
-else ifeq ($(DISABLE_DYNLOADING),TRUE)
-$(eval $(call gb_ExternalPackage_add_file,cppunit,lib/libcppunit.a,src/cppunit/.libs/libcppunit.a))
-else ifeq ($(OS),ANDROID)
-$(eval $(call gb_ExternalPackage_add_file,cppunit,lib/libcppunit-1.13.so,src/cppunit/.libs/libcppunit-1.13.so))
-$(eval $(call gb_ExternalPackage_add_file,cppunit,lib/libcppunit.so,src/cppunit/.libs/libcppunit-1.13.so))
-else
-$(eval $(call gb_ExternalPackage_add_file,cppunit,lib/libcppunit-1.13.so.0,src/cppunit/.libs/libcppunit-1.13.so.0.0.1))
-$(eval $(call gb_ExternalPackage_add_file,cppunit,lib/libcppunit.so,src/cppunit/.libs/libcppunit-1.13.so.0.0.1))
-endif
-endif
-
-# vim: set noet sw=4 ts=4:
diff --git a/cppunit/ExternalProject_cppunit.mk b/cppunit/ExternalProject_cppunit.mk
deleted file mode 100644
index 649bae1dcc01..000000000000
--- a/cppunit/ExternalProject_cppunit.mk
+++ /dev/null
@@ -1,63 +0,0 @@
-# -*- 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)$(COM),WNTMSC)
-$(call gb_ExternalProject_get_state_target,cppunit,build) :
- $(call gb_ExternalProject_run,build,\
- msbuild.exe cppunit_dll.vcxproj /p:Configuration=$(if $(MSVC_USE_DEBUG_RUNTIME),Debug,Release) \
- $(if $(filter 110,$(VCVER)),/p:PlatformToolset=v110 /p:VisualStudioVersion=11.0) \
- && cd ../DllPlugInTester \
- && msbuild.exe DllPlugInTester.vcxproj /p:Configuration=$(if $(MSVC_USE_DEBUG_RUNTIME),Debug,Release) \
- $(if $(filter 110,$(VCVER)),/p:PlatformToolset=v110 /p:VisualStudioVersion=11.0) \
- ,src/cppunit)
-else
-
-cppunit_CXXFLAGS=$(CXXFLAGS)
-
-ifneq (,$(filter ANDROID DRAGONFLY FREEBSD IOS LINUX NETBSD OPENBSD,$(OS)))
-ifneq (,$(gb_ENABLE_DBGUTIL))
-cppunit_CXXFLAGS+=-D_GLIBCXX_DEBUG
-endif
-endif
-
-ifeq ($(OS)-$(COM),WNT-GCC)
-cppunit_CXXFLAGS+=-mthreads
-endif
-
-ifneq (,$(debug))
-cppunit_CXXFLAGS+=-g
-endif
-
-$(call gb_ExternalProject_get_state_target,cppunit,build) :
- $(call gb_ExternalProject_run,build,\
- ./configure \
- --disable-dependency-tracking \
- $(if $(filter TRUE,$(DISABLE_DYNLOADING)),--disable-shared,--disable-static) \
- --disable-doxygen \
- --disable-html-docs \
- --disable-latex-docs \
- $(if $(filter YES,$(CROSS_COMPILING)),--build=$(BUILD_PLATFORM) --host=$(HOST_PLATFORM)) \
- $(if $(filter MACOSX,$(OS)),--prefix=/@.__________________________________________________OOO) \
- $(if $(filter WNT,$(OS)),LDFLAGS="-Wl$(COMMA)--enable-runtime-pseudo-reloc-v2") \
- $(if $(filter SOLARIS,$(OS)),LIBS="-lm") \
- $(if $(filter ANDROID,$(OS)),LIBS="-lgnustl_shared -lm") \
- CXXFLAGS="$(cppunit_CXXFLAGS)" \
- && cd src \
- && $(MAKE) \
- )
-endif
-
-# vim: set noet sw=4 ts=4:
diff --git a/cppunit/Makefile b/cppunit/Makefile
deleted file mode 100644
index ccb1c85a04da..000000000000
--- a/cppunit/Makefile
+++ /dev/null
@@ -1,7 +0,0 @@
-# -*- 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/cppunit/Module_cppunit.mk b/cppunit/Module_cppunit.mk
deleted file mode 100644
index 53ed611fe0c1..000000000000
--- a/cppunit/Module_cppunit.mk
+++ /dev/null
@@ -1,24 +0,0 @@
-# -*- 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))
-
-ifneq (,$(filter DESKTOP,$(BUILD_TYPE)))
-
-ifeq ($(SYSTEM_CPPUNIT),NO)
-$(eval $(call gb_Module_add_targets,cppunit,\
- UnpackedTarball_cppunit \
- ExternalPackage_cppunit \
- ExternalProject_cppunit \
-))
-endif
-
-endif
-
-# vim: set noet sw=4 ts=4:
diff --git a/cppunit/README b/cppunit/README
deleted file mode 100644
index f71c260e6839..000000000000
--- a/cppunit/README
+++ /dev/null
@@ -1,3 +0,0 @@
-C++ port of the JUnit framework for unit testing.
-
-From [http://sourceforge.net/projects/cppunit/]
diff --git a/cppunit/UnpackedTarball_cppunit.mk b/cppunit/UnpackedTarball_cppunit.mk
deleted file mode 100644
index 0a5f64939319..000000000000
--- a/cppunit/UnpackedTarball_cppunit.mk
+++ /dev/null
@@ -1,34 +0,0 @@
-# -*- 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_add_patches,cppunit,\
- cppunit/windows.patch \
- cppunit/unix.patch \
- cppunit/wundef.patch \
-))
-ifeq ($(OS),ANDROID)
-$(eval $(call gb_UnpackedTarball_add_patches,cppunit,\
- cppunit/android.patch \
-))
-else ifeq ($(OS),IOS)
-$(eval $(call gb_UnpackedTarball_add_patches,cppunit,\
- cppunit/ios.patch \
-))
-endif
-ifeq ($(DISABLE_DYNLOADING),TRUE)
-$(eval $(call gb_UnpackedTarball_add_patches,cppunit,\
- cppunit/disable-dynloading.patch \
-))
-endif
-
-# vim: set noet sw=4 ts=4:
diff --git a/cppunit/android.patch b/cppunit/android.patch
deleted file mode 100644
index 59ae4517abf1..000000000000
--- a/cppunit/android.patch
+++ /dev/null
@@ -1,33 +0,0 @@
---- misc/cppunit-1.13.1/config/ltmain.sh
-+++ misc/build/cppunit-1.13.1/config/ltmain.sh
-@@ -3228,6 +3228,12 @@
- fi
- else
-
-+ # Force no versioning suffix for Android thanks to silly
-+ # apkbuilder which doesn't add extra native libs unless their
-+ # name ends with .so
-+
-+ version_type=none
-+
- # Parse the version information argument.
- save_ifs="$IFS"; IFS=':'
- set dummy $vinfo 0 0 0
---- misc/cppunit-1.13.1/src/cppunit/UnixDynamicLibraryManager.cpp
-+++ misc/build/cppunit-1.13.1/src/cppunit/UnixDynamicLibraryManager.cpp
-@@ -13,7 +13,15 @@
- DynamicLibraryManager::LibraryHandle
- DynamicLibraryManager::doLoadLibrary( const std::string &libraryName )
- {
-+#ifdef __ANDROID__
-+ // Use our enhanced dlopen() wrapper, see sal/osl/android/jni/lo-wrapper.c
-+ void *(*lo_dlopen)(const char *) = (void *(*)(const char *)) dlsym( RTLD_DEFAULT, "lo_dlopen" );
-+ if (lo_dlopen == NULL)
-+ return NULL;
-+ return (*lo_dlopen)( libraryName.c_str() );
-+#else
- return ::dlopen( libraryName.c_str(), RTLD_NOW | RTLD_GLOBAL );
-+#endif
- }
-
-
diff --git a/cppunit/disable-dynloading.patch b/cppunit/disable-dynloading.patch
deleted file mode 100644
index a9aa37f6f45d..000000000000
--- a/cppunit/disable-dynloading.patch
+++ /dev/null
@@ -1,25 +0,0 @@
---- 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__)
-+#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/cppunit/ios.patch b/cppunit/ios.patch
deleted file mode 100644
index d7e355cddf44..000000000000
--- a/cppunit/ios.patch
+++ /dev/null
@@ -1,18 +0,0 @@
---- misc/cppunit-1.13.1/configure
-+++ misc/cppunit-1.13.1/configure
-@@ -23273,7 +23273,7 @@
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: creating $ac_prefix_conf_OUT - prefix $ac_prefix_conf_UPP for $ac_prefix_conf_INP defines" >&5
- $as_echo "creating $ac_prefix_conf_OUT - prefix $ac_prefix_conf_UPP for $ac_prefix_conf_INP defines" >&6; }
- if test -f $ac_prefix_conf_INP ; then
-- $as_dirname -- /* automatically generated */ ||
-+ $as_dirname -- '/* automatically generated */' ||
- $as_expr X/* automatically generated */ : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X/* automatically generated */ : 'X\(//\)[^/]' \| \
- X/* automatically generated */ : 'X\(//\)$' \| \
-@@ -23318,5 +23318,5 @@
- else
- as_fn_error $? "input file $ac_prefix_conf_IN does not exist, skip generating $ac_prefix_conf_OUT" "$LINENO" 5
- fi
-- rm -f conftest.*
-+ rm -f -r conftest.*
- fi
diff --git a/cppunit/unix.patch b/cppunit/unix.patch
deleted file mode 100644
index 0a153ad05deb..000000000000
--- a/cppunit/unix.patch
+++ /dev/null
@@ -1,15 +0,0 @@
---- misc/cppunit-1.13.1/src/cppunit/UnixDynamicLibraryManager.cpp
-+++ misc/build/cppunit-1.13.1/src/cppunit/UnixDynamicLibraryManager.cpp
-@@ -34,7 +34,11 @@
- std::string
- DynamicLibraryManager::getLastErrorDetail() const
- {
-- return "";
-+ const char *last_dlerror = ::dlerror();
-+ if (last_dlerror != NULL)
-+ return last_dlerror;
-+ else
-+ return "";
- }
-
-
diff --git a/cppunit/windows.patch b/cppunit/windows.patch
deleted file mode 100644
index c8ea6d7565dc..000000000000
--- a/cppunit/windows.patch
+++ /dev/null
@@ -1,48 +0,0 @@
---- misc/cppunit-1.13.1/include/cppunit/plugin/TestPlugIn.h 2010-01-11 14:42:25.084658287 +0100
-+++ misc/build/cppunit-1.13.1/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,21 +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
--#define NOMINMAX
--#define BLENDFUNCTION void // for mingw & gcc
--#include <windows.h>
--#endif
- #define CPPUNIT_PLUGIN_IMPLEMENT_MAIN() \
-- BOOL APIENTRY DllMain( HANDLE, DWORD, LPVOID ) \
-- { \
-- return TRUE; \
-- } \
- typedef char __CppUnitPlugInImplementMainDummyTypeDef
-
- // Unix
---- misc/cppunit-1.13.1/include/cppunit/TestAssert.h
-+++ misc/build/cppunit-1.13.1/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);
-
diff --git a/cppunit/wundef.patch b/cppunit/wundef.patch
deleted file mode 100644
index 5f701cd702d1..000000000000
--- a/cppunit/wundef.patch
+++ /dev/null
@@ -1,12 +0,0 @@
---- misc/cppunit-1.13.1/include/cppunit/Portability.h 2012-09-24 19:10:36.000000000 +0200
-+++ misc/build/cppunit-1.13.1/include/cppunit/Portability.h 2013-03-18 14:23:48.880718714 +0100
-@@ -68,6 +68,9 @@
- * std::allocator. On some compilers, you may need to change this to
- * std::allocator<T>.
- */
-+#ifndef CPPUNIT_STD_NEED_ALLOCATOR /* avoid -Wundef warning */
-+#define CPPUNIT_STD_NEED_ALLOCATOR 0
-+#endif
- #if CPPUNIT_STD_NEED_ALLOCATOR
- # if !defined(CPPUNIT_STD_ALLOCATOR)
- # define CPPUNIT_STD_ALLOCATOR std::allocator