mirror of
https://github.com/reactos/reactos.git
synced 2025-08-03 14:25:52 +00:00
[CMAKE]
- Add current source directory to MS RC include paths - Add include directories to WRC include paths - Now they should behave identically enough. Thanks to Amine. svn path=/trunk/; revision=53361
This commit is contained in:
parent
f5e9a08c0b
commit
a1cc2c02bf
2 changed files with 13 additions and 2 deletions
|
@ -187,7 +187,7 @@ function(set_rc_compiler)
|
|||
#set(CMAKE_RC_COMPILE_OBJECT "<CMAKE_RC_COMPILER> ${rc_result_defs} ${rc_result_incs} -i <SOURCE> -O coff -o <OBJECT>" PARENT_SCOPE)
|
||||
set(CMAKE_RC_COMPILE_OBJECT
|
||||
"<CMAKE_C_COMPILER> -DRC_INVOKED -D__WIN32__=1 -D__FLAT__=1 ${rc_result_defs} -I${CMAKE_CURRENT_SOURCE_DIR} ${rc_result_incs} -xc -E <SOURCE> -o <OBJECT>"
|
||||
"${WRC} -I${CMAKE_CURRENT_SOURCE_DIR} -i <OBJECT> -o <OBJECT>"
|
||||
"${WRC} -I${CMAKE_CURRENT_SOURCE_DIR} ${rc_result_incs} -i <OBJECT> -o <OBJECT>"
|
||||
"<CMAKE_RC_COMPILER> -i <OBJECT> -J res -O coff -o <OBJECT>" PARENT_SCOPE)
|
||||
endfunction()
|
||||
|
||||
|
|
|
@ -132,7 +132,18 @@ function(set_module_type MODULE TYPE)
|
|||
endfunction()
|
||||
|
||||
function(set_rc_compiler)
|
||||
# dummy, this workaround is only needed in mingw due to lack of RC support in cmake
|
||||
get_directory_property(defines COMPILE_DEFINITIONS)
|
||||
get_directory_property(includes INCLUDE_DIRECTORIES)
|
||||
|
||||
foreach(arg ${defines})
|
||||
set(rc_result_defs "${rc_result_defs} /D${arg}")
|
||||
endforeach()
|
||||
|
||||
foreach(arg ${includes})
|
||||
set(rc_result_incs "/I${arg} ${rc_result_incs}")
|
||||
endforeach()
|
||||
|
||||
set(CMAKE_RC_COMPILE_OBJECT "<CMAKE_RC_COMPILER> ${rc_result_defs} /I${CMAKE_CURRENT_SOURCE_DIR} ${rc_result_incs} /fo <OBJECT> <SOURCE>" PARENT_SCOPE)
|
||||
endfunction()
|
||||
|
||||
# Thanks MS for creating a stupid linker
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue