Project Tool include
-
Hi,
I need to add some library includes to a plugin, outside the sources folder, so I'm using and the
Include=
, I see a few improvements to make it much better.-
We have to specify file by file, there's no way to include a complete folder. I have only 20 sources, but some libraries have dozens or hundreds of includes that should be listed one by one. Imagine if we need to upgrade the lib, having to check it all what's new and what's gone. It shouldn't be that painful.
-
The folder include option should be recursive or not recursive.
-
If I just use
Include=
, it does not work. It has to beInclude.OSX=
orInclude.Win64=
. Having the ability to add per platform is great, but in most cases the sources are common to all platforms. I'm adding around 20 sources, duplicating them all. This is unnecessary and prone to error. -
In XCode, there's one group for each included folder files, would be much better if the groups were created hierarchically. Example, instead of having 2 groups like
/xxxx/include
and/xxx/include/math
, amath
group inside/xxx/include
group is much better. Edit: Ok, it seems to be hierarchical, but with the full path name in the group name, and file names in lowercase. -
Those groups could be inside the
sources
group, or everything into oneIncludes
group.
I can include everything I need right now, but instead of writing a few simple and clear lines, I'm writing 40, checking path by path, with duplicates...
-
-
Hello,
just to be sure: what do you mean with "includes"?
Do you want to add source code files to your project (.cpp) or do you want to use header files (.h)?
If you just want to use header files you don't have to add them to your project. You can just define additional include directories:
// Visual Studio AdditionalIncludeDirectories=../../mylib/include // Xcode USER_HEADER_SEARCH_PATHS=../../mylib/include
See Visual Studio Specific and Xcode Specific.
best wishes,
Sebastian -
@s_bach I want to be able to browse, search or edit the sources, so they need to be in the project.
I'm also missing additional compile options for OSX. Maybe letting us set a xcconfig for the target would be nice catch-all alternative.
-
Hello,
what compile options exactly are you missing?
best wishes,
Sebastian -
Initially I wanted to disable no-rtti, but I found a solution without having to change it.
But I think we should be able to set anything we want in the project from the project definition file. What I used to do in pre-R20 is to have a xcconfig file for the project and assign it to the target. It works very well, allows me to setup anything I want in the project without having to touch the project settings.
-
After some more time on a new R20 plugin, there's a few more things I miss in the Project Tool project generator. I'm assuming that we should never have to touch the generated project settings, or next generation will lose those manual changes.
- Please add
.res
and.str
file from the res folder to the generated project. We need to edit them even too. - Preserve the project name case. The generated project name is always lowercase.
- Preserve the original file name case. Sources added with
Include
are lower case in the project. Any edit on those files will change the actual file name to lowercase too. - Include command for all platforms, when not specified. (
Include=file.cpp
) - Include command accepts full folder contents. (
Include=../folder/
) - Add a custom
.xcconfig
and.props
to the target. - If no xcconfig, at least OTHER_CPLUSPLUSFLAGS (mac).
- Add post build phases to the project. At least add a custom Run Script that runs a specified script so we can properly install the plugin.
- Add a Release build schema to the XCode project.
- Specify the location of the Cinema 4D app/exe and add it to the Run command.
- Add
projectdefinition.txt
to the generated project. Why open it in a separated editor when we need to change it later? - Allow to include any kind of file to the project. I try to add a
.sh
shell script and it just won't - (bug) XCode project gets corrupted if we add a file twice with Include.
Good to have:
- Do not use the full path in hierarchical included groups, they can get too big. Only the final folder name is enough.
- Put all additional included sources into one group, hierarchically.
- Please add
-
@rsodre said in Project Tool include:
I'm assuming that we should never have to touch the generated project settings, or next generation will lose those manual changes.
I can at least answer that.
No, manual changes don't get lost if not crucial for working properly. For example, debugging commands, Post-Build directives and so on stay in your solution. I was very suprised about that and I'm rellay glad to have it this way.Add a Release build schema to the XCode project.
What do you mean? Just switch to release and compile.
Specify the location of the Cinema 4D app/exe and add it to the Run command.
Good idea.
-
@mp5gosu said in Project Tool include:
What do you mean? Just switch to release and compile.
There's no such thing in XCode anymore. We can build for release using Archive or Build For Profiling, but we can't Run as release.
-
Hi,
we have forwarded your ideas and suggestions toi our development.
Add post build phases to the project. At least add a custom Run Script that runs a specified script so we can properly install the plugin.
While I do see use cases for a post-build script/step option, it may not be needed for the purpose of installing a plugin. After all in R20 plugins can be located in arbitrary locations (like for example your project directory). You just need to add these locations via either preferences or via environment variable or command line option.
(bug) XCode project gets corrupted if we add a file twice with Include.
I'm not sure if I can follow here. Can you please check, if you are also lacking a release build option, if you run the project tool on a freshly unpacked sdk.zip?
Actually you should have all the options shown in the screenshot below:Cheers,
Andreas