Skip to content

Commit

Permalink
test 8
Browse files Browse the repository at this point in the history
  • Loading branch information
rfomin committed Sep 3, 2024
1 parent fb817bb commit be6a750
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 4 deletions.
5 changes: 4 additions & 1 deletion prboom2/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,7 @@ endif()
if(WIN32)
set(DEFAULT_WAD_DIR ".")
else()
set(DEFAULT_WAD_DIR "${CMAKE_INSTALL_DATADIR}/games/doom")
set(DEFAULT_WAD_DIR "share/games/doom")
endif()

set(DSDAPWADDIR "${DEFAULT_WAD_DIR}" CACHE STRING "Path to install DSDA-Doom internal WAD, relative to CMAKE_INSTALL_PREFIX or absolute.")
Expand Down Expand Up @@ -207,6 +207,7 @@ set(WAD_DATA_PATH "${DSDA_OUTPUT_PATH}/${WAD_DATA}")

add_subdirectory(data)
add_subdirectory(src)
add_subdirectory(ICONS)

if(NOT CMAKE_CROSSCOMPILING)
export(TARGETS ${CROSS_EXPORTS} FILE "${CMAKE_BINARY_DIR}/ImportExecutables.cmake")
Expand Down Expand Up @@ -246,6 +247,8 @@ elseif(LINUX)
--appimage-extract-and-run
--appdir=${CPACK_TEMPORARY_DIRECTORY}
--executable=$<TARGET_FILE:dsda-doom>
--desktop-file=${CPACK_TEMPORARY_DIRECTORY}/${CPACK_PACKAGING_INSTALL_PREFIX}/share/applications/dsda-doom.desktop
--icon-file=${CPACK_TEMPORARY_DIRECTORY}/${CPACK_PACKAGING_INSTALL_PREFIX}/share/icons/hicolor/scalable/apps/dsda-doom.svg
--output=appimage)
]])
endif()
Expand Down
4 changes: 4 additions & 0 deletions prboom2/ICONS/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
if(UNIX AND NOT APPLE)
install(FILES dsda-doom.desktop DESTINATION share/applications)
install(FILES dsda-doom.svg DESTINATION share/icons/hicolor/scalable/apps)
endif()
2 changes: 1 addition & 1 deletion prboom2/data/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -412,4 +412,4 @@ add_custom_command(
DEPENDS rdatawad ${WAD_SRC}
)
add_custom_target(dsda-doom-wad DEPENDS ${WAD_DATA_PATH})
install(FILES ${WAD_DATA_PATH} DESTINATION ${DSDAPWADDIR} COMPONENT "DSDA-Doom internal WAD")
install(FILES ${WAD_DATA_PATH} DESTINATION ${DSDAPWADDIR})
3 changes: 1 addition & 2 deletions prboom2/src/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -618,10 +618,9 @@ function(AddGameExecutable TARGET SOURCES)
POST_EXCLUDE_REGEXES ".*system32/.*\\.dll"
DIRECTORIES $<TARGET_FILE_DIR:${TARGET}> $ENV{PATH}
RUNTIME DESTINATION "${DSDA_BINARY_INSTALL_DIR}"
COMPONENT "Game executable"
)
else()
install(TARGETS ${TARGET} COMPONENT "Game executable" RUNTIME DESTINATION "${DSDA_BINARY_INSTALL_DIR}")
install(TARGETS ${TARGET} RUNTIME DESTINATION "${DSDA_BINARY_INSTALL_DIR}")
endif()

target_link_libraries(${TARGET} PRIVATE
Expand Down
1 change: 1 addition & 0 deletions prboom2/src/SDL/i_system.c
Original file line number Diff line number Diff line change
Expand Up @@ -431,6 +431,7 @@ char* I_FindFileInternal(const char* wfname, const char* ext, dboolean isStatic)
{DOOMWADDIR}, // build-time configured DOOMWADDIR
{DSDA_ABSOLUTE_PWAD_PATH}, // build-time configured absolute path to dsda-doom.wad
{NULL, NULL, NULL, I_GetBasePath}, // search the base path provided by SDL
{NULL, "../share/games/doom", NULL, I_GetBasePath}, // AppImage
{NULL, "doom", "HOME"}, // ~/doom
{NULL, NULL, "HOME"}, // ~
{"/usr/local/share/games/doom"},
Expand Down

0 comments on commit be6a750

Please # to comment.