diff options
Diffstat (limited to 'bfd')
-rw-r--r-- | bfd/Makefile.in | 1 | ||||
-rw-r--r-- | bfd/aclocal.m4 | 1 | ||||
-rwxr-xr-x | bfd/configure | 60 | ||||
-rw-r--r-- | bfd/configure.ac | 8 | ||||
-rw-r--r-- | bfd/elf.c | 33 | ||||
-rw-r--r-- | bfd/version.h | 2 |
6 files changed, 27 insertions, 78 deletions
diff --git a/bfd/Makefile.in b/bfd/Makefile.in index 1543af7..8a670ad 100644 --- a/bfd/Makefile.in +++ b/bfd/Makefile.in @@ -113,7 +113,6 @@ target_triplet = @target@ subdir = . ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/../config/acx.m4 \ - $(top_srcdir)/../config/bfd64.m4 \ $(top_srcdir)/../config/depstand.m4 \ $(top_srcdir)/../config/gettext-sister.m4 \ $(top_srcdir)/../config/gettext.m4 \ diff --git a/bfd/aclocal.m4 b/bfd/aclocal.m4 index 8364b5d..4d1b7ba 100644 --- a/bfd/aclocal.m4 +++ b/bfd/aclocal.m4 @@ -1168,7 +1168,6 @@ AC_SUBST([am__untar]) ]) # _AM_PROG_TAR m4_include([../config/acx.m4]) -m4_include([../config/bfd64.m4]) m4_include([../config/depstand.m4]) m4_include([../config/gettext-sister.m4]) m4_include([../config/gettext.m4]) diff --git a/bfd/configure b/bfd/configure index ca7f66f..f69df12 100755 --- a/bfd/configure +++ b/bfd/configure @@ -702,8 +702,6 @@ REPORT_BUGS_TEXI REPORT_BUGS_TO PKGVERSION DEBUGDIR -ENABLE_BFD_64_BIT_FALSE -ENABLE_BFD_64_BIT_TRUE PLUGINS_FALSE PLUGINS_TRUE LARGEFILE_CPPFLAGS @@ -11155,7 +11153,7 @@ else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext <<_LT_EOF -#line 11158 "configure" +#line 11156 "configure" #include "confdefs.h" #if HAVE_DLFCN_H @@ -11261,7 +11259,7 @@ else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext <<_LT_EOF -#line 11264 "configure" +#line 11262 "configure" #include "confdefs.h" #if HAVE_DLFCN_H @@ -11930,56 +11928,6 @@ else enable_64_bit_bfd=no fi - -if test "x$enable_64_bit_bfd" = "xno"; then : - # The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of void *" >&5 -$as_echo_n "checking size of void *... " >&6; } -if ${ac_cv_sizeof_void_p+:} false; then : - $as_echo_n "(cached) " >&6 -else - if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (void *))" "ac_cv_sizeof_void_p" "$ac_includes_default"; then : - -else - if test "$ac_cv_type_void_p" = yes; then - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error 77 "cannot compute sizeof (void *) -See \`config.log' for more details" "$LINENO" 5; } - else - ac_cv_sizeof_void_p=0 - fi -fi - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_void_p" >&5 -$as_echo "$ac_cv_sizeof_void_p" >&6; } - - - -cat >>confdefs.h <<_ACEOF -#define SIZEOF_VOID_P $ac_cv_sizeof_void_p -_ACEOF - - - if test "x$ac_cv_sizeof_void_p" = "x8"; then : - enable_64_bit_bfd=yes -fi - -fi - - if test "x$enable_64_bit_bfd" = "xyes"; then - ENABLE_BFD_64_BIT_TRUE= - ENABLE_BFD_64_BIT_FALSE='#' -else - ENABLE_BFD_64_BIT_TRUE='#' - ENABLE_BFD_64_BIT_FALSE= -fi - - if test $enable_64_bit_bfd = yes ; then want64=true else @@ -17677,10 +17625,6 @@ if test -z "${PLUGINS_TRUE}" && test -z "${PLUGINS_FALSE}"; then as_fn_error $? "conditional \"PLUGINS\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi -if test -z "${ENABLE_BFD_64_BIT_TRUE}" && test -z "${ENABLE_BFD_64_BIT_FALSE}"; then - as_fn_error $? "conditional \"ENABLE_BFD_64_BIT\" was never defined. -Usually this means the macro was only invoked conditionally." "$LINENO" 5 -fi if test -z "${MAINTAINER_MODE_TRUE}" && test -z "${MAINTAINER_MODE_FALSE}"; then as_fn_error $? "conditional \"MAINTAINER_MODE\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 diff --git a/bfd/configure.ac b/bfd/configure.ac index 90fad54..e9942d2 100644 --- a/bfd/configure.ac +++ b/bfd/configure.ac @@ -81,7 +81,13 @@ if test x$ac_checking != x ; then AC_DEFINE(ENABLE_CHECKING, 1, [Define if you want run-time sanity checks.]) fi -BFD_64_BIT +AC_ARG_ENABLE(64-bit-bfd, + AS_HELP_STRING([--enable-64-bit-bfd], + [64-bit support (on hosts with narrower word sizes)]), + [AS_CASE([$enableval], + [yes|no], [], + [*], [AC_MSG_ERROR(bad value ${enableval} for 64-bit-bfd option)])], + [enable_64_bit_bfd=no]) if test $enable_64_bit_bfd = yes ; then want64=true else @@ -6292,27 +6292,28 @@ assign_file_positions_for_load_sections (bfd *abfd, } else { - if (p->p_type == PT_LOAD) - { - this_hdr->sh_offset = sec->filepos = off; - if (this_hdr->sh_type != SHT_NOBITS) - off += this_hdr->sh_size; - } - else if (this_hdr->sh_type == SHT_NOBITS - && (this_hdr->sh_flags & SHF_TLS) != 0 - && this_hdr->sh_offset == 0) + if (this_hdr->sh_type == SHT_NOBITS + && (this_hdr->sh_flags & SHF_TLS) != 0 + && this_hdr->sh_offset == 0) { - /* This is a .tbss section that didn't get a PT_LOAD. - (See _bfd_elf_map_sections_to_segments "Create a - final PT_LOAD".) Set sh_offset to the value it - would have if we had created a zero p_filesz and - p_memsz PT_LOAD header for the section. This - also makes the PT_TLS header have the same - p_offset value. */ + /* Set sh_offset for .tbss sections to their nominal + offset after aligning. They are not loaded from + disk so the value doesn't really matter, except + when the .tbss section is the first one in a + PT_TLS segment. In that case it sets the + p_offset for the PT_TLS segment, which according + to the ELF gABI ought to satisfy + p_offset % p_align == p_vaddr % p_align. */ bfd_vma adjust = vma_page_aligned_bias (this_hdr->sh_addr, off, align); this_hdr->sh_offset = sec->filepos = off + adjust; } + else if (p->p_type == PT_LOAD) + { + this_hdr->sh_offset = sec->filepos = off; + if (this_hdr->sh_type != SHT_NOBITS) + off += this_hdr->sh_size; + } if (this_hdr->sh_type != SHT_NOBITS) { diff --git a/bfd/version.h b/bfd/version.h index 61a84a9..2e4741a 100644 --- a/bfd/version.h +++ b/bfd/version.h @@ -16,7 +16,7 @@ In releases, the date is not included in either version strings or sonames. */ -#define BFD_VERSION_DATE 20250426 +#define BFD_VERSION_DATE 20250429 #define BFD_VERSION @bfd_version@ #define BFD_VERSION_STRING @bfd_version_package@ @bfd_version_string@ #define REPORT_BUGS_TO @report_bugs_to@ |