diff options
author | Simon Marchi <simon.marchi@ericsson.com> | 2018-09-18 23:40:55 -0400 |
---|---|---|
committer | Simon Marchi <simon.marchi@polymtl.ca> | 2018-09-18 23:40:55 -0400 |
commit | b567ca638c274e27969975403b885973af9ccae6 (patch) | |
tree | 86bf6c86b2929f9471747d95457f391ea7f8204c /gdb/gnulib/configure | |
parent | 48219c6a06091b873f39c64c5df12ba7ec37a2e0 (diff) | |
download | gdb-b567ca638c274e27969975403b885973af9ccae6.zip gdb-b567ca638c274e27969975403b885973af9ccae6.tar.gz gdb-b567ca638c274e27969975403b885973af9ccae6.tar.bz2 |
Carry the gnulib getcwd backport as a patch
Commit
e2fc52e7457 ("Fix PR gdb/23558: Use system's 'getcwd' when cross-compiling GDB")
backported some changes from a future gnulib version to our import.
However, this means that every time someone wants to change our gnulib
import (e.g. add a module), they must make sure not to include that
backported change. It also means that someone running the
update-gnulib.sh script without changes will get some diffs and wonder
why.
Instead, I suggest we carry that backport as a patch applied by the
update-gnulib.sh script after running the import tool. It will make it
clear what backport or local modification we have and should make
running update-gnulib.sh give a reproducible result.
There is a hunk in the configure file in this patch, this is because the
commit that backported the getcwd bits didn't include the re-generated
configure.
Note: you'll need this patch as well to get deterministic results:
Generate aclocal-m4-deps.mk more deterministically and portably.
https://sourceware.org/ml/gdb-patches/2018-09/msg00643.html
gdb/ChangeLog:
* patches/0001-Fix-PR-gdb-23558-Use-system-s-getcwd-when-cross-comp.patch:
New file.
* update-gnulib.sh: Apply patch.
* configure: Re-generate.
Diffstat (limited to 'gdb/gnulib/configure')
-rw-r--r-- | gdb/gnulib/configure | 18 |
1 files changed, 15 insertions, 3 deletions
diff --git a/gdb/gnulib/configure b/gdb/gnulib/configure index 5fd52d4..dc6c5b6 100644 --- a/gdb/gnulib/configure +++ b/gdb/gnulib/configure @@ -17696,10 +17696,22 @@ else # Arrange for deletion of the temporary directory this test creates. ac_clean_files="$ac_clean_files confdir3" if test "$cross_compiling" = yes; then : - case "$host_os" in - aix*) gl_cv_func_getcwd_path_max='no, it has the AIX bug';; - *) gl_cv_func_getcwd_path_max=no;; + # Cross-compilation guesses: + case "$host_os" in + aix*) # On AIX, it has the AIX bug. + gl_cv_func_getcwd_path_max='no, it has the AIX bug' ;; + gnu*) # On Hurd, it is 'yes'. + gl_cv_func_getcwd_path_max=yes ;; + linux* | kfreebsd*) + # On older Linux+glibc it's 'no, but it is partly working', + # on newer Linux+glibc it's 'yes'. + # On Linux+musl libc, it's 'no, but it is partly working'. + # On kFreeBSD+glibc, it's 'no, but it is partly working'. + gl_cv_func_getcwd_path_max='no, but it is partly working' ;; + *) # If we don't know, assume the worst. + gl_cv_func_getcwd_path_max=no ;; esac + else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ |