xmail: use uclibc++.mk
[openwrt/svn-archive/archive.git] / mail / xmail / Makefile
1 #
2 # Copyright (C) 2007-2011 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:=xmail
11 PKG_VERSION:=1.26
12 PKG_RELEASE:=2
13
14 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
15 PKG_SOURCE_URL:=http://www.xmailserver.org/
16 PKG_MD5SUM:=26d35c2fc104d79ebb6397c7dece5b15
17
18 include $(INCLUDE_DIR)/uclibc++.mk
19 include $(INCLUDE_DIR)/package.mk
20
21 define Package/xmail
22 SECTION:=mail
23 CATEGORY:=Mail
24 DEPENDS:=+libopenssl +libpthread $(CXX_DEPENDS)
25 TITLE:=advanced, fast and reliable ESMTP/POP3 mail server
26 URL:=http://www.xmailserver.org/
27 endef
28
29 define Package/xmail/description
30 XMail is an Internet mail server featuring an SMTP, POP3 and finger server.
31 It's incredibly easy to set up and has lots of features including :
32 multiple domains, virtual users and spam protection.
33 endef
34
35 define Build/Compile
36 CFLAGS="$(TARGET_CFLAGS)" \
37 $(MAKE) -C $(PKG_BUILD_DIR) -f Makefile.lnx \
38 $(TARGET_CONFIGURE_OPTS) \
39 LD="$(TARGET_CXX)" \
40 all
41 tar -cjf $(PKG_BUILD_DIR)/MailRoot.tar.bz2 -C $(PKG_BUILD_DIR)/MailRoot --exclude bin .
42 endef
43
44 define Package/xmail/install
45 $(INSTALL_DIR) $(1)/usr/bin/
46 $(INSTALL_BIN) $(PKG_BUILD_DIR)/bin/* $(1)/usr/bin/
47 $(INSTALL_DIR) $(1)/etc
48 $(INSTALL_DATA) $(PKG_BUILD_DIR)/MailRoot.tar.bz2 $(1)/etc/
49 $(INSTALL_DIR) $(1)/etc/config
50 $(INSTALL_DATA) ./files/xmail.config $(1)/etc/config/xmail
51 $(INSTALL_DIR) $(1)/etc/init.d/
52 $(INSTALL_BIN) ./files/xmail.init $(1)/etc/init.d/xmail
53 endef
54
55 define Package/xmail/conffiles
56 /etc/config/xmail
57 endef
58
59 $(eval $(call BuildPackage,xmail))