[packages] move packages to a new 'mail' section, cleanup
[packages.git] / mail / xmail / Makefile
1 #
2 # Copyright (C) 2007-2008 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7 # $Id$
8
9 include $(TOPDIR)/rules.mk
10
11 PKG_NAME:=xmail
12 PKG_VERSION:=1.24
13 PKG_RELEASE:=1
14
15 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
16 PKG_SOURCE_URL:=http://www.xmailserver.org/
17 PKG_MD5SUM:=106730bdbaa4fda9e90a7c22df024114
18
19 include $(INCLUDE_DIR)/package.mk
20
21 define Package/xmail
22   SECTION:=mail
23   CATEGORY:=Mail
24   DEPENDS:=+uclibcxx +libopenssl
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/Configure
36         $(CP) ./files/SysMachine.h $(PKG_BUILD_DIR)/
37 endef
38
39 define Build/Compile
40         CFLAGS="$(TARGET_CFLAGS)" \
41         $(MAKE) -C $(PKG_BUILD_DIR) -f Makefile.lnx \
42                 $(TARGET_CONFIGURE_OPTS) \
43                 LD="\$$$$(CC)" \
44                 CPPFLAGS="$(TARGET_CPPFLAGS) -I$(STAGING_DIR)/usr/include/uClibc++ -fno-builtin -fno-rtti -nostdinc++" \
45                 LDFLAGS="$(TARGET_LDFLAGS) -nodefaultlibs -lcrypto -lssl -luClibc++ -ldl -lm -lpthread" \
46                 all
47 endef
48
49 define Package/xmail/install
50         $(INSTALL_DIR) $(1)/usr/bin/
51         $(INSTALL_BIN) $(PKG_BUILD_DIR)/bin/* $(1)/usr/bin/
52         $(INSTALL_DIR) $(1)/var/MailRoot/
53         $(CP) $(PKG_BUILD_DIR)/MailRoot $(1)/var/
54 endef
55
56 $(eval $(call BuildPackage,xmail))