Commit 699f7306 authored by Ilya Prokhorov's avatar Ilya Prokhorov

osxcross changes

parent 5b900ff1
......@@ -11,6 +11,16 @@ SET(CMAKE_RC_COMPILER i686-w64-mingw32-windres)
set(CMAKE_RANLIB i686-w64-mingw32-ranlib)
endif()
if (OSXCROSS)
SET(CMAKE_SYSTEM_NAME Darwin)
SET(CMAKE_C_COMPILER o64-clang)
SET(CMAKE_CXX_COMPILER o64-clang++)
SET(CMAKE_C_COMPILER_AR x86_64-apple-darwin19-ar)
SET(CMAKE_CXX_COMPILER_AR x86_64-apple-darwin19-ar)
SET(CMAKE_LINKER x86_64-apple-darwin19-ld)
SET(ENV{OSXCROSS_MP_INC} 1)
endif()
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++14")
set(CMAKE_SHARED_LIBRARY_LINK_CXX_FLAGS)
......@@ -27,6 +37,8 @@ if (EMSCRIPTEN)
add_library(FlameSteelCore STATIC ${SOURCE_FILES})
elseif (MINGW32)
add_library(FlameSteelCore.dll SHARED ${SOURCE_FILES})
elseif (OSXCROSS)
add_library(FlameSteelCore STATIC ${SOURCE_FILES})
else()
add_library(FlameSteelCore SHARED ${SOURCE_FILES})
endif()
......
source ~/Apps/osxcross.sh
mkdir osxCrossBuild
cd osxCrossBuild
ar x ../libFlameSteelCore.a
rm ../libFlameSteelCore.a
x86_64-apple-darwin19-ar rcs ../libFlameSteelCore.a *.o
cd ..
rm -rf osxCrossBuild
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment