Add exe icons (#334)

* add exe icons

* rebuild icon resource on ico change

* drop icon rebuild tracking
This commit is contained in:
patchzyy
2026-10-22 16:43:45 +02:00
committed by GitHub
parent b04654a676
commit b1c99d4cab
5 changed files with 16 additions and 0 deletions
+14
View File
@@ -293,8 +293,21 @@ function(mkw_configure_product target)
endif()
endfunction()
if(MKW_PLATFORM_WINDOWS)
enable_language(RC)
endif()
# Own object library so the products' C++ options never reach the resource compiler.
function(mkw_add_product_icon target)
if(MKW_PLATFORM_WINDOWS)
add_library(${target}_icon OBJECT "${MKW_RUNTIME_SOURCE_DIR}/resources/${target}.rc")
target_sources(${target} PRIVATE $<TARGET_OBJECTS:${target}_icon>)
endif()
endfunction()
add_executable(WiiCompiled "${MKW_BASE_PRODUCT_SOURCE}")
mkw_configure_product(WiiCompiled)
mkw_add_product_icon(WiiCompiled)
target_sources(WiiCompiled PRIVATE $<TARGET_OBJECTS:mkw_base_registration>)
target_precompile_headers(WiiCompiled PRIVATE
"${MKW_RUNTIME_SOURCE_DIR}/include/mkw_pch.h")
@@ -305,6 +318,7 @@ endif()
if(MKW_HAVE_RETRO_REWIND)
add_executable(RetroRewind "${MKW_RETRO_REWIND_PRODUCT_SOURCE}")
mkw_configure_product(RetroRewind)
mkw_add_product_icon(RetroRewind)
target_precompile_headers(RetroRewind REUSE_FROM WiiCompiled)
target_sources(RetroRewind PRIVATE $<TARGET_OBJECTS:mkw_retro_registration>)
if(TARGET mkw_retro_sensitive)
Binary file not shown.

After

Width:  |  Height:  |  Size: 50 KiB

+1
View File
@@ -0,0 +1 @@
1 ICON "RetroRewind.ico"
Binary file not shown.

After

Width:  |  Height:  |  Size: 108 KiB

+1
View File
@@ -0,0 +1 @@
1 ICON "WiiCompiled.ico"