pytrainer: unpin python 3.10
[NixPkgs.git] / pkgs / games / ja2-stracciatella / remove-rust-buildstep.patch
blob64e3c11b25028e8bf8af1e78411d23f59c254dc3
1 diff --git a/CMakeLists.txt b/CMakeLists.txt
2 index e4e5547af..a3017d197 100644
3 --- a/CMakeLists.txt
4 +++ b/CMakeLists.txt
5 @@ -175,13 +175,12 @@ if(BUILD_LAUNCHER)
6 endif()
7 message(STATUS "Fltk Libraries: ${FLTK_LIBRARIES}")
9 -set(JA2_INCLUDES "")
10 +set(JA2_INCLUDES "include/stracciatella")
11 set(JA2_SOURCES "")
12 add_subdirectory("${CMAKE_CURRENT_SOURCE_DIR}/src/externalized")
13 add_subdirectory("${CMAKE_CURRENT_SOURCE_DIR}/src/game")
14 add_subdirectory("${CMAKE_CURRENT_SOURCE_DIR}/src/sgp")
15 add_subdirectory("${CMAKE_CURRENT_SOURCE_DIR}/dependencies/lib-smacker")
16 -add_subdirectory("${CMAKE_CURRENT_SOURCE_DIR}/dependencies/lib-stracciatella")
17 add_subdirectory("${CMAKE_CURRENT_SOURCE_DIR}/dependencies/lib-string_theory")
19 if(BUILD_LAUNCHER)
20 @@ -239,14 +238,12 @@ string(LENGTH "${CMAKE_SOURCE_DIR}/src/" SOURCE_PATH_SIZE)
21 add_definitions("-DSOURCE_PATH_SIZE=${SOURCE_PATH_SIZE}")
23 add_executable(${JA2_BINARY} ${JA2_SOURCES})
24 -target_link_libraries(${JA2_BINARY} ${SDL2_LIBRARY} ${GTEST_LIBRARIES} smacker ${STRACCIATELLA_LIBRARIES} string_theory-internal)
25 -add_dependencies(${JA2_BINARY} stracciatella)
26 +target_link_libraries(${JA2_BINARY} ${SDL2_LIBRARY} ${GTEST_LIBRARIES} smacker lib/libstracciatella_c_api.a dl pthread string_theory-internal)
27 set_property(SOURCE ${CMAKE_SOURCE_DIR}/src/game/GameVersion.cc APPEND PROPERTY COMPILE_DEFINITIONS "GAME_VERSION=v${ja2-stracciatella_VERSION}")
29 if(BUILD_LAUNCHER)
30 add_executable(${LAUNCHER_BINARY} ${LAUNCHER_SOURCES})
31 - target_link_libraries(${LAUNCHER_BINARY} ${FLTK_LIBRARIES} ${STRACCIATELLA_LIBRARIES} string_theory-internal)
32 - add_dependencies(${LAUNCHER_BINARY} stracciatella)
33 + target_link_libraries(${LAUNCHER_BINARY} ${FLTK_LIBRARIES} lib/libstracciatella_c_api.a dl pthread string_theory-internal)
34 endif()
36 macro(copy_assets_dir_to_ja2_binary_after_build DIR)
37 @@ -375,12 +372,12 @@ set(CPACK_PACKAGE_FILE_NAME "${PROJECT_NAME}_${CPACK_PACKAGE_VERSION}_${PACKAGE_
39 include(CPack)
41 -if (UNIX AND NOT MINGW AND NOT APPLE)
42 +if (UNIX)
43 install(TARGETS ${JA2_BINARY} RUNTIME DESTINATION bin)
44 if(BUILD_LAUNCHER)
45 install(TARGETS ${LAUNCHER_BINARY} RUNTIME DESTINATION bin)
46 endif()
47 - install(PROGRAMS "${CMAKE_BINARY_DIR}/lib-stracciatella/bin/ja2-resource-pack${CMAKE_EXECUTABLE_SUFFIX}" DESTINATION bin)
48 + install(PROGRAMS "bin/ja2-resource-pack" DESTINATION bin)
49 install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/assets/externalized assets/mods assets/unittests DESTINATION share/ja2)
50 if(WITH_EDITOR_SLF)
51 install(FILES "${EDITORSLF_FILE}" DESTINATION share/ja2)
52 @@ -400,7 +397,7 @@ else()
53 if(BUILD_LAUNCHER)
54 install(TARGETS ${LAUNCHER_BINARY} RUNTIME DESTINATION .)
55 endif()
56 - install(PROGRAMS "${CMAKE_BINARY_DIR}/lib-stracciatella/bin/ja2-resource-pack${CMAKE_EXECUTABLE_SUFFIX}" DESTINATION .)
57 + install(PROGRAMS "bin/ja2-resource-pack" DESTINATION .)
58 install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/assets/externalized assets/mods assets/unittests DESTINATION .)
59 if(WITH_EDITOR_SLF)
60 install(FILES "${EDITORSLF_FILE}" DESTINATION .)
61 @@ -428,12 +425,6 @@ if (MINGW)
62 install(SCRIPT "${CMAKE_CURRENT_BINARY_DIR}/install-dlls-mingw.cmake")
63 endif()
65 -if(APPLE)
66 - file(GLOB APPLE_DIST_FILES "${CMAKE_CURRENT_SOURCE_DIR}/assets/distr-files-mac/*.txt")
67 - install(FILES ${APPLE_DIST_FILES} DESTINATION .)
68 - install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/dependencies/lib-SDL2-2.0.8-macos/SDL2.framework DESTINATION .)
69 -endif()
71 ## Uninstall
73 add_custom_templated_target("uninstall")