aboutsummaryrefslogtreecommitdiff
path: root/gnulib
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2021-06-08 18:04:28 -0400
committerMike Frysinger <vapier@gentoo.org>2021-06-14 18:01:20 -0400
commit483ab96a1bd6df30035dc2ae1a90b1b59c54ef75 (patch)
tree6caabc894a85765a3cd961a28fc0c635aa462e05 /gnulib
parent09db4332c6017ab57cd136788c48e5a81e3b9399 (diff)
downloadgdb-483ab96a1bd6df30035dc2ae1a90b1b59c54ef75.zip
gdb-483ab96a1bd6df30035dc2ae1a90b1b59c54ef75.tar.gz
gdb-483ab96a1bd6df30035dc2ae1a90b1b59c54ef75.tar.bz2
gnulib: define the path to gnulib's parent dir
The current setting assumes that gnulib is only used by dirs immediately under the source root. Trying to build it two or more levels deep fails. Switch GNULIB_BUILDDIR to a relative GNULIB_PARENT_DIR so that it can be used to construct both the build & source paths.
Diffstat (limited to 'gnulib')
-rw-r--r--gnulib/ChangeLog7
-rw-r--r--gnulib/Makefile.gnulib.inc.in10
2 files changed, 13 insertions, 4 deletions
diff --git a/gnulib/ChangeLog b/gnulib/ChangeLog
index 223b663..f571a99 100644
--- a/gnulib/ChangeLog
+++ b/gnulib/ChangeLog
@@ -1,3 +1,10 @@
+2021-06-14 Mike Frysinger <vapier@gentoo.org>
+
+ * Makefile.gnulib.inc.in (GNULIB_BUILDDIR): Rename to ...
+ (GNULIB_PARENT_DIR): ... this.
+ (LIBGNU): Add "/gnulib" after $(GNULIB_PARENT_DIR).
+ (INCGNU): Likewise. Replace .. with $(GNULIB_PARENT_DIR).
+
2021-06-08 Mike Frysinger <vapier@gentoo.org>
* update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add netdb.
diff --git a/gnulib/Makefile.gnulib.inc.in b/gnulib/Makefile.gnulib.inc.in
index 822f892..cf69b83 100644
--- a/gnulib/Makefile.gnulib.inc.in
+++ b/gnulib/Makefile.gnulib.inc.in
@@ -32,13 +32,15 @@
# INCGNU: A list of -I.... include paths that should be passed to the
# compiler, these are where the gnulib headers can be found.
-ifndef GNULIB_BUILDDIR
-$(error missing GNULIB_BUILDDIR)
+# Packages must define the relative path to gnulib's parent dir.
+ifndef GNULIB_PARENT_DIR
+$(error missing GNULIB_PARENT_DIR)
endif
-LIBGNU = $(GNULIB_BUILDDIR)/import/libgnu.a
+LIBGNU = $(GNULIB_PARENT_DIR)/gnulib/import/libgnu.a
LIBGNU_EXTRA_LIBS = @FREXPL_LIBM@ @FREXP_LIBM@ @INET_NTOP_LIB@ \
@LIBTHREAD@ @LIB_GETLOGIN@ @LIB_GETRANDOM@ \
@LIB_HARD_LOCALE@ @LIB_MBRTOWC@ \
@LIB_SETLOCALE_NULL@ @LIBINTL@ @LIB_SELECT@ @LIBSOCKET@
-INCGNU = -I$(srcdir)/../gnulib/import -I$(GNULIB_BUILDDIR)/import
+INCGNU = -I$(srcdir)/$(GNULIB_PARENT_DIR)/gnulib/import \
+ -I$(GNULIB_PARENT_DIR)/gnulib/import