-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Using as dub dependency is quite painful #6
Comments
There is following behavior:
If you change to preBuildCommands, there will be another error message like "No source files found". You can solve this by adding the "src" folder here: Line 5 in 1f2f06a
|
AFAIK, for things to work the first time you build GlibD the command to generate the source needs to be in the pregeneratecommands otherwise dub won't build the generated source. On a second run it picks up the already generated (old) source code and it will usually compile successfully. I don't have time to test it now, but judging from the dub documentation, pregeneratecommands is only executed once, and prebuildcommands is executed on every build, so this might be a dub issue. The src directory doesn't contain any code that should be compiled, so it shouldn't be part of the sourcepaths. |
I also asked this question in dub dlang slack, as I am not an expert here. But what I can see from the Dub source code, preGenerateCommands works straight forward. While the whole project is generated, preGenerateCommands will be executed for each dependency of the whole project, independent whether it is already built or not. |
@MikeWey I created a pull request to align the dub documentation with the actual implementation |
Thanks, i will look at it when i'm back home, next week. |
When working with a clean git checkout, and doing the generation in the The dub example about generating source files also uses |
I have an application which uses GlibD as dependency (as I have created a binding for Parquet).
Every time I compile now my application, it looks like this:
Even if I do not change anything in my application, girtod is build and executed for glibd every time.
This makes the usage of GlibD almost unusable. I wonder whether this could be improved?
The text was updated successfully, but these errors were encountered: