View Issue Details Jump to Notes ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0012480CMakeCMakepublic2011-10-02 10:572012-07-09 06:52
ReporterVladislav 
Assigned ToDavid Cole 
PriorityhighSeverityblockReproducibilityalways
StatusclosedResolutionfixed 
PlatformOShost: Linux, target: WindowsOS Version
Product VersionCMake 2.8.5 
Target VersionCMake 2.8.7Fixed in VersionCMake 2.8.7 
Summary0012480: Cmake used invalid path to rc file.
DescriptionAt compiler MinGW usage at compilation of rc-files cmake uses a wrong way at which always there is a substring "/foCMakeFiles".

It arises because of usage in a file "/usr/share/cmake/Modules/CMakeRCInformation.cmake" parameters for the rc-compiler from Microsoft Visual Studio which isn't compatible with windres from MinGW.

For the problem resolution it is possible to use a patch "fix_rc_support_workaround.patch".
TagsNo tags attached.
Attached Filespatch file icon fix_rc_support_workaround.patch [^] (779 bytes) 2011-10-02 10:57 [Show Content]

 Relationships
has duplicate 0011773closedDavid Cole CMake ignore .RC files when cross building 
related to 0012870closedKitware Robot CMakeDetermineRCCompiler does not correctly identify GNU windres when cross-compiling 

  Notes
(0027655)
David Cole (manager)
2011-10-26 11:45

Modules/Platform/Windows-windres.cmake contains this line:

  SET(CMAKE_RC_COMPILE_OBJECT "<CMAKE_RC_COMPILER> -O coff <FLAGS> <DEFINES> <SOURCE> <OBJECT>")

Why is that not sufficient?

Is there a Linux windres? Do we also need a Linux-windres.cmake file, or is the Windows one supposed to be included in this scenario?

Alternatively, if your situation is unique in some way, you could provide this rule in a user rules override file...
(0027656)
Vladislav (reporter)
2011-10-26 13:53

I am using cross compiling in openSUSE with MinGW.

The detailed analysis has shown has shown that the initiating patch was not absolutely true.

In MinGW windres can be named on a miscellaneous. On it the code:
INCLUDE(Platform/${CMAKE_SYSTEM_NAME}-${CMAKE_BASE_NAME} OPTIONAL) in file CMakeRCInformation.cmake can work not correctly, trying to include, for example "Platform/Windows-i686-w64-mingw32-windres".


Condition adding will be the correct fix:
IF("${CMAKE_BASE_NAME}" MATCHES "windres")
  SET(CMAKE_BASE_NAME "windres")
ENDIF("${CMAKE_BASE_NAME}" MATCHES "windres")
After a line "GET_FILENAME_COMPONENT(CMAKE_BASE_NAME ${CMAKE_RC_COMPILER} NAME_WE)".
(0027979)
David Cole (manager)
2011-12-13 20:04

Fix pushed to 'next':

  http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=6ddb1e5b9a3eff941ad12d29609839871fe518ed [^]
(0029946)
David Cole (manager)
2012-07-09 06:52

Closing resolved issues that have not been updated in more than 4 months.

 Issue History
Date Modified Username Field Change
2011-10-02 10:57 Vladislav New Issue
2011-10-02 10:57 Vladislav File Added: fix_rc_support_workaround.patch
2011-10-03 10:36 David Cole Assigned To => David Cole
2011-10-03 10:36 David Cole Status new => assigned
2011-10-25 22:59 David Cole Target Version => CMake 2.8.7
2011-10-26 11:45 David Cole Note Added: 0027655
2011-10-26 13:53 Vladislav Note Added: 0027656
2011-10-28 10:13 David Cole Relationship added has duplicate 0011773
2011-12-13 20:04 David Cole Note Added: 0027979
2011-12-13 20:04 David Cole Status assigned => resolved
2011-12-13 20:04 David Cole Resolution open => fixed
2011-12-16 17:19 David Cole Fixed in Version => CMake 2.8.7
2012-01-10 08:40 David Cole Relationship added related to 0012870
2012-07-09 06:52 David Cole Note Added: 0029946
2012-07-09 06:52 David Cole Status resolved => closed


Copyright © 2000 - 2018 MantisBT Team