User forums > Nightly builds

The 12 February 2023 build (13205) is out.

<< < (2/5) > >>

killerbot:
there is an unwanted change to the cbp file, when using the glob feature, I think there are 2 things wrong:
* it should not be enumerating al the files, the goal is to keep the cbp stable and it picks up all the files within the specified glob directories, the cbp file is also in version control systems, one does not want this to change, this is totally the opposite of the goal of the feature when I added this
* next to this it seems to have bugs with those IDs as you can see below (but since this must disappear wrt the first remark, it will be solved by design :-) )


--- Code: ---
-               <UnitsGlob directory="../export/" recursive="1" wildcard="" />
-               <UnitsGlob directory="../local/" recursive="1" wildcard="" />
+               <UnitsGlob directory="../export/" wildcard="" recursive="1" id="769713912" />
+               <UnitsGlob directory="../local/" wildcard="" recursive="1" id="3282429397" />
+               <Unit filename="../export/RepeatingTask/RepeatingTaskFactory.h">
+                       <Option glob="769713912" />
+               </Unit>
+               <Unit filename="../export/RepeatingTask/RepeatingTaskIf.h">
+                       <Option glob="769713912" />
+               </Unit>
+               <Unit filename="../local/RepeatingTask.cpp">
+                       <Option glob="-1012537899" />
+               </Unit>
+               <Unit filename="../local/RepeatingTask.h">
+                       <Option glob="-1012537899" />
+               </Unit>
+               <Unit filename="../local/RepeatingTaskFactory.cpp">
+                       <O

--- End code ---
the 2 ids handed out to the to directories : the oned used for export is reused for files underneath that directory, but the one for local is not used, instead those files end up with a negative ID.

But as said, there should be no enumeration of files in the cbp in this case, and those IDs and I also not sure if this is a wanted feature...

If for some reason as a role of caching this list would be needed, then I would suggest to put it in the layout file, or create an extra similar 'temporary' file.


EDIT : even a third problem is present, when opening the cbp file again, just rebuild everything, again it said the cbp file was changed (while it had it nicely saved the previous time it told me this).

BlueHazzard:
My point of view is, that the project file is like a make file. You have to modify a makefile if you add source files to be able to build it.
If you do not add them to the project we have some problems:
1) you can not modify properties of them: Only build with certain build targets ecc.
2) I had other problems with the old implementation, i can not remember any more exactly (it is a 3 years), i think code completion did not work correctly...

We have discussed this with the problems of the original implementation here: http://forums.codeblocks.org/index.php/topic,22783.msg154862/topicseen.html

My opinion on this: This feature was never/seldom used by user before, because it had no ui/documentation. So the risk of breaking some project files is minimal. I also pointed this out in the announcement post (https://forums.codeblocks.org/index.php/topic,25276.0.html). Now it has UI and documentation and we can expect it to be used... I for example need it for an upcoming plugin i currently am working on...
If you are absolutely against this implementation i can try to look into it and add some flag for old and new behaviour?

I will look into the problems with the ids. Thank you for testing and pointing it out.

Xaviou:
Hi


--- Quote from: BlueHazzard on February 12, 2023, 05:53:20 pm ---Fixed in trunk, thank you!

--- End quote ---
Rev 13209 build fine : thank you

Regards
Xav'

killerbot:

--- Quote from: BlueHazzard on February 12, 2023, 08:11:35 pm ---My point of view is, that the project file is like a make file. You have to modify a makefile if you add source files to be able to build it.
If you do not add them to the project we have some problems:
1) you can not modify properties of them: Only build with certain build targets ecc.
2) I had other problems with the old implementation, i can not remember any more exactly (it is a 3 years), i think code completion did not work correctly...

We have discussed this with the problems of the original implementation here: http://forums.codeblocks.org/index.php/topic,22783.msg154862/topicseen.html

My opinion on this: This feature was never/seldom used by user before, because it had no ui/documentation. So the risk of breaking some project files is minimal. I also pointed this out in the announcement post (https://forums.codeblocks.org/index.php/topic,25276.0.html). Now it has UI and documentation and we can expect it to be used... I for example need it for an upcoming plugin i currently am working on...
If you are absolutely against this implementation i can try to look into it and add some flag for old and new behavior?

I will look into the problems with the ids. Thank you for testing and pointing it out.

--- End quote ---


When I created this feature, long time ago, the intention is to mimic the glob feature of cmake. We have been relying on this feature extensively, and indeed it is not documented, since one needs to know how to use it, it has limitations, eg when new file is added, one needs to reload the project  to pick up the new files. Code completion works, but not always, but with the old code completion plug-in it also worked like this, sometimes yes, sometimes no, but I can indeed think with this glob it is a bit worse.


Now that said, the cmake world is also no longer in favor of their glob feature (it also has some problems), and want sources to be explicitly added. Which we could translate to CB as :

* we also don't want this feature
* we remove both new and old behavior
* we keep the old behavior as is for backwards compatibility
I do think we need to keep the old behavior for backwards compatibility, since it was there to mimic cmake glob (and then you also did not have to touch the CMakeLists.txt anymore), this needs to be re-instated, because overhere everything is now collapsing.

So please provide the old way, and when the new way is wanted, have CB add per directory an extra flag to say new behavior (old behavior should need no changes to be made by the user), absence of this flag means old behavior.

killerbot:
I will copy this post in the other thread, so we can continue talking about it there.

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version