1
0

30 lines
574 B
Bash
Raw Normal View History

#!/bin/bash -e
OGG_VERSION=1.3.5
. scripts/sdk.sh
mkdir -p deps; cd deps
2022-11-13 17:35:33 +01:00
if [ ! -d libogg-src ]; then
git clone -b v$OGG_VERSION --depth 1 https://github.com/xiph/ogg libogg-src
mkdir libogg-src/build
fi
2022-11-13 17:35:33 +01:00
rm -rf libogg
cd libogg-src/build
cmake .. \
-DCMAKE_BUILD_TYPE=Release \
2022-11-13 17:35:33 +01:00
-DCMAKE_C_FLAGS_RELEASE="$OSX_FLAGS $OSX_ARCH" \
-DCMAKE_CXX_FLAGS_RELEASE="$OSX_FLAGS $OSX_ARCH" \
-DCMAKE_OSX_ARCHITECTURES=$OSX_ARCHITECTURES
2022-11-13 17:35:33 +01:00
cmake --build . -j
mkdir -p ../../libogg
2022-11-13 17:35:33 +01:00
cp -v libogg.a ../../libogg
cp -rv ../include ../../libogg/include
echo "Ogg build successful"