Add Apple Silicon support (#86)
This commit is contained in:
parent
365805afe8
commit
032969ce5b
|
@ -111,15 +111,11 @@ jobs:
|
|||
- name: Clone
|
||||
uses: actions/checkout@v3
|
||||
|
||||
- name: Dependencies
|
||||
run: |
|
||||
brew install sdl2
|
||||
|
||||
- name: Cache cmake build
|
||||
uses: actions/cache@v3
|
||||
with:
|
||||
path: build
|
||||
key: macos-cmake-v1
|
||||
key: macos-cmake-v2
|
||||
|
||||
- name: Configure
|
||||
run: |
|
||||
|
|
|
@ -85,10 +85,6 @@ jobs:
|
|||
- name: Clone
|
||||
uses: actions/checkout@v3
|
||||
|
||||
- name: Dependencies
|
||||
run: |
|
||||
brew install sdl2
|
||||
|
||||
- name: Import code signing certificates
|
||||
uses: apple-actions/import-codesign-certs@v1
|
||||
with:
|
||||
|
@ -99,7 +95,7 @@ jobs:
|
|||
uses: actions/cache@v3
|
||||
with:
|
||||
path: build
|
||||
key: macos-cmake-v1
|
||||
key: macos-cmake-v2
|
||||
|
||||
- name: Configure
|
||||
run: |
|
||||
|
|
|
@ -4,6 +4,11 @@ set(CMAKE_POLICY_DEFAULT_CMP0077 NEW)
|
|||
|
||||
set(EXECUTABLE_NAME fallout2-ce)
|
||||
|
||||
if (APPLE)
|
||||
set(CMAKE_OSX_DEPLOYMENT_TARGET "11.0" CACHE STRING "")
|
||||
set(CMAKE_OSX_ARCHITECTURES "x86_64;arm64" CACHE STRING "")
|
||||
endif()
|
||||
|
||||
project(${EXECUTABLE_NAME})
|
||||
|
||||
set(CMAKE_CXX_STANDARD 17)
|
||||
|
@ -268,14 +273,13 @@ if(APPLE)
|
|||
set(MACOSX_BUNDLE_GUI_IDENTIFIER "com.alexbatalov.fallout2-ce")
|
||||
set(MACOSX_BUNDLE_BUNDLE_NAME "${EXECUTABLE_NAME}")
|
||||
set(MACOSX_BUNDLE_DISPLAY_NAME "Fallout 2")
|
||||
set(CMAKE_OSX_DEPLOYMENT_TARGET "11.0")
|
||||
endif()
|
||||
|
||||
add_subdirectory("third_party/fpattern")
|
||||
target_link_libraries(${EXECUTABLE_NAME} ${FPATTERN_LIBRARY})
|
||||
target_include_directories(${EXECUTABLE_NAME} PRIVATE ${FPATTERN_INCLUDE_DIR})
|
||||
|
||||
if(NOT APPLE AND NOT ${CMAKE_SYSTEM_NAME} MATCHES "Linux")
|
||||
if(NOT ${CMAKE_SYSTEM_NAME} MATCHES "Linux")
|
||||
add_subdirectory("third_party/zlib")
|
||||
add_subdirectory("third_party/sdl2")
|
||||
else()
|
||||
|
|
|
@ -24,7 +24,7 @@ $ sudo apt install libsdl2-2.0-0
|
|||
|
||||
### macOS
|
||||
|
||||
> **NOTE**: macOS 11 or higher is required. The app is not universal. It should run on Apple Silicon under Rosetta 2, but I haven't tried it.
|
||||
> **NOTE**: macOS 11 or higher is required.
|
||||
|
||||
- Use Windows installation as a base - it contains data assets needed to play. Copy `Fallout2` folder somewhere, for example `/Applications/Fallout2`.
|
||||
|
||||
|
|
Loading…
Reference in New Issue