Fix LuaJIT failing on MacOS

I had one job
master
Dorian Wouters 2018-08-13 21:20:01 +02:00
parent 771b53eeab
commit 9964d19ebd
No known key found for this signature in database
GPG Key ID: 6E9DA8063322434B
1 changed files with 4 additions and 0 deletions

View File

@ -58,6 +58,10 @@ if(CMAKE_CXX_COMPILER_ID MATCHES "Clang" OR CMAKE_CXX_COMPILER_ID MATCHES "GNU")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -pie")
endif()
endif()
if (${CMAKE_SYSTEM_NAME} MATCHES "Darwin")
# Fix LuaJIT failing to run on OS X
link_libraries("-pagezero_size 10000 -image_base 100000000")
endif()
message(">> Using ${CMAKE_BUILD_TYPE} build configuration")
set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -O0 -DDEBUG -g")