summaryrefslogtreecommitdiff
path: root/aclocal.m4
diff options
context:
space:
mode:
authorwlemb <wlemb>2002-06-05 13:46:41 +0000
committerwlemb <wlemb>2002-06-05 13:46:41 +0000
commitec2d1f2ff2ab2b46e4257ae15cb755898265d08e (patch)
tree43c1870873d873beba843a535ee16aa67200eecf /aclocal.m4
parent3054e1147ac18bdcc25fc06723f8788525c11307 (diff)
downloadgroff-ec2d1f2ff2ab2b46e4257ae15cb755898265d08e.tar.gz
* aclocal.m4 (GROFF_PAGE): Don't use `prefix' directly since it
is not initialized at the time we need it in case `--prefix' hasn't been set. Check for `ac_default_prefix' also. Test for `papersize' keyword also and generalize allowed whitespace. * configure: Regenerated. * font/devps/Makefile.sub (DESC): Use `papersize' instead of `paperlength'. * src/libs/libgroff/Makefile.sub (version, revision): Replaced with... (src_version, src_revision): New variables to avoid overwriting from parent make process. (version.cc): Updated. * contrib/mom/Makefile.sub (groff_bin_dirs): Fix typo (forgotten `src' element). * src/preproc/html/pre-html.cc: Include paper.h and font.h. (linebuf, linebufsize): New global variables. (sys_fatal): Use `fatal' to abort properly. (get_line): New function. (get_resolution): Use it. Improve error messages. (get_papersize): Check `papersize' also. Use `get_line'. Improve error messages.
Diffstat (limited to 'aclocal.m4')
-rw-r--r--aclocal.m427
1 files changed, 18 insertions, 9 deletions
diff --git a/aclocal.m4 b/aclocal.m4
index ee75f770..9abb270f 100644
--- a/aclocal.m4
+++ b/aclocal.m4
@@ -1,5 +1,5 @@
dnl Autoconf macros for groff.
-dnl Copyright (C) 1989-1995, 2001 Free Software Foundation, Inc.
+dnl Copyright (C) 1989-1995, 2001, 2002 Free Software Foundation, Inc.
dnl
dnl This file is part of groff.
dnl
@@ -239,23 +239,32 @@ dnl
dnl
AC_DEFUN(GROFF_PAGE,
[AC_MSG_CHECKING([default paper size])
+groff_prefix=$prefix
+test "x$prefix" = xNONE && groff_prefix=$ac_default_prefix
if test -z "$PAGE"; then
descfile=
- if test -r $prefix/share/groff/font/devps/DESC; then
- descfile=$prefix/share/groff/font/devps/DESC
- elif test -r $prefix/lib/groff/font/devps/DESC; then
- descfile=$prefix/lib/groff/font/devps/DESC
+ if test -r $groff_prefix/share/groff/font/devps/DESC; then
+ descfile=$groff_prefix/share/groff/font/devps/DESC
+ elif test -r $groff_prefix/lib/groff/font/devps/DESC; then
+ descfile=$groff_prefix/lib/groff/font/devps/DESC
else
- for f in $prefix/share/groff/*/font/devps/DESC; do
+ for f in $groff_prefix/share/groff/*/font/devps/DESC; do
if test -r $f; then
descfile=$f
break
fi
done
fi
- if test -n "$descfile" \
- && grep "^paperlength 841890" $descfile >/dev/null 2>&1; then
- PAGE=A4
+ if test -n "$descfile"; then
+changequote(,)dnl
+ if grep '^paperlength[ ]\+841890' $descfile
+ >/dev/null 2>&1; then
+ PAGE=A4
+ elif grep '^papersize[ ]\+[aA]4' $descfile \
+ >/dev/null 2>&1; then
+ PAGE=A4
+ fi
+changequote([,])dnl
fi
fi
if test -z "$PAGE"; then