diff options
author | dec05eba <dec05eba@protonmail.com> | 2017-12-28 01:21:13 +0100 |
---|---|---|
committer | dec05eba <dec05eba@protonmail.com> | 2017-12-28 01:27:11 +0100 |
commit | bcd3c09fc6f4264108e0e658122515b50db29c77 (patch) | |
tree | 8a3de84a800a5295a5f09d9b5943ac386802beaa /src/main.cpp | |
parent | 0cf81a4421f9a4d267245a3041508b617a01d68d (diff) |
Add package include dirs config
Fix getRealPath returning corrupt path.
This allows you to specifying a list of include dirs under [package], like:
[package]
name = "blabla"
include_dirs = ["include"]
There are many libraries that include paths to header files like this,
so when including a header file, you dont have to specify relative path
to header files (which can be long), and you can use same path
no matter where you are including header from.
Currently include_dirs is not propagated to dependant packages
and im not sure if they should be, from the looks of it the reason
you want include_dirs is internal package setup.
Diffstat (limited to 'src/main.cpp')
-rw-r--r-- | src/main.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/main.cpp b/src/main.cpp index e645b70..79d4d9d 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -300,7 +300,7 @@ int newProject(int argc, const char **argv) newProjectCreateConf(projectName, projectTypeConf, projectPath); createProjectSubDir(projectPath + "/src"); createProjectSubDir(projectPath + "/include"); - createProjectFile(projectPath + "/src/main.cpp", "#include <cstdio>\n\nint main()\n{ return 0;\n}\n"); + createProjectFile(projectPath + "/src/main.cpp", "#include <cstdio>\n\nint main()\n{\n return 0;\n}\n"); // We are ignoring git init result on purpose. If it fails, just ignore it; not important gitInitProject(projectPath); return 0; |