Browse Source

Added Rez files to JuceLibraryCode so that they are compiled when not browsable

tags/2021-05-28
tpoole 8 years ago
parent
commit
0b2257c53d
4 changed files with 26 additions and 5 deletions
  1. +6
    -0
      extras/Projucer/Source/Project Saving/jucer_ProjectExport_XCode.h
  2. +12
    -2
      extras/Projucer/Source/Project Saving/jucer_ProjectSaver.h
  3. +6
    -1
      extras/Projucer/Source/Project/jucer_Module.cpp
  4. +2
    -2
      extras/Projucer/Source/Utility/jucer_FileHelpers.h

+ 6
- 0
extras/Projucer/Source/Project Saving/jucer_ProjectExport_XCode.h View File

@@ -1206,6 +1206,12 @@ public:
StringArray paths (owner.extraSearchPaths);
paths.addArray (config.getHeaderSearchPaths());
paths.addArray (getTargetExtraHeaderSearchPaths());
// Always needed to compile .r files
paths.add (owner.getModuleFolderRelativeToProject ("juce_audio_plugin_client")
.rebased (owner.projectFolder, owner.getTargetFolder(), RelativePath::buildTargetFolder)
.toUnixStyle());
paths.add ("$(inherited)");
paths = getCleanedStringArray (paths);


+ 12
- 2
extras/Projucer/Source/Project Saving/jucer_ProjectSaver.h View File

@@ -527,9 +527,19 @@ private:
mem << "*/" << newLine
<< newLine
<< "#include " << project.getAppConfigFilename().quoted() << newLine
<< "#include <" << module.getID() << "/" << cu.file.getFileName() << ">" << newLine;
<< "#include <";
replaceFileIfDifferent (generatedCodeFolder.getChildFile (cu.file.getFileName()), mem);
auto moduleWrapperFilename = cu.file.getFileName();
// .r files require a different include scheme, with a different file name
if (cu.file.getFileExtension() == ".r")
moduleWrapperFilename = cu.file.getFileNameWithoutExtension() + "_r.r";
else
mem << module.getID() << "/";
mem << cu.file.getFileName() << ">" << newLine;
replaceFileIfDifferent (generatedCodeFolder.getChildFile (moduleWrapperFilename), mem);
}
}
}


+ 6
- 1
extras/Projucer/Source/Project/jucer_Module.cpp View File

@@ -506,7 +506,12 @@ void LibraryModule::findAndAddCompiledUnits (ProjectExporter& exporter,
if (cu.isNeededForExporter (exporter))
{
File localFile = exporter.getProject().getGeneratedCodeFolder().getChildFile (cu.file.getFileName());
// .r files require a different include scheme, with a different file name
auto filename = cu.file.getFileName();
if (cu.file.getFileExtension() == ".r")
filename = cu.file.getFileNameWithoutExtension() + "_r.r";
File localFile = exporter.getProject().getGeneratedCodeFolder().getChildFile (filename);
result.add (localFile);
if (projectSaver != nullptr)


+ 2
- 2
extras/Projucer/Source/Utility/jucer_FileHelpers.h View File

@@ -53,14 +53,14 @@ namespace FileHelpers
}
//==============================================================================
const char* const sourceFileExtensions = "cpp;mm;m;c;cc;cxx;swift;s;asm";
const char* const sourceFileExtensions = "cpp;mm;m;c;cc;cxx;swift;s;asm;r";
const char* const headerFileExtensions = "h;hpp;hxx;hh;inl";
const char* const cOrCppFileExtensions = "cpp;cc;cxx;c";
const char* const cppFileExtensions = "cpp;cc;cxx";
const char* const objCFileExtensions = "mm;m";
const char* const asmFileExtensions = "s;S;asm";
const char* const sourceOrHeaderFileExtensions = "cpp;mm;m;c;cc;cxx;swift;s;S;asm;h;hpp;hxx;hh;inl";
const char* const browseableFileExtensions = "cpp;mm;m;c;cc;cxx;swift;s;S;asm;r;h;hpp;hxx;hh;inl;txt;md;rtf";
const char* const browseableFileExtensions = "cpp;mm;m;c;cc;cxx;swift;s;S;asm;h;hpp;hxx;hh;inl;txt;md;rtf";
const char* const fileTypesToCompileByDefault = "cpp;mm;c;m;cc;cxx;swift;s;S;asm;r";
//==============================================================================


Loading…
Cancel
Save