diff --git a/mail/anubis/Makefile b/mail/anubis/Makefile index 05a181702f9d..4b7d13325b66 100644 --- a/mail/anubis/Makefile +++ b/mail/anubis/Makefile @@ -1,117 +1,106 @@ PORTNAME= anubis -PORTVERSION= 4.2 -PORTREVISION= 17 +PORTVERSION= 4.3 CATEGORIES= mail MASTER_SITES= GNU MAINTAINER= jhale@FreeBSD.org COMMENT= Outgoing SMTP mail processor WWW= https://www.gnu.org/software/anubis/ LICENSE= GPLv3 LICENSE_FILE= ${WRKSRC}/COPYING -USES= autoreconf charsetfix cpe localbase makeinfo \ - pkgconfig shebangfix +LIB_DEPENDS= libgnutls.so:security/gnutls \ + libgcrypt.so:security/libgcrypt \ + libgpg-error.so:security/libgpg-error \ + libgsasl.so:security/libgsasl + +USES= autoreconf charsetfix cpe gettext-tools gmake localbase \ + makeinfo pkgconfig shebangfix CHARSETFIX_MAKEFILEIN= gnulib.mk CPE_VENDOR= gnu SHEBANG_FILES= contrib/msg2smtp.pl USE_RC_SUBR= anubis + GNU_CONFIGURE= yes +CONFIGURE_ARGS= --with-gnutls \ + --with-gsasl INFO= anubis PORTEXAMPLES= 1anubisrc 2anubisrc -OPTIONS_DEFINE= NLS EXAMPLES EMACS GUILE GNUPG GNUTLS \ - GSASL LIBWRAP PCRE PAM SOCKS TEST +OPTIONS_DEFINE= NLS EXAMPLES EMACS GUILE GNUPG LIBWRAP PCRE PAM \ + SOCKS TEST DB_DESC= Database backend OPTIONS_GROUP= DB OPTIONS_GROUP_DB= GDBM MYSQL PGSQL -OPTIONS_DEFAULT= GDBM GNUPG GNUTLS GSASL GUILE -OPTIONS_EXCLUDE_aarch64=TEST +OPTIONS_DEFAULT= GDBM GNUPG GUILE OPTIONS_SUB= yes NO_OPTIONS_SORT= yes .if !exists(/usr/include/tcpd.h) OPTIONS_EXCLUDE+= LIBWRAP .endif .if !exists(/usr/lib/libpam.so) OPTIONS_EXCLUDE+= PAM .endif EMACS_DESC= Install EMACS lisp files (requires emacs) EMACS_USES= emacs:build EMACS_CONFIGURE_ON= --with-lispdir=${PREFIX}/${EMACS_SITE_LISPDIR}/anubis EMACS_CONFIGURE_OFF= --with-lispdir=no -GDBM_IMPLIES= GSASL GDBM_LIB_DEPENDS= libgdbm.so:databases/gdbm GDBM_CONFIGURE_WITH= gdbm -GNUPG_LIB_DEPENDS= libgpgme.so:security/gpgme \ - libgpg-error.so:security/libgpg-error +GNUPG_LIB_DEPENDS= libgpgme.so:security/gpgme GNUPG_CONFIGURE_WITH= gpgme -GNUTLS_LIB_DEPENDS= libgnutls.so:security/gnutls \ - libgcrypt.so:security/libgcrypt -GNUTLS_CONFIGURE_WITH= gnutls - -GSASL_DESC= GSASL support (required for databases) -GSASL_LIB_DEPENDS= libgsasl.so:security/libgsasl -GSASL_CONFIGURE_WITH= gsasl - -GUILE_USES= guile:1.8,alias +GUILE_USES= guile:2.2,alias GUILE_CONFIGURE_WITH= guile GUILE_PORTEXAMPLES= anubis.scm anubisrc.guile LIBWRAP_CONFIGURE_WITH= tcp-wrappers -MYSQL_IMPLIES= GSASL MYSQL_USES= mysql MYSQL_CONFIGURE_WITH= mysql MYSQL_VARS= REQUIRE+=mysql -NLS_USES= gettext iconv NLS_CONFIGURE_ENABLE= nls PAM_CONFIGURE_WITH= pam PAM_PORTEXAMPLES= pam PCRE_LIB_DEPENDS= libpcre.so:devel/pcre PCRE_CONFIGURE_WITH= pcre -PGSQL_IMPLIES= GSASL PGSQL_USES= pgsql PGSQL_CONFIGURE_WITH= postgres PGSQL_VARS= REQUIRE+=postgresql SOCKS_CONFIGURE_WITH= socks-proxy +TEST_TEST_TARGET= check + .include # Default requirement for anubis rc script REQUIRE+= mail SUB_LIST+= REQUIRE="${REQUIRE}" -post-patch: - @${REINPLACE_CMD} -e "s|/etc|${PREFIX}/etc|g" ${WRKSRC}/src/headers.h - @${REINPLACE_CMD} -e 's,gdbm_db_,db_gdbm_,g' \ - ${WRKSRC}/src/anubisadm.c ${WRKSRC}/src/gdbm.c \ - ${WRKSRC}/src/headers.h ${WRKSRC}/src/main.c - post-patch-TEST-off: - @${REINPLACE_CMD} -e 's| testsuite||' ${WRKSRC}/Makefile.am + @${REINPLACE_CMD} -e 's| tests||' ${WRKSRC}/Makefile.am post-install-EXAMPLES-on: @${MKDIR} ${STAGEDIR}${EXAMPLESDIR} ${INSTALL_DATA} ${WRKSRC}/examples/*rc ${STAGEDIR}${EXAMPLESDIR} .if ${PORT_OPTIONS:MGUILE} cd ${WRKSRC}/examples && \ ${INSTALL_DATA} ${GUILE_PORTEXAMPLES} ${STAGEDIR}${EXAMPLESDIR} .endif .if ${PORT_OPTIONS:MPAM} @${MKDIR} ${STAGEDIR}${EXAMPLESDIR}/pam ${INSTALL_DATA} ${WRKSRC}/examples/pam/anubis* ${STAGEDIR}${EXAMPLESDIR}/pam .endif .include diff --git a/mail/anubis/distinfo b/mail/anubis/distinfo index b4d82e30637c..031d7eadbdaf 100644 --- a/mail/anubis/distinfo +++ b/mail/anubis/distinfo @@ -1,2 +1,3 @@ -SHA256 (anubis-4.2.tar.gz) = 5f3a2dd77c5ef52a593428c5b6d0042c1746eb8262c31bde9ee67455f8aad6d6 -SIZE (anubis-4.2.tar.gz) = 1623768 +TIMESTAMP = 1704667011 +SHA256 (anubis-4.3.tar.gz) = ff0af3337c462218e5ee244c7ef90188af9efdf095bc05b6333401cf9882af2c +SIZE (anubis-4.3.tar.gz) = 1248000 diff --git a/mail/anubis/files/patch-configure.ac b/mail/anubis/files/patch-configure.ac index 2026a8db65cd..628bedff40c8 100644 --- a/mail/anubis/files/patch-configure.ac +++ b/mail/anubis/files/patch-configure.ac @@ -1,52 +1,52 @@ ---- configure.ac.orig 2014-05-23 20:25:28 UTC +--- configure.ac.orig 2024-01-05 16:09:47 UTC +++ configure.ac -@@ -78,7 +78,6 @@ AH_BOTTOM([ - ]) +@@ -96,7 +96,6 @@ AC_CHECK_LIB(socket, socket) + AC_CHECK_FUNCS(daemon putenv) AC_CHECK_LIB(socket, socket) -AC_CHECK_LIB(nsl, gethostbyaddr) - AC_SUBST(ADD_INCLUDES) - case $build in -@@ -179,11 +178,21 @@ MU_CHECK_GSASL(0.2.3, [ + AM_PATH_LIBGCRYPT([1.7.0], [status_gcrypt=yes], [status_gcrypt=no]) + AM_CONDITIONAL([GCRYPT_COND], [test "$status_gcrypt" = yes]) +@@ -198,11 +197,21 @@ MU_CHECK_GSASL(0.2.3, [ + ANUBIS_SBIN_ADM='$(adm_sbin_programs)' ANUBIS_BIN_ADM='$(adm_bin_programs)' - M4_DEFS="$M4_DEFS -DWITH_GSASL" + AC_ARG_WITH(gdbm, + AC_HELP_STRING([--with-gdbm], + [Configure to work with GDBM]), + [with_gdbm=${withval}], + [with_gdbm=no]) + if test "$with_gdbm" = "yes"; then AC_CHECK_LIB(gdbm, gdbm_open, [WITH_GDBM=yes LIBS="$LIBS -lgdbm" AC_DEFINE(HAVE_LIBGDBM,1,[Define if you have libgdbm])], - [AC_MSG_RESULT([Disabling GDBM support...])]) + with_gdbm=no) + fi + if test "$with_gdbm" = "yes"; then + AC_MSG_RESULT([Enabling GDBM support...]) + fi AC_ARG_WITH(mysql, - AC_HELP_STRING([--with-mysql], -@@ -285,8 +294,8 @@ AC_ARG_WITH(pam, + AS_HELP_STRING([--with-mysql],[Configure to work with MySQL]), +@@ -301,8 +310,8 @@ if test "$with_pam" = "yes"; then [with_pam=no]) if test "$with_pam" = "yes"; then AC_CHECK_LIB(pam, main,, with_pam=no) - AC_CHECK_LIB(pam_misc, main,, with_pam=no) - AC_CHECK_HEADERS(security/pam_appl.h security/pam_misc.h,, with_pam=no) + AC_CHECK_HEADER(security/pam_appl.h,, with_pam=no) + AC_CHECK_HEADER(security/openpam.h,, with_pam=no, [ #include ]) fi if test "$with_pam" = "yes"; then AC_MSG_RESULT([Enabling PAM support...]) -@@ -300,7 +309,6 @@ AC_ARG_WITH(tcp-wrappers, +@@ -315,7 +324,6 @@ if test "$with_tcp_wrappers" = "yes"; then [with_tcp_wrappers=no]) if test "$with_tcp_wrappers" = "yes"; then AC_CHECK_LIB(wrap, main,, with_tcp_wrappers=no) - AC_CHECK_LIB(nsl, main,, with_tcp_wrappers=no) AC_CHECK_HEADERS(tcpd.h,, with_tcp_wrappers=no) fi if test "$with_tcp_wrappers" = "yes"; then diff --git a/mail/anubis/files/patch-src_Makefile.am b/mail/anubis/files/patch-src_Makefile.am deleted file mode 100644 index 21afe4b9beb6..000000000000 --- a/mail/anubis/files/patch-src_Makefile.am +++ /dev/null @@ -1,32 +0,0 @@ ---- src/Makefile.am.orig 2014-05-16 04:19:46 UTC -+++ src/Makefile.am -@@ -25,7 +25,7 @@ bin_PROGRAMS = @ANUBIS_BIN_ADM@ - EXTRA_PROGRAMS = $(adm_bin_programs) $(adm_sbin_programs) - - noinst_LIBRARIES = libanubisdb.a --anubis_LDADD = ./libanubisdb.a $(top_builddir)/lib/libanubis.a\ -+anubis_LDADD = libanubisdb.a $(top_builddir)/lib/libanubis.a\ - @LIBINTL@ $(GUILE_LIBS) @LIBGNUTLS_LIBS@ @GSASL_LIBS@ - - anubis_SOURCES = \ -@@ -65,9 +65,9 @@ anubis_SOURCES = \ - xdatabase.c - - anubisadm_SOURCES = anubisadm.c anubisadm.h adm.c --anubisadm_LDADD = ./libanubisdb.a $(top_builddir)/lib/libanubis.a @LIBINTL@ -+anubisadm_LDADD = libanubisdb.a $(top_builddir)/lib/libanubis.a @LIBINTL@ - anubisusr_SOURCES = anubisusr.c anubisusr.h usr.c --anubisusr_LDADD = ./libanubisdb.a $(top_builddir)/lib/libanubis.a @LIBINTL@ @LIBGNUTLS_LIBS@ @GSASL_LIBS@ -+anubisusr_LDADD = libanubisdb.a $(top_builddir)/lib/libanubis.a @LIBINTL@ @LIBGNUTLS_LIBS@ @GSASL_LIBS@ - - if TLS_COND - TLS_C=tls.c -@@ -99,7 +99,7 @@ BUILT_SOURCES = env.c - - localedir = $(datadir)/locale - DEFS = @DEFS@ -DLOCALEDIR=\"$(localedir)\" --AM_CPPFLAGS = @ADD_INCLUDES@ @LIBGNUTLS_INCLUDES@ -I$(top_srcdir)/lib -+AM_CPPFLAGS = @ADD_INCLUDES@ @LIBGNUTLS_INCLUDES@ @GUILE_INCLUDES@ -I$(top_srcdir)/lib - SUFFIXES=.opt .c - - .opt.c: diff --git a/mail/anubis/files/patch-src_anubisadm.h b/mail/anubis/files/patch-src_anubisadm.h deleted file mode 100644 index 46f435332ec3..000000000000 --- a/mail/anubis/files/patch-src_anubisadm.h +++ /dev/null @@ -1,17 +0,0 @@ ---- src/anubisadm.h.orig 2020-08-27 18:29:03 UTC -+++ src/anubisadm.h -@@ -26,10 +26,10 @@ - - typedef int (*operation_fp) (int, char **); - --char *authid; --char *username; --char *rcfile; --char *password; -+extern char *authid; -+extern char *username; -+extern char *rcfile; -+extern char *password; - - int op_create (int argc, char **argv); - int op_list (int argc, char **argv); diff --git a/mail/anubis/files/patch-src_anubisusr.h b/mail/anubis/files/patch-src_anubisusr.h new file mode 100644 index 000000000000..552ec045ead3 --- /dev/null +++ b/mail/anubis/files/patch-src_anubisusr.h @@ -0,0 +1,13 @@ +--- src/anubisusr.h.orig 2024-01-05 16:03:09 UTC ++++ src/anubisusr.h +@@ -25,10 +25,6 @@ + #include + #include "getopt.h" + +-#define obstack_chunk_alloc malloc +-#define obstack_chunk_free free +-#include +- + #if defined(USE_GNUTLS) + # include + # define HAVE_TLS diff --git a/mail/anubis/files/patch-src_env.c b/mail/anubis/files/patch-src_env.c index ab785c8c4c14..9690f158db94 100644 --- a/mail/anubis/files/patch-src_env.c +++ b/mail/anubis/files/patch-src_env.c @@ -1,11 +1,11 @@ ---- src/env.c.orig 2014-05-17 20:26:43 UTC +--- src/env.c.orig 2024-01-05 16:10:48 UTC +++ src/env.c -@@ -30,7 +30,7 @@ - #ifdef HAVE_PAM +@@ -31,7 +31,7 @@ static struct pam_conv conv = { + # define USE_PAM 1 pam_handle_t *pamh; static struct pam_conv conv = { - misc_conv, + openpam_ttyconv, NULL }; - #endif /* HAVE_PAM */ + #else diff --git a/mail/anubis/files/patch-src_pgsql.c b/mail/anubis/files/patch-src_pgsql.c new file mode 100644 index 000000000000..02522ec3e6d7 --- /dev/null +++ b/mail/anubis/files/patch-src_pgsql.c @@ -0,0 +1,13 @@ +Fix header location. + +--- src/pgsql.c.orig 2024-01-08 01:45:50 UTC ++++ src/pgsql.c +@@ -24,7 +24,7 @@ + #ifdef WITH_PGSQL + + #include "sql.h" +-#include ++#include + + /* PostgreSQL URL: + diff --git a/mail/anubis/files/patch-src_rcfile.h b/mail/anubis/files/patch-src_rcfile.h deleted file mode 100644 index 8b8e005f3f06..000000000000 --- a/mail/anubis/files/patch-src_rcfile.h +++ /dev/null @@ -1,11 +0,0 @@ ---- src/rcfile.h.orig 2020-08-27 18:24:43 UTC -+++ src/rcfile.h -@@ -213,7 +213,7 @@ typedef void (*RC_ERROR_PRINTER) (void *data, - const char *fmt, va_list ap); - - /* Global data */ --struct rc_loc rc_locus; -+extern struct rc_loc rc_locus; - - /* Function declarations */ - void verbatim (void); diff --git a/mail/anubis/files/patch-tests_anustart.c b/mail/anubis/files/patch-tests_anustart.c new file mode 100644 index 000000000000..a5260bc10d87 --- /dev/null +++ b/mail/anubis/files/patch-tests_anustart.c @@ -0,0 +1,10 @@ +--- tests/anustart.c.orig 2024-01-05 16:03:10 UTC ++++ tests/anustart.c +@@ -64,6 +64,7 @@ + #include + #include + #include ++#include + + char const *progname; + diff --git a/mail/anubis/pkg-plist b/mail/anubis/pkg-plist index 3340f18eafbc..27388300cc33 100644 --- a/mail/anubis/pkg-plist +++ b/mail/anubis/pkg-plist @@ -1,30 +1,32 @@ -%%GSASL%%bin/anubisusr +bin/anubisusr bin/msg2smtp.pl sbin/anubis man/man1/anubis.1.gz -%%GSASL%%sbin/anubisadm +sbin/anubisadm %%GUILE%%share/anubis/entire-msg.scm %%GUILE%%share/anubis/remailer.scm %%GUILE%%share/anubis/rot-13.scm %%EMACS%%%%EMACS_SITE_LISPDIR%%/anubis/anubis-mode.el %%EMACS%%%%EMACS_SITE_LISPDIR%%/anubis/anubis-mode.elc %%NLS%%share/locale/da/LC_MESSAGES/anubis.mo %%NLS%%share/locale/de/LC_MESSAGES/anubis.mo %%NLS%%share/locale/es/LC_MESSAGES/anubis.mo %%NLS%%share/locale/fi/LC_MESSAGES/anubis.mo %%NLS%%share/locale/fr/LC_MESSAGES/anubis.mo +%%NLS%%share/locale/hu/LC_MESSAGES/anubis.mo %%NLS%%share/locale/hr/LC_MESSAGES/anubis.mo %%NLS%%share/locale/id/LC_MESSAGES/anubis.mo %%NLS%%share/locale/it/LC_MESSAGES/anubis.mo %%NLS%%share/locale/ms/LC_MESSAGES/anubis.mo %%NLS%%share/locale/nb/LC_MESSAGES/anubis.mo %%NLS%%share/locale/nl/LC_MESSAGES/anubis.mo %%NLS%%share/locale/pl/LC_MESSAGES/anubis.mo +%%NLS%%share/locale/pt/LC_MESSAGES/anubis.mo %%NLS%%share/locale/ro/LC_MESSAGES/anubis.mo %%NLS%%share/locale/ru/LC_MESSAGES/anubis.mo %%NLS%%share/locale/sr/LC_MESSAGES/anubis.mo %%NLS%%share/locale/sv/LC_MESSAGES/anubis.mo %%NLS%%share/locale/tr/LC_MESSAGES/anubis.mo %%NLS%%share/locale/uk/LC_MESSAGES/anubis.mo %%NLS%%share/locale/vi/LC_MESSAGES/anubis.mo %%NLS%%share/locale/zh_CN/LC_MESSAGES/anubis.mo