[LEDE-DEV] [PATCH 1/1] tools: Add gptfdisk

Alif M. A. alive4ever at live.com
Tue Mar 28 09:19:30 PDT 2017


To create gpt formatted disk for use with UEFI, a tool for interacting
with gpt partitioned disk is needed. Import roodsbook's gptfdisk for
this purpose.

The tool will be available as gdisk (for interactive use) and sgdisk
(for scripting use).

Signed-off-by: Alif M. Ahmad <alive4ever at live.com>
---
 tools/gptfdisk/Makefile | 40 ++++++++++++++++++++++++++++++++++++++++
 1 file changed, 40 insertions(+)
 create mode 100644 tools/gptfdisk/Makefile

diff --git a/tools/gptfdisk/Makefile b/tools/gptfdisk/Makefile
new file mode 100644
index 0000000000..6ebf830ff3
--- /dev/null
+++ b/tools/gptfdisk/Makefile
@@ -0,0 +1,40 @@
+#
+# Copyright (C) 2015 OpenWrt.org
+# Copyright (C) 2017 LEDE project
+#
+# This is free software, licensed under the GNU General Public License v2.
+# See /LICENSE for more information.
+#
+include $(TOPDIR)/rules.mk
+
+PKG_NAME:=gptfdisk
+PKG_VERSION:=1.0.1
+
+PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
+PKG_SOURCE_URL:=http://www.rodsbooks.com/gdisk/
+PKG_HASH:=864c8aee2efdda50346804d7e6230407d5f42a8ae754df70404dd8b2fdfaeac7
+PKG_RELEASE:=1
+
+HOST_BUILD_PARALLEL := 1
+
+include $(INCLUDE_DIR)/host-build.mk
+
+
+define Host/Compile
+	$(MAKE) -C $(HOST_BUILD_DIR) gdisk sgdisk
+endef
+
+define Host/Install
+	$(INSTALL_BIN) $(HOST_BUILD_DIR)/gdisk $(STAGING_DIR_HOST)/bin/
+	$(INSTALL_BIN) $(HOST_BUILD_DIR)/sgdisk $(STAGING_DIR_HOST)/bin/
+endef
+
+define Host/Clean
+	rm -f $(STAGING_DIR_HOST)/bin/gdisk
+	rm -f $(STAGING_DIR_HOST)/bin/sgdisk
+endef
+
+HOSTCC := $(HOSTCC_NOCACHE)
+HOSTCXX := $(HOSTCXX_NOCACHE)
+
+$(eval $(call HostBuild))
-- 
2.12.1




More information about the Lede-dev mailing list