ntpd: moved to github
[packages.git] / mail / dovecot / Makefile
1 #
2 # Copyright (C) 2006-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:=dovecot
11 PKG_VERSION:=2.2.13
12 PKG_RELEASE:=1
13
14 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
15 PKG_SOURCE_URL:=http://www.dovecot.org/releases/2.2
16 PKG_MD5SUM:=a3eb1c0b1822c4f2b0fe9247776baa71
17
18 PKG_BUILD_DEPENDS:=libiconv
19
20 PKG_FIXUP:=autoreconf
21 PKG_INSTALL:=1
22
23 include $(INCLUDE_DIR)/package.mk
24
25 define Package/dovecot
26   SECTION:=mail
27   CATEGORY:=Mail
28   DEPENDS:=+libopenssl +librt +zlib +libbz2 +libcap
29   TITLE:=An IMAP and POP3 daemon
30   MAINTAINER:=Peter Wagner <tripolar@gmx.at>
31   URL:=http://www.dovecot.org/
32 endef
33
34 define Package/dovecot/description
35  Dovecot is a program which provides POP3 and IMAP services.
36 endef
37
38 CONFIGURE_ARGS += \
39         --without-gssapi \
40         --without-pam \
41         --with-moduledir=/usr/lib/dovecot/modules \
42         --with-notify=dnotify \
43         --without-lzma \
44         --without-lz4
45
46 CONFIGURE_VARS += \
47         RPCGEN= \
48         i_cv_signed_size_t=no \
49         i_cv_signed_time_t=no \
50         i_cv_gmtime_max_time_t=32 \
51         i_cv_mmap_plays_with_write=yes \
52         i_cv_fd_passing=yes \
53         i_cv_c99_vsnprintf=yes \
54         lib_cv_va_copy=yes \
55         lib_cv_va_copy=yes \
56         lib_cv___va_copy=yes \
57         lib_cv_va_val_copy=yes
58
59 define Package/dovecot/install
60         $(INSTALL_DIR)  $(1)/etc/init.d \
61                         $(1)/etc/dovecot \
62                         $(1)/usr/share/doc/dovecot/example-config \
63                         $(1)/usr/lib/dovecot \
64                         $(1)/usr/bin \
65                         $(1)/usr/sbin
66         $(CP) $(PKG_INSTALL_DIR)/etc/dovecot/* $(1)/etc/dovecot/
67         $(CP) $(PKG_INSTALL_DIR)/usr/lib/dovecot/* $(1)/usr/lib/dovecot/
68         $(CP) $(PKG_INSTALL_DIR)/usr/share/doc/dovecot/example-config $(1)/usr/share/doc/dovecot/example-config
69         $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/doveconf $(1)/usr/bin/
70         $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/* $(1)/usr/sbin/
71         $(INSTALL_BIN) ./files/dovecot.init $(1)/etc/init.d/dovecot
72         rm  $(1)/usr/lib/dovecot/dovecot-config
73         find $(1)/usr/lib/dovecot/ -name "*.a" -o -name "*.la" | xargs rm
74 endef
75
76 $(eval $(call BuildPackage,dovecot))