hedgewars/CMakeLists.txt
changeset 193 56885ea29202
parent 184 f97a7a3dc8f6
child 196 993cf173218b
equal deleted inserted replaced
192:b644f61e803f 193:56885ea29202
    22 	if (fpc_version)
    22 	if (fpc_version)
    23 		string(REGEX REPLACE "([0-9]+)\\.[0-9]+\\.[0-9]+" "\\1" fpc_vers_major "${fpc_version}")
    23 		string(REGEX REPLACE "([0-9]+)\\.[0-9]+\\.[0-9]+" "\\1" fpc_vers_major "${fpc_version}")
    24 		string(REGEX REPLACE "[0-9]+\\.([0-9])+\\.[0-9]+" "\\1" fpc_vers_minor "${fpc_version}")
    24 		string(REGEX REPLACE "[0-9]+\\.([0-9])+\\.[0-9]+" "\\1" fpc_vers_minor "${fpc_version}")
    25 		string(REGEX REPLACE "[0-9]+\\.[0-9]+\\.([0-9]+)" "\\1" fpc_vers_patch "${fpc_version}")
    25 		string(REGEX REPLACE "[0-9]+\\.[0-9]+\\.([0-9]+)" "\\1" fpc_vers_patch "${fpc_version}")
    26 		math(EXPR fpc_ver "${fpc_vers_major}*10000 + ${fpc_vers_minor}*100 + ${fpc_vers_patch}")
    26 		math(EXPR fpc_ver "${fpc_vers_major}*10000 + ${fpc_vers_minor}*100 + ${fpc_vers_patch}")
    27 		if (${fpc_ver} LESS "010906")
    27 		if (fpc_ver LESS "010906")
    28 			message("Minimum required version of FreePascal is 2.0.5")
    28 			message("Minimum required version of FreePascal is 1.9.6")
    29 		else (${fpc_ver} LESS "010906")
    29 		else (fpc_ver LESS "010906")
    30 			set(pascal_compiler ${fpc_executable})
    30 			set(pascal_compiler ${fpc_executable})
    31 			set(pascal_compiler_flags "-B" "-Sd" "-Xs" "-OG" "-O2" "-Cs2000000" ${hwengine_project})
    31 			set(pascal_compiler_flags "-B" "-Sd" "-Xs" "-OG" "-O2" "-Cs2000000" ${hwengine_project})
    32 		endif (${fpc_ver} LESS "010906")
    32 		endif (fpc_ver LESS "010906")
    33 	endif (fpc_version)
    33 	endif (fpc_version)
    34 endif (dcc32version)
    34 endif (dcc32version)
    35 
    35 
    36 if (NOT pascal_compiler)
    36 if (NOT pascal_compiler)
    37 	message(FATAL_ERROR "No Pascal compiler found!")
    37 	message(FATAL_ERROR "No Pascal compiler found!")