mirror of
https://github.com/subsurface/subsurface.git
synced 2024-11-28 05:00:20 +00:00
macOS: support newer SDKs
Update to match Xcode command-line-tools SDKs from 10.X to 16.X Signed-off-by: Doug Junkins <douglas.junkins@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
520be78fa8
commit
d537e16cb1
1 changed files with 3 additions and 6 deletions
|
@ -178,14 +178,11 @@ if [ "$PLATFORM" = Darwin ] ; then
|
||||||
exit 1;
|
exit 1;
|
||||||
fi
|
fi
|
||||||
# find a 10.x base SDK to use, or if none can be found, find a numbered 11.x base SDK to use
|
# find a 10.x base SDK to use, or if none can be found, find a numbered 11.x base SDK to use
|
||||||
BASESDK=$(ls $SDKROOT | grep "MacOSX10\.1.\.sdk" | head -1 | sed -e "s/MacOSX//;s/\.sdk//")
|
BASESDK=$(ls $SDKROOT | grep -E "MacOSX1[0-6]\.[0-9]+\.sdk" | head -1 | sed -e "s/MacOSX//;s/\.sdk//")
|
||||||
if [ -z "$BASESDK" ] ; then
|
if [ -z "$BASESDK" ] ; then
|
||||||
BASESDK=$(ls $SDKROOT | grep -E "MacOSX11\.[0-9]+\.sdk" | head -1 | sed -e "s/MacOSX//;s/\.sdk//")
|
echo "Cannot find a base SDK of type 1[0-6].x under the SDK root of ${SDKROOT}"
|
||||||
if [ -z "$BASESDK" ] ; then
|
|
||||||
echo "Cannot find a base SDK of type 10.x or 11.x under the SDK root of ${SDKROOT}"
|
|
||||||
exit 1;
|
exit 1;
|
||||||
fi
|
fi
|
||||||
fi
|
|
||||||
if [ "$ARCHS" != "" ] ; then
|
if [ "$ARCHS" != "" ] ; then
|
||||||
# we do assume that the two architectures mentioned are x86_64 and arm64 .. that's kinda wrong
|
# we do assume that the two architectures mentioned are x86_64 and arm64 .. that's kinda wrong
|
||||||
MAC_CMAKE="-DCMAKE_OSX_DEPLOYMENT_TARGET=${BASESDK} -DCMAKE_OSX_SYSROOT=${SDKROOT}/MacOSX${BASESDK}.sdk/ -DCMAKE_OSX_ARCHITECTURES='x86_64;arm64'"
|
MAC_CMAKE="-DCMAKE_OSX_DEPLOYMENT_TARGET=${BASESDK} -DCMAKE_OSX_SYSROOT=${SDKROOT}/MacOSX${BASESDK}.sdk/ -DCMAKE_OSX_ARCHITECTURES='x86_64;arm64'"
|
||||||
|
|
Loading…
Reference in a new issue