diff options
-rw-r--r-- | Makefile.am | 2 | ||||
-rw-r--r-- | NEWS | 4 | ||||
-rw-r--r-- | am/mailutils.m4 | 89 | ||||
-rw-r--r-- | configure.ac | 4 | ||||
-rw-r--r-- | tests/.gitignore | 1 | ||||
-rw-r--r-- | tests/Makefile.am | 6 | ||||
-rw-r--r-- | tests/atlocal.in | 2 | ||||
-rw-r--r-- | tests/check-notify.at | 4 | ||||
-rw-r--r-- | tests/etc/Makefile.am | 1 | ||||
-rw-r--r-- | tests/etc/mailstats.rcin | 2 | ||||
-rw-r--r-- | tests/etc/notify.rcin | 2 | ||||
-rwxr-xr-x | tests/etc/nullmail | 11 | ||||
-rw-r--r-- | tests/mailstats.at | 4 | ||||
-rw-r--r-- | tests/notify-upl.at | 8 | ||||
-rw-r--r-- | tests/nullmail.c | 84 |
15 files changed, 192 insertions, 32 deletions
diff --git a/Makefile.am b/Makefile.am index 831bc79..897c567 100644 --- a/Makefile.am +++ b/Makefile.am | |||
@@ -14,7 +14,7 @@ | |||
14 | # You should have received a copy of the GNU General Public License | 14 | # You should have received a copy of the GNU General Public License |
15 | # along with wydawca. If not, see <http://www.gnu.org/licenses/>. | 15 | # along with wydawca. If not, see <http://www.gnu.org/licenses/>. |
16 | 16 | ||
17 | ACLOCAL_AMFLAGS = -I m4 -I grecs/am -I imprimatur | 17 | ACLOCAL_AMFLAGS = -I m4 -I am -I grecs/am -I imprimatur |
18 | 18 | ||
19 | SUBDIRS=grecs libltdl include src modules imprimatur doc etc tests | 19 | SUBDIRS=grecs libltdl include src modules imprimatur doc etc tests |
20 | 20 | ||
@@ -1,11 +1,11 @@ | |||
1 | Wydawca NEWS -- history of user-visible changes. 2013-03-12 | 1 | Wydawca NEWS -- history of user-visible changes. 2017-11-11 |
2 | Copyright (C) 2007-2013, 2017 Sergey Poznyakoff | 2 | Copyright (C) 2007-2013, 2017 Sergey Poznyakoff |
3 | See the end of file for copying conditions. | 3 | See the end of file for copying conditions. |
4 | 4 | ||
5 | Please send Wydawca bug reports to <bug-wydawca@gnu.org.ua>. | 5 | Please send Wydawca bug reports to <bug-wydawca@gnu.org.ua>. |
6 | 6 | ||
7 | 7 | ||
8 | Version 2.99.90 | 8 | Version 2.99.91 (git) |
9 | 9 | ||
10 | Version 2.2 "HGY", 2013-01-01 | 10 | Version 2.2 "HGY", 2013-01-01 |
11 | 11 | ||
diff --git a/am/mailutils.m4 b/am/mailutils.m4 new file mode 100644 index 0000000..9bb79a0 --- /dev/null +++ b/am/mailutils.m4 | |||
@@ -0,0 +1,89 @@ | |||
1 | dnl A fixed version of AM_MAILUTILS macro. | ||
2 | dnl The macro shipped with mailutils 3.3 mishandles the "mailer" | ||
3 | dnl link requirement. Until it is fixed upstream, wydawca will be | ||
4 | dnl using this version. | ||
5 | |||
6 | dnl Copyright (C) 2006-2007, 2010-2012, 2014-2017 Free Software | ||
7 | dnl Foundation, Inc. | ||
8 | dnl | ||
9 | dnl GNU Mailutils is free software; you can redistribute it and/or | ||
10 | dnl modify it under the terms of the GNU General Public License as | ||
11 | dnl published by the Free Software Foundation; either version 3, or (at | ||
12 | dnl your option) any later version. | ||
13 | dnl | ||
14 | dnl GNU Mailutils is distributed in the hope that it will be useful, but | ||
15 | dnl WITHOUT ANY WARRANTY; without even the implied warranty of | ||
16 | dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | ||
17 | dnl General Public License for more details. | ||
18 | dnl | ||
19 | dnl You should have received a copy of the GNU General Public License | ||
20 | dnl along with GNU Mailutils. If not, see <http://www.gnu.org/licenses/>. | ||
21 | |||
22 | m4_define([am_mu_vercmp],[ | ||
23 | m4_pushdef([_ver_A_],m4_car($1))dnl | ||
24 | m4_pushdef([_ver_B_],m4_car($2))dnl | ||
25 | m4_if(_ver_B_,,:,[if test m4_if(_ver_A_,,0,_ver_A_) -lt _ver_B_; then | ||
26 | $3 | ||
27 | elif test m4_if(_ver_A_,,0,_ver_A_) -eq _ver_B_; then | ||
28 | am_mu_vercmp(m4_cdr($1),m4_cdr($2),[$3]) | ||
29 | fi | ||
30 | m4_popdef([_ver_A_])dnl | ||
31 | m4_popdef([_ver_B_])dnl])]) | ||
32 | |||
33 | dnl AM_GNU_MAILUTILS(minversion, link-req, [act-if-found], [ac-if-not-found]) | ||
34 | dnl $1 $2 $3 $4 | ||
35 | dnl Verify if GNU Mailutils is installed and if its version is `minversion' | ||
36 | dnl or newer. If not installed, execute `ac-if-not-found' or, if it is not | ||
37 | dnl given, spit out an error message. | ||
38 | dnl | ||
39 | dnl If Mailutils is found, set: | ||
40 | dnl MAILUTILS_CONFIG to the full name of the mailutils-config program; | ||
41 | dnl MAILUTILS_VERSION to the Mailutils version (string); | ||
42 | dnl MAILUTILS_VERSION_MAJOR Mailutils version: major number | ||
43 | dnl MAILUTILS_VERSION_MINOR Mailutils version: minor number | ||
44 | dnl MAILUTILS_VERSION_PATCH Mailutils version: patchlevel number (or 0, | ||
45 | dnl if not defined) | ||
46 | dnl MAILUTILS_LIBS to the list of cc(1) flags needed to link in the | ||
47 | dnl libraries requested by `link-req'; | ||
48 | dnl MAILUTILS_INCLUDES to the list of cc(1) flags needed to set include | ||
49 | dnl paths to the Mailutils headers. | ||
50 | dnl | ||
51 | dnl Finally, if `act-if-found' is given, execute it. Otherwise, append the | ||
52 | dnl value of $MAILUTILS_LIBS to LIBS. | ||
53 | dnl | ||
54 | AC_DEFUN([AM_GNU_MAILUTILS], | ||
55 | [AC_PATH_PROG(MAILUTILS_CONFIG, mailutils-config, none, $PATH) | ||
56 | if test "$MAILUTILS_CONFIG" = "none"; then | ||
57 | m4_if($4,,[AC_MSG_ERROR(cannot find GNU Mailutils)], [$4]) | ||
58 | fi | ||
59 | AC_SUBST(MAILUTILS_CONFIG) | ||
60 | AC_SUBST(MAILUTILS_VERSION) | ||
61 | AC_SUBST(MAILUTILS_INCLUDES) | ||
62 | AC_SUBST(MAILUTILS_LIBS) | ||
63 | |||
64 | m4_ifndef([MU_VERSION_PARSE_DEFINED],[[ | ||
65 | mu_version_parse() { | ||
66 | set -- `echo "@S|@1" | sed 's/^\([0-9\.][0-9\.]*\).*/\1/;s/\./ /g'` | ||
67 | major=@S|@{1:-0} | ||
68 | minor=@S|@{2:-0} | ||
69 | patch=@S|@{3:-0} | ||
70 | }] | ||
71 | m4_pushdef([MU_VERSION_PARSE_DEFINED])]) | ||
72 | |||
73 | MAILUTILS_VERSION=`$MAILUTILS_CONFIG --info version|sed 's/VERSION=//'` | ||
74 | mu_version_parse $MAILUTILS_VERSION | ||
75 | AC_DEFINE_UNQUOTED([MAILUTILS_VERSION_MAJOR], $major, [Mailutils version major number]) | ||
76 | AC_DEFINE_UNQUOTED([MAILUTILS_VERSION_MINOR], $minor, [Mailutils version minor number]) | ||
77 | AC_DEFINE_UNQUOTED([MAILUTILS_VERSION_PATCH], $patch, [Mailutils version patchlevel number]) | ||
78 | |||
79 | AC_DEFINE_UNQUOTED(MAILUTILS_VERSION, "$MAILUTILS_VERSION", [Mailutils version number]) | ||
80 | m4_if($1,,,[ | ||
81 | am_mu_vercmp(m4_quote($major, $minor, $patch), | ||
82 | m4_dquote(m4_bpatsubst($1, [\.],[,])), | ||
83 | [AC_MSG_ERROR([Mailutils v. $MAILUTILS_VERSION is too old; required is at least ]$1)]) | ||
84 | ]) | ||
85 | MAILUTILS_LIBS=`$MAILUTILS_CONFIG --link $2` | ||
86 | MAILUTILS_INCLUDES=`$MAILUTILS_CONFIG --compile` | ||
87 | m4_if($3,,[LIBS="$LIBS $MAILUTILS_LIBS"], [$3]) | ||
88 | ]) | ||
89 | |||
diff --git a/configure.ac b/configure.ac index 85dce1a..3e18a57 100644 --- a/configure.ac +++ b/configure.ac | |||
@@ -15,7 +15,7 @@ | |||
15 | # along with wydawca. If not, see <http://www.gnu.org/licenses/>. | 15 | # along with wydawca. If not, see <http://www.gnu.org/licenses/>. |
16 | 16 | ||
17 | AC_PREREQ(2.63) | 17 | AC_PREREQ(2.63) |
18 | AC_INIT([wydawca], 2.99.90, [bug-wydawca@gnu.org.ua], [wydawca], | 18 | AC_INIT([wydawca], 2.99.91, [bug-wydawca@gnu.org.ua], [wydawca], |
19 | [http://www.gnu.org.ua/software/wydawca]) | 19 | [http://www.gnu.org.ua/software/wydawca]) |
20 | AC_CONFIG_SRCDIR([src/wydawca.c]) | 20 | AC_CONFIG_SRCDIR([src/wydawca.c]) |
21 | AC_CONFIG_AUX_DIR([build-aux]) | 21 | AC_CONFIG_AUX_DIR([build-aux]) |
@@ -68,7 +68,7 @@ AC_CHECK_FUNCS([fchdir memset strchr strdup strerror strrchr setegid setregid\ | |||
68 | # Mailutils | 68 | # Mailutils |
69 | # ********************** | 69 | # ********************** |
70 | 70 | ||
71 | AM_GNU_MAILUTILS(2.0, [mailer], [status_mailutils=yes], [status_mailutils=no]) | 71 | AM_GNU_MAILUTILS(3.3, [mailer], [status_mailutils=yes], [status_mailutils=no]) |
72 | AM_CONDITIONAL([COND_MAILUTILS],[test $status_mailutils = yes]) | 72 | AM_CONDITIONAL([COND_MAILUTILS],[test $status_mailutils = yes]) |
73 | AC_SUBST(WY_MAILUTILS,[$status_mailutils]) | 73 | AC_SUBST(WY_MAILUTILS,[$status_mailutils]) |
74 | 74 | ||
diff --git a/tests/.gitignore b/tests/.gitignore index 1df6b71..461469e 100644 --- a/tests/.gitignore +++ b/tests/.gitignore | |||
@@ -10,3 +10,4 @@ wstest | |||
10 | wsbatch | 10 | wsbatch |
11 | pushck | 11 | pushck |
12 | bkupname | 12 | bkupname |
13 | nullmail | ||
diff --git a/tests/Makefile.am b/tests/Makefile.am index 3f7a491..ebd86ff 100644 --- a/tests/Makefile.am +++ b/tests/Makefile.am | |||
@@ -80,7 +80,7 @@ check-local: atconfig atlocal $(TESTSUITE) | |||
80 | #installcheck-local: | 80 | #installcheck-local: |
81 | # $(SHELL) $(TESTSUITE) AUTOTEST_PATH=$(exec_prefix)/bin | 81 | # $(SHELL) $(TESTSUITE) AUTOTEST_PATH=$(exec_prefix)/bin |
82 | 82 | ||
83 | check_PROGRAMS = wstest wsbatch pushck bkupname | 83 | check_PROGRAMS = wstest wsbatch pushck bkupname |
84 | AM_CPPFLAGS = \ | 84 | AM_CPPFLAGS = \ |
85 | -I$(top_srcdir)/grecs/src\ | 85 | -I$(top_srcdir)/grecs/src\ |
86 | -I$(top_srcdir)/include\ | 86 | -I$(top_srcdir)/include\ |
@@ -90,3 +90,7 @@ LDADD=@GRECS_LDADD@ | |||
90 | pushck_LDADD=../src/pushd.o | 90 | pushck_LDADD=../src/pushd.o |
91 | bkupname_LDADD=../src/backup.o @GRECS_LDADD@ | 91 | bkupname_LDADD=../src/backup.o @GRECS_LDADD@ |
92 | 92 | ||
93 | if COND_MAILUTILS | ||
94 | check_PROGRAMS += nullmail | ||
95 | nullmail_LDADD = @MAILUTILS_LIBS@ | ||
96 | endif | ||
diff --git a/tests/atlocal.in b/tests/atlocal.in index af69a75..083c968 100644 --- a/tests/atlocal.in +++ b/tests/atlocal.in | |||
@@ -12,6 +12,7 @@ WY_CONFSRC=@abs_top_srcdir@/tests/etc | |||
12 | WY_DISTDIR=@abs_top_srcdir@/tests/dist | 12 | WY_DISTDIR=@abs_top_srcdir@/tests/dist |
13 | WY_SRC=@abs_top_builddir@/tests/source | 13 | WY_SRC=@abs_top_builddir@/tests/source |
14 | WY_DST=@abs_top_builddir@/tests/dest | 14 | WY_DST=@abs_top_builddir@/tests/dest |
15 | WY_TESTDIR=@abs_top_builddir@/tests | ||
15 | WY_MAILUTILS=@WY_MAILUTILS@ | 16 | WY_MAILUTILS=@WY_MAILUTILS@ |
16 | MKDIR_P="@MKDIR_P@" | 17 | MKDIR_P="@MKDIR_P@" |
17 | 18 | ||
@@ -35,6 +36,7 @@ wydawca_expandmeta() { | |||
35 | s,@WY_SRC@,$WY_SRC,g; | 36 | s,@WY_SRC@,$WY_SRC,g; |
36 | s,@WY_DST@,$WY_DST,g; | 37 | s,@WY_DST@,$WY_DST,g; |
37 | s,@WY_CONFSRC@,$WY_CONFSRC,g; | 38 | s,@WY_CONFSRC@,$WY_CONFSRC,g; |
39 | s,@WY_TESTDIR@,$WY_TESTDIR,g; | ||
38 | s,@WY_MODDIR@,@abs_top_builddir@/modules/mailutils,g" $1 > $2 | 40 | s,@WY_MODDIR@,@abs_top_builddir@/modules/mailutils,g" $1 > $2 |
39 | } | 41 | } |
40 | 42 | ||
diff --git a/tests/check-notify.at b/tests/check-notify.at index 65aa8b7..fa5cbeb 100644 --- a/tests/check-notify.at +++ b/tests/check-notify.at | |||
@@ -43,12 +43,10 @@ wydawca: [[NOTICE]] AT_PACKAGE_TARNAME (AT_PACKAGE_NAME AT_PACKAGE_VERSION) fini | |||
43 | ]) | 43 | ]) |
44 | 44 | ||
45 | AT_DATA([outtmpl], | 45 | AT_DATA([outtmpl], |
46 | [-F wydawca-noreply@localhost @USER@@localhost | 46 | [From wydawca-noreply@localhost |
47 | ========= | ||
48 | From: wydawca-noreply@localhost | 47 | From: wydawca-noreply@localhost |
49 | To: "Wydawca Test User" <@USER@@localhost> | 48 | To: "Wydawca Test User" <@USER@@localhost> |
50 | Subject: file rejected | 49 | Subject: file rejected |
51 | X-Mailer: AT_PACKAGE_TARNAME (AT_PACKAGE_NAME AT_PACKAGE_VERSION) | ||
52 | 50 | ||
53 | Your upload of file has been rejected by the distribution | 51 | Your upload of file has been rejected by the distribution |