copy libraries as content when bundling

This commit is contained in:
Alex Birch 2018-03-06 00:48:17 +00:00
parent 94da87af2a
commit 63e2c54fc5
No known key found for this signature in database
GPG Key ID: 305EB1F98D44ACBA
7 changed files with 69 additions and 9 deletions

View File

@ -95,7 +95,11 @@
35967471204E0EF800E16BD3 /* OpenGL.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 8DF3DDC4B854DA1F16AD4564 /* OpenGL.framework */; }; 35967471204E0EF800E16BD3 /* OpenGL.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 8DF3DDC4B854DA1F16AD4564 /* OpenGL.framework */; };
35967472204E0EF800E16BD3 /* QuartzCore.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 2FB62D371AA3AB416FCB73CE /* QuartzCore.framework */; }; 35967472204E0EF800E16BD3 /* QuartzCore.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 2FB62D371AA3AB416FCB73CE /* QuartzCore.framework */; };
35967473204E0EF800E16BD3 /* WebKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 4FD107636B29A49B998F03CA /* WebKit.framework */; }; 35967473204E0EF800E16BD3 /* WebKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 4FD107636B29A49B998F03CA /* WebKit.framework */; };
3596747E204E141B00E16BD3 /* libfluidsynth.1.7.1.dylib in CopyFiles */ = {isa = PBXBuildFile; fileRef = 3596747D204E141B00E16BD3 /* libfluidsynth.1.7.1.dylib */; settings = {ATTRIBUTES = (CodeSignOnCopy, ); }; }; 35967480204E186800E16BD3 /* libintl.8.dylib in CopyFiles */ = {isa = PBXBuildFile; fileRef = 3596747F204E186800E16BD3 /* libintl.8.dylib */; settings = {ATTRIBUTES = (CodeSignOnCopy, ); }; };
35967482204E188D00E16BD3 /* libglib-2.0.0.dylib in CopyFiles */ = {isa = PBXBuildFile; fileRef = 35967481204E188D00E16BD3 /* libglib-2.0.0.dylib */; settings = {ATTRIBUTES = (CodeSignOnCopy, ); }; };
35967484204E189C00E16BD3 /* libgthread-2.0.0.dylib in CopyFiles */ = {isa = PBXBuildFile; fileRef = 35967483204E189C00E16BD3 /* libgthread-2.0.0.dylib */; settings = {ATTRIBUTES = (CodeSignOnCopy, ); }; };
35967486204E18B900E16BD3 /* libpcre.1.dylib in CopyFiles */ = {isa = PBXBuildFile; fileRef = 35967485204E18B900E16BD3 /* libpcre.1.dylib */; settings = {ATTRIBUTES = (CodeSignOnCopy, ); }; };
3596748E204E1B3B00E16BD3 /* libfluidsynth.1.7.1.dylib in CopyFiles */ = {isa = PBXBuildFile; fileRef = 3596748D204E1B3B00E16BD3 /* libfluidsynth.1.7.1.dylib */; settings = {ATTRIBUTES = (CodeSignOnCopy, ); }; };
3758E5B3C2288245817A9ECD /* include_juce_audio_processors.mm in Sources */ = {isa = PBXBuildFile; fileRef = D83BE45225B0E49E077E5B87 /* include_juce_audio_processors.mm */; }; 3758E5B3C2288245817A9ECD /* include_juce_audio_processors.mm in Sources */ = {isa = PBXBuildFile; fileRef = D83BE45225B0E49E077E5B87 /* include_juce_audio_processors.mm */; };
3BE4582C1A69CFFDC17790FE /* CoreAudioKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = FB9DC0F378DBE6110579ABEB /* CoreAudioKit.framework */; }; 3BE4582C1A69CFFDC17790FE /* CoreAudioKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = FB9DC0F378DBE6110579ABEB /* CoreAudioKit.framework */; };
4197FB69EAA917C1B9160B32 /* CoreAudio.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 86183C1237DA7A5F2CF41CC7 /* CoreAudio.framework */; }; 4197FB69EAA917C1B9160B32 /* CoreAudio.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 86183C1237DA7A5F2CF41CC7 /* CoreAudio.framework */; };
@ -191,13 +195,17 @@
/* Begin PBXCopyFilesBuildPhase section */ /* Begin PBXCopyFilesBuildPhase section */
3596747A204E0F1100E16BD3 /* CopyFiles */ = { 3596747A204E0F1100E16BD3 /* CopyFiles */ = {
isa = PBXCopyFilesBuildPhase; isa = PBXCopyFilesBuildPhase;
buildActionMask = 8; buildActionMask = 12;
dstPath = ""; dstPath = "";
dstSubfolderSpec = 10; dstSubfolderSpec = 10;
files = ( files = (
3596747E204E141B00E16BD3 /* libfluidsynth.1.7.1.dylib in CopyFiles */, 3596748E204E1B3B00E16BD3 /* libfluidsynth.1.7.1.dylib in CopyFiles */,
35967486204E18B900E16BD3 /* libpcre.1.dylib in CopyFiles */,
35967484204E189C00E16BD3 /* libgthread-2.0.0.dylib in CopyFiles */,
35967482204E188D00E16BD3 /* libglib-2.0.0.dylib in CopyFiles */,
35967480204E186800E16BD3 /* libintl.8.dylib in CopyFiles */,
); );
runOnlyForDeploymentPostprocessing = 1; runOnlyForDeploymentPostprocessing = 0;
}; };
CDF6CC6582C75689BA673A10 /* Embed App Extensions */ = { CDF6CC6582C75689BA673A10 /* Embed App Extensions */ = {
isa = PBXCopyFilesBuildPhase; isa = PBXCopyFilesBuildPhase;
@ -226,8 +234,11 @@
2465FB46F4FBE888A5D785D5 /* include_juce_audio_plugin_client_utils.cpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = include_juce_audio_plugin_client_utils.cpp; path = ../../JuceLibraryCode/include_juce_audio_plugin_client_utils.cpp; sourceTree = SOURCE_ROOT; }; 2465FB46F4FBE888A5D785D5 /* include_juce_audio_plugin_client_utils.cpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = include_juce_audio_plugin_client_utils.cpp; path = ../../JuceLibraryCode/include_juce_audio_plugin_client_utils.cpp; sourceTree = SOURCE_ROOT; };
2FB62D371AA3AB416FCB73CE /* QuartzCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = QuartzCore.framework; path = System/Library/Frameworks/QuartzCore.framework; sourceTree = SDKROOT; }; 2FB62D371AA3AB416FCB73CE /* QuartzCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = QuartzCore.framework; path = System/Library/Frameworks/QuartzCore.framework; sourceTree = SDKROOT; };
33B56FA30952FB33928A557F /* juicysfplugin.appex */ = {isa = PBXFileReference; explicitFileType = "wrapper.app-extension"; includeInIndex = 0; path = juicysfplugin.appex; sourceTree = BUILT_PRODUCTS_DIR; }; 33B56FA30952FB33928A557F /* juicysfplugin.appex */ = {isa = PBXFileReference; explicitFileType = "wrapper.app-extension"; includeInIndex = 0; path = juicysfplugin.appex; sourceTree = BUILT_PRODUCTS_DIR; };
3596747B204E0F7F00E16BD3 /* libfluidsynth.1.7.1.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; path = libfluidsynth.1.7.1.dylib; sourceTree = "<group>"; }; 3596747F204E186800E16BD3 /* libintl.8.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; path = libintl.8.dylib; sourceTree = "<group>"; };
3596747D204E141B00E16BD3 /* libfluidsynth.1.7.1.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; name = libfluidsynth.1.7.1.dylib; path = "../../../../../../usr/local/Cellar/fluid-synth/1.1.10/lib/libfluidsynth.1.7.1.dylib"; sourceTree = "<group>"; }; 35967481204E188D00E16BD3 /* libglib-2.0.0.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; path = "libglib-2.0.0.dylib"; sourceTree = "<group>"; };
35967483204E189C00E16BD3 /* libgthread-2.0.0.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; path = "libgthread-2.0.0.dylib"; sourceTree = "<group>"; };
35967485204E18B900E16BD3 /* libpcre.1.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; path = libpcre.1.dylib; sourceTree = "<group>"; };
3596748D204E1B3B00E16BD3 /* libfluidsynth.1.7.1.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; name = libfluidsynth.1.7.1.dylib; path = "../../../../../../usr/local/Cellar/fluid-synth/1.1.10/lib/libfluidsynth.1.7.1.dylib"; sourceTree = "<group>"; };
379C84D5A55C1857A91CBC40 /* juce_audio_plugin_client */ = {isa = PBXFileReference; lastKnownFileType = folder; name = juce_audio_plugin_client; path = /Applications/JUCE/modules/juce_audio_plugin_client; sourceTree = "<absolute>"; }; 379C84D5A55C1857A91CBC40 /* juce_audio_plugin_client */ = {isa = PBXFileReference; lastKnownFileType = folder; name = juce_audio_plugin_client; path = /Applications/JUCE/modules/juce_audio_plugin_client; sourceTree = "<absolute>"; };
3B0BE48E8B34519259BA931D /* AudioUnit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AudioUnit.framework; path = System/Library/Frameworks/AudioUnit.framework; sourceTree = SDKROOT; }; 3B0BE48E8B34519259BA931D /* AudioUnit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AudioUnit.framework; path = System/Library/Frameworks/AudioUnit.framework; sourceTree = SDKROOT; };
3B1AE50061C46417C2C4E30D /* FluidSynthModel.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; name = FluidSynthModel.h; path = ../../Source/FluidSynthModel.h; sourceTree = SOURCE_ROOT; }; 3B1AE50061C46417C2C4E30D /* FluidSynthModel.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; name = FluidSynthModel.h; path = ../../Source/FluidSynthModel.h; sourceTree = SOURCE_ROOT; };
@ -570,8 +581,11 @@
FF6BE0B0C430808BA4FD975F /* Source */ = { FF6BE0B0C430808BA4FD975F /* Source */ = {
isa = PBXGroup; isa = PBXGroup;
children = ( children = (
3596747B204E0F7F00E16BD3 /* libfluidsynth.1.7.1.dylib */, 3596748D204E1B3B00E16BD3 /* libfluidsynth.1.7.1.dylib */,
3596747D204E141B00E16BD3 /* libfluidsynth.1.7.1.dylib */, 35967485204E18B900E16BD3 /* libpcre.1.dylib */,
35967483204E189C00E16BD3 /* libgthread-2.0.0.dylib */,
35967481204E188D00E16BD3 /* libglib-2.0.0.dylib */,
3596747F204E186800E16BD3 /* libintl.8.dylib */,
48F8550CF03FCF8FD358D1C0 /* juicysfplugin.entitlements */, 48F8550CF03FCF8FD358D1C0 /* juicysfplugin.entitlements */,
0007E2E1FEE2BAEC9D55BA62 /* juicysfplugin */, 0007E2E1FEE2BAEC9D55BA62 /* juicysfplugin */,
58957C3FD57D051F86CA1D6D /* JUCE Modules */, 58957C3FD57D051F86CA1D6D /* JUCE Modules */,

Binary file not shown.

Binary file not shown.

Binary file not shown.

BIN
Builds/MacOSX/libintl.8.dylib Executable file

Binary file not shown.

Binary file not shown.

View File

@ -13,3 +13,49 @@ We can rewrite this dynamic link like so:
```bash ```bash
install_name_tool -change /usr/local/opt/fluid-synth/lib/libfluidsynth.1.dylib @executable_path/../Frameworks/libfluidsynth.1.dylib /Users/birch/git/juicysfplugin/Builds/MacOSX/build/Release/juicysfplugin.app/Contents/MacOS/juicysfplugin install_name_tool -change /usr/local/opt/fluid-synth/lib/libfluidsynth.1.dylib @executable_path/../Frameworks/libfluidsynth.1.dylib /Users/birch/git/juicysfplugin/Builds/MacOSX/build/Release/juicysfplugin.app/Contents/MacOS/juicysfplugin
``` ```
## dependencies
We'll need:
> glib and gthread, but also iconv and intl
https://lists.nongnu.org/archive/html/fluid-dev/2012-03/msg00032.html
I already added to XCode target "standalone plugin" a "copy files" build phase, which copies the following into Frameworks:
```
/usr/local/Cellar/glib/2.54.3/lib/libglib-2.0.0.dylib
/usr/local/opt/glib/lib/libgthread-2.0.0.dylib
/usr/local/opt/pcre/lib/libpcre.1.dylib
/usr/local/opt/gettext/lib/libintl.8.dylib
/usr/local/Cellar/fluid-synth/1.1.10/lib/libfluidsynth.1.7.1.dylib
```
# Licenses
## `libintl` LGPL
https://www.gnu.org/software/gettext/manual/html_node/Licenses.html
> either version 2.1 of the License, or (at your option) any later version.
## `libglib` LGPL
> either version 2.1 of the License, or (at your option) any later version.
## `libgthread` LGPL
> either version 2.1 of the License, or (at your option) any later version.
## `libpcre` BSD
> Release 8 of PCRE is distributed under the terms of the "BSD" licence.
## `libfluidsynth` LGPL
https://github.com/FluidSynth/fluidsynth/blob/master/LICENSE
> (This is the first released version of the Lesser GPL. It also counts as the successor of the GNU Library Public License, version 2, hence the version number 2.1.)