[vlc-commits] apple: build: export -m{OS}-version-min in LDFLAGS

Alexandre Janniaux git at videolan.org
Sun May 3 01:05:10 CEST 2020


vlc | branch: master | Alexandre Janniaux <ajanni at videolabs.io> | Mon Apr 27 14:22:22 2020 +0200| [b2dc96da888b4b9c8b37fd9af3c5663f876bb5ae] | committer: Alexandre Janniaux

apple: build: export -m{OS}-version-min in LDFLAGS

Vanilla clang doesn't seem to take the -Wl,--ios-version-min flag into
account and adding this flag doesn't break apple clang build.

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=b2dc96da888b4b9c8b37fd9af3c5663f876bb5ae
---

 extras/package/apple/build.sh | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/extras/package/apple/build.sh b/extras/package/apple/build.sh
index 6e2171623b..beac4449b6 100755
--- a/extras/package/apple/build.sh
+++ b/extras/package/apple/build.sh
@@ -309,7 +309,8 @@ set_host_envvars()
     export CXXFLAGS="$clike_flags"
     export OBJCFLAGS="$clike_flags"
 
-    export LDFLAGS="$VLC_DEPLOYMENT_TARGET_LDFLAG -arch $VLC_HOST_ARCH"
+    # Vanilla clang doesn't use VLC_DEPLOYMENT_TAGET_LDFLAGS but only the CFLAGS variant
+    export LDFLAGS="$VLC_DEPLOYMENT_TARGET_LDFLAG $VLC_DEPLOYMENT_TARGET_CFLAG -arch $VLC_HOST_ARCH"
 }
 
 hostenv()
@@ -345,7 +346,8 @@ write_config_mak()
     local vlc_cxxflags="$clike_flags"
     local vlc_objcflags="$clike_flags"
 
-    local vlc_ldflags="$VLC_DEPLOYMENT_TARGET_LDFLAG -arch $VLC_HOST_ARCH"
+    # Vanilla clang doesn't use VLC_DEPLOYMENT_TAGET_LDFLAGS but only the CFLAGS variant
+    local vlc_ldflags="$VLC_DEPLOYMENT_TARGET_LDFLAG $VLC_DEPLOYMENT_TARGET_CFLAG  -arch $VLC_HOST_ARCH"
 
     echo "Creating makefile..."
     test -e config.mak && unlink config.mak



More information about the vlc-commits mailing list