2021-02-12 19:15:39 +01:00
|
|
|
#!/bin/bash -e
|
|
|
|
|
2023-03-01 01:16:34 +01:00
|
|
|
OPENAL_VERSION=1.23.0
|
2021-02-12 19:15:39 +01:00
|
|
|
|
2022-12-02 11:40:55 +01:00
|
|
|
. scripts/sdk.sh
|
|
|
|
mkdir -p deps; cd deps
|
|
|
|
|
2021-02-12 19:15:39 +01:00
|
|
|
if [ ! -d openal-src ]; then
|
2022-11-13 17:35:33 +01:00
|
|
|
git clone -b $OPENAL_VERSION --depth 1 https://github.com/kcat/openal-soft openal-src
|
2021-02-12 19:15:39 +01:00
|
|
|
fi
|
|
|
|
|
2022-09-25 12:10:27 +02:00
|
|
|
rm -rf openal
|
|
|
|
|
2021-02-12 19:15:39 +01:00
|
|
|
cd openal-src
|
|
|
|
|
|
|
|
cmake -S . \
|
2022-09-25 12:10:27 +02:00
|
|
|
-DCMAKE_BUILD_TYPE=Release \
|
|
|
|
-DLIBTYPE=STATIC \
|
2022-01-30 00:10:40 +02:00
|
|
|
-DALSOFT_REQUIRE_COREAUDIO=ON \
|
2022-11-13 17:35:33 +01:00
|
|
|
-DALSOFT_EMBED_HRTF_DATA=ON \
|
|
|
|
-DALSOFT_UTILS=OFF \
|
|
|
|
-DALSOFT_EXAMPLES=OFF \
|
|
|
|
-DALSOFT_BACKEND_WAVE=OFF \
|
|
|
|
-DCMAKE_C_FLAGS_RELEASE="$OSX_FLAGS $OSX_ARCH" \
|
|
|
|
-DCMAKE_CXX_FLAGS_RELEASE="$OSX_FLAGS $OSX_ARCH" \
|
2022-09-25 12:10:27 +02:00
|
|
|
-DCMAKE_OSX_ARCHITECTURES=$OSX_ARCHITECTURES
|
2022-11-13 17:35:33 +01:00
|
|
|
|
2022-01-30 00:10:40 +02:00
|
|
|
cmake --build . -j
|
|
|
|
|
2021-02-12 19:15:39 +01:00
|
|
|
mkdir -p ../openal
|
2022-11-13 17:35:33 +01:00
|
|
|
cp -v libopenal.a ../openal
|
|
|
|
cp -rv include ../openal/include
|
2021-02-12 19:15:39 +01:00
|
|
|
|
|
|
|
echo "OpenAL-Soft build successful"
|