CPack/productbuild: product identifier not set
As seen here, the productbuild CPack generator never sends the optional --identifier
flag to productbuild
. I am not certain what the macOS packaging subsystem does with this value, but it results in a line inserted into distribution.dist
(<product id="[IDENTIFIER]" version="[VERSION]"/>
).
The identifier value is important for component packages, and I have created MR !6738 (merged) to allow for customization of this value to pkgbuild
for the component packages, such that macOS package receipts have meaningful values and the optional signature applied can match for organizations not in com.
. In this MR, I also set the optional identifier when the productbuild
command is run. Both currently use the variable name CPACK_PRODUCTBUILD_IDENTIFIER
.
The question raised is if we should allow for customization between the identifier between pkgbuild
and productbuild
and/or if a universal name should be changed (e.g., to CPACK_PKGBUILD_IDENTIFIER
or CPACK_PKGBUILD_IDENTIFIER_PREFIX
).
Related to: #20830 (closed), !6738 (merged)