1
0
Deve 9d894bc80e
macOS: update and switch off from Cocoapods (#98)
Co-authored-by: Maksym H <Maksym48@pm.me>
2022-09-25 12:10:27 +02:00

31 lines
733 B
Bash
Executable File

#!/bin/bash -e
. sdk.sh
[ ! -d irrlicht-src ] && \
git clone --depth 1 -b SDL2 https://github.com/MoNTE48/Irrlicht irrlicht-src
rm -rf irrlicht
cd irrlicht-src/source/Irrlicht
xcodebuild build \
ARCHS="$OSX_ARCHES" \
OTHER_CFLAGS="-I../../../libpng/include -I../../../libjpeg/include" \
-project Irrlicht.xcodeproj \
-configuration Release \
-scheme Irrlicht_OSX
BUILD_FOLDER=$(xcodebuild -project Irrlicht.xcodeproj -scheme \
Irrlicht_OSX -showBuildSettings | \
grep TARGET_BUILD_DIR | sed -n -e 's/^.*TARGET_BUILD_DIR = //p')
cd ../..
[ -d ../irrlicht ] && rm -r ../irrlicht
mkdir -p ../irrlicht
cp "${BUILD_FOLDER}/libIrrlicht.a" ../irrlicht
cp -r include ../irrlicht/include
echo "Irrlicht build successful"