summaryrefslogtreecommitdiff
path: root/man
diff options
context:
space:
mode:
authorAlan Coopersmith <Alan.Coopersmith@sun.com>2005-11-13 18:14:22 +0000
committerAlan Coopersmith <Alan.Coopersmith@sun.com>2005-11-13 18:14:22 +0000
commit6424ff482a845160bc1146bb8a17fa2bde976685 (patch)
treea5746dbab9ab1cfeaa37bf2d4abdb959c3ba2e25 /man
parent68ee705e1066d5092bc266c9d47d6c1022be2f1c (diff)
downloadxorg-lib-libdmx-6424ff482a845160bc1146bb8a17fa2bde976685.tar.gz
Use $(LIB_MAN_SUFFIX) instead of forcing man pages into section 3. Use sed
to substitute variables in man pages.
Diffstat (limited to 'man')
-rw-r--r--man/Makefile.am59
1 files changed, 40 insertions, 19 deletions
diff --git a/man/Makefile.am b/man/Makefile.am
index d697660..cc773b3 100644
--- a/man/Makefile.am
+++ b/man/Makefile.am
@@ -19,23 +19,44 @@
# PERFORMANCE OF THIS SOFTWARE.
#
-man_MANS = \
- DMX.3 \
- DMXAddInput.3 \
- DMXAddScreen.3 \
- DMXChangeDesktopAttributes.3 \
- DMXChangeScreensAttributes.3 \
- DMXForceWindowCreation.3 \
- DMXGetDesktopAttributes.3 \
- DMXGetInputAttributes.3 \
- DMXGetInputCount.3 \
- DMXGetScreenAttributes.3 \
- DMXGetScreenCount.3 \
- DMXGetWindowAttributes.3 \
- DMXQueryExtension.3 \
- DMXQueryVersion.3 \
- DMXRemoveInput.3 \
- DMXRemoveScreen.3 \
- DMXSync.3
-EXTRA_DIST = $(man_MANS)
+libmandir = $(mandir)/man$(LIB_MAN_SUFFIX)
+libman_SOURCES = \
+ DMX.man \
+ DMXAddInput.man \
+ DMXAddScreen.man \
+ DMXChangeDesktopAttributes.man \
+ DMXChangeScreensAttributes.man \
+ DMXForceWindowCreation.man \
+ DMXGetDesktopAttributes.man \
+ DMXGetInputAttributes.man \
+ DMXGetInputCount.man \
+ DMXGetScreenAttributes.man \
+ DMXGetScreenCount.man \
+ DMXGetWindowAttributes.man \
+ DMXQueryExtension.man \
+ DMXQueryVersion.man \
+ DMXRemoveInput.man \
+ DMXRemoveScreen.man \
+ DMXSync.man
+
+libman_DATA = $(libman_SOURCES:man=@LIB_MAN_SUFFIX@)
+
+EXTRA_DIST = $(libman_SOURCES)
+
+CLEANFILES = $(libman_DATA)
+
+SED = sed
+
+# Strings to replace in man pages
+XORGRELSTRING = @PACKAGE_STRING@
+ XORGMANNAME = X Version 11
+
+MAN_SUBSTS = \
+ -e 's/__vendorversion__/"$(XORGRELSTRING)" "$(XORGMANNAME)"/' \
+ -e 's/__libmansuffix__/$(LIB_MAN_SUFFIX)/g'
+
+SUFFIXES = .$(LIB_MAN_SUFFIX) .man
+
+.man.$(LIB_MAN_SUFFIX):
+ sed $(MAN_SUBSTS) < $< > $@