Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/external/gpl3/binutils Regen x86, add libctf.



details:   https://anonhg.NetBSD.org/src/rev/b90edf756063
branches:  trunk
changeset: 970774:b90edf756063
user:      christos <christos%NetBSD.org@localhost>
date:      Sat Apr 04 00:46:53 2020 +0000

description:
Regen x86, add libctf.

diffstat:

 external/gpl3/binutils/lib/Makefile                        |     4 +-
 external/gpl3/binutils/lib/libbfd/Makefile                 |     8 +-
 external/gpl3/binutils/lib/libbfd/arch/i386/bfd.h          |  1575 +++++------
 external/gpl3/binutils/lib/libbfd/arch/i386/bfd_stdint.h   |     2 +-
 external/gpl3/binutils/lib/libbfd/arch/i386/bfdver.h       |     6 +-
 external/gpl3/binutils/lib/libbfd/arch/i386/config.h       |    11 +-
 external/gpl3/binutils/lib/libbfd/arch/i386/defs.mk        |     8 +-
 external/gpl3/binutils/lib/libbfd/arch/x86_64/bfd.h        |  1577 +++++------
 external/gpl3/binutils/lib/libbfd/arch/x86_64/bfd_stdint.h |     4 +-
 external/gpl3/binutils/lib/libbfd/arch/x86_64/bfdver.h     |     8 +-
 external/gpl3/binutils/lib/libbfd/arch/x86_64/config.h     |    13 +-
 external/gpl3/binutils/lib/libbfd/arch/x86_64/defs.mk      |    10 +-
 external/gpl3/binutils/lib/libctf/Makefile                 |    36 +
 external/gpl3/binutils/lib/libctf/arch/i386/config.h       |   162 +
 external/gpl3/binutils/lib/libctf/arch/i386/defs.mk        |     5 +
 external/gpl3/binutils/lib/libctf/arch/x86_64/config.h     |   162 +
 external/gpl3/binutils/lib/libctf/arch/x86_64/defs.mk      |     5 +
 external/gpl3/binutils/lib/libiberty/arch/i386/config.h    |     3 +
 external/gpl3/binutils/lib/libiberty/arch/i386/defs.mk     |     4 +-
 external/gpl3/binutils/lib/libiberty/arch/x86_64/config.h  |     5 +-
 external/gpl3/binutils/lib/libiberty/arch/x86_64/defs.mk   |     6 +-
 external/gpl3/binutils/lib/libopcodes/Makefile             |     4 +-
 external/gpl3/binutils/lib/libopcodes/arch/i386/config.h   |     6 +-
 external/gpl3/binutils/lib/libopcodes/arch/x86_64/config.h |     8 +-
 external/gpl3/binutils/usr.bin/common/arch/i386/config.h   |    17 +-
 external/gpl3/binutils/usr.bin/common/arch/i386/defs.mk    |     8 +-
 external/gpl3/binutils/usr.bin/common/arch/x86_64/config.h |    19 +-
 external/gpl3/binutils/usr.bin/common/arch/x86_64/defs.mk  |    10 +-
 external/gpl3/binutils/usr.bin/gas/arch/i386/config.h      |    27 +-
 external/gpl3/binutils/usr.bin/gas/arch/x86_64/config.h    |    29 +-
 external/gpl3/binutils/usr.bin/gprof/arch/i386/gconfig.h   |     6 +-
 external/gpl3/binutils/usr.bin/gprof/arch/x86_64/gconfig.h |     8 +-
 external/gpl3/binutils/usr.bin/ld/Makefile                 |     5 +-
 external/gpl3/binutils/usr.bin/ld/arch/i386/config.h       |     6 +-
 external/gpl3/binutils/usr.bin/ld/arch/i386/defs.mk        |     2 +-
 external/gpl3/binutils/usr.bin/ld/arch/x86_64/config.h     |     8 +-
 external/gpl3/binutils/usr.bin/ld/arch/x86_64/defs.mk      |     4 +-
 external/gpl3/binutils/usr.bin/objdump/Makefile            |     4 +-
 external/gpl3/binutils/usr.bin/readelf/Makefile            |     5 +-
 39 files changed, 2101 insertions(+), 1689 deletions(-)

diffs (truncated from 5481 to 300 lines):

diff -r 7319fc28ff45 -r b90edf756063 external/gpl3/binutils/lib/Makefile
--- a/external/gpl3/binutils/lib/Makefile       Sat Apr 04 00:01:28 2020 +0000
+++ b/external/gpl3/binutils/lib/Makefile       Sat Apr 04 00:46:53 2020 +0000
@@ -1,5 +1,5 @@
-#      $NetBSD: Makefile,v 1.1 2009/08/18 20:21:59 skrll Exp $
+#      $NetBSD: Makefile,v 1.2 2020/04/04 00:46:53 christos Exp $
 
-SUBDIR+= libopcodes libbfd libiberty
+SUBDIR+= libctf libopcodes libbfd libiberty
 
 .include <bsd.subdir.mk>
diff -r 7319fc28ff45 -r b90edf756063 external/gpl3/binutils/lib/libbfd/Makefile
--- a/external/gpl3/binutils/lib/libbfd/Makefile        Sat Apr 04 00:01:28 2020 +0000
+++ b/external/gpl3/binutils/lib/libbfd/Makefile        Sat Apr 04 00:46:53 2020 +0000
@@ -1,4 +1,4 @@
-#      $NetBSD: Makefile,v 1.21 2018/11/07 01:13:56 christos Exp $
+#      $NetBSD: Makefile,v 1.22 2020/04/04 00:46:53 christos Exp $
 
 NOLINKLIB=     # defined
 NOLINT=                # defined
@@ -23,11 +23,12 @@
 DEFS_MK=${.CURDIR}/arch/${BFD_MACHINE_ARCH}/defs.mk
 # XXX: Fix me
 BINDIR=/usr/bin
+BINDIR=/usr/lib
 
 .if exists(${DEFS_MK})
 .include "${DEFS_MK}"
 
-SHLIB_MAJOR=   16
+SHLIB_MAJOR=   17
 SHLIB_MINOR=   0
 
 LIBDPLIBS+=    z       ${.CURDIR}/../../../../../lib/libz
@@ -37,7 +38,8 @@
 
 CPPFLAGS+=     -I${.CURDIR}/arch/${BFD_MACHINE_ARCH} -I${DIST}/include -I. \
                -I${DIST}/bfd ${GCPPFLAGS:M-D*} ${GCPPFLAGS:M-I*:N-I.*} \
-               -DDEBUGDIR=\"${DEBUGDIR}\" -DBINDIR=\"${BINDIR}\"
+               -DDEBUGDIR=\"${DEBUGDIR}\" -DLIBDIR=\"${LIBDIR}\" \
+               -DBINDIR=\"${BINDIR}\"
 
 .if (${BFD_MACHINE_ARCH} == "vax")
 CPPFLAGS.elf.c +=      -O0
diff -r 7319fc28ff45 -r b90edf756063 external/gpl3/binutils/lib/libbfd/arch/i386/bfd.h
--- a/external/gpl3/binutils/lib/libbfd/arch/i386/bfd.h Sat Apr 04 00:01:28 2020 +0000
+++ b/external/gpl3/binutils/lib/libbfd/arch/i386/bfd.h Sat Apr 04 00:46:53 2020 +0000
@@ -11,7 +11,7 @@
 
 /* Main header file for the bfd library -- portable access to object files.
 
-   Copyright (C) 1990-2018 Free Software Foundation, Inc.
+   Copyright (C) 1990-2020 Free Software Foundation, Inc.
 
    Contributed by Cygnus Support.
 
@@ -45,6 +45,7 @@
 
 #include "ansidecl.h"
 #include "symcat.h"
+#include "bfd_stdint.h"
 #include "diagnostics.h"
 #include <stdarg.h>
 #include <sys/stat.h>
@@ -245,32 +246,13 @@
 /* A count of carsyms (canonical archive symbols).  */
 typedef unsigned long symindex;
 
-/* How to perform a relocation.  */
-typedef const struct reloc_howto_struct reloc_howto_type;
-
 #define BFD_NO_MORE_SYMBOLS ((symindex) ~0)
 
-/* General purpose part of a symbol X;
-   target specific parts are in libcoff.h, libaout.h, etc.  */
-
-#define bfd_get_section(x) ((x)->section)
-#define bfd_get_output_section(x) ((x)->section->output_section)
-#define bfd_set_section(x,y) ((x)->section) = (y)
-#define bfd_asymbol_base(x) ((x)->section->vma)
-#define bfd_asymbol_value(x) (bfd_asymbol_base(x) + (x)->value)
-#define bfd_asymbol_name(x) ((x)->name)
-/*Perhaps future: #define bfd_asymbol_bfd(x) ((x)->section->owner)*/
-#define bfd_asymbol_bfd(x) ((x)->the_bfd)
-#define bfd_asymbol_flavour(x)                 \
-  (((x)->flags & BSF_SYNTHETIC) != 0           \
-   ? bfd_target_unknown_flavour                        \
-   : bfd_asymbol_bfd (x)->xvec->flavour)
-
 /* A canonical archive symbol.  */
 /* This is a type pun with struct ranlib on purpose!  */
 typedef struct carsym
 {
-  char *name;
+  const char *name;
   file_ptr file_offset;        /* Look here to find the file.  */
 }
 carsym;                        /* To make these you call a carsymogen.  */
@@ -314,37 +296,6 @@
   ((((bfd_vma) (this) + (boundary) - 1) >= (bfd_vma) (this))             \
    ? (((bfd_vma) (this) + ((boundary) - 1)) & ~ (bfd_vma) ((boundary)-1)) \
    : ~ (bfd_vma) 0)
-
-#define bfd_get_section_name(bfd, ptr) ((void) bfd, (ptr)->name)
-#define bfd_get_section_vma(bfd, ptr) ((void) bfd, (ptr)->vma)
-#define bfd_get_section_lma(bfd, ptr) ((void) bfd, (ptr)->lma)
-#define bfd_get_section_alignment(bfd, ptr) ((void) bfd, \
-                                            (ptr)->alignment_power)
-#define bfd_section_name(bfd, ptr) ((ptr)->name)
-#define bfd_section_size(bfd, ptr) ((ptr)->size)
-#define bfd_get_section_size(ptr) ((ptr)->size)
-#define bfd_section_vma(bfd, ptr) ((ptr)->vma)
-#define bfd_section_lma(bfd, ptr) ((ptr)->lma)
-#define bfd_section_alignment(bfd, ptr) ((ptr)->alignment_power)
-#define bfd_get_section_flags(bfd, ptr) ((void) bfd, (ptr)->flags)
-#define bfd_get_section_userdata(bfd, ptr) ((void) bfd, (ptr)->userdata)
-
-#define bfd_is_com_section(ptr) (((ptr)->flags & SEC_IS_COMMON) != 0)
-
-#define bfd_get_section_limit_octets(bfd, sec)                 \
-  ((bfd)->direction != write_direction && (sec)->rawsize != 0  \
-   ? (sec)->rawsize : (sec)->size)
-
-/* Find the address one past the end of SEC.  */
-#define bfd_get_section_limit(bfd, sec) \
-  (bfd_get_section_limit_octets(bfd, sec) / bfd_octets_per_byte (bfd))
-
-/* Return TRUE if input section SEC has been discarded.  */
-#define discarded_section(sec)                         \
-  (!bfd_is_abs_section (sec)                                   \
-   && bfd_is_abs_section ((sec)->output_section)               \
-   && (sec)->sec_info_type != SEC_INFO_TYPE_MERGE              \
-   && (sec)->sec_info_type != SEC_INFO_TYPE_JUST_SYMS)
 
 typedef enum bfd_print_symbol
 {
@@ -531,40 +482,6 @@
 #endif
 extern void _bfd_warn_deprecated (const char *, const char *, int, const char *);
 
-/* Cast from const char * to char * so that caller can assign to
-   a char * without a warning.  */
-#define bfd_get_filename(abfd) ((char *) (abfd)->filename)
-#define bfd_get_cacheable(abfd) ((abfd)->cacheable)
-#define bfd_get_format(abfd) ((abfd)->format)
-#define bfd_get_target(abfd) ((abfd)->xvec->name)
-#define bfd_get_flavour(abfd) ((abfd)->xvec->flavour)
-#define bfd_family_coff(abfd) \
-  (bfd_get_flavour (abfd) == bfd_target_coff_flavour || \
-   bfd_get_flavour (abfd) == bfd_target_xcoff_flavour)
-#define bfd_big_endian(abfd) ((abfd)->xvec->byteorder == BFD_ENDIAN_BIG)
-#define bfd_little_endian(abfd) ((abfd)->xvec->byteorder == BFD_ENDIAN_LITTLE)
-#define bfd_header_big_endian(abfd) \
-  ((abfd)->xvec->header_byteorder == BFD_ENDIAN_BIG)
-#define bfd_header_little_endian(abfd) \
-  ((abfd)->xvec->header_byteorder == BFD_ENDIAN_LITTLE)
-#define bfd_get_file_flags(abfd) ((abfd)->flags)
-#define bfd_applicable_file_flags(abfd) ((abfd)->xvec->object_flags)
-#define bfd_applicable_section_flags(abfd) ((abfd)->xvec->section_flags)
-#define bfd_has_map(abfd) ((abfd)->has_armap)
-#define bfd_is_thin_archive(abfd) ((abfd)->is_thin_archive)
-
-#define bfd_valid_reloc_types(abfd) ((abfd)->xvec->valid_reloc_types)
-#define bfd_usrdata(abfd) ((abfd)->usrdata)
-
-#define bfd_get_start_address(abfd) ((abfd)->start_address)
-#define bfd_get_symcount(abfd) ((abfd)->symcount)
-#define bfd_get_outsymbols(abfd) ((abfd)->outsymbols)
-#define bfd_count_sections(abfd) ((abfd)->section_count)
-
-#define bfd_get_dynamic_symcount(abfd) ((abfd)->dynsymcount)
-
-#define bfd_get_symbol_leading_char(abfd) ((abfd)->xvec->symbol_leading_char)
-
 extern bfd_boolean bfd_cache_close
   (bfd *abfd);
 /* NB: This declaration should match the autogenerated one in libbfd.h.  */
@@ -603,195 +520,6 @@
 bfd_uint64_t bfd_get_bits (const void *, int, bfd_boolean);
 void bfd_put_bits (bfd_uint64_t, void *, int, bfd_boolean);
 
-#if defined(__STDC__) || defined(ALMOST_STDC)
-struct ecoff_debug_info;
-struct ecoff_debug_swap;
-struct ecoff_extr;
-struct bfd_symbol;
-struct bfd_link_info;
-struct bfd_link_hash_entry;
-struct bfd_section_already_linked;
-struct bfd_elf_version_tree;
-#endif
-
-extern bfd_boolean bfd_section_already_linked_table_init (void);
-extern void bfd_section_already_linked_table_free (void);
-extern bfd_boolean _bfd_handle_already_linked
-  (struct bfd_section *, struct bfd_section_already_linked *,
-   struct bfd_link_info *);
-
-/* Externally visible ECOFF routines.  */
-
-extern bfd_boolean bfd_ecoff_set_gp_value
-  (bfd *abfd, bfd_vma gp_value);
-extern bfd_boolean bfd_ecoff_set_regmasks
-  (bfd *abfd, unsigned long gprmask, unsigned long fprmask,
-   unsigned long *cprmask);
-extern void *bfd_ecoff_debug_init
-  (bfd *output_bfd, struct ecoff_debug_info *output_debug,
-   const struct ecoff_debug_swap *output_swap, struct bfd_link_info *);
-extern void bfd_ecoff_debug_free
-  (void *handle, bfd *output_bfd, struct ecoff_debug_info *output_debug,
-   const struct ecoff_debug_swap *output_swap, struct bfd_link_info *);
-extern bfd_boolean bfd_ecoff_debug_accumulate
-  (void *handle, bfd *output_bfd, struct ecoff_debug_info *output_debug,
-   const struct ecoff_debug_swap *output_swap, bfd *input_bfd,
-   struct ecoff_debug_info *input_debug,
-   const struct ecoff_debug_swap *input_swap, struct bfd_link_info *);
-extern bfd_boolean bfd_ecoff_debug_accumulate_other
-  (void *handle, bfd *output_bfd, struct ecoff_debug_info *output_debug,
-   const struct ecoff_debug_swap *output_swap, bfd *input_bfd,
-   struct bfd_link_info *);
-extern bfd_boolean bfd_ecoff_debug_externals
-  (bfd *abfd, struct ecoff_debug_info *debug,
-   const struct ecoff_debug_swap *swap, bfd_boolean relocatable,
-   bfd_boolean (*get_extr) (struct bfd_symbol *, struct ecoff_extr *),
-   void (*set_index) (struct bfd_symbol *, bfd_size_type));
-extern bfd_boolean bfd_ecoff_debug_one_external
-  (bfd *abfd, struct ecoff_debug_info *debug,
-   const struct ecoff_debug_swap *swap, const char *name,
-   struct ecoff_extr *esym);
-extern bfd_size_type bfd_ecoff_debug_size
-  (bfd *abfd, struct ecoff_debug_info *debug,
-   const struct ecoff_debug_swap *swap);
-extern bfd_boolean bfd_ecoff_write_debug
-  (bfd *abfd, struct ecoff_debug_info *debug,
-   const struct ecoff_debug_swap *swap, file_ptr where);
-extern bfd_boolean bfd_ecoff_write_accumulated_debug
-  (void *handle, bfd *abfd, struct ecoff_debug_info *debug,
-   const struct ecoff_debug_swap *swap,
-   struct bfd_link_info *info, file_ptr where);
-
-/* Externally visible ELF routines.  */
-
-struct bfd_link_needed_list
-{
-  struct bfd_link_needed_list *next;
-  bfd *by;
-  const char *name;
-};
-
-enum dynamic_lib_link_class {
-  DYN_NORMAL = 0,
-  DYN_AS_NEEDED = 1,
-  DYN_DT_NEEDED = 2,
-  DYN_NO_ADD_NEEDED = 4,
-  DYN_NO_NEEDED = 8
-};
-
-enum notice_asneeded_action {
-  notice_as_needed,
-  notice_not_needed,
-  notice_needed
-};
-
-extern bfd_boolean bfd_elf_record_link_assignment
-  (bfd *, struct bfd_link_info *, const char *, bfd_boolean,
-   bfd_boolean);
-extern struct bfd_link_needed_list *bfd_elf_get_needed_list
-  (bfd *, struct bfd_link_info *);
-extern bfd_boolean bfd_elf_get_bfd_needed_list
-  (bfd *, struct bfd_link_needed_list **);
-extern bfd_boolean bfd_elf_stack_segment_size (bfd *, struct bfd_link_info *,
-                                              const char *, bfd_vma);
-extern bfd_boolean bfd_elf_size_dynamic_sections
-  (bfd *, const char *, const char *, const char *, const char *, const char *,
-   const char * const *, struct bfd_link_info *, struct bfd_section **);
-extern bfd_boolean bfd_elf_size_dynsym_hash_dynstr
-  (bfd *, struct bfd_link_info *);
-extern void bfd_elf_set_dt_needed_name
-  (bfd *, const char *);
-extern const char *bfd_elf_get_dt_soname
-  (bfd *);
-extern void bfd_elf_set_dyn_lib_class
-  (bfd *, enum dynamic_lib_link_class);
-extern int bfd_elf_get_dyn_lib_class
-  (bfd *);
-extern struct bfd_link_needed_list *bfd_elf_get_runpath_list
-  (bfd *, struct bfd_link_info *);
-extern int bfd_elf_discard_info
-  (bfd *, struct bfd_link_info *);
-extern unsigned int _bfd_elf_default_action_discarded
-  (struct bfd_section *);
-
-/* Return an upper bound on the number of bytes required to store a
-   copy of ABFD's program header table entries.  Return -1 if an error
-   occurs; bfd_get_error will return an appropriate code.  */
-extern long bfd_get_elf_phdr_upper_bound
-  (bfd *abfd);
-
-/* Copy ABFD's program header table entries to *PHDRS.  The entries
-   will be stored as an array of Elf_Internal_Phdr structures, as



Home | Main Index | Thread Index | Old Index