aboutsummaryrefslogtreecommitdiffstats
path: root/package/jshn/Makefile
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2011-02-16 00:24:52 +0000
committerFelix Fietkau <nbd@openwrt.org>2011-02-16 00:24:52 +0000
commit9d4d2587d7ee0d76e1af0bc4e1889176ce209e04 (patch)
tree68cee38eae6a8a98a15cbce7b3a32f0ba20379a0 /package/jshn/Makefile
parentf1ac8cf2859bee611c5bba05a17f7ab0a2ebf5d0 (diff)
downloadupstream-9d4d2587d7ee0d76e1af0bc4e1889176ce209e04.tar.gz
upstream-9d4d2587d7ee0d76e1af0bc4e1889176ce209e04.tar.bz2
upstream-9d4d2587d7ee0d76e1af0bc4e1889176ce209e04.zip
add jshn (JSON SHell Notation), a small utility and shell library for parsing and generating json data
SVN-Revision: 25547
Diffstat (limited to 'package/jshn/Makefile')
-rw-r--r--package/jshn/Makefile32
1 files changed, 32 insertions, 0 deletions
diff --git a/package/jshn/Makefile b/package/jshn/Makefile
new file mode 100644
index 0000000000..d5d1ea0cad
--- /dev/null
+++ b/package/jshn/Makefile
@@ -0,0 +1,32 @@
+include $(TOPDIR)/rules.mk
+
+PKG_NAME:=jshn
+PKG_VERSION:=0.1
+PKG_RELEASE=1
+
+include $(INCLUDE_DIR)/package.mk
+
+define Package/jshn
+ SECTION:=utils
+ CATEGORY:=Utilities
+ DEPENDS:=+libjson
+ TITLE:=JSON SHell Notation
+endef
+
+define Package/jshn/description
+ Library for parsing and generating JSON from shell scripts
+endef
+
+TARGET_CFLAGS += -I$(STAGING_DIR)/usr/include --std=gnu99
+
+define Build/Compile
+ $(TARGET_CC) $(TARGET_CFLAGS) -o $(PKG_BUILD_DIR)/jshn src/jshn.c $(TARGET_LDFLAGS) -ljson
+endef
+
+define Package/jshn/install
+ $(INSTALL_DIR) $(1)/bin $(1)/lib/functions
+ $(INSTALL_BIN) $(PKG_BUILD_DIR)/jshn $(1)/bin
+ $(INSTALL_DATA) ./files/jshn.sh $(1)/lib/functions
+endef
+
+$(eval $(call BuildPackage,jshn))