pkgsrc-Changes archive

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

CVS commit: pkgsrc/lang/gcc10



Module Name:    pkgsrc
Committed By:   rillig
Date:           Sun May 17 19:47:20 UTC 2020

Modified Files:
        pkgsrc/lang/gcc10: Makefile distinfo
Added Files:
        pkgsrc/lang/gcc10/patches: patch-libgfortran_io_format.c
            patch-libgfortran_io_list__read.c patch-libgfortran_io_read.c
            patch-libgfortran_runtime_environ.c
            patch-libquadmath_printf_quadmath-printf.c
            patch-libquadmath_strtod_strtod__l.c

Log Message:
lang/gcc10: fix build with -Werror=char-subscripts


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 pkgsrc/lang/gcc10/Makefile \
    pkgsrc/lang/gcc10/distinfo
cvs rdiff -u -r0 -r1.1 \
    pkgsrc/lang/gcc10/patches/patch-libgfortran_io_format.c \
    pkgsrc/lang/gcc10/patches/patch-libgfortran_io_list__read.c \
    pkgsrc/lang/gcc10/patches/patch-libgfortran_io_read.c \
    pkgsrc/lang/gcc10/patches/patch-libgfortran_runtime_environ.c \
    pkgsrc/lang/gcc10/patches/patch-libquadmath_printf_quadmath-printf.c \
    pkgsrc/lang/gcc10/patches/patch-libquadmath_strtod_strtod__l.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: pkgsrc/lang/gcc10/Makefile
diff -u pkgsrc/lang/gcc10/Makefile:1.1 pkgsrc/lang/gcc10/Makefile:1.2
--- pkgsrc/lang/gcc10/Makefile:1.1      Sun May 10 15:02:44 2020
+++ pkgsrc/lang/gcc10/Makefile  Sun May 17 19:47:19 2020
@@ -1,10 +1,11 @@
-# $NetBSD: Makefile,v 1.1 2020/05/10 15:02:44 maya Exp $
+# $NetBSD: Makefile,v 1.2 2020/05/17 19:47:19 rillig Exp $
 
 GCC_PKGNAME=           gcc10
 .include               "version.mk"
 
 DISTNAME=      gcc-${GCC10_DIST_VERSION}
 PKGNAME=       ${GCC_PKGNAME}-${GCC10_DIST_VERSION}
+PKGREVISION=   1
 ## When bumping the PKGREVISION of this package the PKGREVISION of
 ## lang/gcc10-libs needs to be bump to be at least 1 more than the
 ## PKGREVISION of this package!
Index: pkgsrc/lang/gcc10/distinfo
diff -u pkgsrc/lang/gcc10/distinfo:1.1 pkgsrc/lang/gcc10/distinfo:1.2
--- pkgsrc/lang/gcc10/distinfo:1.1      Sun May 10 15:02:44 2020
+++ pkgsrc/lang/gcc10/distinfo  Sun May 17 19:47:19 2020
@@ -1,4 +1,4 @@
-$NetBSD: distinfo,v 1.1 2020/05/10 15:02:44 maya Exp $
+$NetBSD: distinfo,v 1.2 2020/05/17 19:47:19 rillig Exp $
 
 SHA1 (gcc-10.1.0.tar.xz) = 1af8d963e4a74d05a8f2d0f795ea52d2b91f6c50
 RMD160 (gcc-10.1.0.tar.xz) = eb9c7a9c10fbe5b4ff84818b280248ab97d17769
@@ -20,5 +20,11 @@ SHA1 (patch-isl_configure) = 5523c76d95b
 SHA1 (patch-libffi_configure) = 22006b20d7f655e2455a7ad613d676703b6c1ccc
 SHA1 (patch-libffi_testsuite_libffi.call_float2.c) = 27b84a11378fb648dfaad0c70abedd77a0a1c1a8
 SHA1 (patch-libgcc_crtstuff.c) = a16d465039de00c195cf0694560140a9c38f3a25
+SHA1 (patch-libgfortran_io_format.c) = cff0b1a3ad4357c15a5b28977887a80aa7e006f1
 SHA1 (patch-libgfortran_io_io.h) = d44676239a7f45e42054d24bd5224f43c20055c0
+SHA1 (patch-libgfortran_io_list__read.c) = f141d8ad57ea4ca30727c2d31f745d95633efcd9
+SHA1 (patch-libgfortran_io_read.c) = a3f194f70bbba82283843f7ce2998a925ee207c4
+SHA1 (patch-libgfortran_runtime_environ.c) = 80d1cda03d2da1fac06242982fc6922bd75d622b
+SHA1 (patch-libquadmath_printf_quadmath-printf.c) = 7c68f155cfb99c3bca625a1966a04c2c46b4d6fc
+SHA1 (patch-libquadmath_strtod_strtod__l.c) = 1d448aa1a149ff24742f87443d0da76278206025
 SHA1 (patch-libstdc++-v3_libsupc++_new__opa.cc) = 4183b00a5ee6e61524da4755c825a0c08fd01ed6

Added files:

Index: pkgsrc/lang/gcc10/patches/patch-libgfortran_io_format.c
diff -u /dev/null pkgsrc/lang/gcc10/patches/patch-libgfortran_io_format.c:1.1
--- /dev/null   Sun May 17 19:47:20 2020
+++ pkgsrc/lang/gcc10/patches/patch-libgfortran_io_format.c     Sun May 17 19:47:19 2020
@@ -0,0 +1,17 @@
+$NetBSD: patch-libgfortran_io_format.c,v 1.1 2020/05/17 19:47:19 rillig Exp $
+
+Fix -Werror=char-subscripts.
+
+https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95177
+
+--- libgfortran/io/format.c.orig       2020-05-07 10:50:02.000000000 +0000
++++ libgfortran/io/format.c
+@@ -193,7 +193,7 @@ next_char (format_data *fmt, int literal
+       return -1;
+ 
+       fmt->format_string_len--;
+-      c = toupper (*fmt->format_string++);
++      c = toupper ((unsigned char) *fmt->format_string++);
+       fmt->error_element = c;
+     }
+   while ((c == ' ' || c == '\t') && !literal);
Index: pkgsrc/lang/gcc10/patches/patch-libgfortran_io_list__read.c
diff -u /dev/null pkgsrc/lang/gcc10/patches/patch-libgfortran_io_list__read.c:1.1
--- /dev/null   Sun May 17 19:47:20 2020
+++ pkgsrc/lang/gcc10/patches/patch-libgfortran_io_list__read.c Sun May 17 19:47:19 2020
@@ -0,0 +1,17 @@
+$NetBSD: patch-libgfortran_io_list__read.c,v 1.1 2020/05/17 19:47:19 rillig Exp $
+
+Fix -Werror=char-subscripts.
+
+https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95177
+
+--- libgfortran/io/list_read.c.orig    2020-05-07 10:50:02.000000000 +0000
++++ libgfortran/io/list_read.c
+@@ -2757,7 +2757,7 @@ nml_match_name (st_parameter_dt *dtp, co
+   for (i = 0; i < len; i++)
+     {
+       c = next_char (dtp);
+-      if (c == EOF || (tolower (c) != tolower (name[i])))
++      if (c == EOF || (tolower (c) != tolower ((unsigned char) name[i])))
+       {
+         dtp->u.p.nml_read_error = 1;
+         break;
Index: pkgsrc/lang/gcc10/patches/patch-libgfortran_io_read.c
diff -u /dev/null pkgsrc/lang/gcc10/patches/patch-libgfortran_io_read.c:1.1
--- /dev/null   Sun May 17 19:47:20 2020
+++ pkgsrc/lang/gcc10/patches/patch-libgfortran_io_read.c       Sun May 17 19:47:20 2020
@@ -0,0 +1,44 @@
+$NetBSD: patch-libgfortran_io_read.c,v 1.1 2020/05/17 19:47:20 rillig Exp $
+
+Fix -Werror=char-subscripts.
+
+https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95177
+
+--- libgfortran/io/read.c.orig 2020-05-07 10:50:02.000000000 +0000
++++ libgfortran/io/read.c
+@@ -959,7 +959,7 @@ read_f (st_parameter_dt *dtp, const fnod
+        between "NaN" and the optional perenthesis is not permitted.  */
+       while (w > 0)
+       {
+-        *out = tolower (*p);
++        *out = tolower ((unsigned char) *p);
+         switch (*p)
+           {
+           case ' ':
+@@ -981,7 +981,7 @@ read_f (st_parameter_dt *dtp, const fnod
+               goto bad_float;
+             break;
+           default:
+-            if (!isalnum (*out))
++            if (!isalnum ((unsigned char) *out))
+               goto bad_float;
+           }
+         --w;
+@@ -1109,7 +1109,7 @@ exponent:
+ 
+   if (dtp->u.p.blank_status == BLANK_UNSPECIFIED)
+     {
+-      while (w > 0 && isdigit (*p))
++      while (w > 0 && isdigit ((unsigned char) *p))
+       {
+         exponent *= 10;
+         exponent += *p - '0';
+@@ -1137,7 +1137,7 @@ exponent:
+             else
+               assert (dtp->u.p.blank_status == BLANK_NULL);
+           }
+-        else if (!isdigit (*p))
++        else if (!isdigit ((unsigned char) *p))
+           goto bad_float;
+         else
+           {
Index: pkgsrc/lang/gcc10/patches/patch-libgfortran_runtime_environ.c
diff -u /dev/null pkgsrc/lang/gcc10/patches/patch-libgfortran_runtime_environ.c:1.1
--- /dev/null   Sun May 17 19:47:20 2020
+++ pkgsrc/lang/gcc10/patches/patch-libgfortran_runtime_environ.c       Sun May 17 19:47:20 2020
@@ -0,0 +1,26 @@
+$NetBSD: patch-libgfortran_runtime_environ.c,v 1.1 2020/05/17 19:47:20 rillig Exp $
+
+Fix -Werror=char-subscripts.
+
+https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95177
+
+--- libgfortran/runtime/environ.c.orig 2020-05-07 10:50:02.000000000 +0000
++++ libgfortran/runtime/environ.c
+@@ -91,7 +91,7 @@ init_integer (variable * v)
+     return;
+ 
+   for (q = p; *q; q++)
+-    if (!isdigit (*q) && (p != q || *q != '-'))
++    if (!isdigit ((unsigned char) *q) && (p != q || *q != '-'))
+       return;
+ 
+   *v->var = atoi (p);
+@@ -344,7 +344,7 @@ static int
+ match_integer (void)
+ {
+   unit_num = 0;
+-  while (isdigit (*p))
++  while (isdigit ((unsigned char) *p))
+     unit_num = unit_num * 10 + (*p++ - '0');
+   return INTEGER;
+ }
Index: pkgsrc/lang/gcc10/patches/patch-libquadmath_printf_quadmath-printf.c
diff -u /dev/null pkgsrc/lang/gcc10/patches/patch-libquadmath_printf_quadmath-printf.c:1.1
--- /dev/null   Sun May 17 19:47:20 2020
+++ pkgsrc/lang/gcc10/patches/patch-libquadmath_printf_quadmath-printf.c        Sun May 17 19:47:20 2020
@@ -0,0 +1,26 @@
+$NetBSD: patch-libquadmath_printf_quadmath-printf.c,v 1.1 2020/05/17 19:47:20 rillig Exp $
+
+Fix -Werror=char-subscripts.
+
+https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95178
+
+--- libquadmath/printf/quadmath-printf.c.orig  2020-05-07 10:50:02.000000000 +0000
++++ libquadmath/printf/quadmath-printf.c
+@@ -189,7 +189,7 @@ quadmath_snprintf (char *str, size_t siz
+       ++format;
+       info.width = va_arg (ap, int);
+     }
+-  else if (isdigit (*format))
++  else if (isdigit ((unsigned char) *format))
+     /* Constant width specification.  */
+     info.width = read_int (&format);
+ 
+@@ -206,7 +206,7 @@ quadmath_snprintf (char *str, size_t siz
+ 
+         info.prec = va_arg (ap, int);
+       }
+-      else if (isdigit (*format))
++      else if (isdigit ((unsigned char) *format))
+       info.prec = read_int (&format);
+       else
+       /* "%.?" is treated like "%.0?".  */
Index: pkgsrc/lang/gcc10/patches/patch-libquadmath_strtod_strtod__l.c
diff -u /dev/null pkgsrc/lang/gcc10/patches/patch-libquadmath_strtod_strtod__l.c:1.1
--- /dev/null   Sun May 17 19:47:20 2020
+++ pkgsrc/lang/gcc10/patches/patch-libquadmath_strtod_strtod__l.c      Sun May 17 19:47:20 2020
@@ -0,0 +1,23 @@
+$NetBSD: patch-libquadmath_strtod_strtod__l.c,v 1.1 2020/05/17 19:47:20 rillig Exp $
+
+Fix -Werror=char-subscripts.
+
+https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95178
+
+--- libquadmath/strtod/strtod_l.c.orig 2020-05-07 10:50:02.000000000 +0000
++++ libquadmath/strtod/strtod_l.c
+@@ -57,10 +57,10 @@
+ # define STRING_TYPE char
+ # define CHAR_TYPE char
+ # define L_(Ch) Ch
+-# define ISSPACE(Ch) isspace (Ch)
+-# define ISDIGIT(Ch) isdigit (Ch)
+-# define ISXDIGIT(Ch) isxdigit (Ch)
+-# define TOLOWER(Ch) tolower (Ch)
++# define ISSPACE(Ch) isspace ((unsigned char) Ch)
++# define ISDIGIT(Ch) isdigit ((unsigned char) Ch)
++# define ISXDIGIT(Ch) isxdigit ((unsigned char) Ch)
++# define TOLOWER(Ch) tolower ((unsigned char) Ch)
+ # define TOLOWER_C(Ch) \
+   ({__typeof(Ch) __tlc = (Ch); \
+     (__tlc >= 'A' && __tlc <= 'Z') ? __tlc - 'A' + 'a' : __tlc; })



Home | Main Index | Thread Index | Old Index