summaryrefslogtreecommitdiff
path: root/sys-libs
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2024-09-26 01:25:46 +0100
committerV3n3RiX <venerix@koprulu.sector>2024-09-26 01:25:46 +0100
commit21dea977c89ba487b57c7856a4924950e667f209 (patch)
treeea817bd899b4d1759c030d6439f307b28e51588d /sys-libs
parentc25088d4fc442a7d6dc3a8d0498b43024888318d (diff)
gentoo auto-resync : 26:09:2024 - 01:25:46
Diffstat (limited to 'sys-libs')
-rw-r--r--sys-libs/Manifest.gzbin14433 -> 14425 bytes
-rw-r--r--sys-libs/libstdc++-v3/Manifest2
-rw-r--r--sys-libs/libstdc++-v3/libstdc++-v3-3.3.6-r4.ebuild75
3 files changed, 38 insertions, 39 deletions
diff --git a/sys-libs/Manifest.gz b/sys-libs/Manifest.gz
index 72990b5c2661..e56c7aadc677 100644
--- a/sys-libs/Manifest.gz
+++ b/sys-libs/Manifest.gz
Binary files differ
diff --git a/sys-libs/libstdc++-v3/Manifest b/sys-libs/libstdc++-v3/Manifest
index f7e5908fb2ec..99081c5f478a 100644
--- a/sys-libs/libstdc++-v3/Manifest
+++ b/sys-libs/libstdc++-v3/Manifest
@@ -1,4 +1,4 @@
DIST gcc-3.3.6-patches-4.tar.bz2 53437 BLAKE2B 372ff1fcfcfacca43b420d2cda7fccb2ede4917408e1fcceb6c094694de8ae21148fa9c5ab8663cf6fb9ad858e3d0cbb3f20c91020db7b627828403444c2fd66 SHA512 1ff4563956d2f3af1240a14cd1ec126ff75dcf24e1cec39d32a17d6be92b94aeb081605ceb04b138ba905cea8ccbe204dce4b42a02ef55383fcfa91643f73faf
DIST gcc-3.3.6.tar.bz2 23972413 BLAKE2B e7b33edcdbbb13b0be41a41156bf6fb6dcfe4f5ad75c41de86cb37f854be6b7a6a8dda0e65d331461469848cd912e25920e8aa2dcb142cb661731ba571cb5de1 SHA512 576b88e2fa675314a79a85f180684fe5af370c596476a0bf02e33e8ae0e2be838417ea80675ce4194a8213792cf7ada50cae5131149e4b890ab61e0b8d50d0ed
-EBUILD libstdc++-v3-3.3.6-r4.ebuild 5080 BLAKE2B d152b447ad096eb4f26aa3446a3c57cd2d12781f7b407801b0274d843c0de9308b830df826f1149a9125b74b314ba4e911199d3b4f5f2d03abb18e921bfcfee6 SHA512 0e39522d8624b432350c313d3a341e83558b9c283997ec08a59623d3afd0f1eb7e8c55f32026ee5986666a4c4cbd213423cd120fc1f5f08bf899ba04d9151470
+EBUILD libstdc++-v3-3.3.6-r4.ebuild 5676 BLAKE2B 22c5b065f1bd0698083e7b601e690e092b669adb6f583fc30f5b8c3c5fb30e6f7315c0772c04f2cad93fc55bc8d88c0179deb0862dd2b46520d505a5399fd5e7 SHA512 4c54dbd29cafc9203833fcf8f90831c2b64b801f970fa77c90f4ccbd448646c66b2087c1b76c715b459bb4334fec6afc9a439ca4075364b349ec3bf21d511275
MISC metadata.xml 258 BLAKE2B f45bf60ab247635720461e6f8028b41d748c2c0fecea4d5b6eb29a9f532de573e8054773a084b99b2a6a040e980cfc41c8839b13bdeb8ebe6e1de12a1492873b SHA512 2cd16eedd80ae476d1611112f620d3d5eee88fd181fe635d9f9235ac312e24bf8eac5b44f54ff55806ee7a03aaf1d1382a734f7b3496814853d238b9a7b6ee1e
diff --git a/sys-libs/libstdc++-v3/libstdc++-v3-3.3.6-r4.ebuild b/sys-libs/libstdc++-v3/libstdc++-v3-3.3.6-r4.ebuild
index 7c20c6524879..9ebe0e98eb7e 100644
--- a/sys-libs/libstdc++-v3/libstdc++-v3-3.3.6-r4.ebuild
+++ b/sys-libs/libstdc++-v3/libstdc++-v3-3.3.6-r4.ebuild
@@ -70,11 +70,13 @@ is_arch_allowed() {
}
do_filter_flags() {
- declare setting
+ declare setting newflags
# In general gcc does not like optimization, and add -O2 where
# it is safe. This is especially true for gcc 3.3 + 3.4
- replace-flags -O? -O2
+ if is-flagq -O?; then
+ newflags+=" -O2"
+ fi
# gcc 3.3 doesn't support -mtune on numerous archs, so xgcc will fail
setting="`get-flag mtune`"
@@ -90,47 +92,28 @@ do_filter_flags() {
transform_known_flags
setting="`get-flag march`"
if [[ ! -z "${setting}" ]] ; then
- is_arch_allowed "${setting}" || filter-flags -march="${setting}"
+ is_arch_allowed "${setting}" && newflags+=" -march=${setting}"
fi
setting="`get-flag mcpu`"
if [[ ! -z "${setting}" ]] ; then
- is_arch_allowed "${setting}" || filter-flags -mcpu="${setting}"
+ is_arch_allowed "${setting}" && newflags+=" -mcpu=${setting}"
fi
- # xgcc wont understand gcc 3.4 flags...
- filter-flags -fno-unit-at-a-time
- filter-flags -funit-at-a-time
- filter-flags -fweb
- filter-flags -fno-web
- filter-flags -mno-tls-direct-seg-refs
-
- # xgcc isnt patched with propolice
- filter-flags -fstack-protector-all
- filter-flags -fno-stack-protector-all
- filter-flags -fstack-protector
- filter-flags -fno-stack-protector
-
- # xgcc isnt patched with the gcc symbol visibility patch
- filter-flags -fvisibility-inlines-hidden
- filter-flags -fvisibility=hidden
-
- # Bug #269433 & #290202
- filter-flags -fno-strict-overflow
- filter-flags -fstrict-overflow
-
- # Bug #442784
- filter-flags '-W*'
-
- filter-flags -frecord-gcc-switches
- filter-flags '-fdiagnostics-color*'
-
- # Bug #610064
- filter-flags '-fstack-check*'
-
- # ...sure, why not?
- strip-unsupported-flags
-
- strip-flags
+ # There is lots of brittle old code that violates the aliasing rules. GCC
+ # 3.3 supports disabling this optimization.
+ newflags+=" -fno-strict-aliasing"
+
+ # xgcc wont understand gcc 3.4 flags... in fact it won't understand most
+ # things or have most patches, regardless of what the real GCC understands.
+ # A random collection of bugs:
+ # #269433 #290202 #442784 #610064 #879775 #919184 #832016
+ #
+ # There's some extensive discussion at bug #923112, ultimately the only
+ # practical approach is to simply reject *all* flags unless we handpicked
+ # them to allow them. Check in "${S}"/gcc/doc/gcc.1 before proceeding.
+ export CFLAGS="${newflags}"
+ export CXXFLAGS="${newflags}"
+ unset LDFLAGS
}
S=${WORKDIR}/gcc-${PV}
@@ -153,6 +136,22 @@ src_prepare() {
fi
tc-export AR CC RANLIB NM
+
+ # newer versions of GCC add default werrors that we need to disable for
+ # this very old and brittle code. But adding it to CFLAGS doesn't work,
+ # since GCC creates xgcc and uses that to compile libstdc++, and the
+ # ancient xgcc doesn't understand the flags we need.
+ mkdir "${T}/conservative-compiler" || die
+ export PATH="${$}/conservative-compiler:${PATH}"
+
+ local realcc=$(type -P "${CC}") || die
+ export CC="${T}/conservative-compiler/${CC##*/}"
+ cat > "${CC}" <<- __EOF__ || die
+ #!/bin/sh
+ "${realcc}" -Wno-error=implicit-function-declaration -Wno-error=implicit-int -Wno-error=int-conversion -Wno-error=incompatible-pointer-types "\$@"
+ __EOF__
+
+ chmod +x "${CC}" || die
}
src_configure() {