CMakeLists.txt
changeset 2929 dd4efe601bc6
parent 2834 61f14237dc56
child 3055 f542a36ef6c0
equal deleted inserted replaced
2928:0e95e0e24fd8 2929:dd4efe601bc6
    51 	if(NOT minimum_macosx)
    51 	if(NOT minimum_macosx)
    52 		#if nothing is set, we deploy only for the current system
    52 		#if nothing is set, we deploy only for the current system
    53 		set(minimum_macosx ${current_macosx_version})
    53 		set(minimum_macosx ${current_macosx_version})
    54 	endif()
    54 	endif()
    55 
    55 
       
    56 	if (minimum_macosx LESS "10.4")
       
    57 		set(FATAL "Hedgewars is not supported for pre-10.4 systems")
       
    58 	endif()
       
    59 
    56 	if(current_macosx_version MATCHES "10.6")
    60 	if(current_macosx_version MATCHES "10.6")
    57 		set(CMAKE_OSX_ARCHITECTURES "x86_64")
    61 		set(CMAKE_OSX_ARCHITECTURES "x86_64")
    58 	endif()
    62 	endif()
    59 
    63 
    60 	#create universal binaries only when it's time to bundle the application, also build server
    64 	#create universal binaries only when it's time to bundle the application, also build server
    61 	IF(BUNDLE)
    65 	IF(BUNDLE)
    62 		set(WITH_SERVER false)
    66 		set(WITH_SERVER false)
    63 		if(minimum_macosx NOT MATCHES "10.6")
    67 		if(NOT minimum_macosx MATCHES "10.6")
       
    68 			set(CMAKE_C_COMPILER "gcc-4.0")
       
    69 			set(CMAKE_CXX_COMPILER "g++-4.0")
    64 			set(CMAKE_OSX_ARCHITECTURES "i386;ppc7400")
    70 			set(CMAKE_OSX_ARCHITECTURES "i386;ppc7400")
    65 		endif()
    71 		endif()
    66 	ENDIF()	
    72 	ENDIF()	
    67 
    73 
    68 	message(STATUS "Target system: Mac OS X ${minimum_macosx} ${CMAKE_OSX_ARCHITECTURES}")	
    74 	message(STATUS "Target system: Mac OS X ${minimum_macosx} ${CMAKE_OSX_ARCHITECTURES}")