2 # Copyright (C) 2006-2018 OpenWrt.org
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
8 include $(TOPDIR
)/rules.mk
14 PKG_SOURCE
:=$(PKG_NAME
)-$(PKG_VERSION
).
tar.gz
15 PKG_SOURCE_URL
:=https
://www.dovecot.org
/releases
/2.3
16 PKG_HASH
:=ba14e41aefd81a868a35b83bcb54194116106424d37690519b50ea83c0f31bf2
17 PKG_LICENSE
:=LGPL-2.1 MIT BSD-3-Clause Unique
18 PKG_LICENSE_FILES
:=COPYING COPYING.LGPL COPYING.MIT
19 PKG_MAINTAINER
:=Lucian Cristian
<lucian.cristian@gmail.com
>
21 PKG_BUILD_DEPENDS
:=libiconv
22 PKG_CONFIG_DEPENDS
:= \
23 CONFIG_DOVECOT_GSSAPI \
25 CONFIG_DOVECOT_MYSQL \
26 CONFIG_DOVECOT_PGSQL \
27 CONFIG_DOVECOT_SQLITE \
34 include $(INCLUDE_DIR
)/package.mk
35 # iconv is needed when compiling with MySQL support. iconv will also be used by
37 include $(INCLUDE_DIR
)/nls.mk
39 define Package
/dovecot
42 DEPENDS
:=+DOVECOT_GSSAPI
:krb5-libs
+DOVECOT_LDAP
:libopenldap
+DOVECOT_MYSQL
:libmysqlclient
+DOVECOT_PGSQL
:libpq
+DOVECOT_SQLITE
:libsqlite3
+libopenssl
+librt
+zlib
+libbz2
+libcap
+DOVECOT_ICU
:icu
$(ICONV_DEPENDS
)
43 TITLE
:=An IMAP and POP3 daemon
44 URL
:=https
://www.dovecot.org
/
45 USERID
:=dovecot
=59:dovecot
=59
46 ABI_VERSION
:=$(PKG_VERSION
)
49 define Package
/dovecot
/description
50 Dovecot is a program which provides POP3 and IMAP services.
53 define Package
/dovecot
/config
54 menu
"Select dovecot build options"
55 depends on PACKAGE_dovecot
60 Implements GSSAPI support in dovecot.
65 Implements LDAP support in dovecot.
70 Implements MYSQL support in dovecot.
72 bool
"PostgreSQL support"
75 Implements PostgreSQL support in dovecot.
80 Implements SQLite DB support in dovecot.
82 bool
"Enable i18n features"
85 Enable ICU
(International Components for Unicode
) support.
89 define Package
/dovecot
/conffiles
94 define Package
/dovecot-utils
98 TITLE
:=doveadm and dsync utilities for Dovecot
102 --libexecdir
=/usr
/libexec \
104 --with-notify
=dnotify \
108 $(if
$(CONFIG_DOVECOT_GSSAPI
),--with-gssapi
=yes
,--with-gssapi
=no
) \
109 $(if
$(CONFIG_DOVECOT_LDAP
),--with-ldap
=yes
,--with-ldap
=no
) \
110 $(if
$(CONFIG_DOVECOT_MYSQL
),--with-mysql
=yes
,--with-mysql
=no
) \
111 $(if
$(CONFIG_DOVECOT_PGSQL
),--with-pgsql
=yes
,--with-pgsql
=no
) \
112 $(if
$(CONFIG_DOVECOT_SQLITE
),--with-sqlite
=yes
,--with-sqlite
=no
) \
113 $(if
$(CONFIG_DOVECOT_ICU
),--with-icu
=yes
,--with-icu
=no
)
117 i_cv_signed_size_t
=no \
118 i_cv_signed_time_t
=no \
119 i_cv_gmtime_max_time_t
=32 \
120 i_cv_mmap_plays_with_write
=yes \
121 i_cv_fd_passing
=yes \
122 i_cv_c99_vsnprintf
=yes \
125 lib_cv___va_copy
=yes \
126 lib_cv_va_val_copy
=yes \
127 ac_cv_prog_KRB5CONFIG
="krb5-config"
129 define Build
/InstallDev
130 $(INSTALL_DIR
) $(1)/usr
/include $(1)/usr
/lib
131 $(CP
) $(PKG_INSTALL_DIR
)/usr
/include/dovecot
$(1)/usr
/include/
132 $(CP
) $(PKG_INSTALL_DIR
)/usr
/lib
/dovecot
$(1)/usr
/lib
/
133 rm -f
$(1)/usr
/lib
/dovecot
/*.la
137 define Package
/dovecot
/install
138 $(INSTALL_DIR
) $(1)/etc
/init.d \
140 $(1)/usr
/share
/doc
/dovecot \
141 $(1)/usr
/lib
/dovecot \
142 $(1)/usr
/libexec
/dovecot \
145 $(CP
) $(PKG_INSTALL_DIR
)/etc
/dovecot
/* $(1)/etc
/dovecot
/
146 $(CP
) $(PKG_INSTALL_DIR
)/usr
/lib
/dovecot
/* $(1)/usr
/lib
/dovecot
/
147 $(CP
) $(PKG_INSTALL_DIR
)/usr
/libexec
/dovecot
/* $(1)/usr
/libexec
/dovecot
/
148 $(CP
) $(PKG_INSTALL_DIR
)/usr
/share
/doc
/dovecot
/example-config
$(1)/usr
/share
/doc
/dovecot
/
149 $(INSTALL_BIN
) $(PKG_INSTALL_DIR
)/usr
/bin
/doveconf
$(1)/usr
/bin
/
150 $(INSTALL_BIN
) $(PKG_INSTALL_DIR
)/usr
/sbin
/* $(1)/usr
/sbin
/
151 $(INSTALL_BIN
) .
/files
/dovecot.init
$(1)/etc
/init.d
/dovecot
152 rm $(1)/usr
/lib
/dovecot
/dovecot-config
153 find
$(1)/usr
/lib
/dovecot
/ -name
"*.a" -o
-name
"*.la" | xargs
rm
156 define Package
/dovecot-utils
/install
157 $(INSTALL_DIR
) $(1)/usr
/bin
158 $(INSTALL_BIN
) $(PKG_INSTALL_DIR
)/usr
/bin
/doveadm
$(1)/usr
/bin
/
159 $(CP
) $(PKG_INSTALL_DIR
)/usr
/bin
/dsync
$(1)/usr
/bin
/
162 $(eval
$(call BuildPackage
,dovecot
))
163 $(eval
$(call BuildPackage
,dovecot-utils
))