put actual information in readme

closes #17

[skip ci]
This commit is contained in:
alexey.lysiuk 2021-01-20 16:28:31 +02:00 committed by GitHub
parent dde53f6936
commit ea74a92a68
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1,30 +1,35 @@
# *ZDoom binary dependencies for macOS
This repository contains all binary dependencies required to build macOS application bundles of [ZDoom-derived](https://zdoom.org) source ports.
This repository contains all binary dependencies required to build macOS application bundles of [ZDoom-derived](https://zdoom.org) source ports. A few other projects are supported as well, with lesser priority though.
## Usage
Download source code, and build a target
Libraries were built with the following environment variables set:
```sh
export CFLAGS="-I/usr/local/include -mmacosx-version-min=10.9 -isysroot MacOSX10.9.sdk"
export CXXFLAGS="-I/usr/local/include -mmacosx-version-min=10.9 -isysroot MacOSX10.9.sdk"
export CPPFLAGS="-I/usr/local/include -mmacosx-version-min=10.9 -isysroot MacOSX10.9.sdk"
export LDFLAGS="-L/usr/local/lib -mmacosx-version-min=10.9 -isysroot MacOSX10.9.sdk"
```
macOS 10.9 SDK was obtained from Xcode 6.4 which is the last version shipped with Mavericks SDK.
The exception is MoltenVK as it must be build as a dynamic library and requires 10.11 or newer.
In addition to CMake, it needs Python 3.x to build its dependencies.
```sh
export CFLAGS="-I/usr/local/include -mmacosx-version-min=10.11 -isysroot MacOSX10.11.sdk"
export CXXFLAGS="-I/usr/local/include -mmacosx-version-min=10.11 -isysroot MacOSX10.11.sdk"
export CPPFLAGS="-I/usr/local/include -mmacosx-version-min=10.11 -isysroot MacOSX10.11.sdk"
export LDFLAGS="-L/usr/local/lib -mmacosx-version-min=10.11 -isysroot MacOSX10.11.sdk"
git clone https://github.com/KhronosGroup/MoltenVK.git
cd MoltenVK
git checkout v1.0.38 # See https://github.com/KhronosGroup/MoltenVK/tags
./fetchDependencies -v # Assumes CMake and Python 3 are accessible
xcodebuild -project MoltenVK/MoltenVK.xcodeproj -scheme MoltenVK-macOS
build.py --target=<target-name>
```
macOS 10.11 SDK was obtained from Xcode 7.3.1 which is the last version shipped with El Capitan SDK.
Build target from existing source code
```
build.py --source=<path-to-source-code>
```
Generate Xcode project instead of building target, and open it
```
build.py --source=...|--target=... --xcode
```
Run `build.py` without arguments for complete list of options.
## Prerequisites
* Xcode 12.2 or newer, launch it once to finish installation
* CMake 3.18 or newer, `CMake.app` in `/Applications` or system-wide `cmake` console executable
## Common information
Libraries were built using 10.9 SDK (Intel x64_64) and 11.0 SDK (ARM64).
macOS 10.9 SDK was obtained from Xcode 6.4. macOS 11.0 SDK was obtained from Xcode 12.2.