Fix compilation with CMake on Windows when some other building tool than

msbuild is used.
This commit is contained in:
arezey 2015-04-12 02:11:51 +03:00
parent 9f2b3efd13
commit a6287a4706

View file

@ -1158,10 +1158,17 @@ if( MSVC )
set_target_properties(zdoom PROPERTIES LINK_FLAGS "/MANIFEST:NO /DELAYLOAD:\"fmodex${X64}.dll\"")
endif( ZDOOM_GENERATE_MAPFILE )
add_custom_command(TARGET zdoom POST_BUILD
COMMAND "mt.exe" -manifest \"${CMAKE_CURRENT_SOURCE_DIR}\\win32\\zdoom.exe.manifest\" -outputresource:\"$(TargetDir)$(TargetFileName)\"\;\#1
COMMENT "Adding manifest..."
)
if( NO_GENERATOR_EXPRESSIONS )
add_custom_command(TARGET zdoom POST_BUILD
COMMAND "mt.exe" -manifest \"${CMAKE_CURRENT_SOURCE_DIR}\\win32\\zdoom.exe.manifest\" -outputresource:\"$(TargetDir)$(TargetFileName)\"\;\#1
COMMENT "Adding manifest..."
)
else( NO_GENERATOR_EXPRESSIONS )
add_custom_command(TARGET zdoom POST_BUILD
COMMAND "mt.exe" -manifest \"${CMAKE_CURRENT_SOURCE_DIR}\\win32\\zdoom.exe.manifest\" -outputresource:$<TARGET_FILE:zdoom>
COMMENT "Adding manifest..."
)
endif( NO_GENERATOR_EXPRESSIONS )
create_default_target_launcher( zdoom WORKING_DIRECTORY ${ZDOOM_OUTPUT_DIR} )
endif( MSVC )