gkermit: add package 3116/head
authorNathaniel Wesley Filardo <nwfilardo@gmail.com>
Fri, 10 Jun 2016 21:11:48 +0000 (21:11 +0000)
committerNathaniel Wesley Filardo <nwfilardo@gmail.com>
Wed, 31 Aug 2016 16:29:10 +0000 (12:29 -0400)
Maintainer: @nwf
Compile tested: LEDE HEAD ar71xx
Run tested: LEDE HEAD on ar71xx, basic functionality testing

Description: A minimal kermit file transfer program

Signed-off-by: Nathaniel Wesley Filardo <nwfilardo@gmail.com>
utils/gkermit/Makefile [new file with mode: 0644]

diff --git a/utils/gkermit/Makefile b/utils/gkermit/Makefile
new file mode 100644 (file)
index 0000000..8263095
--- /dev/null
@@ -0,0 +1,58 @@
+# Copyright (C) 2017 OpenWrt.org
+#
+# This is free software, licensed under the GNU General Public License v3+.
+# See /LICENSE for more information.
+#
+
+include $(TOPDIR)/rules.mk
+
+PKG_NAME:=gkermit
+PKG_VERSION:=1.00
+PKG_RELEASE:=1
+PKG_LICENSE:=GPL-2.0
+
+PKG_SOURCE:=gku100.tar.gz
+PKG_SOURCE_URL:=ftp://kermit.columbia.edu/kermit/archives/gku100.tar.gz
+PKG_MD5SUM:=aea4fa728b9981fce41c9f2c635f2e05
+PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
+
+PKG_MAINTAINER:=Nathaniel Wesley Filardo <nwfilardo@gmail.com>
+
+include $(INCLUDE_DIR)/package.mk
+
+define Package/gkermit
+  SECTION:=utils
+  CATEGORY:=Utilities
+  TITLE:=gkermit
+  URL:=http://www.columbia.edu/kermit/gkermit.html
+endef
+
+define Package/gkermit/description
+  A minimal kermit file transfer program
+endef
+
+define Build/Prepare
+       mkdir -p $(PKG_BUILD_DIR)
+       tar -C $(PKG_BUILD_DIR) -xzvf "$(DL_DIR)/$(PKG_SOURCE)"
+endef
+
+# nothing to do
+define Build/Configure
+endef
+define Build/Compile
+       mkdir -p $(PKG_INSTALL_DIR)
+       $(TARGET_CC) \
+         $(TARGET_CFLAGS) $(TARGET_CPPFLAGS) \
+         -include string.h -include unistd.h \
+         -DPOSIX -DERRNO_H \
+         -o $(PKG_INSTALL_DIR)/gkermit \
+         $(PKG_BUILD_DIR)/{gproto,gkermit,gunixio,gcmdline}.c
+endef
+
+define Package/gkermit/install
+       $(INSTALL_DIR) $(1)/bin
+       $(INSTALL_BIN) $(PKG_INSTALL_DIR)/gkermit $(1)/bin
+endef
+
+$(eval $(call BuildPackage,gkermit))