Browse Source

Android: Added binary location support when building Android static libraries

tags/2021-05-28
hogliux 7 years ago
parent
commit
224bed4c86
1 changed files with 13 additions and 0 deletions
  1. +13
    -0
      extras/Projucer/Source/ProjectSaving/jucer_ProjectExport_Android.h

+ 13
- 0
extras/Projucer/Source/ProjectSaving/jucer_ProjectExport_Android.h View File

@@ -467,8 +467,21 @@ private:
mo << (first ? "IF" : "ELSEIF") << "(JUCE_BUILD_CONFIGURATION MATCHES \"" << cfg.getProductFlavourCMakeIdentifier() <<"\")" << newLine;
if (isLibrary())
{
mo << " SET(BINARY_NAME \"" << getNativeModuleBinaryName (cfg) << "\")" << newLine;
auto binaryLocation = cfg.getTargetBinaryRelativePathString();
if (binaryLocation.isNotEmpty())
{
auto locationRelativeToCmake = RelativePath (binaryLocation, RelativePath::projectFolder)
.rebased (getProject().getFile().getParentDirectory(),
file.getParentDirectory(), RelativePath::buildTargetFolder);
mo << " SET(CMAKE_ARCHIVE_OUTPUT_DIRECTORY \"" << "../../../../" << locationRelativeToCmake.toUnixStyle() << "\")" << newLine;
}
}
writeCmakePathLines (mo, " ", "link_directories(", libSearchPaths);
if (cfgDefines.size() > 0)


Loading…
Cancel
Save