summaryrefslogtreecommitdiff
path: root/dev-libs/tinyxml2/files/tinyxml2-4.0.1-optional-tests.patch
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2017-10-09 18:53:29 +0100
committerV3n3RiX <venerix@redcorelinux.org>2017-10-09 18:53:29 +0100
commit4f2d7949f03e1c198bc888f2d05f421d35c57e21 (patch)
treeba5f07bf3f9d22d82e54a462313f5d244036c768 /dev-libs/tinyxml2/files/tinyxml2-4.0.1-optional-tests.patch
reinit the tree, so we can have metadata
Diffstat (limited to 'dev-libs/tinyxml2/files/tinyxml2-4.0.1-optional-tests.patch')
-rw-r--r--dev-libs/tinyxml2/files/tinyxml2-4.0.1-optional-tests.patch30
1 files changed, 30 insertions, 0 deletions
diff --git a/dev-libs/tinyxml2/files/tinyxml2-4.0.1-optional-tests.patch b/dev-libs/tinyxml2/files/tinyxml2-4.0.1-optional-tests.patch
new file mode 100644
index 000000000000..95e849fdc8ff
--- /dev/null
+++ b/dev-libs/tinyxml2/files/tinyxml2-4.0.1-optional-tests.patch
@@ -0,0 +1,30 @@
+--- tinyxml2-4.0.1/CMakeLists.txt
++++ tinyxml2-4.0.1/CMakeLists.txt
+@@ -100,15 +100,18 @@
+ ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR})
+ endif()
+
+-add_executable(xmltest xmltest.cpp)
+-if(BUILD_SHARED_LIBS)
+- add_dependencies(xmltest tinyxml2)
+- add_dependencies(xmltest ${TARGET_DATA_COPY})
+- target_link_libraries(xmltest tinyxml2)
+-else(BUILD_STATIC_LIBS)
+- add_dependencies(xmltest tinyxml2_static)
+- add_dependencies(xmltest ${TARGET_DATA_COPY})
+- target_link_libraries(xmltest tinyxml2_static)
++set(BUILD_TEST OFF CACHE BOOL "Set to ON to build tests")
++if(BUILD_TEST)
++ add_executable(xmltest xmltest.cpp)
++ if(BUILD_SHARED_LIBS)
++ add_dependencies(xmltest tinyxml2)
++ add_dependencies(xmltest ${TARGET_DATA_COPY})
++ target_link_libraries(xmltest tinyxml2)
++ else(BUILD_STATIC_LIBS)
++ add_dependencies(xmltest tinyxml2_static)
++ add_dependencies(xmltest ${TARGET_DATA_COPY})
++ target_link_libraries(xmltest tinyxml2_static)
++ endif()
+ endif()
+ install(TARGETS DESTINATION ${CMAKE_INSTALL_BINDIR})
+