]> git.tuebingen.mpg.de Git - paraslash.git/commitdiff
Merge branch 'refs/heads/t/lopsub'
authorAndre Noll <maan@tuebingen.mpg.de>
Sun, 6 Aug 2017 13:56:25 +0000 (15:56 +0200)
committerAndre Noll <maan@tuebingen.mpg.de>
Sun, 6 Aug 2017 13:56:25 +0000 (15:56 +0200)
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.

Makefile.in
configure.ac
m4/lls/makefile

index b3e3be5cc82deb414f85404af830759ccd0e0963..556a926c235fac68714c877c7fd9bc6f9838d927 100644 (file)
@@ -9,6 +9,7 @@ PACKAGE_TARNAME := @PACKAGE_TARNAME@
 PACKAGE_VERSION := @PACKAGE_VERSION@
 
 M4 := @M4@
+LOPSUBGEN := @LOPSUBGEN@
 
 executables := @executables@
 
index c2cb47e6f993c6cbbad343208ce634af8bf80173..811364b19b4aded3c0d5f090ef16094e8a5162ea 100644 (file)
@@ -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([
index cf3965e6fb09bcaea4015618e8ffe7346738473f..dd86b51def8cfbeff487def5d883e3a88e0f9078 100644 (file)
@@ -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 $<'