|
@@ -0,0 +1,62 @@
|
|
1
|
+#
|
|
2
|
+# Copyright (C) 2008-2014 OpenWrt.org
|
|
3
|
+#
|
|
4
|
+# This is free software, licensed under the GNU General Public License v2.
|
|
5
|
+# See /LICENSE for more information.
|
|
6
|
+#
|
|
7
|
+
|
|
8
|
+include $(TOPDIR)/rules.mk
|
|
9
|
+
|
|
10
|
+PKG_NAME:=linknx
|
|
11
|
+PKG_VERSION:=0.0.1.32
|
|
12
|
+PKG_RELEASE:=1
|
|
13
|
+PKG_MD5SUM:=7ecc1208f59bceb05068c752b2250b63
|
|
14
|
+
|
|
15
|
+PKG_MAINTAINER:=Othmar Truniger <tru7@users.noreply.github.com>
|
|
16
|
+PKG_LICENSE:=GPL-2.0+
|
|
17
|
+
|
|
18
|
+PKG_SOURCE_URL:=@SF/linknx
|
|
19
|
+PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
|
|
20
|
+PKG_CAT:=zcat
|
|
21
|
+PKG_BUILD_DEPENDS:=pthsem curl libesmtp
|
|
22
|
+
|
|
23
|
+PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
|
|
24
|
+include $(INCLUDE_DIR)/package.mk
|
|
25
|
+
|
|
26
|
+define Package/linknx
|
|
27
|
+ SECTION:=net
|
|
28
|
+ CATEGORY:=Network
|
|
29
|
+ TITLE:=KNX home automation platform
|
|
30
|
+ URL:=http://sourceforge.net/projects/linknx/
|
|
31
|
+ DEPENDS:=pthsem +lua +luac +libstdcpp +libcurl +libesmtp
|
|
32
|
+endef
|
|
33
|
+
|
|
34
|
+define Build/Configure
|
|
35
|
+ (cd $(PKG_BUILD_DIR); touch aclocal.m4 Makefile.in config.h.in configure; \
|
|
36
|
+ $(SED) 's,\"2.0.4\",\"2.0.4\"\n_pth_version=\"2.0.8\",g' $(PKG_BUILD_DIR)/configure )
|
|
37
|
+ $(call Build/Configure/Default,--verbose --without-pth-test --with-pth=$(STAGING_DIR) --without-log4cpp --with-lua --with-libcurl --without-mysql, \
|
|
38
|
+ CXXFLAGS="$(TARGET_CFLAGS) -fno-builtin -lcrypt" \
|
|
39
|
+ )
|
|
40
|
+endef
|
|
41
|
+
|
|
42
|
+define Build/Compile
|
|
43
|
+ $(MAKE) -C $(PKG_BUILD_DIR)/ \
|
|
44
|
+ LIBDIR="$(TARGET_LDFLAGS)" \
|
|
45
|
+ CC="$(TARGET_CC) $(TARGET_CFLAGS) $(TARGET_CPPFLAGS) " \
|
|
46
|
+ LD="$(TARGET_CROSS)ld -shared" \
|
|
47
|
+ LUA="$(STAGING_DIR_HOST)/bin/lua" \
|
|
48
|
+ LUAC="$(STAGING_DIR_HOST)/bin/luac" \
|
|
49
|
+ CFLAGS="$(TARGET_CFLAGS) -nodefaultlibs" all
|
|
50
|
+endef
|
|
51
|
+
|
|
52
|
+define Package/linknx/install
|
|
53
|
+ mkdir -p $(1)/usr/bin
|
|
54
|
+ $(CP) $(PKG_BUILD_DIR)/src/linknx $(1)/usr/bin/
|
|
55
|
+ mkdir -p $(1)/etc/init.d
|
|
56
|
+ $(CP) ./files/linknx.init $(1)/etc/init.d/linknx
|
|
57
|
+ mkdir -p $(1)/etc/config
|
|
58
|
+ $(CP) ./files/linknx.config $(1)/etc/config/linknx
|
|
59
|
+ $(CP) ./files/linknx.xml.dist $(1)/etc/linknx.xml.dist
|
|
60
|
+endef
|
|
61
|
+
|
|
62
|
+$(eval $(call BuildPackage,linknx))
|