diff options
author | madpilot <madpilot@FreeBSD.org> | 2014-04-23 07:39:32 +0800 |
---|---|---|
committer | madpilot <madpilot@FreeBSD.org> | 2014-04-23 07:39:32 +0800 |
commit | efcb01b310ed08f1674c9ac853f0baaec313ef0c (patch) | |
tree | 455b928195ef6d1c824d9ce45624f2e8d2a6b55f /mail | |
parent | f44e7b70beddf036c19e51c951937851e015c697 (diff) | |
download | freebsd-ports-gnome-efcb01b310ed08f1674c9ac853f0baaec313ef0c.tar.gz freebsd-ports-gnome-efcb01b310ed08f1674c9ac853f0baaec313ef0c.tar.zst freebsd-ports-gnome-efcb01b310ed08f1674c9ac853f0baaec313ef0c.zip |
- Prevent from auto-detecting fam library when FAM option is unset
- Add IDN option and stop auto-detection of libidn
- Prefer base iconv
- Add USE_PERL5=build since it is needed only for build
- Use ${opt}_CONFIGURE_OFF knob for MAILWRAPPER option.
PR: ports/188839
Submitted by: Yasuhiro KIMURA <yasu@utahime.org>
Diffstat (limited to 'mail')
-rw-r--r-- | mail/maildrop/Makefile | 15 | ||||
-rw-r--r-- | mail/maildrop/files/patch-libs_unicode_configure | 311 |
2 files changed, 320 insertions, 6 deletions
diff --git a/mail/maildrop/Makefile b/mail/maildrop/Makefile index 5b73e3528f65..1d7f3c6bcab8 100644 --- a/mail/maildrop/Makefile +++ b/mail/maildrop/Makefile @@ -11,6 +11,7 @@ PORTNAME= maildrop PORTVERSION= 2.7.1 +PORTREVISION= 1 CATEGORIES= mail MASTER_SITES= SF/courier/${PORTNAME}/${PORTVERSION} @@ -20,6 +21,7 @@ COMMENT= Mail delivery agent (MDA) with filtering abilities LICENSE= GPLv3 USES= iconv shebangfix perl5 tar:bzip2 +USE_PERL5= build GNU_CONFIGURE= yes CONFIGURE_ARGS= --enable-syslog=1 \ --enable-use-flock=1 \ @@ -58,7 +60,7 @@ OPTIONS_MULTI= AUTHLIB AUTHLIB_DESC= Courier Auth Library support .endif -OPTIONS_DEFINE+= DOVECOTAUTH FAM GDBM MAILWRAPPER +OPTIONS_DEFINE+= DOVECOTAUTH FAM GDBM IDN MAILWRAPPER DOVECOTAUTH_DESC= Dovecot Authentication support MAILWRAPPER_DESC= Let configure guess which sendmail binary to use @@ -67,6 +69,9 @@ OPTIONS_SUB= yes GDBM_CONFIGURE_ON= --with-db=gdbm GDBM_CONFIGURE_OFF= --with-db=db GDBM_LIB_DEPENDS= libgdbm.so:${PORTSDIR}/databases/gdbm +IDN_CONFIGURE_WITH= libidn +IDN_LIB_DEPENDS= libidn.so:${PORTSDIR}/dns/libidn +MAILWRAPPER_CONFIGURE_OFF= --enable-sendmail=/usr/sbin/sendmail .include <bsd.port.options.mk> @@ -84,12 +89,10 @@ PLIST_SUB+= MSGID='' MGID='${MAILDROP_SGID}' PLIST_SUB+= MSGID='@comment ' MGID='mail' .endif -.if ! ${PORT_OPTIONS:MMAILWRAPPER} -CONFIGURE_ARGS+= --enable-sendmail=/usr/sbin/sendmail -.endif - -.if ${PORT_OPTIONS:MFAM} || exists(${LOCALBASE}/lib/libfam.so.0) +.if ${PORT_OPTIONS:MFAM} USES+= fam +.else +CONFIGURE_ARGS+= ac_cv_header_fam_h=no ac_cv_lib_fam_FAMOpen=no .endif .if defined(MAILDROP_TRUSTED_USERS) diff --git a/mail/maildrop/files/patch-libs_unicode_configure b/mail/maildrop/files/patch-libs_unicode_configure new file mode 100644 index 000000000000..dbc3696b2a3a --- /dev/null +++ b/mail/maildrop/files/patch-libs_unicode_configure @@ -0,0 +1,311 @@ +--- libs/unicode/configure.orig 2013-08-26 03:55:18.000000000 +0900 ++++ libs/unicode/configure 2014-04-21 15:49:46.000000000 +0900 +@@ -2382,7 +2382,7 @@ + + ac_config_headers="$ac_config_headers unicode_config.h" + +-am__api_version='1.13' ++am__api_version='1.14' + + # Find a good install program. We prefer a C program (faster), + # so one script is as good as another. But avoid the broken or +@@ -2910,6 +2910,47 @@ + + + ++# POSIX will say in a future version that running "rm -f" with no argument ++# is OK; and we want to be able to make that assumption in our Makefile ++# recipes. So use an aggressive probe to check that the usage we want is ++# actually supported "in the wild" to an acceptable degree. ++# See automake bug#10828. ++# To make any issue more visible, cause the running configure to be aborted ++# by default if the 'rm' program in use doesn't match our expectations; the ++# user can still override this though. ++if rm -f && rm -fr && rm -rf; then : OK; else ++ cat >&2 <<'END' ++Oops! ++ ++Your 'rm' program seems unable to run without file operands specified ++on the command line, even when the '-f' option is present. This is contrary ++to the behaviour of most rm programs out there, and not conforming with ++the upcoming POSIX standard: <http://austingroupbugs.net/view.php?id=542> ++ ++Please tell bug-automake@gnu.org about your system, including the value ++of your $PATH and any error possibly output before this message. This ++can help us improve future automake versions. ++ ++END ++ if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then ++ echo 'Configuration will proceed anyway, since you have set the' >&2 ++ echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2 ++ echo >&2 ++ else ++ cat >&2 <<'END' ++Aborting the configuration process, to ensure you take notice of the issue. ++ ++You can download and install GNU coreutils to get an 'rm' implementation ++that behaves properly: <http://www.gnu.org/software/coreutils/>. ++ ++If you want to complete the configuration process using your problematic ++'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM ++to "yes", and re-run configure. ++ ++END ++ as_fn_error $? "Your 'rm' program is bad, sorry." "$LINENO" 5 ++ fi ++fi + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5 + $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; } +@@ -3959,6 +4000,65 @@ + ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' + ac_compiler_gnu=$ac_cv_c_compiler_gnu + ++ac_ext=c ++ac_cpp='$CPP $CPPFLAGS' ++ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ++ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ++ac_compiler_gnu=$ac_cv_c_compiler_gnu ++{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5 ++$as_echo_n "checking whether $CC understands -c and -o together... " >&6; } ++if ${am_cv_prog_cc_c_o+:} false; then : ++ $as_echo_n "(cached) " >&6 ++else ++ cat confdefs.h - <<_ACEOF >conftest.$ac_ext ++/* end confdefs.h. */ ++ ++int ++main () ++{ ++ ++ ; ++ return 0; ++} ++_ACEOF ++ # Make sure it works both with $CC and with simple cc. ++ # Following AC_PROG_CC_C_O, we do the test twice because some ++ # compilers refuse to overwrite an existing .o file with -o, ++ # though they will create one. ++ am_cv_prog_cc_c_o=yes ++ for am_i in 1 2; do ++ if { echo "$as_me:$LINENO: $CC -c conftest.$ac_ext -o conftest2.$ac_objext" >&5 ++ ($CC -c conftest.$ac_ext -o conftest2.$ac_objext) >&5 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); } \ ++ && test -f conftest2.$ac_objext; then ++ : OK ++ else ++ am_cv_prog_cc_c_o=no ++ break ++ fi ++ done ++ rm -f core conftest* ++ unset am_i ++fi ++{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5 ++$as_echo "$am_cv_prog_cc_c_o" >&6; } ++if test "$am_cv_prog_cc_c_o" != yes; then ++ # Losing compiler, so override with the script. ++ # FIXME: It is wrong to rewrite CC. ++ # But if we don't then we get into trouble of one sort or another. ++ # A longer-term fix would be to have automake use am__CC in this case, ++ # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)" ++ CC="$am_aux_dir/compile $CC" ++fi ++ac_ext=c ++ac_cpp='$CPP $CPPFLAGS' ++ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ++ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ++ac_compiler_gnu=$ac_cv_c_compiler_gnu ++ ++ + depcc="$CC" am_compiler_list= + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 +@@ -10515,14 +10615,10 @@ + # before this can be enabled. + hardcode_into_libs=yes + +- # Add ABI-specific directories to the system library path. +- sys_lib_dlsearch_path_spec="/lib64 /usr/lib64 /lib /usr/lib" +- + # Append ld.so.conf contents to the search path + if test -f /etc/ld.so.conf; then + lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '` +- sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec $lt_ld_extra" +- ++ sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" + fi + + # We used to test for /lib/ld.so.1 and disable shared libraries on +@@ -12055,6 +12151,65 @@ + ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' + ac_compiler_gnu=$ac_cv_c_compiler_gnu + ++ac_ext=c ++ac_cpp='$CPP $CPPFLAGS' ++ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ++ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ++ac_compiler_gnu=$ac_cv_c_compiler_gnu ++{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5 ++$as_echo_n "checking whether $CC understands -c and -o together... " >&6; } ++if ${am_cv_prog_cc_c_o+:} false; then : ++ $as_echo_n "(cached) " >&6 ++else ++ cat confdefs.h - <<_ACEOF >conftest.$ac_ext ++/* end confdefs.h. */ ++ ++int ++main () ++{ ++ ++ ; ++ return 0; ++} ++_ACEOF ++ # Make sure it works both with $CC and with simple cc. ++ # Following AC_PROG_CC_C_O, we do the test twice because some ++ # compilers refuse to overwrite an existing .o file with -o, ++ # though they will create one. ++ am_cv_prog_cc_c_o=yes ++ for am_i in 1 2; do ++ if { echo "$as_me:$LINENO: $CC -c conftest.$ac_ext -o conftest2.$ac_objext" >&5 ++ ($CC -c conftest.$ac_ext -o conftest2.$ac_objext) >&5 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); } \ ++ && test -f conftest2.$ac_objext; then ++ : OK ++ else ++ am_cv_prog_cc_c_o=no ++ break ++ fi ++ done ++ rm -f core conftest* ++ unset am_i ++fi ++{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5 ++$as_echo "$am_cv_prog_cc_c_o" >&6; } ++if test "$am_cv_prog_cc_c_o" != yes; then ++ # Losing compiler, so override with the script. ++ # FIXME: It is wrong to rewrite CC. ++ # But if we don't then we get into trouble of one sort or another. ++ # A longer-term fix would be to have automake use am__CC in this case, ++ # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)" ++ CC="$am_aux_dir/compile $CC" ++fi ++ac_ext=c ++ac_cpp='$CPP $CPPFLAGS' ++ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ++ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ++ac_compiler_gnu=$ac_cv_c_compiler_gnu ++ ++ + depcc="$CC" am_compiler_list= + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 +@@ -15446,14 +15601,10 @@ + # before this can be enabled. + hardcode_into_libs=yes + +- # Add ABI-specific directories to the system library path. +- sys_lib_dlsearch_path_spec="/lib64 /usr/lib64 /lib /usr/lib" +- + # Append ld.so.conf contents to the search path + if test -f /etc/ld.so.conf; then + lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '` +- sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec $lt_ld_extra" +- ++ sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" + fi + + # We used to test for /lib/ld.so.1 and disable shared libraries on +@@ -16405,33 +16556,72 @@ + + fi + +-save_LIBS="$LIBS" +- +-LIBS="$LIBS -liconv" +- ++{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing iconv_open" >&5 ++$as_echo_n "checking for library containing iconv_open... " >&6; } ++if ${ac_cv_search_iconv_open+:} false; then : ++ $as_echo_n "(cached) " >&6 ++else ++ ac_func_search_save_LIBS=$LIBS + cat confdefs.h - <<_ACEOF >conftest.$ac_ext + /* end confdefs.h. */ + +-#include <iconv.h> +- ++/* Override any GCC internal prototype to avoid an error. ++ Use char because int might match the return type of a GCC ++ builtin and then its argument prototype would still apply. */ ++#ifdef __cplusplus ++extern "C" ++#endif ++char iconv_open (); + int + main () + { +- +- +-iconv_open("",""); +- ++return iconv_open (); + ; + return 0; + } + _ACEOF +-if ac_fn_c_try_link "$LINENO"; then : +- : +-else +- LIBS="$save_LIBS" ++for ac_lib in '' iconv; do ++ if test -z "$ac_lib"; then ++ ac_res="none required" ++ else ++ ac_res=-l$ac_lib ++ LIBS="-l$ac_lib $ac_func_search_save_LIBS" ++ fi ++ if ac_fn_c_try_link "$LINENO"; then : ++ ac_cv_search_iconv_open=$ac_res + fi + rm -f core conftest.err conftest.$ac_objext \ +- conftest$ac_exeext conftest.$ac_ext ++ conftest$ac_exeext ++ if ${ac_cv_search_iconv_open+:} false; then : ++ break ++fi ++done ++if ${ac_cv_search_iconv_open+:} false; then : ++ ++else ++ ac_cv_search_iconv_open=no ++fi ++rm conftest.$ac_ext ++LIBS=$ac_func_search_save_LIBS ++fi ++{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_iconv_open" >&5 ++$as_echo "$ac_cv_search_iconv_open" >&6; } ++ac_res=$ac_cv_search_iconv_open ++if test "$ac_res" != no; then : ++ test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" ++ ++else ++ as_fn_error $? "iconv library was not found." "$LINENO" 5 ++fi ++ ++ac_fn_c_check_header_mongrel "$LINENO" "iconv.h" "ac_cv_header_iconv_h" "$ac_includes_default" ++if test "x$ac_cv_header_iconv_h" = xyes; then : ++ ++else ++ as_fn_error $? "iconv.h was not found." "$LINENO" 5 ++fi ++ ++ + + if test "$GCC" = "yes" + then |