pkgsrc/print/cups/patches/patch-ao

76 lines
1.5 KiB
Text

$NetBSD: patch-ao,v 1.9 2009/05/14 01:19:13 christos Exp $
--- config-scripts/cups-manpages.m4.orig 2009-01-12 14:17:21.000000000 -0500
+++ config-scripts/cups-manpages.m4 2009-05-13 21:07:50.000000000 -0400
@@ -13,6 +13,8 @@
dnl file is missing or damaged, see the license at "http://www.cups.org/".
dnl
+AC_ARG_WITH(manext, [ --with-manext set man page extension style (bsd,irix,sysv,none)],manext="$withval",manext="")
+
dnl Fix "mandir" variable...
if test "$mandir" = "\${datarootdir}/man" -a "$prefix" = "/"; then
# New GNU "standards" break previous ones, so make sure we use
@@ -50,8 +52,33 @@
AC_SUBST(PMANDIR)
dnl Setup manpage extensions...
-case "$uname" in
- IRIX*)
+if test x$manext = x; then
+ case "$uname" in
+ *BSD* | DragonFly*)
+ # *BSD and Darwin (MacOS X)
+ manext=bsd
+ ;;
+ IRIX*)
+ # SGI IRIX
+ manext=irix
+ ;;
+ SunOS* | HP-UX*)
+ # Solaris and HP-UX
+ manext=sysv
+ ;;
+ Linux* | GNU* | Darwin*)
+ # Linux and GNU Hurd
+ manext=linux
+ ;;
+ *)
+ # All others
+ manext=none
+ ;;
+ esac
+fi
+
+case "$manext" in
+ irix)
# SGI IRIX
MAN1EXT=1
MAN5EXT=5
@@ -59,7 +86,7 @@
MAN8EXT=1m
MAN8DIR=1
;;
- SunOS* | HP-UX*)
+ sysv)
# Solaris and HP-UX
MAN1EXT=1
MAN5EXT=5
@@ -67,7 +94,7 @@
MAN8EXT=1m
MAN8DIR=1m
;;
- Linux* | GNU* | Darwin*)
+ linux)
# Linux, GNU Hurd, and Mac OS X
MAN1EXT=1.gz
MAN5EXT=5.gz
@@ -75,7 +102,7 @@
MAN8EXT=8.gz
MAN8DIR=8
;;
- *)
+ none|*)
# All others
MAN1EXT=1
MAN5EXT=5