diff mbox

gdbsupport: Fix setting up 'development' var.

Message ID 43ef95f1-a57b-97c2-ad20-38b467f17460@gmail.com
State New
Headers show

Commit Message

Vyacheslav Petrishchev Feb. 25, 2020, 8:32 p.m. UTC
Since gdbsupport is now on top level, fixing setting up 'development' var
in 'configure', thats prevent gbd build failure when development=false 
(undefined symbols (selftest) when linking).

Comments

Doug Evans via gdb-patches Feb. 25, 2020, 9:17 p.m. UTC | #1
On Tue, Feb 25, 2020 at 2:33 PM Vyacheslav Petrishchev
<vyachemail@gmail.com> wrote:
>
> Since gdbsupport is now on top level, fixing setting up 'development' var
> in 'configure', thats prevent gbd build failure when development=false
> (undefined symbols (selftest) when linking).

Oh, that explains the error someone mentioned on IRC recently...

I can't approve patches, but it looks like you used Debian's autoconf
to regenerate the configure script, leading to extra changes. To avoid
that it is best if you install and use an unmodified upstream autoconf
directly, perhaps by installing with --prefix and running it from
there.

Christian
diff mbox

Patch

From de5de9077a4159e9b9bdccd62d964097087f3e30 Mon Sep 17 00:00:00 2001
From: Vyacheslav Petrishchev <vyachemail@gmail.com>
Date: Wed, 26 Feb 2020 01:00:02 +0600
Subject: gdbsupport:  Fix setting up 'development' var.

gdbsupport/ChangeLog:

        * configure.ac: Added call development.sh.
        * configure: Regenerate.
---
 gdbsupport/ChangeLog    |  5 +++++
 gdbsupport/configure    | 29 +++++++++++++++++++++++------
 gdbsupport/configure.ac |  3 +++
 3 files changed, 31 insertions(+), 6 deletions(-)

diff --git a/gdbsupport/ChangeLog b/gdbsupport/ChangeLog
index d01966ed1d..e1d4853df7 100644
--- a/gdbsupport/ChangeLog
+++ b/gdbsupport/ChangeLog
@@ -1,3 +1,8 @@ 
+2020-02-25  Vyacheslav Petrishchev <vyachemail@gmail.com>
+
+	* configure.ac: Added call development.sh.
+	* configure: Regenerate.
+
 2020-02-19  Andrew Burgess  <andrew.burgess@embecosm.com>
 
 	* configure: Regenerate.
diff --git a/gdbsupport/configure b/gdbsupport/configure
index a4871f8d5b..6ba9b98659 100755
--- a/gdbsupport/configure
+++ b/gdbsupport/configure
@@ -739,6 +739,7 @@  infodir
 docdir
 oldincludedir
 includedir
+runstatedir
 localstatedir
 sharedstatedir
 sysconfdir
@@ -826,6 +827,7 @@  datadir='${datarootdir}'
 sysconfdir='${prefix}/etc'
 sharedstatedir='${prefix}/com'
 localstatedir='${prefix}/var'
+runstatedir='${localstatedir}/run'
 includedir='${prefix}/include'
 oldincludedir='/usr/include'
 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
@@ -1078,6 +1080,15 @@  do
   | -silent | --silent | --silen | --sile | --sil)
     silent=yes ;;
 
+  -runstatedir | --runstatedir | --runstatedi | --runstated \
+  | --runstate | --runstat | --runsta | --runst | --runs \
+  | --run | --ru | --r)
+    ac_prev=runstatedir ;;
+  -runstatedir=* | --runstatedir=* | --runstatedi=* | --runstated=* \
+  | --runstate=* | --runstat=* | --runsta=* | --runst=* | --runs=* \
+  | --run=* | --ru=* | --r=*)
+    runstatedir=$ac_optarg ;;
+
   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
     ac_prev=sbindir ;;
   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
@@ -1215,7 +1226,7 @@  fi
 for ac_var in	exec_prefix prefix bindir sbindir libexecdir datarootdir \
 		datadir sysconfdir sharedstatedir localstatedir includedir \
 		oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
-		libdir localedir mandir
+		libdir localedir mandir runstatedir
 do
   eval ac_val=\$$ac_var
   # Remove trailing slashes.
@@ -1368,6 +1379,7 @@  Fine tuning of the installation directories:
   --sysconfdir=DIR        read-only single-machine data [PREFIX/etc]
   --sharedstatedir=DIR    modifiable architecture-independent data [PREFIX/com]
   --localstatedir=DIR     modifiable single-machine data [PREFIX/var]
+  --runstatedir=DIR       modifiable per-process data [LOCALSTATEDIR/run]
   --libdir=DIR            object code libraries [EPREFIX/lib]
   --includedir=DIR        C header files [PREFIX/include]
   --oldincludedir=DIR     C header files for non-gcc [/usr/include]
@@ -5664,7 +5676,7 @@  else
     We can't simply define LARGE_OFF_T to be 9223372036854775807,
     since some C++ compilers masquerading as C compilers
     incorrectly reject 9223372036854775807.  */
-#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
+#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
 		       && LARGE_OFF_T % 2147483647 == 1)
 		      ? 1 : -1];
@@ -5710,7 +5722,7 @@  else
     We can't simply define LARGE_OFF_T to be 9223372036854775807,
     since some C++ compilers masquerading as C compilers
     incorrectly reject 9223372036854775807.  */
-#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
+#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
 		       && LARGE_OFF_T % 2147483647 == 1)
 		      ? 1 : -1];
@@ -5734,7 +5746,7 @@  rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
     We can't simply define LARGE_OFF_T to be 9223372036854775807,
     since some C++ compilers masquerading as C compilers
     incorrectly reject 9223372036854775807.  */
-#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
+#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
 		       && LARGE_OFF_T % 2147483647 == 1)
 		      ? 1 : -1];
@@ -5779,7 +5791,7 @@  else
     We can't simply define LARGE_OFF_T to be 9223372036854775807,
     since some C++ compilers masquerading as C compilers
     incorrectly reject 9223372036854775807.  */
-#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
+#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
 		       && LARGE_OFF_T % 2147483647 == 1)
 		      ? 1 : -1];
@@ -5803,7 +5815,7 @@  rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
     We can't simply define LARGE_OFF_T to be 9223372036854775807,
     since some C++ compilers masquerading as C compilers
     incorrectly reject 9223372036854775807.  */
-#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
+#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
 		       && LARGE_OFF_T % 2147483647 == 1)
 		      ? 1 : -1];
@@ -6569,6 +6581,9 @@  fi
 am_cv_prog_cc_stdc=$ac_cv_prog_cc_stdc
 
 
+# Set the 'development' global.
+. $srcdir/../bfd/development.sh
+
 # We require a C++11 compiler.  Check if one is available, and if
 # necessary, set CXX_DIALECT to some -std=xxx switch.
 
@@ -8571,6 +8586,8 @@  main ()
     if (*(data + i) != *(data3 + i))
       return 14;
   close (fd);
+  free (data);
+  free (data3);
   return 0;
 }
 _ACEOF
diff --git a/gdbsupport/configure.ac b/gdbsupport/configure.ac
index 401e16f821..ab71a3cb36 100644
--- a/gdbsupport/configure.ac
+++ b/gdbsupport/configure.ac
@@ -33,6 +33,9 @@  AC_USE_SYSTEM_EXTENSIONS
 ACX_LARGEFILE
 AM_PROG_CC_STDC
 
+# Set the 'development' global.
+. $srcdir/../bfd/development.sh
+
 # We require a C++11 compiler.  Check if one is available, and if
 # necessary, set CXX_DIALECT to some -std=xxx switch.
 AX_CXX_COMPILE_STDCXX(11, , mandatory)
-- 
2.20.1