Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
home:goupilmtos:games
openclonk
fix-CMakeLists.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File fix-CMakeLists.patch of Package openclonk
diff -up openclonk-release-8.1-src/CMakeLists.txt.orig openclonk-release-8.1-src/CMakeLists.txt --- openclonk-release-8.1-src/CMakeLists.txt.orig 2018-06-01 21:32:58.860958303 +0200 +++ openclonk-release-8.1-src/CMakeLists.txt 2018-06-01 21:42:04.568980927 +0200 @@ -48,6 +48,8 @@ CMAKE_DEPENDENT_OPTION(USE_WIN32_WINDOWS CMAKE_DEPENDENT_OPTION(USE_SDL_MAINLOOP "Use SDL to create windows etc. Qt editor." ON "NOT USE_COCOA AND NOT USE_WIN32_WINDOWS AND NOT HEADLESS_ONLY" OFF) option(WITH_AUTOMATIC_UPDATE "Automatic updates are downloaded from the project website." OFF) option(HEADLESS_ONLY "Only build headless parts. Somewhat reduces dependencies. (still needs libpng because that one's small and hard to remove.) Only tested with make/gcc/linux." OFF) +set(OC_SYSTEM_DATA_DIR "${CMAKE_INSTALL_PREFIX}/share/games/openclonk" CACHE PATH "Path to openclonk datafiles on system.") +set(OC_SYSTEM_GAMES_DIR "${CMAKE_INSTALL_PREFIX}/games" CACHE PATH "Path to where to install games on the system.") set_property(GLOBAL PROPERTY USE_FOLDERS ${PROJECT_FOLDERS}) @@ -167,7 +169,7 @@ if(WIN32 AND MINGW) endif() if(UNIX) - add_definitions("-DOC_SYSTEM_DATA_DIR=\"${CMAKE_INSTALL_PREFIX}/share/games/openclonk\"") + add_definitions("-DOC_SYSTEM_DATA_DIR=\"${OC_SYSTEM_DATA_DIR}\"") endif() if(APPLE) @@ -187,8 +189,8 @@ include(CheckCXXSourceCompiles) include(RequireCXXSourceCompiles) include(CheckCXXSymbolExists) -REQUIRE_CXX_SOURCE_COMPILES("#include <memory>\nint main() { std::unique_ptr<int> a; std::shared_ptr<int> b; }" HAVE_C11_SMART_PTRS) -REQUIRE_CXX_SOURCE_COMPILES("int main() { static_assert(true, \"\"); }" HAVE_STATIC_ASSERT) +REQUIRE_CXX_SOURCE_COMPILES("#include <memory>\nint main() { std::unique_ptr<int> a; std::shared_ptr<int> b; return 0;}" HAVE_C11_SMART_PTRS) +REQUIRE_CXX_SOURCE_COMPILES("int main() { static_assert(true, \"\"); return 0; }" HAVE_STATIC_ASSERT) REQUIRE_CXX_SOURCE_COMPILES("#include <memory>\nint main() { auto a = std::make_unique<int>(0); return !!a; }" HAVE_MAKE_UNIQUE) REQUIRE_CXX_SOURCE_COMPILES("#include <utility>\ntemplate<std::size_t... Is> int foo(std::index_sequence<Is...>) {return 0;} int main() { return foo(std::index_sequence_for<int,int>{}); }" HAVE_INDEX_SEQUENCE) REQUIRE_CXX_SOURCE_COMPILES("template<class... T> class C; int main() { return 0; }" HAVE_VARIADIC_TEMPLATES) @@ -990,7 +992,7 @@ include_directories(SYSTEM ############################################################################ add_definitions(-DHAVE_CONFIG_H) -add_library(libmisc +add_library(libmisc STATIC src/C4Include.cpp src/c4group/C4Group.cpp src/c4group/C4Group.h @@ -1055,7 +1057,7 @@ if(UNIX AND NOT APPLE) target_link_libraries(libmisc rt) endif() -add_library(libc4script +add_library(libc4script STATIC src/C4Include.cpp src/c4group/C4ComponentHost.cpp src/c4group/C4ComponentHost.h @@ -1537,13 +1539,13 @@ foreach(group ${OC_C4GROUPS}) DEPENDS "${native_c4group}" VERBATIM ) - install(FILES ${CMAKE_CURRENT_BINARY_DIR}/${group} DESTINATION share/games/openclonk) + install(FILES ${CMAKE_CURRENT_BINARY_DIR}/${group} DESTINATION "${OC_SYSTEM_DATA_DIR}") endif() endforeach() if(NOT APPLE) if(NOT HEADLESS_ONLY) - install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/planet/Music.ocg DESTINATION share/games/openclonk) + install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/planet/Music.ocg DESTINATION "${OC_SYSTEM_DATA_DIR}") endif() # group files (game data) add_custom_target(groups DEPENDS ${OC_C4GROUPS}) @@ -1563,7 +1565,7 @@ if(NOT HEADLESS_ONLY) install(FILES ${CMAKE_CURRENT_SOURCE_DIR}/openclonk.appdata.xml DESTINATION share/appdata) # Install binaries - install(TARGETS openclonk DESTINATION games) + install(TARGETS openclonk DESTINATION "${OC_SYSTEM_GAMES_DIR}") else() install(TARGETS openclonk BUNDLE DESTINATION . diff -Nur oc/thirdparty/getopt/CMakeLists.txt new/thirdparty/getopt/CMakeLists.txt --- oc/thirdparty/getopt/CMakeLists.txt 2016-01-15 21:56:57.000000000 +0100 +++ new/thirdparty/getopt/CMakeLists.txt 2016-08-28 22:40:12.661794806 +0200 @@ -1,4 +1,4 @@ -add_library(getopt +add_library(getopt STATIC getopt.c getopt.h getopt_long.c diff -Nur oc/thirdparty/tinyxml/CMakeLists.txt new/thirdparty/tinyxml/CMakeLists.txt --- oc/thirdparty/tinyxml/CMakeLists.txt 2016-01-15 21:56:57.000000000 +0100 +++ new/thirdparty/tinyxml/CMakeLists.txt 2016-08-28 22:39:56.245637044 +0200 @@ -1,4 +1,4 @@ -add_library(tinyxml +add_library(tinyxml STATIC tinystr.cpp tinystr.h tinyxml.cpp
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor