From: Bruno Haible Date: Mon, 30 Jan 2023 01:45:23 +0000 (+0100) Subject: maintainer-makefile: Determine gnulib's location on disk correctly. X-Git-Url: https://gitweb.git.savannah.gnu.org/gitweb/?a=commitdiff_plain;h=24437fcd4ff1ef53074a781344c0b620e71a7a74;p=gnulib.git maintainer-makefile: Determine gnulib's location on disk correctly. * top/maint.mk (gnulib_dir): Give priority to $(GNULIB_SRCDIR) over $(srcdir)/gnulib. --- diff --git a/ChangeLog b/ChangeLog index 6a7de98c0f..f209619fd7 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2023-01-29 Bruno Haible + + maintainer-makefile: Determine gnulib's location on disk correctly. + * top/maint.mk (gnulib_dir): Give priority to $(GNULIB_SRCDIR) over + $(srcdir)/gnulib. + 2023-01-29 Bruno Haible Fix compilation errors with CC="clang -D_FORTIFY_SOURCE=2" on Android. diff --git a/top/maint.mk b/top/maint.mk index 034e25be3d..44f3db9d9d 100644 --- a/top/maint.mk +++ b/top/maint.mk @@ -64,10 +64,10 @@ VC_LIST = $(srcdir)/$(_build-aux)/vc-list-files -C $(srcdir) # You can override this variable in cfg.mk if your gnulib submodule lives # in a different location. -gnulib_dir ?= $(shell if test -f $(srcdir)/gnulib/gnulib-tool; then \ - echo $(srcdir)/gnulib; \ +gnulib_dir ?= $(shell if test -n "$(GNULIB_SRCDIR)" && test -f "$(GNULIB_SRCDIR)/gnulib-tool"; then \ + echo "$(GNULIB_SRCDIR)"; \ else \ - echo ${GNULIB_SRCDIR}; \ + echo $(srcdir)/gnulib; \ fi) # You can override this variable in cfg.mk to set your own regexp