Not sure whether to issue this as a bug or feature request.
In my dll project I have an .rc file which depends on resource.xml in the following line:
IDR_GMPXML1 GMPXML "resource.xml"
C::B insists ignoring this, and inside the .depend file it only lists resource.h and windows.h as dependencies.
I have therefore to always add resource.xml by hand to the .depend file, but the .depend file gets
automatically rebuilt by CB from time to time, so I have to edit it everytime this happens, which
is quite frustrating.
I kindly ask you to fix this, thank you very much
Really, can't you have a look on this ? For my workflow it is very frustrating! Thanks
Can you create a minimal project and upload it?
I did my best, find it attached. Please note that it doesn't really produce anything useful or useable. As you can easily see, resource.rc contains references to resource.h, resource.xml and windows.h. But look at the .depend file generated by codeblocks: only resource.h and windows.h are listed, not the .xml which is a key part. So I have to add it manually to the .depend file everytime. Thank you very much for investigating ! Ps if you think this is not a bug and one should rather specify the missing xml somewhere in the project setting please let me know, I simply could not figure out a way. Thx
To elaborate better, I have to modify the xml file very often. But from time to time, CB rebuilds the .depend file, and the result is that I compile the project but I then realize it doesn't work, because CB thinks that the resource.rc is up to date ( by rebuilding the .depend it drops the resource.xml which I am forced to add by hand) and therefore it does not invoke the resource compiler on it. So I have to edit the .depend file and add resource.xml under the dependencies of resource.rc everytime
Have you tried Project->Properties->Build targets->Select you target on the left->Dependencies->External dependency files->Add your xml file
Sorry I deleted my previous comment written in a rush of enthusiasm. I thought it worked but nope. If I specify the .xml in the external dependencies, the project gets just re-linked but the resource.rc does NOT get recompiled. Indeed, if those are named "external" there was a reason. It seemed too good to be true. The only solution by now is "touching" resource.rc as a pre-build action. Dirty, but works. CB simply cannot detect that resource.rc depends on resource.xml and it looks like there is no way to force this manually
Last edit: Elena 2023-03-30