image-commands.patch 601 B

1234567891011121314151617181920
  1. --- a/include/image-commands.mk
  2. +++ b/include/image-commands.mk
  3. @@ -419,6 +419,17 @@ endef
  4. # Convert a raw image into a $1 type image.
  5. # E.g. | qemu-image vdi <optional extra arguments to qemu-img binary>
  6. +define Build/qemu-exsi
  7. + if command -v qemu-img; then \
  8. + name="$(subst .vmdk.zip,,$@)"; \
  9. + qemu-img convert -f raw -O $1 $@ $$name.vmdk; \
  10. + rm -f $@; \
  11. + zip -jm $@ $$name*.vmdk; \
  12. + else \
  13. + echo "WARNING: Install qemu-img to create VDI/VMDK images" >&2; exit 1; \
  14. + fi
  15. +endef
  16. +
  17. define Build/qemu-image
  18. if command -v qemu-img; then \
  19. qemu-img convert -f raw -O $1 $@ [email protected]; \