GDB currently doesn't build on 32-bit Solaris:
* On Solaris 11.4/x86:
In file included from /usr/include/sys/procfs.h:26,
from /vol/src/gnu/gdb/hg/master/dist/gdb/i386-sol2-nat.c:24:
/usr/include/sys/old_procfs.h:31:2: error: #error "Cannot use procfs in the large file compilation environment"
#error "Cannot use procfs in the large file compilation environment"
^~~~~
* On Solaris 11.3/x86 there are several more instances of this.
The interaction between procfs and large-file support historically has
been a royal mess on Solaris:
* There are two versions of the procfs interface:
** The old ioctl-based /proc, deprecated and not used any longer in
either gdb or binutils.
** The `new' (introduced in Solaris 2.6, 1997) structured /proc.
* There are two headers one can possibly include:
** <procfs.h> which only provides the structured /proc, definining
_STRUCTURED_PROC=1 and then including ...
** <sys/procfs.h> which defaults to _STRUCTURED_PROC=0, the ioctl-based
/proc, but provides structured /proc if _STRUCTURED_PROC == 1.
* procfs and the large-file environment didn't go well together:
** Until Solaris 11.3, <sys/procfs.h> would always #error in 32-bit
compilations when the large-file environment was active
(_FILE_OFFSET_BITS == 64).
** In both Solaris 11.4 and Illumos, this restriction was lifted for
structured /proc.
So one has to be careful always to define _STRUCTURED_PROC=1 when
testing for or using <sys/procfs.h> on Solaris. As the errors above
show, this isn't always the case in binutils-gdb right now.
Also one may need to disable large-file support for 32-bit compilations
on Solaris. config/largefile.m4 meant to do this by wrapping the
AC_SYS_LARGEFILE autoconf macro with appropriate checks, yielding
ACX_LARGEFILE. Unfortunately the macro doesn't always succeed because
it neglects the _STRUCTURED_PROC part.
To make things even worse, since GCC 9 g++ predefines
_FILE_OFFSET_BITS=64 on Solaris. So even if largefile.m4 deciced not to
enable large-file support, this has no effect, breaking the gdb build.
This patch addresses all this as follows:
* All tests for the <sys/procfs.h> header are made with
_STRUCTURED_PROC=1, the definition going into the various config.h
files instead of having to make them (and sometimes failing) in the
affected sources.
* To cope with the g++ predefine of _FILE_OFFSET_BITS=64,
-U_FILE_OFFSET_BITS is added to various *_CPPFLAGS variables. It had
been far easier to have just
#undef _FILE_OFFSET_BITS
in config.h, but unfortunately such a construct in config.in is
commented by config.status irrespective of indentation and whitespace
if large-file support is disabled. I found no way around this and
putting the #undef in several global headers for bfd, binutils, ld,
and gdb seemed way more invasive.
* Last, the applicability check in largefile.m4 was modified only to
disable largefile support if really needed. To do so, it checks if
<sys/procfs.h> compiles with _FILE_OFFSET_BITS=64 defined. If it
doesn't, the disabling only happens if gdb exists in-tree and isn't
disabled, otherwise (building binutils from a tarball), there's no
conflict.
What initially confused me was the check for $plugins here, which
originally caused the disabling not to take place. Since AC_PLUGINGS
does enable plugin support if <dlfcn.h> exists (which it does on
Solaris), the disabling never happened.
I could find no explanation why the linker plugin needs large-file
support but thought it would be enough if gld and GCC's lto-plugin
agreed on the _FILE_OFFSET_BITS value. Unfortunately, that's not
enough: lto-plugin uses the simple-object interface from libiberty,
which includes off_t arguments. So to fully disable large-file
support would mean also disabling it in libiberty and its users: gcc
and libstdc++-v3. This seems highly undesirable, so I decided to
disable the linker plugin instead if large-file support won't work.
The patch allows binutils+gdb to build on i386-pc-solaris2.11 (both
Solaris 11.3 and 11.4, using GCC 9.3.0 which is the worst case due to
predefined _FILE_OFFSET_BITS=64). Also regtested on
amd64-pc-solaris2.11 (again on Solaris 11.3 and 11.4),
x86_64-pc-linux-gnu and i686-pc-linux-gnu.
config:
* largefile.m4 (ACX_LARGEFILE) <sparc-*-solaris*|i?86-*-solaris*>:
Check for <sys/procfs.h> incompatilibity with large-file support
on Solaris.
Only disable large-file support and perhaps plugins if needed.
Set, substitute LARGEFILE_CPPFLAGS if so.
bfd:
* bfd.m4 (BFD_SYS_PROCFS_H): New macro.
(BFD_HAVE_SYS_PROCFS_TYPE): Require BFD_SYS_PROCFS_H.
Don't define _STRUCTURED_PROC.
(BFD_HAVE_SYS_PROCFS_TYPE_MEMBER): Likewise.
* elf.c [HAVE_SYS_PROCFS_H] (_STRUCTURED_PROC): Don't define.
* configure.ac: Use BFD_SYS_PROCFS_H to check for <sys/procfs.h>.
* configure, config.in: Regenerate.
* Makefile.am (AM_CPPFLAGS): Add LARGEFILE_CPPFLAGS.
* Makefile.in, doc/Makefile.in: Regenerate.
binutils:
* Makefile.am (AM_CPPFLAGS): Add LARGEFILE_CPPFLAGS.
* Makefile.in, doc/Makefile.in: Regenerate.
* configure: Regenerate.
gas:
* Makefile.am (AM_CPPFLAGS): Add LARGEFILE_CPPFLAGS.
* Makefile.in, doc/Makefile.in: Regenerate.
* configure: Regenerate.
gdb:
* proc-api.c (_STRUCTURED_PROC): Don't define.
* proc-events.c: Likewise.
* proc-flags.c: Likewise.
* proc-why.c: Likewise.
* procfs.c: Likewise.
* Makefile.in (INTERNAL_CPPFLAGS): Add LARGEFILE_CPPFLAGS.
* configure, config.in: Regenerate.
gdbserver:
* configure, config.in: Regenerate.
gdbsupport:
* Makefile.am (AM_CPPFLAGS): Add LARGEFILE_CPPFLAGS.
* common.m4 (GDB_AC_COMMON): Use BFD_SYS_PROCFS_H to check for
<sys/procfs.h>.
* Makefile.in: Regenerate.
* configure, config.in: Regenerate.
gnulib:
* configure.ac: Run ACX_LARGEFILE before gl_EARLY.
* configure: Regenerate.
gprof:
* Makefile.am (AM_CPPFLAGS): Add LARGEFILE_CPPFLAGS.
* Makefile.in: Regenerate.
* configure: Regenerate.
ld:
* Makefile.am (AM_CPPFLAGS): Add LARGEFILE_CPPFLAGS.
* Makefile.in: Regenerate.
* configure: Regenerate.
277 lines
7.7 KiB
Plaintext
277 lines
7.7 KiB
Plaintext
2020-07-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
|
|
|
|
* Makefile.am (AM_CPPFLAGS): Add LARGEFILE_CPPFLAGS.
|
|
* common.m4 (GDB_AC_COMMON): Use BFD_SYS_PROCFS_H to check for
|
|
<sys/procfs.h>.
|
|
* Makefile.in: Regenerate.
|
|
* configure, config.in: Regenerate.
|
|
|
|
2020-07-28 Tom de Vries <tdevries@suse.de>
|
|
|
|
PR build/26281
|
|
* gdb_optional.h (class optional): Add volatile member to union
|
|
contaning m_dummy and m_item.
|
|
|
|
2020-07-17 Andrew Burgess <andrew.burgess@embecosm.com>
|
|
|
|
* tdesc.h (struct target_desc_deleter): Moved here
|
|
from gdb/target-descriptions.h, extend comment.
|
|
(target_desc_up): Likewise.
|
|
|
|
2020-06-30 Tom Tromey <tromey@adacore.com>
|
|
|
|
PR build/26183:
|
|
* gdb_string_view.h (basic_string_view::to_string): Remove.
|
|
(gdb::to_string): New function.
|
|
|
|
2020-06-27 Simon Marchi <simon.marchi@efficios.com>
|
|
|
|
* tdesc.h (class print_xml_feature) <add_line>: Add
|
|
ATTRIBUTE_PRINTF.
|
|
|
|
2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
|
|
|
|
* tdesc.cc (print_xml_feature::visit_pre): Use add_line to add
|
|
output content, and call indent as needed in all overloaded
|
|
variants.
|
|
(print_xml_feature::visit_post): Likewise.
|
|
(print_xml_feature::visit): Likewise.
|
|
(print_xml_feature::add_line): Two new overloaded functions.
|
|
* tdesc.h (print_xml_feature::indent): New member function.
|
|
(print_xml_feature::add_line): Two new overloaded member
|
|
functions.
|
|
(print_xml_feature::m_depth): New member variable.
|
|
|
|
2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
|
|
|
|
* tdesc.cc (print_xml_feature::visit_pre): Print compatible
|
|
information.
|
|
* tdesc.h (struct tdesc_compatible_info): Declare new struct.
|
|
(tdesc_compatible_info_up): New typedef.
|
|
(tdesc_compatible_info_list): Declare new function.
|
|
(tdesc_compatible_info_arch_name): Declare new function.
|
|
|
|
2020-05-25 Michael Weghorn <m.weghorn@posteo.de>
|
|
|
|
* common-utils.cc, common-utils.h (stringify_argv): Drop
|
|
now unused function stringify_argv
|
|
|
|
2020-05-25 Michael Weghorn <m.weghorn@posteo.de>
|
|
|
|
* common-inferior.cc, common-inferior.h (construct_inferior_arguments):
|
|
Adapt to take a gdb::array_view<char * const> parameter.
|
|
Adapt call site.
|
|
|
|
2020-05-25 Michael Weghorn <m.weghorn@posteo.de>
|
|
|
|
* common-inferior.cc, common-inferior.h (construct_inferior_arguments):
|
|
Adapt to handle zero args and return a std::string.
|
|
Adapt call site.
|
|
|
|
2020-05-25 Michael Weghorn <m.weghorn@posteo.de>
|
|
|
|
* common-inferior.h, common-inferior.cc: (construct_inferior_arguments):
|
|
Move function here from gdb/infcmd.c, gdb/inferior.h
|
|
|
|
2020-05-14 Kevin Buettner <kevinb@redhat.com>
|
|
|
|
* btrace-common.h (btrace_cpu_vendor): Add CV_AMD.
|
|
|
|
2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
|
|
|
|
* common-regcache.h (regcache_read_pc_protected): New function
|
|
declaration.
|
|
|
|
2020-04-28 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
|
|
|
|
* gdb-sigmask.h: Fix typo (pthead_sigmask -> pthread_sigmask).
|
|
|
|
2020-04-27 Simon Marchi <simon.marchi@polymtl.ca>
|
|
|
|
* common-defs.h: Include cstdlib.h.
|
|
|
|
2020-04-20 Tom Tromey <tromey@adacore.com>
|
|
|
|
* scoped_mmap.h (scoped_mmap): Mark move constructor as noexcept.
|
|
Use initialization style. Don't call destroy.
|
|
* scoped_fd.h (class scoped_fd): Mark move constructor as
|
|
noexcept.
|
|
* gdb_ref_ptr.h (class ref_ptr): Mark move constructor as
|
|
noexcept.
|
|
|
|
2020-04-13 Tom Tromey <tom@tromey.com>
|
|
|
|
* event-loop.c: Move comment. Remove obsolete comment.
|
|
|
|
2020-04-13 Tom Tromey <tom@tromey.com>
|
|
|
|
* event-loop.h: Move from ../gdb/.
|
|
* event-loop.cc: Move from ../gdb/.
|
|
|
|
2020-04-13 Tom Tromey <tom@tromey.com>
|
|
|
|
* errors.h (flush_streams): Declare.
|
|
|
|
2020-04-13 Tom Tromey <tom@tromey.com>
|
|
|
|
* gdb_select.h: Move from ../gdb/.
|
|
|
|
2020-04-13 Tom Tromey <tom@tromey.com>
|
|
|
|
* config.in, configure: Rebuild.
|
|
* common.m4 (GDB_AC_COMMON): Check for poll.h, sys/poll.h,
|
|
sys/select.h, and poll.
|
|
|
|
2020-03-31 Tom Tromey <tromey@adacore.com>
|
|
|
|
* btrace-common.cc (btrace_data_append): Conditionally call
|
|
memcpy.
|
|
|
|
2020-03-27 Andrew Burgess <andrew.burgess@embecosm.com>
|
|
|
|
* create-version.sh: Resolve issues highlighted by shellcheck.
|
|
|
|
2020-03-20 Simon Marchi <simon.marchi@efficios.com>
|
|
|
|
* config.in: Re-generate.
|
|
* configure: Re-generate.
|
|
|
|
2020-03-17 Kamil Rytarowski <n54@gmx.com>
|
|
|
|
* common-defs.h: Include alloca.h if HAVE_ALLOCA_H is defined.
|
|
|
|
2020-03-12 Tom Tromey <tom@tromey.com>
|
|
|
|
* common-types.h: Remove GDBSERVER code.
|
|
(gdb_byte, CORE_ADDR, LONGEST, ULONGEST): Redefine.
|
|
* common-defs.h: Remove GDBSERVER code.
|
|
|
|
2020-03-12 Simon Marchi <simon.marchi@efficios.com>
|
|
|
|
* selftest.m4: Moved from gdb/.
|
|
* acinclude.m4: Update path to selftest.m4.
|
|
|
|
2020-03-12 Simon Marchi <simon.marchi@efficios.com>
|
|
|
|
* configure.ac: Don't source bfd/development.sh.
|
|
* common.m4: Source bfd/development.sh.
|
|
* configure: Re-generate.
|
|
|
|
2020-03-12 Simon Marchi <simon.marchi@efficios.com>
|
|
|
|
* configure: Re-generate.
|
|
|
|
2020-03-11 Simon Marchi <simon.marchi@efficios.com>
|
|
|
|
* configure: Re-generate.
|
|
* warning.m4: Enable -Wmissing-prototypes.
|
|
|
|
2020-03-08 Tom Tromey <tom@tromey.com>
|
|
|
|
* gdb_binary_search.h: Fix two typos.
|
|
|
|
2020-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
|
|
|
|
* .dir-locals.el: New file.
|
|
|
|
2020-03-05 Vyacheslav Petrishchev <vyachemail@gmail.com>
|
|
|
|
* configure.ac: Added call development.sh.
|
|
* configure: Regenerate.
|
|
|
|
2020-03-05 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
|
|
|
|
* .gitattributes: New file.
|
|
|
|
2020-03-03 Simon Marchi <simon.marchi@efficios.com>
|
|
|
|
* Makefile.in: Re-generate.
|
|
|
|
2020-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
|
|
|
|
* gdb-dlfcn.h (gdb_dlopen): Update comment.
|
|
|
|
2020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
|
|
|
|
* configure: Regenerate.
|
|
|
|
2020-02-14 Tom Tromey <tom@tromey.com>
|
|
|
|
* common-defs.h: Change path to gnulib/config.h.
|
|
|
|
2020-02-13 Simon Marchi <simon.marchi@efficios.com>
|
|
|
|
* Makefile.am: Rename source files from .c to .cc.
|
|
(CC, CFLAGS): Don't override.
|
|
(AM_CFLAGS): Rename to ...
|
|
(AM_CXXFLAGS): ... this.
|
|
* Makefile.in: Re-generate.
|
|
* %.c: Rename to %.cc.
|
|
|
|
2020-02-11 Simon Marchi <simon.marchi@efficios.com>
|
|
|
|
* configure: Re-generate.
|
|
|
|
2020-02-11 Simon Marchi <simon.marchi@efficios.com>
|
|
|
|
* warning.m4: Add -Wstrict-null-sentinel.
|
|
* configure: Re-generate.
|
|
|
|
2020-02-11 Simon Marchi <simon.marchi@efficios.com>
|
|
|
|
* warning.m4: Move here, from gdb/warning.m4.
|
|
* acinclude.m4: Update warning.m4 path.
|
|
* Makefile.in: Re-generate.
|
|
|
|
2020-02-11 Simon Marchi <simon.marchi@efficios.com>
|
|
|
|
* acinclude.m4: Include ../gdb/warning.m4.
|
|
* configure.ac: Use AM_GDB_WARNINGS.
|
|
* Makefile.am: Set AM_CFLAGS to WARN_CFLAGS and WERROR_CFLAGS.
|
|
* Makefile.in: Re-generate.
|
|
* configure: Re-generate.
|
|
|
|
2020-02-10 Tom de Vries <tdevries@suse.de>
|
|
|
|
* environ.c (gdb_environ::set): Cast concat NULL sentinel to char *.
|
|
|
|
2020-01-24 Christian Biesinger <cbiesinger@google.com>
|
|
|
|
* thread-pool.c (set_thread_name): Add an overload for the NetBSD
|
|
version of pthread_setname_np.
|
|
|
|
2020-01-17 Pedro Alves <palves@redhat.com>
|
|
|
|
* Makefile.am: Append CXX_DIALECT to CXX.
|
|
* Makefile.in: Regenerate.
|
|
|
|
2020-01-17 Pedro Alves <palves@redhat.com>
|
|
|
|
* configure.ac: Generate config.h instead of support-config.h.
|
|
* common-defs.h: Include <gdbsupport/config.h> instead of
|
|
<gdbsupport/support-config.h>.
|
|
* Makefile.in: Regenerate.
|
|
* configure: Regenerate.
|
|
|
|
2020-01-14 Tom Tromey <tom@tromey.com>
|
|
|
|
* Makefile.in: Rebuild.
|
|
* Makefile.am (check-defines): New target.
|
|
* check-defines.el: New file.
|
|
|
|
2020-01-14 Tom Tromey <tom@tromey.com>
|
|
|
|
* configure, Makefile.in, aclocal.m4, common.m4, config.in:
|
|
Rebuild.
|
|
* common.m4 (GDB_AC_COMMON): Move many checks from
|
|
gdb/configure.ac.
|
|
* acinclude.m4: Include bfd.m4, ptrace.m4.
|
|
|
|
2020-01-14 Tom Tromey <tom@tromey.com>
|
|
|
|
* common-defs.h: Add GDBSERVER case. Update includes.
|
|
* acinclude.m4, aclocal.m4, config.in, configure, configure.ac,
|
|
Makefile.am, Makefile.in, README: New files.
|
|
* Moved from ../gdb/gdbsupport/
|
|
|