[
Date Prev][
Date Next][
Thread Prev][
Thread Next][
Date Index][
Thread Index]
[
List Home]
Re: [cdt-dev] What exactly is CDT core build?
|
A couple of observations about these random IDs from my years of fighting them, in managed-build projects where we need to apply programmatically generated settings to the .cproject and keep them up to date, which tends to involve removing and recreating build objects:
- The random number parts can't be any strings, they need to be numbers, because ManagedBuildManager.calculateBaseId() expects them that way (I don't remember what it's used for). They can be less random though, in one place we use our product IDs (SKUs) to make configurations for the same hardware target always get the same numbers, as far as unique.
- From a lenghty commit message (https://gitlab.indel.ch/indel-public/idev/-/commit/441645e):
"Getting rid of the random numbers entirely was considered infeasible, because the function responsible for them, ManagedBuildManager.calculateChildId(), does not receive enough information to generate anything more meaningful (e.g. hash of holder and superclass IDs) and is called from tons of locations all over CDT, and the IDs do need to be unique across the whole workspace because of the PropertyManager."
I'm a bit skeptical of the last bit because when I look at the code now, o.e.cdt.managedbuilder.internal.core.PropertyManager does seem to take project and configuration ID into account, but maybe that has changed or I'm missing something. (But there is another design issue with the PropertyManager mentioned elswehere in that commit message and diff.)
-Christian