treewide: remove AUTORELEASE
[feed/packages.git] / utils / klish / Makefile
1
2 #
3 # Copyright (C) 2016 OpenWrt.org
4 #
5 # This is free software, licensed under the GNU General Public License v2.
6 # See /LICENSE for more information.
7 #
8
9 include $(TOPDIR)/rules.mk
10
11 PKG_NAME:=klish
12 PKG_VERSION:=2.2.3
13 PKG_RELEASE:=1
14
15 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
16 PKG_SOURCE_URL:=http://libcode.org/attachments/download/82
17 PKG_HASH:=89a08295522fea9736a84e11da3d990641fc43b7e548626d2a56e75ed9d8d47b
18
19 PKG_MAINTAINER:=Takashi Umeno <umeno.takashi@gmail.com>
20 PKG_LICENSE:=BSD-3-Clause
21 PKG_LICENSE_FILES:=LICENCE
22
23 PKG_INSTALL:=1
24 PKG_BUILD_PARALLEL:=1
25
26 include $(INCLUDE_DIR)/package.mk
27 include $(INCLUDE_DIR)/nls.mk
28
29 define Package/klish/default
30 SECTION:=utils
31 CATEGORY:=Utilities
32 SUBMENU:=Shells
33 TITLE:=Kommand Line Interface SHell ($(1))
34 URL:=https://libcode.org/projects/klish/
35 endef
36
37 define Package/klish
38 $(call Package/klish/default,main tool)
39 DEPENDS:=+libxml2
40 endef
41
42 define Package/klish/description
43 The klish is a framework for implementing a CISCO-like CLI on a UNIX
44 systems. It is configurable by XML files. The KLISH stands for Kommand
45 Line Interface Shell.
46 The klish is a fork of clish 0.7.3 developed by Graeme McKerrell.
47 It defines new features but it's compatible (as much as possible) with
48 clish's XML configuration files.
49 klish is able to run using clish XML configuration files although
50 current clish users may expect some changes in behavior.
51 Konf and konfd are klish utilities that are used to store configuration
52 informations in a way which is similar to what's found on CISCO devices.
53 More information about these tools is to be found on the klish web site.
54 endef
55
56 CONFIGURE_ARGS += --with-libxml2
57
58 TARGET_CFLAGS += -D_GNU_SOURCE
59
60 define Package/klish/install
61 $(INSTALL_DIR) $(1)/usr/bin
62 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/clish $(1)/usr/bin/
63 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/konf $(1)/usr/bin/
64 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/konfd $(1)/usr/bin/
65 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/sigexec $(1)/usr/bin/
66 $(INSTALL_DIR) $(1)/usr/lib
67 $(CP) $(PKG_INSTALL_DIR)/usr/lib/*.so* $(1)/usr/lib/
68 endef
69
70 $(eval $(call BuildPackage,klish))
71
72 define Package/klish-xml-files
73 SECTION:=utils
74 CATEGORY:=Utilities
75 DEPENDS:=klish
76 TITLE:=klish sample XML files
77 URL:=https://libcode.org/projects/klish/
78 endef
79
80 define Package/klish-xml-files/description
81 This is a set of sample XML files for klish.
82 endef
83
84 define Package/klish-xml-files/install
85 $(INSTALL_DIR) $(1)/etc/clish
86 $(CP) $(PKG_BUILD_DIR)/xml-examples/clish $(1)/etc/clish/
87 $(CP) $(PKG_BUILD_DIR)/xml-examples/klish $(1)/etc/clish/
88 $(CP) $(PKG_BUILD_DIR)/xml-examples/lua $(1)/etc/clish/
89 $(CP) $(PKG_BUILD_DIR)/xml-examples/test $(1)/etc/clish/
90 endef
91
92 $(eval $(call BuildPackage,klish-xml-files))