devtool's submodule detection seems to check HEAD for sub-modules but not the version we're asking. Link to a patch to workaround this in the test-suite (test_devtool_add_git_style2) : https://lists.openembedded.org/g/openembedded-core/message/197961 In the test, the mbedtls repo is used and triggered this with this patch on the development branch (the main one): https://github.com/Mbed-TLS/mbedtls/commit/456a54da8ef44c8b725b524567c08cffec6a7214 The test asks for the 3.1.0 version which does not contain sub-modules. How to reproduce the problem: devtool add --version v3.1.0 mbedtls git://git@github.com/ARMmbed/mbedtls.git;protocol=https # We should have git://git@github.com/ARMmbed/mbedtls.git;protocol=https;branch=master we get gitsm://git@github.com/ARMmbed/mbedtls.git;protocol=https;branch=master
This is not an issue with devtool not setting the correct URI for a version, but the --version not being used for anything else but setting the "PV" value in the recipe. The version it will check out from git will be the same as if no version is specified. If I add mbedtls by doing: > devtool add --srcrev v3.1.0 mbedtls git://git@github.com/ARMmbed/mbedtls.git it checks out the correct tag and sets the SRC_URI as expected. > SRC_URI = "git://git@github.com/ARMmbed/mbedtls.git;protocol=ssh;branch=master" To fix this issue I ould change the command to set both the --srcrev and the --version: > devtool add --srcrev v3.1.0 --version v3.1.0 mbedtls git://git@github.com/ARMmbed/mbedtls.git
Patches sent: https://lists.openembedded.org/g/openembedded-core/topic/patch_2_2/105746806 https://lists.openembedded.org/g/openembedded-core/topic/patch_1_2_revert/105746807
Link to the v2 of the patches: https://lists.openembedded.org/g/openembedded-core/message/198719 https://lists.openembedded.org/g/openembedded-core/message/198720
https://git.openembedded.org/openembedded-core/log/?qt=range&q=731f47ecfd8ad6558aac629806810789c623986b and follow commit. Thanks!