diff --git a/extras/Introjucer/Source/Project Saving/jucer_ProjectExport_Android.h b/extras/Introjucer/Source/Project Saving/jucer_ProjectExport_Android.h index 4ccb52a6ad..320b53791b 100644 --- a/extras/Introjucer/Source/Project Saving/jucer_ProjectExport_Android.h +++ b/extras/Introjucer/Source/Project Saving/jucer_ProjectExport_Android.h @@ -439,29 +439,17 @@ private: out << " LOCAL_CPPFLAGS += " << createCPPFlags (androidConfig) << (" " + replacePreprocessorTokens (androidConfig, getExtraCompilerFlagsString()).trim()).trimEnd() << newLine - << getDynamicLibs (androidConfig); + << getLDLIBS (androidConfig); break; } } } - String getDynamicLibs (const AndroidBuildConfiguration& config) const + String getLDLIBS (const AndroidBuildConfiguration& config) const { - String flags (" LOCAL_LDLIBS :="); - - flags << config.getGCCLibraryPathFlags(); - - { - StringArray libs; - libs.add ("log"); - libs.add ("GLESv2"); - - for (int i = 0; i < libs.size(); ++i) - flags << " -l" << libs[i]; - } - - return flags + newLine; + return " LOCAL_LDLIBS :=" + config.getGCCLibraryPathFlags() + + " -llog -lGLESv2 " + getExternalLibraryFlags (config) + newLine; } String createIncludePathFlags (const BuildConfiguration& config) const diff --git a/extras/Introjucer/Source/Project Saving/jucer_ProjectExport_XCode.h b/extras/Introjucer/Source/Project Saving/jucer_ProjectExport_XCode.h index 5f0465d17a..ff48be0824 100644 --- a/extras/Introjucer/Source/Project Saving/jucer_ProjectExport_XCode.h +++ b/extras/Introjucer/Source/Project Saving/jucer_ProjectExport_XCode.h @@ -618,13 +618,7 @@ private: getLinkerFlagsForStaticLibrary (extraLibs.getReference(i), flags, librarySearchPaths); flags.add (replacePreprocessorTokens (config, getExtraLinkerFlagsString())); - - StringArray libraries; - libraries.addTokens (getExternalLibrariesString(), ";", "\"'"); - libraries.removeEmptyStrings (true); - - if (libraries.size() != 0) - flags.add (replacePreprocessorTokens (config, "-l" + libraries.joinIntoString (" -l")).trim()); + flags.add (getExternalLibraryFlags (config)); flags.removeEmptyStrings (true); } diff --git a/extras/Introjucer/Source/Project Saving/jucer_ProjectExporter.cpp b/extras/Introjucer/Source/Project Saving/jucer_ProjectExporter.cpp index 5509a1e154..65d3ffcb47 100644 --- a/extras/Introjucer/Source/Project Saving/jucer_ProjectExporter.cpp +++ b/extras/Introjucer/Source/Project Saving/jucer_ProjectExporter.cpp @@ -577,3 +577,15 @@ String ProjectExporter::BuildConfiguration::getGCCLibraryPathFlags() const return s; } + +String ProjectExporter::getExternalLibraryFlags (const BuildConfiguration& config) const +{ + StringArray libraries; + libraries.addTokens (getExternalLibrariesString(), ";", "\"'"); + libraries.removeEmptyStrings (true); + + if (libraries.size() != 0) + return replacePreprocessorTokens (config, "-l" + libraries.joinIntoString (" -l")).trim(); + + return String::empty; +} diff --git a/extras/Introjucer/Source/Project Saving/jucer_ProjectExporter.h b/extras/Introjucer/Source/Project Saving/jucer_ProjectExporter.h index 3c404cc386..092e068381 100644 --- a/extras/Introjucer/Source/Project Saving/jucer_ProjectExporter.h +++ b/extras/Introjucer/Source/Project Saving/jucer_ProjectExporter.h @@ -220,6 +220,8 @@ public: bool hasConfigurationNamed (const String& name) const; String getUniqueConfigName (String name) const; + String getExternalLibraryFlags (const BuildConfiguration& config) const; + //============================================================================== struct ConfigIterator { diff --git a/modules/juce_data_structures/values/juce_ValueTree.cpp b/modules/juce_data_structures/values/juce_ValueTree.cpp index 35a7f7e095..8539165c74 100644 --- a/modules/juce_data_structures/values/juce_ValueTree.cpp +++ b/modules/juce_data_structures/values/juce_ValueTree.cpp @@ -779,9 +779,8 @@ class ValueTreePropertyValueSource : public Value::ValueSource, private ValueTree::Listener { public: - ValueTreePropertyValueSource (const ValueTree& tree_, const Identifier& property_, - UndoManager* const undoManager_) - : tree (tree_), property (property_), undoManager (undoManager_) + ValueTreePropertyValueSource (const ValueTree& vt, const Identifier& prop, UndoManager* um) + : tree (vt), property (prop), undoManager (um) { tree.addListener (this); }