diff --git a/autogen.sh b/autogen.sh index b64521e5ed..f1591d8e17 100755 --- a/autogen.sh +++ b/autogen.sh @@ -41,10 +41,13 @@ fi # is required. The first is just the SHA1 that selects a gnulib snapshot. # The second ensures that whenever we change the set of gnulib modules used # by this package, we rerun bootstrap to pull in the matching set of files. +# The third ensures that whenever we change the set of local gnulib diffs, +# we rerun bootstrap to pull in those diffs. bootstrap_hash() { git submodule status | sed 's/^[ +-]//;s/ .*//' git hash-object bootstrap.conf + git ls-tree -d HEAD gnulib/local | awk '{print $3}' } # Ensure that whenever we pull in a gnulib update or otherwise change to a diff --git a/bootstrap.conf b/bootstrap.conf index 4557d2da9d..6498aba502 100644 --- a/bootstrap.conf +++ b/bootstrap.conf @@ -160,9 +160,10 @@ fi # Tell gnulib to: # require LGPLv2+ +# apply any local diffs in gnulib/local/ dir # put *.m4 files in new gnulib/m4/ dir -# put *.[ch] files in new gnulib/lib/ dir. -# import gnulib tests in new gnulib/tests/ dir. +# put *.[ch] files in new gnulib/lib/ dir +# import gnulib tests in new gnulib/tests/ dir gnulib_name=libgnu m4_base=gnulib/m4 source_base=gnulib/lib @@ -172,6 +173,7 @@ gnulib_tool_option_extras="\ --with-tests\ --avoid=pt_chown\ " +local_gl_dir=gnulib/local # Convince bootstrap to use multiple m4 directories. : ${ACLOCAL=aclocal} diff --git a/cfg.mk b/cfg.mk index 463ce0c4f8..574c7a49f4 100644 --- a/cfg.mk +++ b/cfg.mk @@ -627,6 +627,7 @@ ifeq (0,$(MAKELEVEL)) test -f po/Makevars || { echo 1; exit; }; \ actual=$$(git submodule status | $(_submodule_hash); \ git hash-object bootstrap.conf; \ + git ls-tree -d HEAD gnulib/local | awk '{print $$3}'; \ git diff .gnulib); \ stamp="$$($(_submodule_hash) $(_curr_status) 2>/dev/null)"; \ test "$$stamp" = "$$actual"; echo $$?)