$NetBSD: patch-CMakeLists.txt,v 1.2 2025/05/07 12:20:08 micha Exp $ Treat macOS like every other Unix. Let pkgsrc handle icon and desktop files. --- CMakeLists.txt.orig 2024-07-09 18:15:50.000000000 +0000 +++ CMakeLists.txt @@ -69,11 +69,11 @@ if(WIN32) ) endif() -if(NOT APPLE) +#if(NOT APPLE) target_sources(eureka PRIVATE mainroot.cc) -endif() +#endif() -if(APPLE) +if(APPLE_DISABLED) set(exe_display_name "Eureka Doom Editor") set_target_properties(eureka PROPERTIES OUTPUT_NAME "${exe_display_name}") @@ -139,7 +139,7 @@ else() endif() add_subdirectory(src) -if(APPLE) +if(APPLE_DISABLED) target_link_libraries(eurekasrc PRIVATE eurekamac) target_link_libraries(eurekamac PRIVATE eurekasrc) endif() @@ -170,10 +170,12 @@ if(UNIX AND NOT APPLE) # Linux DESTINATION "${eureka_install_dir}" ) # The full-install sequence is here - install(CODE "execute_process( - COMMAND xdg-desktop-menu install --novendor ${CMAKE_CURRENT_SOURCE_DIR}/misc/eureka.desktop - COMMAND xdg-icon-resource install --novendor --size 32 ${CMAKE_CURRENT_SOURCE_DIR}/misc/eureka.xpm - )") + #install(CODE "execute_process( + # COMMAND xdg-desktop-menu install --novendor ${CMAKE_CURRENT_SOURCE_DIR}/misc/eureka.desktop + # COMMAND xdg-icon-resource install --novendor --size 32 ${CMAKE_CURRENT_SOURCE_DIR}/misc/eureka.xpm + #)") + install(FILES misc/eureka.xpm DESTINATION share/icons/hicolor/32x32/apps) + install(FILES misc/eureka.desktop DESTINATION share/applications) # uninstall target if(NOT TARGET uninstall)