[vlc-devel] [PATCH 2/3] macOS packaging: Add target to package an sdk version for macOS

david.fuhrmann at gmail.com david.fuhrmann at gmail.com
Mon Dec 2 10:05:16 CET 2019

From: David Fuhrmann <dfuhrmann at videolan.org>

This adds a separate target to add an SDK version of the macOS
binaries. This package is the result of a destroot'ed 'make install'

It shall serve two purposes:

1) Out of tree modules compilation: Module authors can use the included
pkgconfig files to link against libvlc(core) for their own modules.
This is similar to the existing SDK we have on Windows.

2) Packaging libvlc for our own app: If someone does not want to use
VLCKit, but links against libvlc directly, these precompiled artefacts
can be used for packaging the libs into the own app. Packaging shall
be done in the same way as with VLC.app (i.e.: lib/* and the vlc plugins
directory goes to Contents/Frameworks, share/ goes to
Contents/Resources/share/ if needed). In this case, all ressources are
found by libvlc automatically.

Users can also execute vlc directly from the extracted tarball, after
specifying LD_LIBRARY_PATH and VLC_PLUGIN_PATH. Using the macOS UI
module is not supported.
 extras/package/macosx/package.mak | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/extras/package/macosx/package.mak b/extras/package/macosx/package.mak
index 9be48169a4ea..f1a84e413d16 100644
--- a/extras/package/macosx/package.mak
+++ b/extras/package/macosx/package.mak
@@ -65,6 +65,10 @@ endif
 	find $@ -type d -exec chmod ugo+rx '{}' \;
 	find $@ -type f -exec chmod ugo+r '{}' \;
+package-macosx-sdk: macos-install
+	rm -f "$(top_builddir)/vlc-macos-sdk-$(VERSION).tar.gz"
+	tar -cf - --exclude "usr/share/macosx" -C "$(macos_destdir)" . \
+		| gzip -c > "$(top_builddir)/vlc-macos-sdk-$(VERSION).tar.gz"
 package-macosx: VLC.app
 	rm -f "$(top_builddir)/vlc-$(VERSION).dmg"
2.21.0 (Apple Git-122.2)

More information about the vlc-devel mailing list