Browse Source

Merge topic 'mingw-windres-cross-compile'

af4adf6aa9 MinGW: Fix default windres selection when cross-compiling
0251ddadab MinGW: Drop unnecessary windres selection code with Unix Makefiles

Acked-by: Kitware Robot <[email protected]>
Merge-request: !4520
Brad King 5 years ago
parent
commit
545875bebe
1 changed files with 1 additions and 5 deletions
  1. 1 5
      Modules/Platform/Windows-GNU.cmake

+ 1 - 5
Modules/Platform/Windows-GNU.cmake

@@ -47,10 +47,6 @@ if("${_help}" MATCHES "GNU ld .* 2\\.1[1-6]")
   set(__WINDOWS_GNU_LD_RESPONSE 0)
   set(__WINDOWS_GNU_LD_RESPONSE 0)
 endif()
 endif()
 
 
-if(NOT CMAKE_GENERATOR_RC AND CMAKE_GENERATOR MATCHES "Unix Makefiles")
-  set(CMAKE_GENERATOR_RC windres)
-endif()
-
 macro(__windows_compiler_gnu lang)
 macro(__windows_compiler_gnu lang)
 
 
   if(MSYS OR MINGW)
   if(MSYS OR MINGW)
@@ -132,7 +128,7 @@ macro(__windows_compiler_gnu lang)
   endif()
   endif()
 
 
   if(NOT CMAKE_RC_COMPILER_INIT AND NOT CMAKE_GENERATOR_RC)
   if(NOT CMAKE_RC_COMPILER_INIT AND NOT CMAKE_GENERATOR_RC)
-    set(CMAKE_RC_COMPILER_INIT windres)
+    set(CMAKE_RC_COMPILER_INIT ${_CMAKE_TOOLCHAIN_PREFIX}windres)
   endif()
   endif()
 
 
   enable_language(RC)
   enable_language(RC)