Fixed:
INHERIT += "archiver"
$ bitbake notary -car_original

bb.data_smart.ExpansionError: Failure expanding variable SRCPV, expression was 
${@bb.fetch2.get_srcrev(d)} which triggered exception FetchError: Fetcher 
failure: The SRCREV_FORMAT variable must be set when multiple SCMs are used.
The SCMs are:
git://github.com/docker/notary.git;destsuffix=git/src/github.com/docker/notary
git://github.com/docker/notary.git

Another solution is define SRCREV_FORMAT in archiver.bbclass, but that doesn't
work since it is too late to define it there.

Signed-off-by: Robert Yang <[email protected]>
---
 recipes-devtools/go/notary_git.bb | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/recipes-devtools/go/notary_git.bb 
b/recipes-devtools/go/notary_git.bb
index 9cfb46e..76dfa8f 100644
--- a/recipes-devtools/go/notary_git.bb
+++ b/recipes-devtools/go/notary_git.bb
@@ -9,6 +9,11 @@ SRCNAME = "notary"
 PKG_NAME = "github.com/docker/${SRCNAME}"
 SRC_URI = "git://${PKG_NAME}.git;destsuffix=git/src/${PKG_NAME}"
 
+# The archiver.bbclass will append a uri to SRC_URI when it contains
+# destsuffix, then the SRC_URI would contain multilib SCMs, and bitbake's
+# fetcher requires a SRCREV_FORMAT for multiple SCMs.
+SRCREV_FORMAT = "${SRCNAME}"
+
 SRCREV = "d6e1431feb32348e0650bf7551ac5cffd01d857b"
 PV = "0.6.1+git${SRCPV}"
 
-- 
2.17.1

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#5328): 
https://lists.yoctoproject.org/g/meta-virtualization/message/5328
Mute This Topic: https://lists.yoctoproject.org/mt/74345499/21656
Group Owner: [email protected]
Unsubscribe: https://lists.yoctoproject.org/g/meta-virtualization/unsub  
[[email protected]]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to