binutils: update to 2.27
This commit is contained in:
@@ -6,13 +6,13 @@ and nul here acts like a normal file with 0 size as far as stat() is concerned.
|
||||
Check harder for the file in question being unusual (isatty() does see that).
|
||||
And since configure script expects /dev/nul, do report it that way.
|
||||
|
||||
--- binutils-git-39d1b2aef3c1dbbf31d82e555624afcbda9d58e7/binutils/bucomm.c.orig 2014-04-27 18:05:31.328777900 +0400
|
||||
+++ binutils-git-39d1b2aef3c1dbbf31d82e555624afcbda9d58e7/binutils/bucomm.c 2014-05-02 08:54:46.651964974 +0400
|
||||
@@ -570,7 +570,15 @@
|
||||
get_file_size (const char * file_name)
|
||||
diff -urN binutils-2.27.orig/binutils/bucomm.c binutils-2.27/binutils/bucomm.c
|
||||
--- binutils-2.27.orig/binutils/bucomm.c 2016-08-03 09:36:51.000000000 +0200
|
||||
+++ binutils-2.27/binutils/bucomm.c 2016-09-21 20:43:33.158175700 +0200
|
||||
@@ -575,6 +575,15 @@
|
||||
{
|
||||
struct stat statbuf;
|
||||
-
|
||||
|
||||
+ int f, t;
|
||||
+ t = -1;
|
||||
+ f = open (file_name, O_RDONLY | O_BINARY);
|
||||
@@ -25,10 +25,10 @@ And since configure script expects /dev/nul, do report it that way.
|
||||
if (stat (file_name, &statbuf) < 0)
|
||||
{
|
||||
if (errno == ENOENT)
|
||||
@@ -579,8 +587,15 @@
|
||||
@@ -583,8 +592,15 @@
|
||||
non_fatal (_("Warning: could not locate '%s'. reason: %s"),
|
||||
file_name, strerror (errno));
|
||||
}
|
||||
}
|
||||
- else if (! S_ISREG (statbuf.st_mode))
|
||||
- non_fatal (_("Warning: '%s' is not an ordinary file"), file_name);
|
||||
+ else if (! S_ISREG (statbuf.st_mode) || t > 0)
|
||||
@@ -43,9 +43,10 @@ And since configure script expects /dev/nul, do report it that way.
|
||||
else if (statbuf.st_size < 0)
|
||||
non_fatal (_("Warning: '%s' has negative size, probably it is too large"),
|
||||
file_name);
|
||||
--- binutils-git-39d1b2aef3c1dbbf31d82e555624afcbda9d58e7/binutils/elfedit.c.orig 2014-04-27 18:05:31.340778000 +0400
|
||||
+++ binutils-git-39d1b2aef3c1dbbf31d82e555624afcbda9d58e7/binutils/elfedit.c 2014-05-02 08:55:09.433461424 +0400
|
||||
@@ -441,6 +441,14 @@
|
||||
diff -urN binutils-2.27.orig/binutils/elfedit.c binutils-2.27/binutils/elfedit.c
|
||||
--- binutils-2.27.orig/binutils/elfedit.c 2016-08-03 09:36:51.000000000 +0200
|
||||
+++ binutils-2.27/binutils/elfedit.c 2016-09-21 20:38:40.359931800 +0200
|
||||
@@ -483,6 +483,14 @@
|
||||
check_file (const char *file_name, struct stat *statbuf_p)
|
||||
{
|
||||
struct stat statbuf;
|
||||
@@ -57,13 +58,13 @@ And since configure script expects /dev/nul, do report it that way.
|
||||
+ t = isatty (f);
|
||||
+ close (f);
|
||||
+ }
|
||||
|
||||
|
||||
if (statbuf_p == NULL)
|
||||
statbuf_p = &statbuf;
|
||||
@@ -455,8 +463,13 @@
|
||||
@@ -497,8 +505,13 @@
|
||||
return 1;
|
||||
}
|
||||
|
||||
|
||||
- if (! S_ISREG (statbuf_p->st_mode))
|
||||
+ if (! S_ISREG (statbuf_p->st_mode) || t > 0)
|
||||
{
|
||||
@@ -75,35 +76,3 @@ And since configure script expects /dev/nul, do report it that way.
|
||||
error (_("'%s' is not an ordinary file\n"), file_name);
|
||||
return 1;
|
||||
}
|
||||
--- binutils-git-39d1b2aef3c1dbbf31d82e555624afcbda9d58e7/binutils/readelf.c.orig 2014-04-27 18:05:31.384778200 +0400
|
||||
+++ binutils-git-39d1b2aef3c1dbbf31d82e555624afcbda9d58e7/binutils/readelf.c 2014-05-02 08:55:27.018918502 +0400
|
||||
@@ -14613,6 +14613,14 @@
|
||||
struct stat statbuf;
|
||||
char armag[SARMAG];
|
||||
int ret;
|
||||
+ int f, t;
|
||||
+ t = -1;
|
||||
+ f = open (file_name, O_RDONLY | O_BINARY);
|
||||
+ if (f != 0)
|
||||
+ {
|
||||
+ t = isatty (f);
|
||||
+ close (f);
|
||||
+ }
|
||||
|
||||
if (stat (file_name, &statbuf) < 0)
|
||||
{
|
||||
@@ -14624,8 +14632,13 @@
|
||||
return 1;
|
||||
}
|
||||
|
||||
- if (! S_ISREG (statbuf.st_mode))
|
||||
+ if (! S_ISREG (statbuf.st_mode) || t > 0)
|
||||
{
|
||||
+#ifdef _WIN32
|
||||
+ /* libtool passes /dev/null and checks for /dev/null in the output */
|
||||
+ if (stricmp (file_name, "nul") == 0)
|
||||
+ file_name = "/dev/null";
|
||||
+#endif
|
||||
error (_("'%s' is not an ordinary file\n"), file_name);
|
||||
return 1;
|
||||
}
|
||||
|
||||
@@ -1,7 +1,8 @@
|
||||
--- gdb-7.6/libiberty/Makefile.in.orig 2013-06-12 04:27:21 +0400
|
||||
+++ gdb-7.6/libiberty/Makefile.in 2013-06-12 04:35:26 +0400
|
||||
@@ -129,7 +129,7 @@
|
||||
dwarfnames.c dyn-string.c \
|
||||
diff -urN binutils-2.27.orig/libiberty/Makefile.in binutils-2.27/libiberty/Makefile.in
|
||||
--- binutils-2.27.orig/libiberty/Makefile.in 2016-08-03 09:36:54.000000000 +0200
|
||||
+++ binutils-2.27/libiberty/Makefile.in 2016-09-21 21:10:01.901622600 +0200
|
||||
@@ -131,7 +131,7 @@
|
||||
d-demangle.c dwarfnames.c dyn-string.c \
|
||||
fdmatch.c ffs.c fibheap.c filename_cmp.c floatformat.c \
|
||||
fnmatch.c fopen_unlocked.c \
|
||||
- getcwd.c getopt.c getopt1.c getpagesize.c getpwd.c getruntime.c \
|
||||
@@ -9,18 +10,19 @@
|
||||
gettimeofday.c \
|
||||
hashtab.c hex.c \
|
||||
index.c insque.c \
|
||||
@@ -154,8 +154,8 @@
|
||||
strtoul.c strndup.c strnlen.c strverscmp.c \
|
||||
timeval-utils.c tmpnam.c \
|
||||
@@ -156,9 +156,9 @@
|
||||
strtoll.c strtoul.c strtoull.c strndup.c strnlen.c \
|
||||
strverscmp.c timeval-utils.c tmpnam.c \
|
||||
unlink-if-ordinary.c \
|
||||
- vasprintf.c vfork.c vfprintf.c vprintf.c vsnprintf.c vsprintf.c \
|
||||
- vasprintf.c vfork.c vfprintf.c vprintf.c vprintf-support.c \
|
||||
+ vasprintf.c vfprintf.c vprintf.c vprintf-support.c \
|
||||
vsnprintf.c vsprintf.c \
|
||||
- waitpid.c \
|
||||
+ vasprintf.c vfprintf.c vprintf.c vsnprintf.c vsprintf.c \
|
||||
+ msdos.c \
|
||||
xatexit.c xexit.c xmalloc.c xmemdup.c xstrdup.c xstrerror.c \
|
||||
xstrndup.c
|
||||
|
||||
@@ -171,7 +171,7 @@
|
||||
xasprintf.c xatexit.c xexit.c xmalloc.c xmemdup.c xstrdup.c \
|
||||
xstrerror.c xstrndup.c xvasprintf.c
|
||||
|
||||
@@ -174,7 +174,7 @@
|
||||
./fdmatch.$(objext) ./fibheap.$(objext) \
|
||||
./filename_cmp.$(objext) ./floatformat.$(objext) \
|
||||
./fnmatch.$(objext) ./fopen_unlocked.$(objext) \
|
||||
@@ -29,15 +31,15 @@
|
||||
./getruntime.$(objext) ./hashtab.$(objext) ./hex.$(objext) \
|
||||
./lbasename.$(objext) ./lrealpath.$(objext) \
|
||||
./make-relative-prefix.$(objext) ./make-temp-file.$(objext) \
|
||||
@@ -220,9 +220,9 @@
|
||||
@@ -224,9 +224,9 @@
|
||||
./strrchr.$(objext) ./strstr.$(objext) ./strtod.$(objext) \
|
||||
./strtol.$(objext) ./strtoul.$(objext) ./strverscmp.$(objext) \
|
||||
./tmpnam.$(objext) \
|
||||
./strtol.$(objext) ./strtoul.$(objext) strtoll.$(objext) \
|
||||
./strtoull.$(objext) ./tmpnam.$(objext) ./strverscmp.$(objext) \
|
||||
- ./vasprintf.$(objext) ./vfork.$(objext) ./vfprintf.$(objext) \
|
||||
+ ./vasprintf.$(objext) ./vfprintf.$(objext) \
|
||||
./vprintf.$(objext) ./vsnprintf.$(objext) ./vsprintf.$(objext) \
|
||||
- ./waitpid.$(objext)
|
||||
+ ./msdos.$(objext)
|
||||
|
||||
|
||||
# These files are installed if the library has been configured to do so.
|
||||
INSTALLED_HEADERS = \
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
diff -Naur binutils-2.24/bfd/bfd-in.h binutils-2.24-mingw/bfd/bfd-in.h
|
||||
--- binutils-2.24/bfd/bfd-in.h 2013-11-04 19:33:37.000000000 +0400
|
||||
+++ binutils-2.24-mingw/bfd/bfd-in.h 2014-03-13 22:24:26.512400000 +0400
|
||||
diff -urN binutils-2.27.orig/bfd/bfd-in.h binutils-2.27/bfd/bfd-in.h
|
||||
--- binutils-2.27.orig/bfd/bfd-in.h 2016-08-03 09:36:50.000000000 +0200
|
||||
+++ binutils-2.27/bfd/bfd-in.h 2016-09-21 21:13:49.177148600 +0200
|
||||
@@ -137,7 +137,7 @@
|
||||
|
||||
|
||||
#if BFD_HOST_64BIT_LONG
|
||||
#define BFD_VMA_FMT "l"
|
||||
-#elif defined (__MSVCRT__)
|
||||
@@ -10,11 +10,11 @@ diff -Naur binutils-2.24/bfd/bfd-in.h binutils-2.24-mingw/bfd/bfd-in.h
|
||||
#define BFD_VMA_FMT "I64"
|
||||
#else
|
||||
#define BFD_VMA_FMT "ll"
|
||||
diff -Naur binutils-2.24/bfd/bfd-in2.h binutils-2.24-mingw/bfd/bfd-in2.h
|
||||
--- binutils-2.24/bfd/bfd-in2.h 2013-11-18 12:40:15.000000000 +0400
|
||||
+++ binutils-2.24-mingw/bfd/bfd-in2.h 2014-03-13 22:24:03.580400000 +0400
|
||||
diff -urN binutils-2.27.orig/bfd/bfd-in2.h binutils-2.27/bfd/bfd-in2.h
|
||||
--- binutils-2.27.orig/bfd/bfd-in2.h 2016-08-03 09:36:50.000000000 +0200
|
||||
+++ binutils-2.27/bfd/bfd-in2.h 2016-09-21 21:13:49.185161800 +0200
|
||||
@@ -144,7 +144,7 @@
|
||||
|
||||
|
||||
#if BFD_HOST_64BIT_LONG
|
||||
#define BFD_VMA_FMT "l"
|
||||
-#elif defined (__MSVCRT__)
|
||||
@@ -22,22 +22,22 @@ diff -Naur binutils-2.24/bfd/bfd-in2.h binutils-2.24-mingw/bfd/bfd-in2.h
|
||||
#define BFD_VMA_FMT "I64"
|
||||
#else
|
||||
#define BFD_VMA_FMT "ll"
|
||||
diff -Naur binutils-2.24/binutils/dwarf.c binutils-2.24-mingw/binutils/dwarf.c
|
||||
--- binutils-2.24/binutils/dwarf.c 2013-11-08 14:13:48.000000000 +0400
|
||||
+++ binutils-2.24-mingw/binutils/dwarf.c 2014-03-13 22:58:50.101400000 +0400
|
||||
@@ -140,7 +140,7 @@
|
||||
diff -urN binutils-2.27.orig/binutils/dwarf.c binutils-2.27/binutils/dwarf.c
|
||||
--- binutils-2.27.orig/binutils/dwarf.c 2016-08-03 09:36:51.000000000 +0200
|
||||
+++ binutils-2.27/binutils/dwarf.c 2016-09-21 21:13:49.210178100 +0200
|
||||
@@ -164,7 +164,7 @@
|
||||
}
|
||||
|
||||
|
||||
#if defined HAVE_LONG_LONG && SIZEOF_LONG_LONG > SIZEOF_LONG
|
||||
-# ifndef __MINGW32__
|
||||
+#if !defined(__MSVCRT__) || defined(__USE_MINGW_ANSI_STDIO)
|
||||
# define DWARF_VMA_FMT "ll"
|
||||
# define DWARF_VMA_FMT_LONG "%16.16llx"
|
||||
# else
|
||||
diff -Naur binutils-2.24/binutils/nm.c binutils-2.24-mingw/binutils/nm.c
|
||||
--- binutils-2.24/binutils/nm.c 2013-11-08 14:13:48.000000000 +0400
|
||||
+++ binutils-2.24-mingw/binutils/nm.c 2014-03-13 22:18:43.452800000 +0400
|
||||
@@ -164,7 +164,7 @@
|
||||
diff -urN binutils-2.27.orig/binutils/nm.c binutils-2.27/binutils/nm.c
|
||||
--- binutils-2.27.orig/binutils/nm.c 2016-08-03 09:36:51.000000000 +0200
|
||||
+++ binutils-2.27/binutils/nm.c 2016-09-21 21:13:49.221191400 +0200
|
||||
@@ -170,7 +170,7 @@
|
||||
#if BFD_HOST_64BIT_LONG
|
||||
static char value_format_64bit[] = "%016lx";
|
||||
#elif BFD_HOST_64BIT_LONG_LONG
|
||||
@@ -46,7 +46,7 @@ diff -Naur binutils-2.24/binutils/nm.c binutils-2.24-mingw/binutils/nm.c
|
||||
static char value_format_64bit[] = "%016llx";
|
||||
#else
|
||||
static char value_format_64bit[] = "%016I64x";
|
||||
@@ -290,7 +290,7 @@
|
||||
@@ -300,7 +300,7 @@
|
||||
#if BFD_HOST_64BIT_LONG
|
||||
value_format_64bit[5] = *radix;
|
||||
#elif BFD_HOST_64BIT_LONG_LONG
|
||||
@@ -55,9 +55,9 @@ diff -Naur binutils-2.24/binutils/nm.c binutils-2.24-mingw/binutils/nm.c
|
||||
value_format_64bit[6] = *radix;
|
||||
#else
|
||||
value_format_64bit[7] = *radix;
|
||||
diff -Naur binutils-2.24/binutils/prdbg.c binutils-2.24-mingw/binutils/prdbg.c
|
||||
--- binutils-2.24/binutils/prdbg.c 2013-11-04 19:33:37.000000000 +0400
|
||||
+++ binutils-2.24-mingw/binutils/prdbg.c 2014-03-13 22:19:45.603200000 +0400
|
||||
diff -urN binutils-2.27.orig/binutils/prdbg.c binutils-2.27/binutils/prdbg.c
|
||||
--- binutils-2.27.orig/binutils/prdbg.c 2016-08-03 09:36:51.000000000 +0200
|
||||
+++ binutils-2.27/binutils/prdbg.c 2016-09-21 21:13:49.229194100 +0200
|
||||
@@ -502,7 +502,7 @@
|
||||
#if BFD_HOST_64BIT_LONG_LONG
|
||||
else if (sizeof (vma) <= sizeof (unsigned long long))
|
||||
@@ -67,10 +67,10 @@ diff -Naur binutils-2.24/binutils/prdbg.c binutils-2.24-mingw/binutils/prdbg.c
|
||||
if (hexp)
|
||||
sprintf (buf, "0x%llx", (unsigned long long) vma);
|
||||
else if (unsignedp)
|
||||
diff -Naur binutils-2.24/binutils/readelf.c binutils-2.24-mingw/binutils/readelf.c
|
||||
--- binutils-2.24/binutils/readelf.c 2013-11-18 12:40:15.000000000 +0400
|
||||
+++ binutils-2.24-mingw/binutils/readelf.c 2014-03-13 22:20:53.494400000 +0400
|
||||
@@ -1006,7 +1006,7 @@
|
||||
diff -urN binutils-2.27.orig/binutils/readelf.c binutils-2.27/binutils/readelf.c
|
||||
--- binutils-2.27.orig/binutils/readelf.c 2016-08-03 09:36:51.000000000 +0200
|
||||
+++ binutils-2.27/binutils/readelf.c 2016-09-21 21:13:49.240194700 +0200
|
||||
@@ -1154,7 +1154,7 @@
|
||||
: "%12.12lx %12.12lx ",
|
||||
offset, inf);
|
||||
#elif BFD_HOST_64BIT_LONG_LONG
|
||||
@@ -79,19 +79,19 @@ diff -Naur binutils-2.24/binutils/readelf.c binutils-2.24-mingw/binutils/readelf
|
||||
printf (do_wide
|
||||
? "%16.16llx %16.16llx "
|
||||
: "%12.12llx %12.12llx ",
|
||||
@@ -10836,7 +10836,7 @@
|
||||
@@ -12372,7 +12372,7 @@
|
||||
{
|
||||
size_t maxlen = end - data;
|
||||
|
||||
|
||||
-#ifndef __MSVCRT__
|
||||
+#if !defined(__MSVCRT__) || defined(__USE_MINGW_ANSI_STDIO)
|
||||
/* PR 11128: Use two separate invocations in order to work
|
||||
around bugs in the Solaris 8 implementation of printf. */
|
||||
printf (" [%6tx] ", data - start);
|
||||
diff -Naur binutils-2.24/binutils/strings.c binutils-2.24-mingw/binutils/strings.c
|
||||
--- binutils-2.24/binutils/strings.c 2013-11-04 19:33:37.000000000 +0400
|
||||
+++ binutils-2.24-mingw/binutils/strings.c 2014-03-13 22:21:29.140400000 +0400
|
||||
@@ -582,7 +582,7 @@
|
||||
diff -urN binutils-2.27.orig/binutils/strings.c binutils-2.27/binutils/strings.c
|
||||
--- binutils-2.27.orig/binutils/strings.c 2016-08-03 09:36:51.000000000 +0200
|
||||
+++ binutils-2.27/binutils/strings.c 2016-09-21 21:13:49.251195600 +0200
|
||||
@@ -595,7 +595,7 @@
|
||||
#ifdef HAVE_LONG_LONG
|
||||
if (sizeof (start) > sizeof (long))
|
||||
{
|
||||
@@ -100,7 +100,7 @@ diff -Naur binutils-2.24/binutils/strings.c binutils-2.24-mingw/binutils/strings
|
||||
printf ("%7llo ", (unsigned long long) start);
|
||||
# else
|
||||
printf ("%7I64o ", (unsigned long long) start);
|
||||
@@ -601,7 +601,7 @@
|
||||
@@ -614,7 +614,7 @@
|
||||
#ifdef HAVE_LONG_LONG
|
||||
if (sizeof (start) > sizeof (long))
|
||||
{
|
||||
@@ -109,7 +109,7 @@ diff -Naur binutils-2.24/binutils/strings.c binutils-2.24-mingw/binutils/strings
|
||||
printf ("%7lld ", (unsigned long long) start);
|
||||
# else
|
||||
printf ("%7I64d ", (unsigned long long) start);
|
||||
@@ -620,7 +620,7 @@
|
||||
@@ -633,7 +633,7 @@
|
||||
#ifdef HAVE_LONG_LONG
|
||||
if (sizeof (start) > sizeof (long))
|
||||
{
|
||||
@@ -118,47 +118,50 @@ diff -Naur binutils-2.24/binutils/strings.c binutils-2.24-mingw/binutils/strings
|
||||
printf ("%7llx ", (unsigned long long) start);
|
||||
# else
|
||||
printf ("%7I64x ", (unsigned long long) start);
|
||||
diff -Naur binutils-2.24/gas/read.c binutils-2.24-mingw/gas/read.c
|
||||
--- binutils-2.24/gas/read.c 2013-11-08 14:13:48.000000000 +0400
|
||||
+++ binutils-2.24-mingw/gas/read.c 2014-03-13 22:22:11.806400000 +0400
|
||||
@@ -4293,7 +4293,7 @@
|
||||
|| (get & hibit) == 0))
|
||||
{ /* Leading bits contain both 0s & 1s. */
|
||||
diff -urN binutils-2.27.orig/gas/as.h binutils-2.27/gas/as.h
|
||||
--- binutils-2.27.orig/gas/as.h 2016-08-03 09:36:51.000000000 +0200
|
||||
+++ binutils-2.27/gas/as.h 2016-09-21 21:25:33.955958500 +0200
|
||||
@@ -438,10 +438,10 @@
|
||||
|
||||
#define PRINTF_LIKE(FCN) \
|
||||
void FCN (const char *format, ...) \
|
||||
- __attribute__ ((__format__ (__printf__, 1, 2)))
|
||||
+ __attribute__ ((__format__ (gnu_printf, 1, 2)))
|
||||
#define PRINTF_WHERE_LIKE(FCN) \
|
||||
void FCN (const char *file, unsigned int line, const char *format, ...) \
|
||||
- __attribute__ ((__format__ (__printf__, 3, 4)))
|
||||
+ __attribute__ ((__format__ (gnu_printf, 3, 4)))
|
||||
|
||||
#else /* __GNUC__ < 2 || defined(VMS) */
|
||||
|
||||
diff -urN binutils-2.27.orig/gas/read.c binutils-2.27/gas/read.c
|
||||
--- binutils-2.27.orig/gas/read.c 2016-08-03 09:36:51.000000000 +0200
|
||||
+++ binutils-2.27/gas/read.c 2016-09-21 21:13:49.262196200 +0200
|
||||
@@ -4415,7 +4415,7 @@
|
||||
{
|
||||
/* Leading bits contain both 0s & 1s. */
|
||||
#if defined (BFD64) && BFD_HOST_64BIT_LONG_LONG
|
||||
-#ifndef __MSVCRT__
|
||||
+#if !defined(__MSVCRT__) || defined(__USE_MINGW_ANSI_STDIO)
|
||||
as_warn (_("value 0x%llx truncated to 0x%llx"),
|
||||
(unsigned long long) get, (unsigned long long) use);
|
||||
#else
|
||||
--- binutils-2.25/gas/as.h.orig 2014-12-26 08:20:07.506000000 +0300
|
||||
+++ binutils-2.25/gas/as.h 2014-12-26 08:21:13.350000000 +0300
|
||||
@@ -451,10 +451,10 @@
|
||||
|
||||
#define PRINTF_LIKE(FCN) \
|
||||
void FCN (const char *format, ...) \
|
||||
- __attribute__ ((__format__ (__printf__, 1, 2)))
|
||||
+ __attribute__ ((__format__ (gnu_printf, 1, 2)))
|
||||
#define PRINTF_WHERE_LIKE(FCN) \
|
||||
void FCN (char *file, unsigned int line, const char *format, ...) \
|
||||
- __attribute__ ((__format__ (__printf__, 3, 4)))
|
||||
+ __attribute__ ((__format__ (gnu_printf, 3, 4)))
|
||||
|
||||
#else /* __GNUC__ < 2 || defined(VMS) */
|
||||
|
||||
--- binutils-2.25/gold/configure.orig 2014-12-26 08:22:19.978000000 +0300
|
||||
+++ binutils-2.25/gold/configure 2014-12-26 08:22:23.697000000 +0300
|
||||
@@ -7530,7 +7530,7 @@
|
||||
diff -urN binutils-2.27.orig/gold/configure binutils-2.27/gold/configure
|
||||
--- binutils-2.27.orig/gold/configure 2016-08-03 09:36:53.000000000 +0200
|
||||
+++ binutils-2.27/gold/configure 2016-09-21 21:13:49.306197900 +0200
|
||||
@@ -7558,7 +7558,7 @@
|
||||
/* end confdefs.h. */
|
||||
|
||||
|
||||
template<typename T> extern void foo(const char*, ...)
|
||||
- __attribute__ ((__format__ (__printf__, 1, 2)));
|
||||
+ __attribute__ ((__format__ (gnu_printf, 1, 2)));
|
||||
template<typename T> void foo(const char* format, ...) {}
|
||||
void bar() { foo<int>("%s\n", "foo"); }
|
||||
|
||||
--- binutils-2.25/gold/configure.ac.orig 2014-12-26 08:22:49.521000000 +0300
|
||||
+++ binutils-2.25/gold/configure.ac 2014-12-26 08:23:05.556000000 +0300
|
||||
@@ -601,7 +601,7 @@
|
||||
|
||||
diff -urN binutils-2.27.orig/gold/configure.ac binutils-2.27/gold/configure.ac
|
||||
--- binutils-2.27.orig/gold/configure.ac 2016-08-03 09:36:53.000000000 +0200
|
||||
+++ binutils-2.27/gold/configure.ac 2016-09-21 21:13:49.317584300 +0200
|
||||
@@ -635,7 +635,7 @@
|
||||
[gold_cv_template_attribute],
|
||||
[AC_COMPILE_IFELSE([
|
||||
template<typename T> extern void foo(const char*, ...)
|
||||
@@ -167,9 +170,10 @@ diff -Naur binutils-2.24/gas/read.c binutils-2.24-mingw/gas/read.c
|
||||
template<typename T> void foo(const char* format, ...) {}
|
||||
void bar() { foo<int>("%s\n", "foo"); }
|
||||
], [gold_cv_template_attribute=yes], [gold_cv_template_attribute=no])])
|
||||
--- binutils-2.25/include/ansidecl.h.orig 2014-12-26 08:23:33.513000000 +0300
|
||||
+++ binutils-2.25/include/ansidecl.h 2014-12-26 08:24:16.479000000 +0300
|
||||
@@ -197,7 +197,7 @@
|
||||
diff -urN binutils-2.27.orig/include/ansidecl.h binutils-2.27/include/ansidecl.h
|
||||
--- binutils-2.27.orig/include/ansidecl.h 2016-08-03 09:36:53.000000000 +0200
|
||||
+++ binutils-2.27/include/ansidecl.h 2016-09-21 21:13:49.327082000 +0200
|
||||
@@ -195,7 +195,7 @@
|
||||
before GCC 3.3, but as of 3.3 we need to add the `nonnull'
|
||||
attribute to retain this behavior. */
|
||||
#ifndef ATTRIBUTE_PRINTF
|
||||
@@ -178,7 +182,7 @@ diff -Naur binutils-2.24/gas/read.c binutils-2.24-mingw/gas/read.c
|
||||
#define ATTRIBUTE_PRINTF_1 ATTRIBUTE_PRINTF(1, 2)
|
||||
#define ATTRIBUTE_PRINTF_2 ATTRIBUTE_PRINTF(2, 3)
|
||||
#define ATTRIBUTE_PRINTF_3 ATTRIBUTE_PRINTF(3, 4)
|
||||
@@ -225,7 +225,7 @@
|
||||
@@ -223,7 +223,7 @@
|
||||
NULL format specifier was allowed as of gcc 3.3. */
|
||||
#ifndef ATTRIBUTE_NULL_PRINTF
|
||||
# if (GCC_VERSION >= 3003)
|
||||
|
||||
@@ -1,36 +0,0 @@
|
||||
From 27aaeda0cdf9f69625b96e3abdb25c8fdbbb3435 Mon Sep 17 00:00:00 2001
|
||||
From: Nick Clifton <nickc@redhat.com>
|
||||
Date: Wed, 18 Mar 2015 16:19:59 +0000
|
||||
Subject: [PATCH] Fixes a problem generating relocs for import libraries
|
||||
created by Microsoft tools for the x86_64 architecture.
|
||||
|
||||
PR ld/16598
|
||||
* peicode.h (pe_ILF_build_a_bfd): Add support for creating relocs
|
||||
suitable for the AMD64.
|
||||
---
|
||||
bfd/peicode.h | 9 +++++++++
|
||||
1 files changed, 9 insertions(+)
|
||||
|
||||
diff --git a/bfd/peicode.h b/bfd/peicode.h
|
||||
index e36568a..200ef5e 100644
|
||||
--- a/bfd/peicode.h
|
||||
+++ b/bfd/peicode.h
|
||||
@@ -973,6 +973,15 @@ pe_ILF_build_a_bfd (bfd * abfd,
|
||||
}
|
||||
else
|
||||
#endif
|
||||
+#ifdef AMD64MAGIC
|
||||
+ if (magic == AMD64MAGIC)
|
||||
+ {
|
||||
+ pe_ILF_make_a_symbol_reloc (&vars, (bfd_vma) jtab[i].offset,
|
||||
+ BFD_RELOC_32_PCREL, (asymbol **) imp_sym,
|
||||
+ imp_index);
|
||||
+ }
|
||||
+ else
|
||||
+#endif
|
||||
pe_ILF_make_a_symbol_reloc (&vars, (bfd_vma) jtab[i].offset,
|
||||
BFD_RELOC_32, (asymbol **) imp_sym,
|
||||
imp_index);
|
||||
--
|
||||
2.4.0
|
||||
|
||||
@@ -1,30 +0,0 @@
|
||||
From 9ac47a43ffc8e3c73867b9953145a8e7a227132d Mon Sep 17 00:00:00 2001
|
||||
From: Toni Spets <toni.spets@iki.fi>
|
||||
Date: Wed, 6 May 2015 14:18:34 +0100
|
||||
Subject: [PATCH] Skip discarded resource sections when building a PE resource
|
||||
table.
|
||||
|
||||
PR ld/18372
|
||||
* peXXigen.c (rsrc_process_section): Skip discarded resource
|
||||
sections.
|
||||
---
|
||||
bfd/peXXigen.c | 3 ++-
|
||||
1 files changed, 2 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/bfd/peXXigen.c b/bfd/peXXigen.c
|
||||
index 6aa18ca..c897c64 100644
|
||||
--- a/bfd/peXXigen.c
|
||||
+++ b/bfd/peXXigen.c
|
||||
@@ -4160,7 +4160,8 @@ rsrc_process_section (bfd * abfd,
|
||||
{
|
||||
asection * rsrc_sec = bfd_get_section_by_name (input, ".rsrc");
|
||||
|
||||
- if (rsrc_sec != NULL)
|
||||
+ /* PR 18372 - skip discarded .rsrc sections. */
|
||||
+ if (rsrc_sec != NULL && !discarded_section (rsrc_sec))
|
||||
{
|
||||
if (num_input_rsrc == max_num_input_rsrc)
|
||||
{
|
||||
--
|
||||
2.4.0
|
||||
|
||||
@@ -4,8 +4,8 @@
|
||||
_realname=binutils
|
||||
pkgbase=mingw-w64-${_realname}
|
||||
pkgname=("${MINGW_PACKAGE_PREFIX}-${_realname}")
|
||||
pkgver=2.25.1
|
||||
pkgrel=7
|
||||
pkgver=2.27
|
||||
pkgrel=1
|
||||
pkgdesc="A set of programs to assemble and manipulate binary and object files (mingw-w64)"
|
||||
arch=('any')
|
||||
url="http://www.gnu.org/software/binutils/"
|
||||
@@ -29,28 +29,23 @@ source=(https://ftp.gnu.org/gnu/binutils/${_realname}-${pkgver}.tar.bz2{,.sig}
|
||||
0014-dont-link-binutils-to-libiberty.mingw.patch
|
||||
0015-dont-link-ld-to-libiberty.mingw.patch
|
||||
0017-fix-iconv-linking.all.patch
|
||||
0110-binutils-mingw-gnu-print.patch
|
||||
27aaeda.diff
|
||||
a93d5cb.diff
|
||||
9ac47a4.diff)
|
||||
sha256sums=('b5b14added7d78a8d1ca70b5cb75fef57ce2197264f4f5835326b0df22ac9f22'
|
||||
0110-binutils-mingw-gnu-print.patch)
|
||||
sha256sums=('369737ce51587f92466041a97ab7d2358c6d9e1b6490b3940eb09fb0a9a6ac88'
|
||||
'SKIP'
|
||||
'93296b909e1a4f9d8a4bbe2437aafa17ca565ef6642a9812b0360c05be228c9d'
|
||||
'd182569814dbcad46ba6f2b4d72f4f827cefa7d0bd7030c89379613a53ca9786'
|
||||
'7f885fd0ceeca6e70f31eb93f6f8a854046737af9aa4695f5e12b7dee8c16f4f'
|
||||
'f084cf708da231584d1b1dd0fbdb6294ce176849c4f77d1666fa778df8d07781'
|
||||
'617adc1fd9fa66cc6e1da840b49edc1f88ae4bfd5b2807eeb34984eff8827e39'
|
||||
'b3fc8b894b9cfe9d0d27c49e36a808a0843020fccb3019737794fcde69af2352'
|
||||
'acae8564367601b4f601dca724596dbffbf056c0690e2aa090b185f3dcf2bc4f'
|
||||
'7c4349bbd4ad57157c896917fb692b41eb6d1ce50197c58fecbc45e5501b0104'
|
||||
'35a3f7ac2ee4b655da6c3cee116a8d5edff48f312a38eadf336793bdc86249ee'
|
||||
'4849fe969fc7abb6b6dfcef4d4c6506f23831d86ba22c6dbf8d3039212654837'
|
||||
'fa009b8a2baf122700b9583fce47c0e304a37211af09c7dcd0a1169a511be362'
|
||||
'177426db0ac7f9e9794b1052cbd15c59fa0167ece4cb3ac4f72673403aabc97a'
|
||||
'376931c0c2f8f5d655458016ac496f93e75c00bf5538e445c29984920a2f5415'
|
||||
'6b336f218443a95e141d231e4fab726c85d27de7c60ad1ce9fb1a1687943a1ce'
|
||||
'bb20764800b394af3ffa12567158ae1cfcd4fb44077d4c44d4e261251e60cf9f'
|
||||
'ec32f5a63fe00315586d1502bd91fc0c700ce63174fc5eade3ae96420140b134'
|
||||
'2ed73d77ec8757cf0deef72aee44e55c0801ac3c75c79fdc727cf5fb7d9b983c'
|
||||
'de7f8850150921a321196822a18ddca8574e69e706323226c2156752318fb6d0')
|
||||
'0f145655d4f2aae3383e0c0269d0c47b8a7176144bf0595425fc38b7ebf53153')
|
||||
validpgpkeys=('EAF1C276A747E9ED86210CBAC3126D3B4AE55E93')
|
||||
|
||||
prepare() {
|
||||
cd ${srcdir}/${_realname}-${pkgver}
|
||||
@@ -67,12 +62,8 @@ prepare() {
|
||||
#patch -p1 -i "${srcdir}"/0015-dont-link-ld-to-libiberty.mingw.patch
|
||||
#patch -p1 -i "${srcdir}"/0017-fix-iconv-linking.all.patch
|
||||
patch -p1 -i "${srcdir}"/0110-binutils-mingw-gnu-print.patch
|
||||
|
||||
# Upstream patches
|
||||
patch -p1 -i "${srcdir}"/27aaeda.diff
|
||||
patch -p1 -i "${srcdir}"/a93d5cb.diff
|
||||
patch -p1 -i "${srcdir}"/9ac47a4.diff
|
||||
|
||||
# Upstream patches
|
||||
}
|
||||
|
||||
build() {
|
||||
|
||||
@@ -1,33 +0,0 @@
|
||||
From a93d5cb1976818c8d34133fd8798b3df76269f80 Mon Sep 17 00:00:00 2001
|
||||
From: Nick Clifton <nickc@redhat.com>
|
||||
Date: Wed, 29 Apr 2015 12:26:46 +0100
|
||||
Subject: [PATCH] Add support for absolute PE/x86 relocations.
|
||||
|
||||
PR 17099
|
||||
* coff-i386.c (coff_i386_rtype_to_howto): Allow absolute PCRLONG
|
||||
relocs.
|
||||
---
|
||||
bfd/coff-i386.c | 7 ++++++-
|
||||
1 files changed, 6 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/bfd/coff-i386.c b/bfd/coff-i386.c
|
||||
index 20d2402..b185b81 100644
|
||||
--- a/bfd/coff-i386.c
|
||||
+++ b/bfd/coff-i386.c
|
||||
@@ -509,7 +509,12 @@ coff_i386_rtype_to_howto (bfd *abfd ATTRIBUTE_UNUSED,
|
||||
*addendp -= pe_data(sec->output_section->owner)->pe_opthdr.ImageBase;
|
||||
}
|
||||
|
||||
- BFD_ASSERT (sym != NULL);
|
||||
+ /* PR 17099 - Absolute R_PCRLONG relocations do not need a symbol. */
|
||||
+ if (rel->r_type == R_PCRLONG && sym == NULL)
|
||||
+ *addendp -= rel->r_vaddr;
|
||||
+ else
|
||||
+ BFD_ASSERT (sym != NULL);
|
||||
+
|
||||
if (rel->r_type == R_SECREL32 && sym != NULL)
|
||||
{
|
||||
bfd_vma osect_vma;
|
||||
--
|
||||
2.4.0
|
||||
|
||||
Reference in New Issue
Block a user