summaryrefslogtreecommitdiff
path: root/Makefile.am
diff options
context:
space:
mode:
authorGaetan Nadon <memsize@videotron.ca>2011-01-22 14:41:33 -0500
committerGaetan Nadon <memsize@videotron.ca>2011-01-24 10:43:23 -0500
commit8b8f94bca1576e7365c492cfc8131d5aa7bcd7c8 (patch)
tree891dc182ea83e422a152c9dedbb1e0f37ea3b582 /Makefile.am
parent490ceddc3e97e8c5bf1ed61265525c213abf65d1 (diff)
config: substitute x11perfcompdir using Autoconf @x11perfcompdir@
Use the Autoconf recommended way of substituting bindir and friends, see http://www.gnu.org/software/autoconf/manual/autoconf.html Use # sign for comment in script. Only sed is used, drop the cpp terminology. Reviewed-by: RĂ©mi Cardona <remi@gentoo.org> Signed-off-by: Gaetan Nadon <memsize@videotron.ca>
Diffstat (limited to 'Makefile.am')
-rw-r--r--Makefile.am25
1 files changed, 13 insertions, 12 deletions
diff --git a/Makefile.am b/Makefile.am
index 3b6d13b..60839b3 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -20,14 +20,8 @@
# PERFORMANCE OF THIS SOFTWARE.
SUBDIRS = man
-bin_PROGRAMS = x11perf
-
-bin_SCRIPTS = x11perfcomp
-
-LIBPATH = $(libdir)/X11/x11perfcomp
-x11perfcompdir = $(LIBPATH)
-dist_x11perfcomp_SCRIPTS = fillblnk perfboth perfratio Xmark
+bin_PROGRAMS = x11perf
AM_CFLAGS = $(CWARNFLAGS) $(XEXT_CFLAGS) $(XFT_CFLAGS) $(XRENDER_CFLAGS) $(X11PERF_CFLAGS)
x11perf_LDADD = $(XEXT_LIBS) $(XFT_LIBS) $(XRENDER_LIBS) $(X11PERF_LIBS) -lm
@@ -53,12 +47,19 @@ x11perf_SOURCES = \
x11perf.c \
x11perf.h
-x11perfcomp: x11pcomp.cpp
- $(AM_V_GEN)$(SED) s/LIBPATH/`echo $(LIBPATH) | sed -e s/\\\\//\\\\\\\\\\\\\//g`/ < $(srcdir)/x11pcomp.cpp | \
- $(SED) s/XCOMM/\#/ > $@
+bin_SCRIPTS = x11perfcomp
+CLEANFILES = $(bin_SCRIPTS)
+EXTRA_DIST = $(bin_SCRIPTS:=.in)
+DIR_SUBSTS = -e 's|@x11perfcompdir[@]|$(x11perfcompdir)|g'
+
+x11perfcomp: x11perfcomp.in
+ $(AM_V_GEN)$(SED) $(DIR_SUBSTS) < $< > $@
-CLEANFILES = $(bin_SCRIPTS) x11perfcomp
-EXTRA_DIST = x11pcomp.cpp
+dist_x11perfcomp_SCRIPTS = \
+ fillblnk \
+ perfboth \
+ perfratio \
+ Xmark
MAINTAINERCLEANFILES = ChangeLog INSTALL