source: packages/net/umurmur/Makefile @ 19886

Last change on this file since 19886 was 19886, checked in by spudz76, 7 years ago

[patchteam] Update umurmur package to version 0.2.1 (and split into openssl and polarssl versions) - closes #6745 - thanks Zuljin

File size: 2.5 KB
Line 
1#
2# Copyright (C) 2009-2010 OpenWrt.org
3#
4# This is free software, licensed under the GNU General Public License v2.
5# See /LICENSE for more information.
6#
7include $(TOPDIR)/rules.mk
8
9PKG_NAME:=umurmur
10PKG_VERSION:=0.2.1
11PKG_RELEASE:=1
12
13PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
14PKG_SOURCE_URL:=http://umurmur.googlecode.com/files/
15PKG_MD5SUM:=e3471fb925dadc60e3b307efe2a1cc80
16
17
18include $(INCLUDE_DIR)/package.mk
19
20define Package/umurmur/Default
21  SECTION:=net
22  CATEGORY:=Network
23  TITLE:=uMurmur
24  DEPENDS:=+libconfig
25  URL:=http://code.google.com/p/umurmur
26  MAINTAINER:=Martin Johansson <martin@fatbob.nu>
27endef
28
29define Package/umurmur/Default/description
30  Minimalistic Mumble server daemon.
31endef
32
33define Package/umurmur-openssl
34  $(call Package/umurmur/Default)
35  TITLE+= (with OpenSSL support)
36  DEPENDS+= +libopenssl
37endef
38
39define Package/umurmur-openssl/description
40  $(call Package/umurmur/Default/description)
41  Uses OpenSSL library for SSL and crypto.
42endef
43
44define Package/umurmur-polarssl
45  $(call Package/umurmur/Default)
46  TITLE+= (with PolarSSL support)
47  DEPENDS+= +libpolarssl
48endef
49
50define Package/umurmur-polarssl/description
51  $(call Package/umurmur/Default/description)
52  Uses the PolarSSL library for SSL and crypto.
53endef
54
55define Build/Compile
56endef
57
58define Build/Template
59
60$(STAMP_BUILT)-$(2): $(STAMP_PREPARED)
61        -$(MAKE) -C $(PKG_BUILD_DIR)/src clean
62        CC="$(TARGET_CC)" \
63        CFLAGS="$(3) -DWRT_TARGET -I$(STAGING_DIR)/usr/include $(TARGET_CFLAGS)" \
64        LDFLAGS="$(4) $(TARGET_LDFLAGS)" \
65        $(MAKE) -C $(PKG_BUILD_DIR)/src all
66        ( cd $(PKG_BUILD_DIR)/src; mv -f umurmurd umurmurd-$(2))
67        touch $$@
68
69$(STAMP_BUILT): $(STAMP_BUILT)-$(2)
70
71define Package/$(1)/conffiles
72/etc/umurmur.conf
73endef
74
75define Package/$(1)/install
76        $(INSTALL_DIR) $$(1)/usr/bin
77        $(INSTALL_BIN) $(PKG_BUILD_DIR)/src/umurmurd-$(2) $$(1)/usr/bin/umurmurd
78        $(INSTALL_DIR) $$(1)/etc
79        $(INSTALL_CONF) $(PKG_BUILD_DIR)/openwrt/files/umurmur.conf $$(1)/etc/
80        $(INSTALL_DIR) $$(1)/etc/init.d
81        $(INSTALL_BIN) $(PKG_BUILD_DIR)/openwrt/files/umurmur.init $$(1)/etc/init.d/umurmur
82        $(INSTALL_DIR) $$(1)/etc/umurmur
83endef
84endef
85
86ifneq ($(SDK)$(CONFIG_PACKAGE_umurmur-openssl),)
87  define Build/with-openssl
88    $(call Build/Template,umurmur-openssl,openssl,,-lcrypto -lssl)
89  endef
90endif
91$(eval $(Build/with-openssl))
92
93ifneq ($(SDK)$(CONFIG_PACKAGE_umurmur-polarssl),)
94  define Build/with-polarssl
95    $(call Build/Template,umurmur-polarssl,polarssl,-DUSE_POLARSSL,-lpolarssl)
96  endef
97endif
98$(eval $(Build/with-polarssl))
99
100
101$(eval $(call BuildPackage,umurmur-openssl))
102$(eval $(call BuildPackage,umurmur-polarssl))
Note: See TracBrowser for help on using the repository browser.