summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makefile.am3
-rw-r--r--configure.ac11
-rw-r--r--man/Makefile.am12
-rw-r--r--man/transset.man (renamed from transset.1)0
4 files changed, 21 insertions, 5 deletions
diff --git a/Makefile.am b/Makefile.am
index 5d1d806..fd6627f 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -1,5 +1,6 @@
+SUBDIRS = man
+
bin_PROGRAMS = transset
-man_MANS = transset.1
AM_CFLAGS = $(CWARNFLAGS) $(TRANSSET_CFLAGS)
transset_LDADD = $(TRANSSET_LIBS) $(LIBOBJS)
diff --git a/configure.ac b/configure.ac
index d0351cb..b04ba86 100644
--- a/configure.ac
+++ b/configure.ac
@@ -9,13 +9,16 @@ AC_CONFIG_HEADER([config.h])
AM_INIT_AUTOMAKE([dist-bzip2 foreign])
AM_MAINTAINER_MODE
-# Require xorg-macros 1.3 or later: XORG_DEFAULT_OPTIONS
+# Require xorg-macros 1.8 or later for MAN_SUBSTS set by XORG_MANPAGE_SECTIONS
m4_ifndef([XORG_MACROS_VERSION],
- [m4_fatal([must install xorg-macros 1.3 or later before running autoconf/autogen])])
-XORG_MACROS_VERSION(1.3)
+ [m4_fatal([must install xorg-macros 1.8 or later before running autoconf/autogen])])
+XORG_MACROS_VERSION(1.8)
XORG_DEFAULT_OPTIONS
# Checks for library functions.
PKG_CHECK_MODULES(TRANSSET, x11)
-AC_OUTPUT([Makefile])
+AC_CONFIG_FILES([
+ Makefile
+ man/Makefile])
+AC_OUTPUT
diff --git a/man/Makefile.am b/man/Makefile.am
new file mode 100644
index 0000000..35f8f11
--- /dev/null
+++ b/man/Makefile.am
@@ -0,0 +1,12 @@
+
+appmandir = $(APP_MAN_DIR)
+appman_PRE = transset.man
+appman_DATA = $(appman_PRE:man=$(APP_MAN_SUFFIX))
+
+EXTRA_DIST = $(appman_PRE)
+CLEANFILES = $(appman_DATA)
+SUFFIXES = .$(APP_MAN_SUFFIX) .man
+
+# String replacements in MAN_SUBSTS now come from xorg-macros.m4 via configure
+.man.$(APP_MAN_SUFFIX):
+ $(AM_V_GEN)$(SED) $(MAN_SUBSTS) < $< > $@
diff --git a/transset.1 b/man/transset.man
index 3fd8b13..3fd8b13 100644
--- a/transset.1
+++ b/man/transset.man