From: "David Seifert" <soap@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] proj/gcc-patches:master commit in: 12.0.0/gentoo/
Date: Sat, 5 Feb 2022 16:45:02 +0000 (UTC) [thread overview]
Message-ID: <1644079489.6d85c86f2e04da2bfe0ef6441159d1ac2c111ac2.soap@gentoo> (raw)
commit: 6d85c86f2e04da2bfe0ef6441159d1ac2c111ac2
Author: WANG Xuerui <git <AT> xen0n <DOT> name>
AuthorDate: Sat Feb 5 15:22:52 2022 +0000
Commit: David Seifert <soap <AT> gentoo <DOT> org>
CommitDate: Sat Feb 5 16:44:49 2022 +0000
URL: https://gitweb.gentoo.org/proj/gcc-patches.git/commit/?id=6d85c86f
12.0.0: cut patchset 3
- Rename *.c to *.cc
- Drop the upstreamed patches (15 through 19)
- Rebase to avoid fuzz
Signed-off-by: WANG Xuerui <git <AT> xen0n.name>
Signed-off-by: David Seifert <soap <AT> gentoo.org>
12.0.0/gentoo/01_all_default-fortify-source.patch | 4 ++--
.../gentoo/02_all_default-warn-format-security.patch | 12 ++++++------
12.0.0/gentoo/04_all_nossp-on-nostdlib.patch | 10 +++++-----
12.0.0/gentoo/07_all_libiberty-asprintf.patch | 6 +++---
12.0.0/gentoo/11_all_ia64-TEXTREL.patch | 4 ++--
12.0.0/gentoo/15_all_libgomp-Werror.patch | 20 --------------------
12.0.0/gentoo/16_all_libitm-Werror.patch | 19 -------------------
12.0.0/gentoo/17_all_libatomic-Werror.patch | 19 -------------------
12.0.0/gentoo/18_all_libbacktrace-Werror.patch | 17 -----------------
12.0.0/gentoo/19_all_libsanitizer-Werror.patch | 17 -----------------
| 14 +++++++-------
| 16 ++++++++--------
12.0.0/gentoo/README.history | 15 +++++++++++++++
13 files changed, 48 insertions(+), 125 deletions(-)
diff --git a/12.0.0/gentoo/01_all_default-fortify-source.patch b/12.0.0/gentoo/01_all_default-fortify-source.patch
index d307474..5bfec1d 100644
--- a/12.0.0/gentoo/01_all_default-fortify-source.patch
+++ b/12.0.0/gentoo/01_all_default-fortify-source.patch
@@ -5,8 +5,8 @@ initially Gentoo used too complicated macro.
# DP: Turn on -D_FORTIFY_SOURCE=2 by default for C, C++, ObjC, ObjC++,
# DP: if the optimization level is > 0
---- a/gcc/c-family/c-cppbuiltin.c
-+++ b/gcc/c-family/c-cppbuiltin.c
+--- a/gcc/c-family/c-cppbuiltin.cc
++++ b/gcc/c-family/c-cppbuiltin.cc
@@ -951,6 +951,12 @@ c_cpp_builtins (cpp_reader *pfile)
builtin_define_with_value ("__REGISTER_PREFIX__", REGISTER_PREFIX, 0);
builtin_define_with_value ("__USER_LABEL_PREFIX__", user_label_prefix, 0);
diff --git a/12.0.0/gentoo/02_all_default-warn-format-security.patch b/12.0.0/gentoo/02_all_default-warn-format-security.patch
index f809abd..9723a1c 100644
--- a/12.0.0/gentoo/02_all_default-warn-format-security.patch
+++ b/12.0.0/gentoo/02_all_default-warn-format-security.patch
@@ -1,9 +1,9 @@
Enable -Wformat and -Wformat-security by default.
---- a/gcc/c-family/c.opt 2016-03-23 18:51:56.000000000 +0100
-+++ b/gcc/c-family/c.opt 2016-04-28 23:45:54.063351272 +0200
-@@ -459,7 +459,7 @@ C ObjC C++ ObjC++ Var(warn_format_nonlit
- Warn about format strings that are not literals.
+--- a/gcc/c-family/c.opt
++++ b/gcc/c-family/c.opt
+@@ -696,7 +696,7 @@ Warn about function calls with format strings that write past the end
+ of the destination region. Same as -Wformat-overflow=1.
Wformat-security
-C ObjC C++ ObjC++ Var(warn_format_security) Warning LangEnabledBy(C ObjC C++ ObjC++,Wformat=, warn_format >= 2, 0)
@@ -11,7 +11,7 @@ Enable -Wformat and -Wformat-security by default.
Warn about possible security problems with format functions.
Wformat-signedness
-@@ -475,7 +475,7 @@ C ObjC C++ ObjC++ Var(warn_format_zero_l
+@@ -717,7 +717,7 @@ C ObjC C++ ObjC++ Var(warn_format_zero_length) Warning LangEnabledBy(C ObjC C++
Warn about zero-length formats.
Wformat=
@@ -19,4 +19,4 @@ Enable -Wformat and -Wformat-security by default.
+C ObjC C++ ObjC++ Joined RejectNegative UInteger Var(warn_format) Init(1) Warning LangEnabledBy(C ObjC C++ ObjC++,Wall, 1, 0) IntegerRange(0, 2)
Warn about printf/scanf/strftime/strfmon format string anomalies.
- Wignored-qualifiers
+ Wformat-overflow=
diff --git a/12.0.0/gentoo/04_all_nossp-on-nostdlib.patch b/12.0.0/gentoo/04_all_nossp-on-nostdlib.patch
index 4e581a5..b633d7f 100644
--- a/12.0.0/gentoo/04_all_nossp-on-nostdlib.patch
+++ b/12.0.0/gentoo/04_all_nossp-on-nostdlib.patch
@@ -1,10 +1,10 @@
Disable ssp on -nostdlib, -nodefaultlibs and -ffreestanding
https://bugs.gentoo.org/484714
---- a/gcc/gcc.c 2017-07-04 09:15:57.740793000 +0200
-+++ b/gcc/gcc.c 2018-03-02 13:58:44.387741114 +0100
-@@ -857,6 +857,12 @@ proper position among the other output f
- #define LINK_GCC_C_SEQUENCE_SPEC "%G %L %G"
+--- a/gcc/gcc.cc
++++ b/gcc/gcc.cc
+@@ -984,6 +984,12 @@ proper position among the other output files. */
+ #define LINK_GCC_C_SEQUENCE_SPEC "%G %{!nolibc:%L %G}"
#endif
+#ifdef ENABLE_DEFAULT_SSP
@@ -16,7 +16,7 @@ https://bugs.gentoo.org/484714
#ifndef LINK_SSP_SPEC
#ifdef TARGET_LIBC_PROVIDES_SSP
#define LINK_SSP_SPEC "%{fstack-protector|fstack-protector-all" \
-@@ -1131,7 +1148,7 @@ static const char *cc1_options =
+@@ -1280,7 +1286,7 @@ static const char *cc1_options =
%{-version:--version}\
%{-help=*:--help=%*}\
%{!fsyntax-only:%{S:%W{o*}%{!o*:-o %w%b.s}}}\
diff --git a/12.0.0/gentoo/07_all_libiberty-asprintf.patch b/12.0.0/gentoo/07_all_libiberty-asprintf.patch
index bee0c4c..1ed2ba3 100644
--- a/12.0.0/gentoo/07_all_libiberty-asprintf.patch
+++ b/12.0.0/gentoo/07_all_libiberty-asprintf.patch
@@ -4,7 +4,7 @@
--- a/include/libiberty.h
+++ b/include/libiberty.h
-@@ -609,8 +609,11 @@ extern int pwait (int, int *, int);
+@@ -652,8 +652,11 @@ extern void *bsearch_r (const void *, const void *,
/* Like sprintf but provides a pointer to malloc'd storage, which must
be freed by the caller. */
@@ -14,5 +14,5 @@
#endif
+#endif
- #if !HAVE_DECL_VASPRINTF
- /* Like vsprintf but provides a pointer to malloc'd storage, which
+ /* Like asprintf but allocates memory without fail. This works like
+ xmalloc. */
diff --git a/12.0.0/gentoo/11_all_ia64-TEXTREL.patch b/12.0.0/gentoo/11_all_ia64-TEXTREL.patch
index 706dbe5..d9d0ae8 100644
--- a/12.0.0/gentoo/11_all_ia64-TEXTREL.patch
+++ b/12.0.0/gentoo/11_all_ia64-TEXTREL.patch
@@ -1,8 +1,8 @@
Fix textrels on -rdynamic binaries:
Bug: https://gcc.gnu.org/PR84553
Bug: https://bugs.gentoo.org/566118
---- a/gcc/config/ia64/ia64.c
-+++ a/gcc/config/ia64/ia64.c
+--- a/gcc/config/ia64/ia64.cc
++++ a/gcc/config/ia64/ia64.cc
@@ -10838,12 +10838,14 @@ ia64_hpux_reloc_rw_mask (void)
/* For others, relax this so that relocations to local data goes in
diff --git a/12.0.0/gentoo/15_all_libgomp-Werror.patch b/12.0.0/gentoo/15_all_libgomp-Werror.patch
deleted file mode 100644
index 416808a..0000000
--- a/12.0.0/gentoo/15_all_libgomp-Werror.patch
+++ /dev/null
@@ -1,20 +0,0 @@
-libgomp does not respect --disable-werror
-
-https://bugs.gentoo.org/229059
-http://gcc.gnu.org/PR38436
---- a/libgomp/configure.ac
-+++ b/libgomp/configure.ac
-@@ -4282,4 +4282,4 @@ save_CFLAGS="$CFLAGS"
- # Add -Wall -Werror if we are using GCC.
- if test "x$GCC" = "xyes"; then
-- XCFLAGS="$XCFLAGS -Wall -Werror"
-+ XCFLAGS="$XCFLAGS -Wall"
- fi
---- a/libgomp/configure
-+++ b/libgomp/configure
-@@ -4282,4 +4282,4 @@ save_CFLAGS="$CFLAGS"
- # Add -Wall -Werror if we are using GCC.
- if test "x$GCC" = "xyes"; then
-- XCFLAGS="$XCFLAGS -Wall -Werror"
-+ XCFLAGS="$XCFLAGS -Wall"
- fi
diff --git a/12.0.0/gentoo/16_all_libitm-Werror.patch b/12.0.0/gentoo/16_all_libitm-Werror.patch
deleted file mode 100644
index 27181e0..0000000
--- a/12.0.0/gentoo/16_all_libitm-Werror.patch
+++ /dev/null
@@ -1,19 +0,0 @@
-libitm does not respect --disable-werror
-
-https://bugs.gentoo.org/475350
---- a/libitm/configure.ac
-+++ b/libitm/configure.ac
-@@ -4282,4 +4282,4 @@ save_CFLAGS="$CFLAGS"
- # Add -Wall -Werror if we are using GCC.
- if test "x$GCC" = "xyes"; then
-- XCFLAGS="$XCFLAGS -Wall -Werror"
-+ XCFLAGS="$XCFLAGS -Wall"
- fi
---- a/libitm/configure
-+++ b/libitm/configure
-@@ -4282,4 +4282,4 @@ save_CFLAGS="$CFLAGS"
- # Add -Wall -Werror if we are using GCC.
- if test "x$GCC" = "xyes"; then
-- XCFLAGS="$XCFLAGS -Wall -Werror"
-+ XCFLAGS="$XCFLAGS -Wall"
- fi
diff --git a/12.0.0/gentoo/17_all_libatomic-Werror.patch b/12.0.0/gentoo/17_all_libatomic-Werror.patch
deleted file mode 100644
index 0550722..0000000
--- a/12.0.0/gentoo/17_all_libatomic-Werror.patch
+++ /dev/null
@@ -1,19 +0,0 @@
-libatomic does not respect --disable-werror
-
-https://bugs.gentoo.org/475350
---- a/libatomic/configure.ac
-+++ b/libatomic/configure.ac
-@@ -4282,4 +4282,4 @@ save_CFLAGS="$CFLAGS"
- # Add -Wall -Werror if we are using GCC.
- if test "x$GCC" = "xyes"; then
-- XCFLAGS="$XCFLAGS -Wall -Werror"
-+ XCFLAGS="$XCFLAGS -Wall"
- fi
---- a/libatomic/configure
-+++ b/libatomic/configure
-@@ -4282,4 +4282,4 @@ save_CFLAGS="$CFLAGS"
- # Add -Wall -Werror if we are using GCC.
- if test "x$GCC" = "xyes"; then
-- XCFLAGS="$XCFLAGS -Wall -Werror"
-+ XCFLAGS="$XCFLAGS -Wall"
- fi
diff --git a/12.0.0/gentoo/18_all_libbacktrace-Werror.patch b/12.0.0/gentoo/18_all_libbacktrace-Werror.patch
deleted file mode 100644
index 57dd284..0000000
--- a/12.0.0/gentoo/18_all_libbacktrace-Werror.patch
+++ /dev/null
@@ -1,17 +0,0 @@
-libbacktrace does not respect --disable-werror
-
-https://bugs.gentoo.org/667104
---- a/libbacktrace/configure
-+++ b/libbacktrace/configure
-@@ -11634,3 +11634,3 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu
- if test -n "${with_target_subdir}"; then
-- WARN_FLAGS="$WARN_FLAGS -Werror"
-+ WARN_FLAGS="$WARN_FLAGS"
- fi
---- a/libbacktrace/configure.ac
-+++ b/libbacktrace/configure.ac
-@@ -138,3 +138,3 @@ ACX_PROG_CC_WARNING_OPTS([-W -Wall -Wwrite-strings -Wstrict-prototypes \
- if test -n "${with_target_subdir}"; then
-- WARN_FLAGS="$WARN_FLAGS -Werror"
-+ WARN_FLAGS="$WARN_FLAGS"
- fi
diff --git a/12.0.0/gentoo/19_all_libsanitizer-Werror.patch b/12.0.0/gentoo/19_all_libsanitizer-Werror.patch
deleted file mode 100644
index 0e484a4..0000000
--- a/12.0.0/gentoo/19_all_libsanitizer-Werror.patch
+++ /dev/null
@@ -1,17 +0,0 @@
-libsanitizer does not respect --disable-werror
-
-https://bugs.gentoo.org/667104
---- a/libsanitizer/libbacktrace/Makefile.am
-+++ b/libsanitizer/libbacktrace/Makefile.am
-@@ -37,3 +37,3 @@ AM_CPPFLAGS = -I $(top_srcdir)/../include -I $(top_srcdir)/../libgcc \
- WARN_FLAGS = -W -Wall -Wwrite-strings -Wmissing-format-attribute \
-- -Wcast-qual -Werror
-+ -Wcast-qual
- C_WARN_FLAGS = $(WARN_FLAGS) -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition
---- a/libsanitizer/libbacktrace/Makefile.in
-+++ b/libsanitizer/libbacktrace/Makefile.in
-@@ -297,3 +297,3 @@ AM_CPPFLAGS = -I $(top_srcdir)/../include -I $(top_srcdir)/../libgcc \
- WARN_FLAGS = -W -Wall -Wwrite-strings -Wmissing-format-attribute \
-- -Wcast-qual -Werror
-+ -Wcast-qual
-
--git a/12.0.0/gentoo/23_all_EXTRA_OPTIONS-z-now.patch b/12.0.0/gentoo/23_all_EXTRA_OPTIONS-z-now.patch
index 121dec4..b244690 100644
--- a/12.0.0/gentoo/23_all_EXTRA_OPTIONS-z-now.patch
+++ b/12.0.0/gentoo/23_all_EXTRA_OPTIONS-z-now.patch
@@ -1,8 +1,8 @@
On Hardened we add some options like -z now
---- a/gcc/gcc.c 2016-02-19 23:18:38.000000000 +0100
-+++ b/gcc/gcc.c 2016-05-02 22:56:10.185721270 +0200
-@@ -868,6 +868,12 @@ proper position among the other output f
+--- a/gcc/gcc.cc
++++ b/gcc/gcc.cc
+@@ -995,6 +995,12 @@ proper position among the other output files. */
#endif
#endif
@@ -13,9 +13,9 @@ On Hardened we add some options like -z now
+#endif
+
#ifdef ENABLE_DEFAULT_PIE
- #define NO_PIE_SPEC "no-pie|static"
- #define PIE_SPEC NO_PIE_SPEC "|r|shared:;"
-@@ -1013,7 +1020,7 @@ proper position among the other output f
+ #define PIE_SPEC "!no-pie"
+ #define NO_FPIE1_SPEC "fno-pie"
+@@ -1155,7 +1161,7 @@ proper position among the other output files. */
%(linker) " \
LINK_PLUGIN_SPEC \
"%{flto|flto=*:%<fcompare-debug*} \
@@ -23,4 +23,4 @@ On Hardened we add some options like -z now
+ %{flto} %{fno-lto} %{flto=*} %l " LINK_PIE_SPEC LINK_NOW_SPEC \
"%{fuse-ld=*:-fuse-ld=%*} " LINK_COMPRESS_DEBUG_SPEC \
"%X %{o*} %{e*} %{N} %{n} %{r}\
- %{s} %{t} %{u*} %{z} %{Z} %{!nostdlib:%{!nostartfiles:%S}} \
+ %{s} %{t} %{u*} %{z} %{Z} %{!nostdlib:%{!r:%{!nostartfiles:%S}}} \
diff --git a/12.0.0/gentoo/24_all_EXTRA_OPTIONS-fstack-clash-protection.patch b/12.0.0/gentoo/24_all_EXTRA_OPTIONS-fstack-clash-protection.patch
index e836c92..5481721 100644
--- a/12.0.0/gentoo/24_all_EXTRA_OPTIONS-fstack-clash-protection.patch
+++ b/12.0.0/gentoo/24_all_EXTRA_OPTIONS-fstack-clash-protection.patch
@@ -1,7 +1,7 @@
On Hardened we add some options like -fstack-clash-protection.
---- a/gcc/common.opt 2018-03-28 16:51:09.000000000 +0200
-+++ a/gcc/common.opt 2018-04-30 15:35:55.274096877 +0200
+--- a/gcc/common.opt
++++ a/gcc/common.opt
@@ -2367,7 +2367,7 @@ Common Alias(fstack-check=, specific, no
Insert stack checking code into the program. Same as -fstack-check=specific.
@@ -11,8 +11,8 @@ On Hardened we add some options like -fstack-clash-protection.
Insert code to probe each page of stack space as it is allocated to protect
from stack-clash style attacks.
---- a/gcc/defaults.h 2018-01-03 11:03:58.000000000 +0100
-+++ b/gcc/defaults.h 2018-05-01 12:41:29.522851451 +0200
+--- a/gcc/defaults.h
++++ b/gcc/defaults.h
@@ -1435,6 +1435,15 @@ see the files COPYING3 and COPYING.RUNTI
#define STACK_CHECK_MAX_VAR_SIZE (STACK_CHECK_MAX_FRAME_SIZE / 100)
#endif
@@ -29,8 +29,8 @@ On Hardened we add some options like -fstack-clash-protection.
/* By default, the C++ compiler will use function addresses in the
vtable entries. Setting this nonzero tells the compiler to use
function descriptors instead. The value of this macro says how
---- a/gcc/toplev.c 2018-02-13 17:18:37.000000000 +0100
-+++ b/gcc/toplev.c 2018-04-30 16:46:37.244027303 +0200
+--- a/gcc/toplev.cc
++++ b/gcc/toplev.cc
@@ -1682,6 +1682,10 @@ process_options (void)
/* -fstack-clash-protection is not currently supported on targets
@@ -43,8 +43,8 @@ On Hardened we add some options like -fstack-clash-protection.
{
warning_at (UNKNOWN_LOCATION, 0,
---- a/libgcc/Makefile.in 2011-11-22 04:01:02.000000000 +0100
-+++ b/libgcc/Makefile.in 2011-12-25 15:18:22.449610631 +0100
+--- a/libgcc/Makefile.in
++++ b/libgcc/Makefile.in
@@ -225,7 +225,7 @@ endif
LIBGCC2_DEBUG_CFLAGS = -g
LIBGCC2_CFLAGS = -O2 $(LIBGCC2_INCLUDES) $(GCC_CFLAGS) $(HOST_LIBGCC2_CFLAGS) \
diff --git a/12.0.0/gentoo/README.history b/12.0.0/gentoo/README.history
index d329e6f..99f4801 100644
--- a/12.0.0/gentoo/README.history
+++ b/12.0.0/gentoo/README.history
@@ -1,3 +1,18 @@
+3 5 Feb 2022
+
+ U 01_all_default-fortify-source.patch
+ U 02_all_default-warn-format-security.patch
+ U 04_all_nossp-on-nostdlib.patch
+ U 07_all_libiberty-asprintf.patch
+ U 11_all_ia64-TEXTREL.patch
+ - 15_all_libgomp-Werror.patch
+ - 16_all_libitm-Werror.patch
+ - 17_all_libatomic-Werror.patch
+ - 18_all_libbacktrace-Werror.patch
+ - 19_all_libsanitizer-Werror.patch
+ U 23_all_EXTRA_OPTIONS-z-now.patch
+ U 24_all_EXTRA_OPTIONS-fstack-clash-protection.patch
+
2 28 July 2021
- 21_all_disable-riscv32-ABIs.patch
next reply other threads:[~2022-02-05 16:45 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-02-05 16:45 David Seifert [this message]
-- strict thread matches above, loose matches on Subject: below --
2022-03-31 10:07 [gentoo-commits] proj/gcc-patches:master commit in: 12.0.0/gentoo/ Sam James
2021-07-28 9:32 Sergei Trofimovich
2021-04-20 17:43 Sergei Trofimovich
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1644079489.6d85c86f2e04da2bfe0ef6441159d1ac2c111ac2.soap@gentoo \
--to=soap@gentoo.org \
--cc=gentoo-commits@lists.gentoo.org \
--cc=gentoo-dev@lists.gentoo.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox