CMakeLists.txt | 5 +++++ src/CMakeLists.txt | 1 + src/DllPlugInTester/CMakeLists.txt | 23 +++++++++++++++++++++++ 3 files changed, 29 insertions(+)
New commits: commit 78b0923b6ae906753a843956a7b187df60dee595 Author: Bernhard Sessler <bernhard.sess...@corscience.de> Date: Thu Dec 12 13:27:40 2013 +0100 DllPluginTester: Add CMake build system This patch will enable building the plugin tester executable Change-Id: If14360b92dbc2d9698162b8fd0263421a061f90c Signed-off-by: Bernhard Sessler <bernhard.sess...@corscience.de> Reviewed-on: https://gerrit.libreoffice.org/7314 Reviewed-by: Markus Mohrhard <markus.mohrh...@googlemail.com> Tested-by: Markus Mohrhard <markus.mohrh...@googlemail.com> diff --git a/CMakeLists.txt b/CMakeLists.txt index 3e6c407..b545035 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -19,6 +19,11 @@ option(BUILD_SHARED_LIBS "Build cppunit as shared or static library" option(CPPUNIT_BUILD_APIDOC "Adds a build target for generating the API documentation" OFF) option(CPPUNIT_BUILD_QT_TESTRUNNER "Build the Qt test runner library" OFF) option(CPPUNIT_BUILD_EXAMPLES "Build the examples shipped with cppunit" OFF) +option(CPPUNIT_BUILD_TESTING "Enables testing with CTest and adds a 'test' target" OFF) + +if(CPPUNIT_BUILD_TESTING) + enable_testing() +endif() if(BUILD_SHARED_LIBS AND WIN32) add_definitions(-DCPPUNIT_BUILD_DLL) diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index cc89dcb..fea7014 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -1,4 +1,5 @@ add_subdirectory(cppunit) +add_subdirectory(DllPlugInTester) if(CPPUNIT_BUILD_QT_TESTRUNNER) add_subdirectory(qttestrunner) diff --git a/src/DllPlugInTester/CMakeLists.txt b/src/DllPlugInTester/CMakeLists.txt new file mode 100644 index 0000000..d15e0a0 --- /dev/null +++ b/src/DllPlugInTester/CMakeLists.txt @@ -0,0 +1,23 @@ +# Create plugin tester executable +set(cppunit-plugintester_SOURCES + CommandLineParser.cpp + DllPlugInTester.cpp) + +add_executable(cppunit-plugintester ${cppunit-plugintester_SOURCES}) +target_link_libraries(cppunit-plugintester cppunit) + +install(TARGETS cppunit-plugintester + RUNTIME DESTINATION bin COMPONENT misc) + +if(CPPUNIT_BUILD_TESTING) + # Create plugin tester test executable + set(cppunit-plugintester-test_SOURCES + CommandLineParser.cpp + CommandLineParserTest.cpp + DllPlugInTesterTest.cpp) + + add_executable(cppunit-plugintester-test ${cppunit-plugintester-test_SOURCES}) + target_link_libraries(cppunit-plugintester-test cppunit) + + add_test(NAME cppunit-plugintester-test COMMAND cppunit-plugintester-test) +endif() _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits