From baeaa70028e41e41c30226b5297fdc57576ce5ed Mon Sep 17 00:00:00 2001 From: Andre Noll Date: Sat, 8 Jul 2017 18:53:11 +0200 Subject: [PATCH] build: Run lopsubgen with absolute path. The configure script detects the location of the lopsubgen executable, but we never use this information and rely on the shell to find the executable in $PATH when the recipes in m4/lls/makefile are run. This should not matter much, but it is inconsistent to how we deal with m4. Moreover, using the LOPSUBGEN autoconf variable in the recipes allows the user to override the path at build time. --- Makefile.in | 1 + configure.ac | 4 ++-- m4/lls/makefile | 6 +++--- 3 files changed, 6 insertions(+), 5 deletions(-) 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 6d56e652..0cc0df57 100644 --- a/configure.ac +++ b/configure.ac @@ -69,8 +69,8 @@ LIB_SUBST_FLAGS(osl) UNSTASH_FLAGS ######################################################################## lopsub HAVE_LOPSUB=yes -AC_PATH_PROG([lopsubgen], [lopsubgen]) -test -z "$lopsubgen" && HAVE_LOPSUB=no +AC_PATH_PROG([LOPSUBGEN], [lopsubgen]) +test -z "$LOPSUBGEN" && HAVE_LOPSUB=no STASH_FLAGS LIB_ARG_WITH([lopsub], [-llopsub]) AC_CHECK_HEADER(lopsub.h, [], [HAVE_LOPSUB=no]) diff --git a/m4/lls/makefile b/m4/lls/makefile index cf3965e6..d1cfab5d 100644 --- a/m4/lls/makefile +++ b/m4/lls/makefile @@ -15,15 +15,15 @@ $(lls_suite_dir)/%.suite: $(lls_m4_dir)/%.suite.m4 | $(lls_suite_dir) $(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 $<' -- 2.39.5