summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFabian Groffen <grobian@gentoo.org>2024-07-17 14:01:20 +0200
committerFabian Groffen <grobian@gentoo.org>2024-07-17 14:01:20 +0200
commitbbd5711ebc5b29443ad3f7aae599cbc2b9418cf3 (patch)
tree5dd554870f8d8e155fdacc9211998ed34506dcb3
parenttoolchain.eclass: handle quirky behaviour of --enable-host-bind-now (diff)
downloadprefix-bbd5711ebc5b29443ad3f7aae599cbc2b9418cf3.tar.gz
prefix-bbd5711ebc5b29443ad3f7aae599cbc2b9418cf3.tar.bz2
prefix-bbd5711ebc5b29443ad3f7aae599cbc2b9418cf3.zip
sys-devel/gcc-14.1.0: version bump
Signed-off-by: Fabian Groffen <grobian@gentoo.org>
-rw-r--r--sys-devel/gcc/Manifest9
-rw-r--r--sys-devel/gcc/gcc-14.0.1_pre20240225.ebuild150
-rw-r--r--sys-devel/gcc/gcc-14.1.0.ebuild94
3 files changed, 99 insertions, 154 deletions
diff --git a/sys-devel/gcc/Manifest b/sys-devel/gcc/Manifest
index 1b263733fb..f6b643c4e9 100644
--- a/sys-devel/gcc/Manifest
+++ b/sys-devel/gcc/Manifest
@@ -14,7 +14,8 @@ DIST gcc-13.2.0-patches-7.tar.xz 37064 BLAKE2B 4a8700a8d44bfaa84926f8bfd0da4c5b0
DIST gcc-13.2.0.tar.xz 87858592 BLAKE2B 0034b29d3d6cc05821f0c4253ce077805943aff7b370729dd203bda57d89c107edd657eeddc2fb1e69ea15c7b0323b961f46516c7f4af89a3ccf7fea84701be2 SHA512 d99e4826a70db04504467e349e9fbaedaa5870766cda7c5cab50cdebedc4be755ebca5b789e1232a34a20be1a0b60097de9280efe47bdb71c73251e30b0862a2
DIST gcc-13.3.0-arm64-darwin.patch 570896 BLAKE2B 6fcecb4adbf607f06a82b926c4b198a094a136210875320d784f49ac88e940d9b3c110f5b4e43df6751e40cdd90b82d00d461178c520b8692e1be427804b4cad SHA512 6165b6201f4ef94ee254ea40410911f5e5e1a05d80d4da2fce90b3db94000c3d5c5a28c9a4ad1a43387faae68d94fbef8e4d24e1ff049b9c0014c00f6f50757b
DIST gcc-13.3.0.tar.xz 87909952 BLAKE2B 0f3728b026bd8aab0e469dda54facf157a4b753d3405a74b0be6105a6e3a493d26df4007d90ae4e05d86277d41873312638f9589d1757cee80ca84de7f2099e3 SHA512 ed5f2f4c6ed2c796fcf2c93707159e9dbd3ddb1ba063d549804dd68cdabbb6d550985ae1c8465ae9a336cfe29274a6eb0f42e21924360574ebd8e5d5c7c9a801
-DIST gcc-14-20240225.tar.xz 87651536 BLAKE2B 01283581b8684e0dce73b2d9a586e473f3c87753435d905e193816911edc06f9bd2a8d542a95d69f47f1c884124349520f410925b13b7bb51b913e603000d32f SHA512 f424b0935d8fdcf9ff55067467eac20a518a11c2cb14928a47e1a218cde1f4238091f25861daf417d1125c5d5d5465d32fc1b3cb04504b3ca99fe27a7a7d5792
-DIST gcc-14.0.0-musl-patches-1.tar.xz 3576 BLAKE2B 692baee8a7709905d53aeb150d73a3721c4ba47ee5f397cfb1b5be905cf003ca02b60c94ee294d90ac39645cd5cdf186c7a3aa950c47d8cf680c128ed705b807 SHA512 0592ab98a7142e404623a6511c67dff61e9ade32c3fb2c0e75b456306e0af3799ad13252b50b3d2fdd31e5815d7f0b16b0ad63ab8386fe4d78729fc9c182d617
-DIST gcc-14.0.0-patches-24.tar.xz 14280 BLAKE2B f5594e07f91a7871fc4470d84ecbf6576f53620c92f60821d2fdcf140869827d27a323d535af11b74f4b671ee7308e501f24841ceb0607ca3ebc032bd97d85b4 SHA512 d887b53a0849246bc79ee2510d7deffabc58fe7598e9e147e4a97fc3714341017627df3dae9a39ae5d3185946cb6e11d01a28aa1287958c401e641fa4312f48b
-DIST gcc-darwin-arm64-14.0.1_pre20240225.tar.gz 143722125 BLAKE2B 23bc15e1243d10e897c6bd78cc0459c4163e767867d29a354aa51335703d3cee669b550816f2dad3becbade5a604a269bb52c8518e0f58338a61433d378d0a3c SHA512 a83c9764a7525a0768c871ef75915ad8dd5169873b29dc7c7b2413f2e7ab03c8c64888df4dbd74d0e82163cc760c01cec750e729b6df4ead03f23d6065b114d6
+DIST gcc-14.1.0-arm64-darwin.patch 200436 BLAKE2B ba92f8a1586f01085775c2a0a724f597a3e51468ee906169f41b46e58f2c615173120e38b4fc8e800d67cbdd97375564e009d3d1bd810293897466c817e03dcf SHA512 8ea5c3f80fa406294a95fa86264998c9090a4b7e734563e336dd670c0f8da0cb6bee8f80296905c0d7d6f17d0b895147d703951e94ba71466423d959404f5a0e
+DIST gcc-14.1.0-macos-SDK-availability.patch 9044 BLAKE2B 783340d55590337b156d3fd866027a931bafc3bd7d6a14c7d7940e13ff6fffebe351dae3a6d98c0ba7c7c5b4f226179bb24a8714f5ca334170ab353e0c2f4be8 SHA512 6db397718d20eca0b4caf7de45358379d05e83bfc4cb4d800aaf82dd8b7994af5dbfd9ff56e3480722dfec78ad381457034552358fc1e8eeb0a5a3e3ad0e4cc1
+DIST gcc-14.1.0-musl-patches-1.tar.xz 3600 BLAKE2B 4cd920b7ca1f122cae806707564d8e45bfd48e78c88788a12a301f6068b5a5f335d8885e67479ac536c66aeaa81f2ecb7240ae56e9fc821a7246ab66b453711f SHA512 61c48d90a55dfc2129d96aee69d939d6a89f6407f69f7bd12c1a619f28989f471fd219d731958f8e62b0fd650c32300f0ad8dc06d5df23d9fc8c1a77fe210c25
+DIST gcc-14.1.0-patches-3.tar.xz 11868 BLAKE2B 06d079766bfbaddd066cd70f2d3f5e9ef17f3617fe90de4cb0a9562e6c3b2dc46d94dce03649f2e530c21e3fa0e0e6e5aae3c7b768bd08717c4f29ff29b00a04 SHA512 636a2853b5bf057fef262d54bcb250f3ebf63c600bc184cfea499783d254c462f6c0ecf5f0c5dac6634110ba0d11193fbfb96850ac27fc5a318f1d810f2231cc
+DIST gcc-14.1.0.tar.xz 92265736 BLAKE2B 7efd6574b8bca081de6e31480ec0565c6d7fb773383e8e1fdcc17e35bba2bf44b3f4f995cdbcccd001689926e96a6563ef3d099902fe3b37ab09dcf553ab0596 SHA512 e9e224f2b26646fcf038d28dfa08b94c623bc57941f99894a321d01c600f7c68aff6b8837fd25e73e540de1f8de5606e98694a62cdcdfb525ce768b3ef6879ea
diff --git a/sys-devel/gcc/gcc-14.0.1_pre20240225.ebuild b/sys-devel/gcc/gcc-14.0.1_pre20240225.ebuild
deleted file mode 100644
index a1b9fee8c4..0000000000
--- a/sys-devel/gcc/gcc-14.0.1_pre20240225.ebuild
+++ /dev/null
@@ -1,150 +0,0 @@
-# Copyright 1999-2022 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-
-TOOLCHAIN_PATCH_DEV="sam"
-PATCH_GCC_VER="14.0.0"
-PATCH_VER="24"
-MUSL_VER="1"
-MUSL_GCC_VER="14.0.0"
-
-inherit toolchain
-
-# Don't keyword live ebuilds
-if ! tc_is_live && [[ -z ${TOOLCHAIN_USE_GIT_PATCHES} ]] ; then
- #KEYWORDS="~amd64-linux ~x86-linux ~arm64-macos ~ppc-macos ~x64-macos ~x64-solaris"
- # can't bootstrap from this using clang's libc++, better not use it
- KEYWORDS=""
-fi
-
-# use alternate source for Apple M1 (also works for x86_64)
-IANSGCCVER="9bc66f9b11baf1c291b2afac429cb12bf8461f91"
-SRC_URI+=" elibc_Darwin? ( https://github.com/iains/gcc-darwin-arm64/archive/${IANSGCCVER}.tar.gz -> gcc-darwin-arm64-${PV}.tar.gz )"
-
-# Technically only if USE=hardened *too* right now, but no point in complicating it further.
-# If GCC is enabling CET by default, we need glibc to be built with support for it.
-# bug #830454
-RDEPEND="!prefix-guest? ( elibc_glibc? ( sys-libs/glibc[cet(-)?] ) )"
-DEPEND="${RDEPEND}"
-BDEPEND="
- kernel_linux? ( >=${CATEGORY}/binutils-2.30[cet(-)?] )
- kernel_Darwin? (
- || ( ${CATEGORY}/binutils-apple ${CATEGORY}/native-cctools )
- )"
-
-src_unpack() {
- if use elibc_Darwin ; then
- # just use Ian's source, not the main one
- S="${WORKDIR}/gcc-darwin-arm64-${IANSGCCVER}"
- fi
- default
-}
-
-src_prepare() {
- # make sure 64-bits native targets don't screw up the linker paths
- eapply "${FILESDIR}"/gcc-12-no-libs-for-startfile.patch
-
- # doesn't apply on official and Darwin sources
- rm "${WORKDIR}"/patch/31_all_gm2_make_P_var.patch
-
- toolchain_src_prepare
-
- eapply_user
-
- eapply "${FILESDIR}"/${PN}-13-fix-cross-fixincludes.patch
-
- # make it have correct install_names on Darwin
- eapply -p1 "${FILESDIR}"/4.3.3/darwin-libgcc_s-installname.patch
-
- if [[ ${CHOST} == powerpc*-darwin* ]] ; then
- # https://gcc.gnu.org/bugzilla/show_bug.cgi?id=44107
- sed -i -e 's|^ifeq (/usr/lib,|ifneq (/usr/lib,|' \
- libgcc/config/t-slibgcc-darwin || die
- fi
-
- if [[ ${CHOST} == *-solaris* ]] ; then
- # madvise is not available in the compatibility mode GCC uses,
- # posix_madvise however, is
- sed -i -e 's/madvise/posix_madvise/' gcc/cp/module.cc || die
- fi
-
- if [[ ${CHOST} == *-darwin* ]] ; then
- # our ld64 is a slight bit different, so tweak expression to not
- # get confused and break the build
- sed -i -e 's/grep ld64/grep :ld64/' gcc/configure || die
-
- # rip out specific macos version min
- sed -i -e 's/-mmacosx-version-min=11.0//' \
- libgcc/config/aarch64/t-darwin \
- libgcc/config/aarch64/t-heap-trampoline \
- || die
-
- # weird, because we call --disable-host-bind-now but the check
- # interprets that as as using -Wl,-z,now
- sed -i -e 's/-Wl,-z,now//' c++tools/configure{.ac,} || die
- fi
-}
-
-src_configure() {
- local myconf=()
- case ${CTARGET}:" ${USE} " in
- powerpc*-darwin*)
- # bug #381179
- filter-flags "-mcpu=*" "-mtune=*"
- # bug #657522
- # A bug in configure checks whether -no-pie works, but the
- # compiler doesn't pass -no-pie onto the linker if -fno-PIE
- # isn't passed, so the configure check always finds -no-pie
- # is accepted. (Likewise, when -fno-PIE is passed, the
- # compiler passes -no_pie onto the linker.)
- # Since our linker doesn't grok this, avoid above checks to
- # be run
- # NOTE: later ld64 does grok -no_pie, not -no-pie (as checked)
- export gcc_cv_c_no_fpie=no
- export gcc_cv_no_pie=no
- ;;
- *-darwin20)
- # use sysroot with the linker, #756160
- export gcc_cv_ld_sysroot=yes
- ;;
- *-solaris*)
- # todo: some magic for native vs. GNU linking?
- myconf+=( --with-gnu-ld --with-gnu-as --enable-largefile )
- # Solaris 11 defines this in its headers, but that causes a
- # mismatch whilst compiling, bug #657514
- #export ac_cv_func_aligned_alloc=no
- #export ac_cv_func_memalign=no
- #export ac_cv_func_posix_memalign=no
- ;;
- i[34567]86-*-linux*:*" prefix "*)
- # to allow the linux-x86-on-amd64.patch become useful, we need
- # to enable multilib, even if there is just one multilib option.
- myconf+=( --enable-multilib )
- if [[ ${CBUILD:-${CHOST}} == "${CHOST}" ]]; then
- # we might be on x86_64-linux, but don't do cross-compile, so
- # tell the host-compiler to really create 32bits (for stage1)
- # (real x86-linux-gcc also accept -m32).
- append-flags -m32
- fi
- ;;
- esac
-
- if [[ ${CHOST} == *-darwin ]] ; then
- # GCC' Darwin fork enables support for "-stdlib=libc++"
- # unconditionally, and its default include path is invalid,
- # causing package build failures due to missing header.
- # But more importantly, it breaks the assumption of many build
- # scripts and changes their CFLAGS and linking behaviors. The
- # situation is tricky and needs careful considerations.
- # For now, just disable support for "-stdlib=libc++".
- myconf+=( --with-gxx-libcxx-include-dir=no )
- fi
-
- # Since GCC 4.1.2 some non-posix (?) /bin/sh compatible code is used, at
- # least on Solaris, and AIX /bin/sh is way too slow,
- # so force it to use $BASH (that portage uses) - it can't be EPREFIX
- # in case that doesn't exist yet
- export CONFIG_SHELL="${CONFIG_SHELL:-${BASH}}"
- toolchain_src_configure "${myconf[@]}"
-}
diff --git a/sys-devel/gcc/gcc-14.1.0.ebuild b/sys-devel/gcc/gcc-14.1.0.ebuild
new file mode 100644
index 0000000000..26e9c01106
--- /dev/null
+++ b/sys-devel/gcc/gcc-14.1.0.ebuild
@@ -0,0 +1,94 @@
+# Copyright 1999-2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+TOOLCHAIN_PATCH_DEV="sam"
+PATCH_GCC_VER="14.1.0"
+PATCH_VER="3"
+MUSL_VER="1"
+MUSL_GCC_VER="14.1.0"
+PYTHON_COMPAT=( python3_{10..12} )
+
+if [[ -n ${TOOLCHAIN_GCC_RC} ]] ; then
+ # Cheesy hack for RCs
+ MY_PV=$(ver_cut 1).$((($(ver_cut 2) + 1))).$((($(ver_cut 3) - 1)))-RC-$(ver_cut 5)
+ MY_P=${PN}-${MY_PV}
+ GCC_TARBALL_SRC_URI="mirror://gcc/snapshots/${MY_PV}/${MY_P}.tar.xz"
+ TOOLCHAIN_SET_S=no
+ S="${WORKDIR}"/${MY_P}
+fi
+
+inherit toolchain
+
+if tc_is_live ; then
+ # Needs to be after inherit (for now?), bug #830908
+ EGIT_BRANCH=releases/gcc-$(ver_cut 1)
+elif [[ -z ${TOOLCHAIN_USE_GIT_PATCHES} ]] ; then
+ # Don't keyword live ebuilds
+ KEYWORDS="~amd64-linux ~x86-linux ~arm64-macos ~ppc-macos ~x64-macos ~x64-solaris"
+fi
+
+# use alternate source for Apple M1 (also works for x86_64)
+SRC_URI+=" elibc_Darwin? ( https://raw.githubusercontent.com/Homebrew/formula-patches/82b5c1cd38826ab67ac7fc498a8fe74376a40f4a/gcc/gcc-14.1.0.diff -> gcc-14.1.0-arm64-darwin.patch https://github.com/iains/gcc-14-branch/commit/75ff8c390327ac693f6a1c40510bc0d35d7a1e22.patch?full_index=1 -> gcc-14.1.0-macos-SDK-availability.patch )"
+IUSE+=" bootstrap"
+
+if [[ ${CATEGORY} != cross-* ]] ; then
+ # Technically only if USE=hardened *too* right now, but no point in complicating it further.
+ # If GCC is enabling CET by default, we need glibc to be built with support for it.
+ # bug #830454
+ RDEPEND="!prefix-guest? ( elibc_glibc? ( sys-libs/glibc[cet(-)?] ) )"
+ DEPEND="${RDEPEND}"
+fi
+
+src_prepare() {
+ # apply big arm64-darwin patch first thing
+ use elibc_Darwin && eapply \
+ "${DISTDIR}"/gcc-14.1.0-arm64-darwin.patch \
+ "${DISTDIR}"/gcc-14.1.0-macos-SDK-availability.patch
+
+ # make sure 64-bits native targets don't screw up the linker paths
+ eapply "${FILESDIR}"/gcc-12-no-libs-for-startfile.patch
+
+ local p upstreamed_patches=(
+ # add them here
+ )
+ for p in "${upstreamed_patches[@]}"; do
+ rm -v "${WORKDIR}/patch/${p}" || die
+ done
+
+ toolchain_src_prepare
+ #
+ # make it have correct install_names on Darwin
+ eapply -p1 "${FILESDIR}"/4.3.3/darwin-libgcc_s-installname.patch
+
+ if [[ ${CHOST} == powerpc*-darwin* ]] ; then
+ # https://gcc.gnu.org/bugzilla/show_bug.cgi?id=44107
+ sed -i -e 's|^ifeq (/usr/lib,|ifneq (/usr/lib,|' \
+ libgcc/config/t-slibgcc-darwin || die
+ fi
+
+ if [[ ${CHOST} == *-solaris* ]] ; then
+ # madvise is not available in the compatibility mode GCC uses,
+ # posix_madvise however, is
+ sed -i -e 's/madvise/posix_madvise/' gcc/cp/module.cc || die
+ fi
+
+ if [[ ${CHOST} == *-darwin* ]] ; then
+ use bootstrap && eapply "${FILESDIR}"/${PN}-13-darwin14-bootstrap.patch
+
+ # our ld64 is a slight bit different, so tweak expression to not
+ # get confused and break the build
+ sed -i -e "s/EGREP 'ld64|dyld'/& | head -n1/" \
+ gcc/configure{.ac,} || die
+
+ # rip out specific macos version min
+ sed -i -e 's/-mmacosx-version-min=11.0//' \
+ libgcc/config/aarch64/t-darwin \
+ libgcc/config/aarch64/t-heap-trampoline \
+ || die
+ fi
+
+ eapply "${FILESDIR}"/${PN}-13-fix-cross-fixincludes.patch
+ eapply_user
+}