summaryrefslogtreecommitdiff
path: root/Makefile.am
diff options
context:
space:
mode:
Diffstat (limited to 'Makefile.am')
-rw-r--r--Makefile.am12
1 files changed, 9 insertions, 3 deletions
diff --git a/Makefile.am b/Makefile.am
index e96b0d3..f33a11a 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -23,6 +23,7 @@ bin_PROGRAMS = sessreg
sessreg_CFLAGS = $(SESSREG_CFLAGS)
sessreg_SOURCES = \
+ sessreg.h \
sessreg.c
appman_PRE = sessreg.man
@@ -31,8 +32,8 @@ appmandir = $(APP_MAN_DIR)
appman_DATA = $(appman_PRE:man=@APP_MAN_SUFFIX@)
-EXTRA_DIST = $(appman_PRE)
-CLEANFILES = $(appman_DATA)
+EXTRA_DIST = $(appman_PRE) filenames.sed.c
+CLEANFILES = $(appman_DATA) filenames.sed
SED = sed
@@ -40,7 +41,7 @@ SED = sed
XORGRELSTRING = @PACKAGE_STRING@
XORGMANNAME = X Version 11
-MAN_SUBSTS = \
+MAN_SUBSTS = -f filenames.sed \
-e 's|__vendorversion__|"$(XORGRELSTRING)" "$(XORGMANNAME)"|' \
-e 's|__xorgversion__|"$(XORGRELSTRING)" "$(XORGMANNAME)"|' \
-e 's|__xservername__|Xorg|g' \
@@ -57,3 +58,8 @@ SUFFIXES = .$(APP_MAN_SUFFIX) .man
.man.$(APP_MAN_SUFFIX):
sed $(MAN_SUBSTS) < $< > $@
+
+sessreg.$(APP_MAN_SUFFIX): filenames.sed
+
+filenames.sed: filenames.sed.c
+ $(CPP) $(DEFS) $(srcdir)/filenames.sed.c | grep 's\|__' > $@