small configury update
Hello there,
Nice to see Matthias' (and others') work on the mutt configury!
There are a couple of superfluous lines in Makefile.am; also, you could
spell out the version recommendations from doc/devel-notes.txt
explicitly in configure.in and Makefile.am (although that will break for
users who insist on trying out an older Automake version, for example;
feel free to drop that part of the patch).
More seriously though, Autoconf-2.60 won't provide for an exit
declaration any more, which may falsify a couple of tests (e.g., on
recent 64 bit systems); the solution is to either #include stdlib.h in
the test source, or to use return instead of exit (the systems where a
return value from main was unportable should be long dead).
Further, note one instance of uninitialized datarootdir variable I
missed in the 2006-01-26 change, in doc/instdoc.sh.in.
For you users, it may be helpful to run
autoreconf --install --include=m4 --force
once (with current autotools installed) and check in the newer generated
files; on some of the younger systems, builds may fail merely due to
outdated config.guess and similar files.
The changes in the patch below are compatible with Autoconf 2.59.
Cheers,
Ralf
* Makefile.am: No need to set CPP, OPS manually.
Require Automake 1.9.
* configure.in: Require Autoconf 2.59.
Include stdlib.h in tests that use exit.
* doc/instdoc.sh.in: Set datarootdir.
Index: Makefile.am
===================================================================
RCS file: /home/roessler/cvs/mutt/Makefile.am,v
retrieving revision 3.45
diff -u -r3.45 Makefile.am
--- Makefile.am 18 Jul 2006 18:04:14 -0000 3.45
+++ Makefile.am 10 Aug 2006 19:15:48 -0000
@@ -1,7 +1,7 @@
## Process this file with automake to produce Makefile.in
## Use aclocal -I m4; automake --foreign
-AUTOMAKE_OPTIONS = 1.6 foreign
+AUTOMAKE_OPTIONS = 1.9 foreign
EXTRA_PROGRAMS = mutt_dotlock pgpring pgpewrap makedoc
if BUILD_IMAP
@@ -48,8 +48,6 @@
# @rm -rf makedoc
# $(HOST_CC) $(AM_CFLAGS) $(LDFLAGS) $(makedoc_LDFLAGS)
$(makedoc_OBJECTS) $(makedoc_LDADD) -o makedoc
-CPP=@CPP@
-
DEFS=-DPKGDATADIR=\"$(pkgdatadir)\" -DSYSCONFDIR=\"$(sysconfdir)\" \
-DBINDIR=\"$(bindir)\" -DMUTTLOCALEDIR=\"$(datadir)/locale\" \
-DHAVE_CONFIG_H=1
@@ -105,8 +103,6 @@
LDADD = @LIBOBJS@ @INTLLIBS@
-OPS=@OPS@
-
flea: muttbug.sh
cp muttbug.sh flea
chmod +x flea
Index: configure.in
===================================================================
RCS file: /home/roessler/cvs/mutt/configure.in,v
retrieving revision 3.53
diff -u -r3.53 configure.in
--- configure.in 8 Aug 2006 22:49:12 -0000 3.53
+++ configure.in 10 Aug 2006 12:15:48 -0000
@@ -3,7 +3,7 @@
dnl !!! WHEN ADDING NEW CONFIGURE TESTS, PLEASE ADD CODE TO MAIN.C !!!
dnl !!! TO DUMP THEIR RESULTS WHEN MUTT -V IS CALLED !!!
-AC_PREREQ([2.54])
+AC_PREREQ([2.59])
AC_INIT([mutt.h])
AM_CONFIG_HEADER([config.h])
@@ -183,6 +183,7 @@
AC_ARG_WITH(slang, AC_HELP_STRING([--with-slang[=DIR]], [Use S-Lang instead of
ncurses]),
[AC_CACHE_CHECK([if this is a BSD system], mutt_cv_bsdish,
[AC_TRY_RUN([#include <sys/param.h>
+#include <stdlib.h>
main ()
{
@@ -465,6 +466,7 @@
AC_CACHE_CHECK(if $mutt_cv_mailpath is world writable,
mutt_cv_worldwrite, [AC_TRY_RUN([#include <sys/types.h>
#include <sys/stat.h>
+#include <stdlib.h>
int main (int argc, char **argv)
{
@@ -482,6 +484,7 @@
AC_CACHE_CHECK(if $mutt_cv_mailpath is group writable,
mutt_cv_groupwrite, [AC_TRY_RUN([#include <sys/types.h>
#include <sys/stat.h>
+#include <stdlib.h>
int main (int argc, char **argv)
{
Index: doc/instdoc.sh.in
===================================================================
RCS file: /home/roessler/cvs/mutt/doc/instdoc.sh.in,v
retrieving revision 3.0
diff -u -r3.0 instdoc.sh.in
--- doc/instdoc.sh.in 24 Jan 2002 13:35:07 -0000 3.0
+++ doc/instdoc.sh.in 10 Aug 2006 12:15:48 -0000
@@ -6,6 +6,7 @@
libdir=@libdir@
mandir=@mandir@
srcdir=@srcdir@
+datarootdir=@datarootdir@
docdir=@docdir@
includedir=@includedir@
top_srcdir=@top_srcdir@