core: do not accept multiple definitions of a package
One of the selling points for br2-external is to provide a mean to add
new packages. However, it is not supported that a package be defined by
Buildroot and then redefined in a br2-external tree.
This situation may occur without the user noticing or even willing to
redefine the package, for example:
- br2-external is first created against a version of Buildroot
- a package (missing in Buildroot) is added to that br2-external tree
- upstream Buildroot adds this package
- user updates to the new Buildroot
In this case, the result in undefined, and we can't make any guarantee
on the result (working or not).
Add a sanity check so that a package redefinition gets caught.
Signed-off-by: "Yann E. MORIN" <[email protected]>
Cc: Thomas Petazzoni <[email protected]>
Cc: Peter Korsgaard <[email protected]>
Cc: Arnout Vandecappelle <[email protected]>
Reviewed-by: Arnout Vandecappelle (Essensium/Mind) <[email protected]>
Reviewed-by: Samuel Martin <[email protected]>
Signed-off-by: Thomas Petazzoni <[email protected]>