Open-CMSIS-Pack / devtools

Open-CMSIS-Pack development tools - C++
Apache License 2.0
70 stars 51 forks source link

[packchk] Add validation that a source module cannot be concurrently added to a project by multiple components #1499

Open jkrech opened 2 months ago

jkrech commented 2 months ago

Describe The Problem To Be Solved For a successful build of a project all source modules must be unique. In case a project selects two components referencing the identical source module this can lead to duplicated objects causing errors at link time and is considered incorrect software design.

Suggest A Solution Add a validation step for all component's <file> elements with attribute category= in (library, object, source, sourceC, sourceCpp, sourceAsm, genSource) a) finding identical references to files in the pack b) checking whether they belong to component's that can be selected concurrently