pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/mail/spamdyke Fix Linux build by respecting CFLAGS dur...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/453dec6713c3
branches:  trunk
changeset: 771164:453dec6713c3
user:      schmonz <schmonz%pkgsrc.org@localhost>
date:      Tue Dec 14 12:49:35 2021 +0000

description:
Fix Linux build by respecting CFLAGS during configure. Remove unneeded
workaround for FreeBSD 6. NFCI on other platforms. Build-tested on:

- NetBSD 9.2 and -current (9.99.92)
- Tribblix m25.1
- FreeBSD 13
- CentOS 7 and 8
- Devuan 4
- Debian 9, 10, 11
- Ubuntu 16.04.7 LTS, 18.04.6 LTS, and 20.10

diffstat:

 mail/spamdyke/distinfo                   |     7 +-
 mail/spamdyke/patches/patch-Makefile.in  |    26 +
 mail/spamdyke/patches/patch-configure    |  5875 +++++++++++++++++++++++++++++-
 mail/spamdyke/patches/patch-configure.ac |    12 +-
 4 files changed, 5816 insertions(+), 104 deletions(-)

diffs (truncated from 6168 to 300 lines):

diff -r 1819acdc9b6a -r 453dec6713c3 mail/spamdyke/distinfo
--- a/mail/spamdyke/distinfo    Tue Dec 14 10:35:29 2021 +0000
+++ b/mail/spamdyke/distinfo    Tue Dec 14 12:49:35 2021 +0000
@@ -1,11 +1,12 @@
-$NetBSD: distinfo,v 1.37 2021/10/26 10:54:30 nia Exp $
+$NetBSD: distinfo,v 1.38 2021/12/14 12:49:35 schmonz Exp $
 
 BLAKE2s (spamdyke-5.0.1.tgz) = bbee05a4d7529e2aa4ddb58e1a5babe4b3ba35b8dba9c4007d09c67e0e28d07c
 SHA512 (spamdyke-5.0.1.tgz) = a022c8a8d4a8d74f5249f8e2d901d3de423ee853bbaffaf7e86cece1d19880d9039135892ef6ccb8a2a0fb11532c487402dc97a8dd6d89c9de431752c55f6eb9
 Size (spamdyke-5.0.1.tgz) = 383720 bytes
+SHA1 (patch-Makefile.in) = a68d1077ada42e034c9ea3c989aa5ece77887b6c
 SHA1 (patch-configuration.c) = 81548b8a7cc557446d3ecfca3546a129b04a2173
-SHA1 (patch-configure) = 308cde4c9f54c30ce11c7d7c415ebe7caf51732e
-SHA1 (patch-configure.ac) = 23ed678900fbb9b9d1a2613e9267607ac59eb5b8
+SHA1 (patch-configure) = 4800a832a8144a6e394220e5cd09cecaa9e9c2d8
+SHA1 (patch-configure.ac) = c7a17cc40a677db1d0d04a10395aabc214440fa0
 SHA1 (patch-md5.c) = d30f421e28fbc6b87c4dc78f4a2e7f5048c61a45
 SHA1 (patch-spamdyke.h) = 689d4774d78b60a4dd2fbb62a99b218aca9b500b
 SHA1 (patch-tls.c) = 1cc05d30dfd3736727c6203a81ebb24c44cd2c1f
diff -r 1819acdc9b6a -r 453dec6713c3 mail/spamdyke/patches/patch-Makefile.in
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/mail/spamdyke/patches/patch-Makefile.in   Tue Dec 14 12:49:35 2021 +0000
@@ -0,0 +1,26 @@
+$NetBSD: patch-Makefile.in,v 1.1 2021/12/14 12:49:35 schmonz Exp $
+
+Remove unneeded workaround.
+
+--- Makefile.in.orig   2015-04-30 00:53:36.000000000 +0000
++++ Makefile.in
+@@ -17,7 +17,6 @@
+ # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
+ 
+ CC := @CC@
+-CPP := @CPP@
+ CFLAGS := @CFLAGS@ -funsigned-char @CPPFLAGS@
+ LDFLAGS := @LDFLAGS@
+ LIBS := @LIBS@
+@@ -59,10 +58,8 @@ filter.o: filter.c filter.h Makefile spa
+       $(CC) $(CFLAGS) $(DEFS) -c filter.c
+ cdb.o: cdb.c cdb.h Makefile spamdyke.h config.h
+       $(CC) $(CFLAGS) $(DEFS) -c cdb.c
+-
+-# This avoids a gcc segfault on FreeBSD 6.0.
+ configuration.o: configuration.c configuration.h Makefile spamdyke.h config.h
+-      $(CPP) $(CFLAGS) $(DEFS) configuration.c | $(CC) $(CFLAGS) $(DEFS) -x c -c -o configuration.o -
++      $(CC) $(CFLAGS) $(DEFS) -c configuration.c
+ 
+ clean:
+       rm -rf spamdyke *.o .gdb_history *.dSYM
diff -r 1819acdc9b6a -r 453dec6713c3 mail/spamdyke/patches/patch-configure
--- a/mail/spamdyke/patches/patch-configure     Tue Dec 14 10:35:29 2021 +0000
+++ b/mail/spamdyke/patches/patch-configure     Tue Dec 14 12:49:35 2021 +0000
@@ -1,15 +1,16 @@
-$NetBSD: patch-configure,v 1.2 2020/07/02 08:50:09 schmonz Exp $
+$NetBSD: patch-configure,v 1.3 2021/12/14 12:49:35 schmonz Exp $
 
 Remove anonymous inner functions to build with clang.
 Remove outdated OpenSSL check to build with 1.1.x.
+Respect CFLAGS.
 
 --- configure.orig     2015-04-30 00:53:36.000000000 +0000
 +++ configure
-@@ -1,13 +1,11 @@
+@@ -1,13 +1,12 @@
  #! /bin/sh
  # Guess values for system-dependent variables and create Makefiles.
 -# Generated by GNU Autoconf 2.68 for spamdyke 5.0.1.
-+# Generated by GNU Autoconf 2.69 for spamdyke 5.0.1.
++# Generated by GNU Autoconf 2.71 for spamdyke 5.0.1.
  #
  # Report bugs to <samc (at) silence (dot) org>.
  #
@@ -17,13 +18,170 @@
 -# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
 -# 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 Free Software
 -# Foundation, Inc.
-+# Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
++# Copyright (C) 1992-1996, 1998-2017, 2020-2021 Free Software Foundation,
++# Inc.
  #
  #
  # This configure script is free software; the Free Software Foundation
-@@ -136,6 +134,31 @@ export LANGUAGE
- # CDPATH.
- (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
+@@ -18,14 +17,16 @@
+ 
+ # Be more Bourne compatible
+ DUALCASE=1; export DUALCASE # for MKS sh
+-if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
++as_nop=:
++if test ${ZSH_VERSION+y} && (emulate sh) >/dev/null 2>&1
++then :
+   emulate sh
+   NULLCMD=:
+   # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
+   # is contrary to our usage.  Disable this feature.
+   alias -g '${1+"$@"}'='"$@"'
+   setopt NO_GLOB_SUBST
+-else
++else $as_nop
+   case `(set -o) 2>/dev/null` in #(
+   *posix*) :
+     set -o posix ;; #(
+@@ -35,46 +36,46 @@ esac
+ fi
+ 
+ 
++
++# Reset variables that may have inherited troublesome values from
++# the environment.
++
++# IFS needs to be set, to space, tab, and newline, in precisely that order.
++# (If _AS_PATH_WALK were called with IFS unset, it would have the
++# side effect of setting IFS to empty, thus disabling word splitting.)
++# Quoting is to prevent editors from complaining about space-tab.
+ as_nl='
+ '
+ export as_nl
+-# Printing a long string crashes Solaris 7 /usr/bin/printf.
+-as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
+-as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
+-as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
+-# Prefer a ksh shell builtin over an external printf program on Solaris,
+-# but without wasting forks for bash or zsh.
+-if test -z "$BASH_VERSION$ZSH_VERSION" \
+-    && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
+-  as_echo='print -r --'
+-  as_echo_n='print -rn --'
+-elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
+-  as_echo='printf %s\n'
+-  as_echo_n='printf %s'
+-else
+-  if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
+-    as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
+-    as_echo_n='/usr/ucb/echo -n'
+-  else
+-    as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
+-    as_echo_n_body='eval
+-      arg=$1;
+-      case $arg in #(
+-      *"$as_nl"*)
+-      expr "X$arg" : "X\\(.*\\)$as_nl";
+-      arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
+-      esac;
+-      expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
+-    '
+-    export as_echo_n_body
+-    as_echo_n='sh -c $as_echo_n_body as_echo'
+-  fi
+-  export as_echo_body
+-  as_echo='sh -c $as_echo_body as_echo'
+-fi
++IFS=" ""      $as_nl"
++
++PS1='$ '
++PS2='> '
++PS4='+ '
++
++# Ensure predictable behavior from utilities with locale-dependent output.
++LC_ALL=C
++export LC_ALL
++LANGUAGE=C
++export LANGUAGE
++
++# We cannot yet rely on "unset" to work, but we need these variables
++# to be unset--not just set to an empty or harmless value--now, to
++# avoid bugs in old shells (e.g. pre-3.0 UWIN ksh).  This construct
++# also avoids known problems related to "unset" and subshell syntax
++# in other old shells (e.g. bash 2.01 and pdksh 5.2.14).
++for as_var in BASH_ENV ENV MAIL MAILPATH CDPATH
++do eval test \${$as_var+y} \
++  && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
++done
++
++# Ensure that fds 0, 1, and 2 are open.
++if (exec 3>&0) 2>/dev/null; then :; else exec 0</dev/null; fi
++if (exec 3>&1) 2>/dev/null; then :; else exec 1>/dev/null; fi
++if (exec 3>&2)            ; then :; else exec 2>/dev/null; fi
+ 
+ # The user is always right.
+-if test "${PATH_SEPARATOR+set}" != set; then
++if ${PATH_SEPARATOR+false} :; then
+   PATH_SEPARATOR=:
+   (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
+     (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
+@@ -83,13 +84,6 @@ if test "${PATH_SEPARATOR+set}" != set;
+ fi
+ 
+ 
+-# IFS
+-# We need space, tab and new line, in precisely that order.  Quoting is
+-# there to prevent editors from complaining about space-tab.
+-# (If _AS_PATH_WALK were called with IFS unset, it would disable word
+-# splitting by setting IFS to empty value.)
+-IFS=" ""      $as_nl"
+-
+ # Find who we are.  Look in the path if we contain no directory separator.
+ as_myself=
+ case $0 in #((
+@@ -98,8 +92,12 @@ case $0 in #((
+ for as_dir in $PATH
+ do
+   IFS=$as_save_IFS
+-  test -z "$as_dir" && as_dir=.
+-    test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
++  case $as_dir in #(((
++    '') as_dir=./ ;;
++    */) ;;
++    *) as_dir=$as_dir/ ;;
++  esac
++    test -r "$as_dir$0" && as_myself=$as_dir$0 && break
+   done
+ IFS=$as_save_IFS
+ 
+@@ -111,40 +109,47 @@ if test "x$as_myself" = x; then
+   as_myself=$0
+ fi
+ if test ! -f "$as_myself"; then
+-  $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
++  printf "%s\n" "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
+   exit 1
+ fi
+ 
+-# Unset variables that we do not need and which cause bugs (e.g. in
+-# pre-3.0 UWIN ksh).  But do not cause bugs in bash 2.01; the "|| exit 1"
+-# suppresses any "Segmentation fault" message there.  '((' could
+-# trigger a bug in pdksh 5.2.14.
+-for as_var in BASH_ENV ENV MAIL MAILPATH
+-do eval test x\${$as_var+set} = xset \
+-  && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
+-done
+-PS1='$ '
+-PS2='> '
+-PS4='+ '
+-
+-# NLS nuisances.
+-LC_ALL=C
+-export LC_ALL
+-LANGUAGE=C
+-export LANGUAGE
+-
+-# CDPATH.
+-(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
  
 +# Use a proper internal environment variable to ensure we don't fall
 +  # into an infinite loop, continuously re-executing ourselves.
@@ -45,28 +203,114 @@
 +exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
 +# Admittedly, this is quite paranoid, since all the known shells bail
 +# out after a failed `exec'.
-+$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
-+as_fn_exit 255
++printf "%s\n" "$0: could not re-execute with $CONFIG_SHELL" >&2
++exit 255
 +  fi
 +  # We don't want this to propagate to other subprocesses.
 +          { _as_can_reexec=; unset _as_can_reexec;}
  if test "x$CONFIG_SHELL" = x; then
-   as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
+-  as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
++  as_bourne_compatible="as_nop=:
++if test \${ZSH_VERSION+y} && (emulate sh) >/dev/null 2>&1
++then :
    emulate sh
-@@ -169,7 +192,8 @@ if ( set x; as_fn_ret_success y && test 
- else
+   NULLCMD=:
+   # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
+   # is contrary to our usage.  Disable this feature.
+   alias -g '\${1+\"\$@\"}'='\"\$@\"'
+   setopt NO_GLOB_SUBST
+-else
++else \$as_nop
+   case \`(set -o) 2>/dev/null\` in #(
+   *posix*) :
+     set -o posix ;; #(
+@@ -164,41 +169,52 @@ as_fn_success || { exitcode=1; echo as_f
+ as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
+ as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
+ as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
+-if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
++if ( set x; as_fn_ret_success y && test x = \"\$1\" )
++then :
+ 
+-else
++else \$as_nop
    exitcode=1; echo positional parameters were not saved.
  fi
 -test x\$exitcode = x0 || exit 1"
 +test x\$exitcode = x0 || exit 1
++blah=\$(echo \$(echo blah))
++test x\"\$blah\" = xblah || exit 1
 +test -x / || exit 1"
    as_suggested="  as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
    as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
    eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
-@@ -214,21 +238,25 @@ IFS=$as_save_IFS
- 
- 



Home | Main Index | Thread Index | Old Index