From: Andre Noll Date: Sun, 6 Aug 2017 13:56:25 +0000 (+0200) Subject: Merge branch 'refs/heads/t/lopsub' X-Git-Tag: v0.6.1~41 X-Git-Url: http://git.tuebingen.mpg.de/?a=commitdiff_plain;h=7649f22106cec2c6eb8bb10f279401e1af5451d0;hp=a6fc2bd6ed685c4e3ab3006b808cfbd383ea97c9;p=paraslash.git Merge branch 'refs/heads/t/lopsub' Three simple patches for the build system, all related to lopsub. Cooking for three weeks. * refs/heads/t/lopsub: build: Echo "M4" when running an m4 command. build: Run lopsubgen with absolute path. build: Improve lopsub error diagnostics. --- diff --git a/Makefile.in b/Makefile.in index b3e3be5c..556a926c 100644 --- a/Makefile.in +++ b/Makefile.in @@ -9,6 +9,7 @@ PACKAGE_TARNAME := @PACKAGE_TARNAME@ PACKAGE_VERSION := @PACKAGE_VERSION@ M4 := @M4@ +LOPSUBGEN := @LOPSUBGEN@ executables := @executables@ diff --git a/configure.ac b/configure.ac index c2cb47e6..811364b1 100644 --- a/configure.ac +++ b/configure.ac @@ -54,10 +54,6 @@ AC_PATH_PROG([M4], [m4]) test -z "$M4" && AC_MSG_ERROR( [The m4 macro processor is required to build this package]) -AC_PATH_PROG([lopsubgen], [lopsubgen]) -test -z "$lopsubgen" && AC_MSG_ERROR( - [lopsubgen is required to build this package]) - AC_PROG_CC AC_PROG_CPP @@ -71,9 +67,11 @@ AC_CHECK_LIB([osl], [osl_open_table], [], [HAVE_OSL=no]) LIB_SUBST_FLAGS(osl) UNSTASH_FLAGS ######################################################################## lopsub +HAVE_LOPSUB=yes +AC_PATH_PROG([LOPSUBGEN], [lopsubgen]) +test -z "$LOPSUBGEN" && HAVE_LOPSUB=no STASH_FLAGS LIB_ARG_WITH([lopsub], [-llopsub]) -HAVE_LOPSUB=yes AC_CHECK_HEADER(lopsub.h, [], [HAVE_LOPSUB=no]) AC_CHECK_LIB([lopsub], [lls_merge], [], [HAVE_LOPSUB=no]) if test $HAVE_LOPSUB = no; then AC_MSG_ERROR([ diff --git a/m4/lls/makefile b/m4/lls/makefile index cf3965e6..dd86b51d 100644 --- a/m4/lls/makefile +++ b/m4/lls/makefile @@ -3,27 +3,27 @@ lls_m4_include_dir := $(lls_m4_dir)/include $(lls_suite_dir)/%.m4d: $(lls_m4_dir)/%.suite.m4 | $(lls_suite_dir) @[ -z "$(Q)" ] || echo 'M4D $<' - $(Q) $(M4) -Pg -I $(lls_m4_include_dir) -s $< \ | awk '{if ($$1 ~ /#line/) {gsub(/"/, "", $$3); if ($$3 != "$<") \ print "$(lls_suite_dir)/$(*F).suite: " $$3}}' | sort | uniq > $@ $(lls_suite_dir)/%.suite: $(lls_m4_dir)/%.suite.m4 | $(lls_suite_dir) + @[ -z "$(Q)" ] || echo 'M4 $<' $(Q) $(M4) -Pg -I $(lls_m4_include_dir) -D GIT_VERSION=$(GIT_VERSION) \ -D COPYRIGHT_YEAR=$(COPYRIGHT_YEAR) -D LOGLEVELS=$(LOGLEVELS) \ $< > $@ $(lls_suite_dir)/%.lsg.c: $(lls_suite_dir)/%.suite @[ -z "$(Q)" ] || echo 'LSGC $<' - $(Q) lopsubgen --gen-c --output-dir $(lls_suite_dir) < $< + $(Q) $(LOPSUBGEN) --gen-c --output-dir $(lls_suite_dir) < $< $(lls_suite_dir)/%.lsg.h: $(lls_suite_dir)/%.suite @[ -z "$(Q)" ] || echo 'LSGH $<' - $(Q) lopsubgen --gen-header --output-dir $(lls_suite_dir) < $< + $(Q) $(LOPSUBGEN) --gen-header --output-dir $(lls_suite_dir) < $< $(lls_suite_dir)/%.lsg.man: $(lls_suite_dir)/%.suite @[ -z "$(Q)" ] || echo 'LSGM $<' - $(Q) lopsubgen --gen-man --output-dir $(lls_suite_dir) < $< + $(Q) $(LOPSUBGEN) --gen-man --output-dir $(lls_suite_dir) < $< $(object_dir)/%.o: $(lls_suite_dir)/%.c | $(object_dir) @[ -z "$(Q)" ] || echo 'CC $<'