From 7288637bcfdc483aaf0bd480a95ac135bb11be3a Mon Sep 17 00:00:00 2001 From: Li xin Date: Wed, 22 Jul 2015 16:46:36 +0800 Subject: dovecot: upgrade 2.2.10 -> 2.2.18 Dropped building-rquota_xdr.c-depend-on-rquota.h.patch,since 2.2.18 fixed the problem. Update 0001-configure.ac-convert-AC_TRY_RUN-to-AC_TRY_LINK-state.patch,since the file configure.ac has been changed. Signed-off-by: Li Xin Signed-off-by: Martin Jansa Signed-off-by: Joe MacDonald --- ...c-convert-AC_TRY_RUN-to-AC_TRY_LINK-state.patch | 57 ++++++------------- .../building-rquota_xdr.c-depend-on-rquota.h.patch | 28 ---------- .../recipes-support/dovecot/dovecot_2.2.10.bb | 65 ---------------------- .../recipes-support/dovecot/dovecot_2.2.18.bb | 64 +++++++++++++++++++++ 4 files changed, 80 insertions(+), 134 deletions(-) delete mode 100644 meta-networking/recipes-support/dovecot/dovecot/building-rquota_xdr.c-depend-on-rquota.h.patch delete mode 100644 meta-networking/recipes-support/dovecot/dovecot_2.2.10.bb create mode 100644 meta-networking/recipes-support/dovecot/dovecot_2.2.18.bb diff --git a/meta-networking/recipes-support/dovecot/dovecot/0001-configure.ac-convert-AC_TRY_RUN-to-AC_TRY_LINK-state.patch b/meta-networking/recipes-support/dovecot/dovecot/0001-configure.ac-convert-AC_TRY_RUN-to-AC_TRY_LINK-state.patch index 6f5c279be2..f86235076e 100644 --- a/meta-networking/recipes-support/dovecot/dovecot/0001-configure.ac-convert-AC_TRY_RUN-to-AC_TRY_LINK-state.patch +++ b/meta-networking/recipes-support/dovecot/dovecot/0001-configure.ac-convert-AC_TRY_RUN-to-AC_TRY_LINK-state.patch @@ -1,21 +1,23 @@ -From 483f120603ada8db680085e3f462396da937e036 Mon Sep 17 00:00:00 2001 -From: Koen Kooi -Date: Wed, 8 Jan 2014 09:30:36 +0100 +From 07150f3a27681e034f18ab2ed2b68914c1e10af6 Mon Sep 17 00:00:00 2001 +From: Li xin +Date: Sat, 18 Jul 2015 05:03:57 +0900 Subject: [PATCH] configure.ac: convert AC_TRY_RUN to AC_TRY_LINK statements This is not completely safe, but it's the least invasive fix. +Upstream-Status: pending + Signed-off-by: Koen Kooi -Upstream-status: Inappropriate +Signed-off-by: Li Xin --- - configure.ac | 23 +++++++---------------- - 1 file changed, 7 insertions(+), 16 deletions(-) + configure.ac | 15 +++++---------- + 1 file changed, 5 insertions(+), 10 deletions(-) diff --git a/configure.ac b/configure.ac -index 95984bb..dff1f87 100644 +index 3b32614..94ec002 100644 --- a/configure.ac +++ b/configure.ac -@@ -499,13 +499,10 @@ have_ioloop=no +@@ -519,13 +519,10 @@ have_ioloop=no if test "$ioloop" = "best" || test "$ioloop" = "epoll"; then AC_CACHE_CHECK([whether we can use epoll],i_cv_epoll_works,[ @@ -27,39 +29,12 @@ index 95984bb..dff1f87 100644 - { - return epoll_create(5) < 1; - } -+ ], [ -+ epoll_create(5) < 1; - ], [ - i_cv_epoll_works=yes - ], [ -@@ -551,15 +548,13 @@ have_notify=none - if test "$notify" = "" || test "$notify" = "inotify" ; then - dnl * inotify? - AC_CACHE_CHECK([whether we can use inotify],i_cv_inotify_works,[ -- AC_TRY_RUN([ -+ AC_TRY_LINK([ - #define _GNU_SOURCE - #include - #include - #include - #include -- -- int main() -- { + ], [ - int wd, fd; - char * fn = "/tmp"; - -@@ -581,8 +576,6 @@ if test "$notify" = "" || test "$notify" = "inotify" ; then - inotify_rm_watch (fd, wd); - - close (fd); -- return 0; -- } ++ epoll_create(5) < 1; ], [ - i_cv_inotify_works=yes + i_cv_epoll_works=yes ], [ -@@ -670,7 +663,7 @@ fi +@@ -653,7 +650,7 @@ fi dnl * Old glibcs have broken posix_fallocate(). Make sure not to use it. dnl * It may also be broken in AIX. AC_CACHE_CHECK([whether posix_fallocate() works],i_cv_posix_fallocate_works,[ @@ -68,16 +43,16 @@ index 95984bb..dff1f87 100644 #define _XOPEN_SOURCE 600 #include #include -@@ -679,7 +672,7 @@ AC_CACHE_CHECK([whether posix_fallocate() works],i_cv_posix_fallocate_works,[ +@@ -662,7 +659,7 @@ AC_CACHE_CHECK([whether posix_fallocate() works],i_cv_posix_fallocate_works,[ #if defined(__GLIBC__) && (__GLIBC__ < 2 || __GLIBC_MINOR__ < 7) possibly broken posix_fallocate #endif - int main() { -+ ], [ ++ ], [ int fd = creat("conftest.temp", 0600); int ret; if (fd == -1) { -@@ -688,8 +681,6 @@ AC_CACHE_CHECK([whether posix_fallocate() works],i_cv_posix_fallocate_works,[ +@@ -671,8 +668,6 @@ AC_CACHE_CHECK([whether posix_fallocate() works],i_cv_posix_fallocate_works,[ } ret = posix_fallocate(fd, 1024, 1024) < 0 ? 1 : 0; unlink("conftest.temp"); diff --git a/meta-networking/recipes-support/dovecot/dovecot/building-rquota_xdr.c-depend-on-rquota.h.patch b/meta-networking/recipes-support/dovecot/dovecot/building-rquota_xdr.c-depend-on-rquota.h.patch deleted file mode 100644 index 11d9d8c0d2..0000000000 --- a/meta-networking/recipes-support/dovecot/dovecot/building-rquota_xdr.c-depend-on-rquota.h.patch +++ /dev/null @@ -1,28 +0,0 @@ -[PATCH] building rquota_xdr.c depends on rquota.h - -Upstream-status: Pending - -rquota.h is generated automatically, and building rquota_xdr.c -needs rquota.h, so add the dependency on rquota.h for rquota_xdr.c - -Signed-off-by: rongqing li ---- - src/plugins/quota/Makefile.am | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/src/plugins/quota/Makefile.am b/src/plugins/quota/Makefile.am -index 8a6988d..3626d79 100644 ---- a/src/plugins/quota/Makefile.am -+++ b/src/plugins/quota/Makefile.am -@@ -70,7 +70,7 @@ RQUOTA_XDR = rquota_xdr.c - RQUOTA_XDR_LO = rquota_xdr.lo - #RQUOTA_X = /usr/include/rpcsvc/rquota.x - RQUOTA_X = $(srcdir)/rquota.x --rquota_xdr.c: Makefile $(RQUOTA_X) -+rquota_xdr.c: Makefile $(RQUOTA_X) rquota.h - if [ "$(top_srcdir)" != "$(top_builddir)" ]; then \ - cp $(RQUOTA_X) $(top_builddir)/src/plugins/quota/; \ - fi; \ --- -1.8.2.1 - diff --git a/meta-networking/recipes-support/dovecot/dovecot_2.2.10.bb b/meta-networking/recipes-support/dovecot/dovecot_2.2.10.bb deleted file mode 100644 index 4b2f6c025a..0000000000 --- a/meta-networking/recipes-support/dovecot/dovecot_2.2.10.bb +++ /dev/null @@ -1,65 +0,0 @@ -SUMMARY = "Dovecot is an open source IMAP and POP3 email server" -DESCRIPTION = "Dovecot is an open source IMAP and POP3 email server for Linux/UNIX-like systems, written with security primarily in mind. Dovecot is an excellent choice for both small and large installations. It's fast, simple to set up, requires no special administration and it uses very little memory." -SECTION = "mail" -LICENSE = "LGPLv2.1 & MIT" -LIC_FILES_CHKSUM = "file://COPYING;md5=a981379bd0f1c362f8d1d21515e5b30b" - -SRC_URI = "http://dovecot.org/releases/2.2/dovecot-${PV}.tar.gz \ - file://0001-configure.ac-convert-AC_TRY_RUN-to-AC_TRY_LINK-state.patch \ - file://building-rquota_xdr.c-depend-on-rquota.h.patch \ - file://dovecot.service \ - file://dovecot.socket" - -SRC_URI[md5sum] = "037e9c9e07d9dbff54dcff09f280fc8c" -SRC_URI[sha256sum] = "75592483d40dc4f76cc3b41af40caa4be80478946a699d46846d5d03e4d2e09b" - -DEPENDS = "openssl xz zlib bzip2 libcap" - -inherit autotools pkgconfig systemd useradd - -PACKAGECONFIG ??= " \ - ${@base_contains('DISTRO_FEATURES', 'ldap', 'ldap', '', d)} \ - ${@base_contains('DISTRO_FEATURES', 'pam', 'pam', '', d)} \ - " - -PACKAGECONFIG[pam] = "--with-pam,--without-pam,libpam," -PACKAGECONFIG[ldap] = "--with-ldap=plugin,--without-ldap,openldap," - -# From native build in armv7a-hf/eglibc -CACHED_CONFIGUREVARS += "i_cv_signed_size_t=no \ - i_cv_gmtime_max_time_t=32 \ - i_cv_signed_time_t=yes \ - i_cv_mmap_plays_with_write=yes \ - i_cv_fd_passing=yes \ - i_cv_c99_vsnprintf=yes \ - lib_cv___va_copy=yes \ - lib_cv_va_copy=yes \ - lib_cv_va_val_copy=yes \ - " - -# hardcode epoll() to avoid running unsafe tests -# BSD needs kqueue and uclibc poll() -EXTRA_OECONF = " --with-ioloop=epoll \ - --with-systemdsystemunitdir=${systemd_unitdir}/system" - -SYSTEMD_PACKAGES = "${PN}" -SYSTEMD_SERVICE_${PN} = "dovecot.service dovecot.socket" -SYSTEMD_AUTO_ENABLE = "disable" - -do_install_append () { - install -d 755 ${D}/etc/dovecot - touch 644 ${D}/etc/dovecot/dovecot.conf - install -m 0644 ${WORKDIR}/dovecot.service ${D}${systemd_unitdir}/system - sed -i -e 's#@SYSCONFDIR@#${sysconfdir}#g' ${D}${systemd_unitdir}/system/dovecot.service - sed -i -e 's#@SBINDIR@#${sbindir}#g' ${D}${systemd_unitdir}/system/dovecot.service -} - -USERADD_PACKAGES = "${PN}" -USERADD_PARAM_${PN} = "-r -d ${libexecdir} -M -s ${base_sbindir}/nologin -g dovecot dovecot; \ - -r -d ${libexecdir} -M -s ${base_sbindir}/nologin -g dovenull dovenull" -GROUPADD_PARAM_${PN} = "-f -r dovecot;-f -r dovenull" - -FILES_${PN}-staticdev += "${libdir}/dovecot/*/*.a" -FILES_${PN}-dev += "${libdir}/dovecot/*.so" -FILES_${PN}-dbg += "${libdir}/dovecot/*/.debug" - diff --git a/meta-networking/recipes-support/dovecot/dovecot_2.2.18.bb b/meta-networking/recipes-support/dovecot/dovecot_2.2.18.bb new file mode 100644 index 0000000000..9b5f53613f --- /dev/null +++ b/meta-networking/recipes-support/dovecot/dovecot_2.2.18.bb @@ -0,0 +1,64 @@ +SUMMARY = "Dovecot is an open source IMAP and POP3 email server" +DESCRIPTION = "Dovecot is an open source IMAP and POP3 email server for Linux/UNIX-like systems, written with security primarily in mind. Dovecot is an excellent choice for both small and large installations. It's fast, simple to set up, requires no special administration and it uses very little memory." +SECTION = "mail" +LICENSE = "LGPLv2.1 & MIT" +LIC_FILES_CHKSUM = "file://COPYING;md5=a981379bd0f1c362f8d1d21515e5b30b" + +SRC_URI = "http://dovecot.org/releases/2.2/dovecot-${PV}.tar.gz \ + file://0001-configure.ac-convert-AC_TRY_RUN-to-AC_TRY_LINK-state.patch \ + file://dovecot.service \ + file://dovecot.socket" + +SRC_URI[md5sum] = "1e42eb3b69544c447ad882d7858f3630" +SRC_URI[sha256sum] = "b6d8468cea47f1227f47b80618f7fb872e2b2e9d3302adc107a005dd083865bb" + +DEPENDS = "openssl xz zlib bzip2 libcap icu" + +inherit autotools pkgconfig systemd useradd + +PACKAGECONFIG ??= " \ + ${@base_contains('DISTRO_FEATURES', 'ldap', 'ldap', '', d)} \ + ${@base_contains('DISTRO_FEATURES', 'pam', 'pam', '', d)} \ + " + +PACKAGECONFIG[pam] = "--with-pam,--without-pam,libpam," +PACKAGECONFIG[ldap] = "--with-ldap=plugin,--without-ldap,openldap," + +# From native build in armv7a-hf/eglibc +CACHED_CONFIGUREVARS += "i_cv_signed_size_t=no \ + i_cv_gmtime_max_time_t=32 \ + i_cv_signed_time_t=yes \ + i_cv_mmap_plays_with_write=yes \ + i_cv_fd_passing=yes \ + i_cv_c99_vsnprintf=yes \ + lib_cv___va_copy=yes \ + lib_cv_va_copy=yes \ + lib_cv_va_val_copy=yes \ + " + +# hardcode epoll() to avoid running unsafe tests +# BSD needs kqueue and uclibc poll() +EXTRA_OECONF = " --with-ioloop=epoll \ + --with-systemdsystemunitdir=${systemd_unitdir}/system" + +SYSTEMD_PACKAGES = "${PN}" +SYSTEMD_SERVICE_${PN} = "dovecot.service dovecot.socket" +SYSTEMD_AUTO_ENABLE = "disable" + +do_install_append () { + install -d 755 ${D}/etc/dovecot + touch 644 ${D}/etc/dovecot/dovecot.conf + install -m 0644 ${WORKDIR}/dovecot.service ${D}${systemd_unitdir}/system + sed -i -e 's#@SYSCONFDIR@#${sysconfdir}#g' ${D}${systemd_unitdir}/system/dovecot.service + sed -i -e 's#@SBINDIR@#${sbindir}#g' ${D}${systemd_unitdir}/system/dovecot.service +} + +USERADD_PACKAGES = "${PN}" +USERADD_PARAM_${PN} = "-r -d ${libexecdir} -M -s ${base_sbindir}/nologin -g dovecot dovecot; \ + -r -d ${libexecdir} -M -s ${base_sbindir}/nologin -g dovenull dovenull" +GROUPADD_PARAM_${PN} = "-f -r dovecot;-f -r dovenull" + +FILES_${PN}-staticdev += "${libdir}/dovecot/*/*.a" +FILES_${PN}-dev += "${libdir}/dovecot/*.so" +FILES_${PN}-dbg += "${libdir}/dovecot/*/.debug" + -- cgit v1.2.3-54-g00ecf