CREATE_PROJECT: Add --include-dir and --library-dir
Additional include and library directories can now be added. This is most useful to Xcode Mac projects where a vanilla Homebrew setup requires manually adding five directories through the Xcode UI and then repeating that every time the project needs to be regenerated. Now create_project can be scripted to regenerate a working Mac project without any extra Xcode steps.
This commit is contained in:
parent
f08f2a52fc
commit
c67adbb301
7 changed files with 79 additions and 14 deletions
|
@ -135,6 +135,9 @@ void CodeBlocksProvider::createProjectFile(const std::string &name, const std::s
|
|||
writeWarnings(name, project);
|
||||
writeDefines(setup.defines, project);
|
||||
|
||||
for (StringList::const_iterator i = setup.includeDirs.begin(); i != setup.includeDirs.end(); ++i)
|
||||
project << "\t\t\t\t\t<Add directory=\"" << convertPathToWin(*i) << "\" />\n";
|
||||
|
||||
project << "\t\t\t\t\t<Add directory=\"$(" << LIBS_DEFINE << ")include\" />\n"
|
||||
"\t\t\t\t\t<Add directory=\"$(" << LIBS_DEFINE << ")include\\SDL\" />\n"
|
||||
"\t\t\t\t\t<Add directory=\"..\\..\\engines\" />\n"
|
||||
|
@ -154,6 +157,9 @@ void CodeBlocksProvider::createProjectFile(const std::string &name, const std::s
|
|||
project << "\t\t\t\t\t<Add library=\"" << setup.projectName << "\\engines\\" << i->first << "\\lib" << i->first << ".a\" />\n";
|
||||
}
|
||||
|
||||
for (StringList::const_iterator i = setup.libraryDirs.begin(); i != setup.libraryDirs.end(); ++i)
|
||||
project << "\t\t\t\t\t<Add directory=\"" << convertPathToWin(*i) << "\" />\n";
|
||||
|
||||
project << "\t\t\t\t\t<Add directory=\"$(" << LIBS_DEFINE << ")lib\\mingw\" />\n"
|
||||
"\t\t\t\t\t<Add directory=\"$(" << LIBS_DEFINE << ")lib\" />\n"
|
||||
"\t\t\t\t</Linker>\n";
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue