swupdate_git.bb 673 B

1234567891011121314151617181920
  1. require swupdate.inc
  2. require swupdate_tools.inc
  3. DEFAULT_PREFERENCE = "-1"
  4. # If a recipe sets SRCREV to ${AUTOREV}, bitbake tries
  5. # a git ls-remote. This breaks when a mirror is built
  6. # and BB_NO_NETWORK is set.
  7. # To work-around the issue, sets the revision for the git
  8. # version to a fix commit (not relevant)
  9. # In casethe _git version is chosen, sets the revision
  10. # to TOT to test with last commit-id.
  11. def version_git(d):
  12. version = d.getVar("PREFERRED_VERSION_%s" % d.getVar('PN'))
  13. if version is not None and "git" in version:
  14. return d.getVar("AUTOREV")
  15. else:
  16. return "c0fec16b3fc82b0db12d8ac58be7055ed1b8d439"
  17. SRCREV ?= '${@version_git(d)}'