--- a/hedgewars/CMakeLists.txt Mon Jul 31 11:31:31 2006 +0000
+++ b/hedgewars/CMakeLists.txt Sat Aug 05 20:57:36 2006 +0000
@@ -18,7 +18,7 @@
string(REGEX MATCH "[0-9]+\\.[0-9]+" dcc32version "${dcc32_output}")
if (dcc32version)
set(pascal_compiler ${dcc32_executable})
- set(pascal_compiler_flags "-B -W"${hwengine_project})
+ set(pascal_compiler_flags "-B -W "${hwengine_project})
else (dcc32version)
string(REGEX MATCH "[0-9]+\\.[0-9]+\\.[0-9]+" ppc386_version "${ppc386_output}")
if (ppc386_version)
@@ -30,7 +30,7 @@
message("Minimum required version of FreePascal is 1.9.2")
else (ppc386_ver LESS "010902")
set(pascal_compiler ${ppc386_executable})
- set(pascal_compiler_flags "-B -Sd -Xs -OG -O3 -Cs2000000"${hwengine_project})
+ set(pascal_compiler_flags "-B -Sd -Xs -OG -O3 -Cs2000000 "${hwengine_project})
endif (ppc386_ver LESS "010902")
endif (ppc386_version)
endif (dcc32version)
@@ -39,6 +39,6 @@
message(FATAL_ERROR "No Pascal compiler found!")
endif (NOT pascal_compiler)
-add_custom_command(COMMAND ${pascal_compiler} TARGET hwengine OUTPUTS hwengine ARGS ${pascal_compiler_flags})
+add_custom_target(hwengine ALL COMMAND "${pascal_compiler}" ${pascal_compiler_flags})
install(PROGRAMS "hwengine${CMAKE_EXECUTABLE_SUFFIX}" DESTINATION bin)