X-Git-Url: https://review.fuel-infra.org/gitweb?a=blobdiff_plain;f=cirros-testvm%2Fsrc-cirros%2Fbuildroot-2015.05%2Fpackage%2Fsunxi-tools%2Fsunxi-tools.mk;fp=cirros-testvm%2Fsrc-cirros%2Fbuildroot-2015.05%2Fpackage%2Fsunxi-tools%2Fsunxi-tools.mk;h=2dfd4961f970e4885391262859777482d00306fd;hb=b0a0f15dfaa205161a7fcb20cf1b8cd4948c2ef3;hp=0000000000000000000000000000000000000000;hpb=c6ac3cd55ee2da956195eee393b0882105dfad4e;p=packages%2Ftrusty%2Fcirros-testvm.git diff --git a/cirros-testvm/src-cirros/buildroot-2015.05/package/sunxi-tools/sunxi-tools.mk b/cirros-testvm/src-cirros/buildroot-2015.05/package/sunxi-tools/sunxi-tools.mk new file mode 100644 index 0000000..2dfd496 --- /dev/null +++ b/cirros-testvm/src-cirros/buildroot-2015.05/package/sunxi-tools/sunxi-tools.mk @@ -0,0 +1,37 @@ +################################################################################ +# +# sunxi-tools +# +################################################################################ + +SUNXI_TOOLS_VERSION = v1.2 +SUNXI_TOOLS_SITE = $(call github,linux-sunxi,sunxi-tools,$(SUNXI_TOOLS_VERSION)) +SUNXI_TOOLS_LICENSE = GPLv2+ +SUNXI_TOOLS_LICENSE_FILES = COPYING +HOST_SUNXI_TOOLS_DEPENDENCIES = host-libusb +FEX2BIN = $(HOST_DIR)/usr/bin/fex2bin + +define HOST_SUNXI_TOOLS_BUILD_CMDS + $(HOST_MAKE_ENV) $(MAKE) $(HOST_CONFIGURE_OPTS) \ + CFLAGS="$(HOST_CFLAGS) -std=c99 -D_POSIX_C_SOURCE=200112L -Iinclude/" \ + -C $(@D) +endef + +define HOST_SUNXI_TOOLS_INSTALL_CMDS + for i in fexc bin2fex fex2bin bootinfo fel pio; do \ + $(INSTALL) -D -m 0755 $(@D)/$$i $(HOST_DIR)/usr/bin/$$i ; \ + done +endef + +define SUNXI_TOOLS_BUILD_CMDS + $(TARGET_MAKE_ENV) $(MAKE) $(TARGET_CONFIGURE_OPTS) \ + CFLAGS="$(TARGET_CFLAGS) -std=c99 -D_POSIX_C_SOURCE=200112L -Iinclude/" \ + -C $(@D) nand-part +endef + +define SUNXI_TOOLS_INSTALL_TARGET_CMDS + $(INSTALL) -D -m 0755 $(@D)/nand-part $(TARGET_DIR)/usr/bin/nand-part +endef + +$(eval $(generic-package)) +$(eval $(host-generic-package))