mirror of
https://github.com/novatiq/packages.git
synced 2026-04-30 15:38:40 +01:00
dovecot: Improve packaging and include configs
- Add dovenull user, otherwise, dovecot doesn't start
- Build docs to have configuration files for dovecot
- Remove init script as conffile
- Move build options from Makefile to Config.in
- Install section to be more readable
- Refresh patches
Signed-off-by: Josef Schlehofer <pepe.schlehofer@gmail.com>
(cherry-picked from commit e27438f140)
This commit is contained in:
+21
-48
@@ -40,10 +40,11 @@ include $(INCLUDE_DIR)/nls.mk
|
||||
define Package/dovecot
|
||||
SECTION:=mail
|
||||
CATEGORY:=Mail
|
||||
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)
|
||||
TITLE:=An IMAP and POP3 daemon
|
||||
URL:=https://www.dovecot.org/
|
||||
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)
|
||||
USERID:=dovecot=59:dovecot=59
|
||||
USERID:=dovenull=60:dovenull=60
|
||||
ABI_VERSION:=$(PKG_VERSION)
|
||||
endef
|
||||
|
||||
@@ -52,43 +53,10 @@ define Package/dovecot/description
|
||||
endef
|
||||
|
||||
define Package/dovecot/config
|
||||
menu "Select dovecot build options"
|
||||
depends on PACKAGE_dovecot
|
||||
config DOVECOT_GSSAPI
|
||||
bool "GSSAPI support"
|
||||
default n
|
||||
help
|
||||
Implements GSSAPI support in dovecot.
|
||||
config DOVECOT_LDAP
|
||||
bool "LDAP support"
|
||||
default n
|
||||
help
|
||||
Implements LDAP support in dovecot.
|
||||
config DOVECOT_MYSQL
|
||||
bool "MYSQL support"
|
||||
default n
|
||||
help
|
||||
Implements MYSQL support in dovecot.
|
||||
config DOVECOT_PGSQL
|
||||
bool "PostgreSQL support"
|
||||
default n
|
||||
help
|
||||
Implements PostgreSQL support in dovecot.
|
||||
config DOVECOT_SQLITE
|
||||
bool "SQLite support"
|
||||
default n
|
||||
help
|
||||
Implements SQLite DB support in dovecot.
|
||||
config DOVECOT_ICU
|
||||
bool "Enable i18n features"
|
||||
default n
|
||||
help
|
||||
Enable ICU (International Components for Unicode) support.
|
||||
endmenu
|
||||
source "$(SOURCE)/Config.in"
|
||||
endef
|
||||
|
||||
define Package/dovecot/conffiles
|
||||
/etc/init.d/dovecot
|
||||
/etc/dovecot/
|
||||
endef
|
||||
|
||||
@@ -106,7 +74,6 @@ CONFIGURE_ARGS += \
|
||||
--without-lzma \
|
||||
--without-lz4 \
|
||||
--without-sodium \
|
||||
--without-docs \
|
||||
$(if $(CONFIG_DOVECOT_GSSAPI),--with-gssapi=yes,--with-gssapi=no) \
|
||||
$(if $(CONFIG_DOVECOT_LDAP),--with-ldap=yes,--with-ldap=no) \
|
||||
$(if $(CONFIG_DOVECOT_MYSQL),--with-mysql=yes,--with-mysql=no) \
|
||||
@@ -132,24 +99,30 @@ define Build/InstallDev
|
||||
$(INSTALL_DIR) $(1)/usr/include $(1)/usr/lib
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/include/dovecot $(1)/usr/include/
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/lib/dovecot $(1)/usr/lib/
|
||||
rm -f $(1)/usr/lib/dovecot/*.la
|
||||
$(call libtool_remove_files,$(1))
|
||||
endef
|
||||
|
||||
|
||||
define Package/dovecot/install
|
||||
$(INSTALL_DIR) $(1)/etc/init.d \
|
||||
$(1)/etc/dovecot \
|
||||
$(1)/usr/lib/dovecot \
|
||||
$(1)/usr/libexec/dovecot \
|
||||
$(1)/usr/bin \
|
||||
$(1)/usr/sbin
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/lib/dovecot/* $(1)/usr/lib/dovecot/
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/libexec/dovecot/* $(1)/usr/libexec/dovecot/
|
||||
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/doveconf $(1)/usr/bin/
|
||||
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/* $(1)/usr/sbin/
|
||||
$(INSTALL_DIR) $(1)/etc/init.d
|
||||
$(INSTALL_BIN) ./files/dovecot.init $(1)/etc/init.d/dovecot
|
||||
|
||||
$(INSTALL_DIR) $(1)/etc/dovecot
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/share/doc/dovecot/example-config/* $(1)/etc/dovecot/
|
||||
|
||||
$(INSTALL_DIR) $(1)/usr/lib/dovecot
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/lib/dovecot/* $(1)/usr/lib/dovecot/
|
||||
rm $(1)/usr/lib/dovecot/dovecot-config
|
||||
find $(1)/usr/lib/dovecot/ -name "*.a" -o -name "*.la" | xargs rm
|
||||
find $(1)/usr/lib/dovecot/ -name "*.a" -o -name "*.la" | $(XARGS) rm -f
|
||||
|
||||
$(INSTALL_DIR) $(1)/usr/libexec/dovecot
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/libexec/dovecot/* $(1)/usr/libexec/dovecot/
|
||||
|
||||
$(INSTALL_DIR) $(1)/usr/bin
|
||||
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/doveconf $(1)/usr/bin/
|
||||
|
||||
$(INSTALL_DIR) $(1)/usr/sbin
|
||||
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/* $(1)/usr/sbin/
|
||||
endef
|
||||
|
||||
define Package/dovecot-utils/install
|
||||
|
||||
Reference in New Issue
Block a user