From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 2653B13835A for ; Wed, 14 Oct 2020 20:22:37 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 7A3A1E0942; Wed, 14 Oct 2020 20:22:36 +0000 (UTC) Received: from smtp.gentoo.org (mail.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 56B4CE0942 for ; Wed, 14 Oct 2020 20:22:36 +0000 (UTC) Received: from oystercatcher.gentoo.org (unknown [IPv6:2a01:4f8:202:4333:225:90ff:fed9:fc84]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 3C7C4340E7A for ; Wed, 14 Oct 2020 20:22:35 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 6DE053A7 for ; Wed, 14 Oct 2020 20:22:32 +0000 (UTC) From: "Matt Turner" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Matt Turner" Message-ID: <1602706927.e59f4f8b190152fe9ab5bbfdcc24ffe48838a3ae.mattst88@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: sys-boot/yaboot/ X-VCS-Repository: repo/gentoo X-VCS-Files: sys-boot/yaboot/yaboot-1.3.17-r4.ebuild X-VCS-Directories: sys-boot/yaboot/ X-VCS-Committer: mattst88 X-VCS-Committer-Name: Matt Turner X-VCS-Revision: e59f4f8b190152fe9ab5bbfdcc24ffe48838a3ae X-VCS-Branch: master Date: Wed, 14 Oct 2020 20:22:32 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: 27ac691b-70b9-4e4d-bf17-f9b8e9f8536b X-Archives-Hash: c3a1b40e9792d44a79ae0ea82670bef7 commit: e59f4f8b190152fe9ab5bbfdcc24ffe48838a3ae Author: Matt Turner gentoo org> AuthorDate: Wed Oct 14 20:03:36 2020 +0000 Commit: Matt Turner gentoo org> CommitDate: Wed Oct 14 20:22:07 2020 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=e59f4f8b sys-boot/yaboot: Depend on sys-apps/ibm-powerpc-utils Signed-off-by: Matt Turner gentoo.org> sys-boot/yaboot/yaboot-1.3.17-r4.ebuild | 117 ++++++++++++++++++++++++++++++++ 1 file changed, 117 insertions(+) diff --git a/sys-boot/yaboot/yaboot-1.3.17-r4.ebuild b/sys-boot/yaboot/yaboot-1.3.17-r4.ebuild new file mode 100644 index 00000000000..28bd397e2aa --- /dev/null +++ b/sys-boot/yaboot/yaboot-1.3.17-r4.ebuild @@ -0,0 +1,117 @@ +# Copyright 1999-2020 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +inherit flag-o-matic toolchain-funcs + +# yaboot is sensitive to external libc dependencies +# of e2fsprogs. Pin to known working versions. +# As a bonus we can control CFLAGS used to build e2fsprogs. +# See compile_bundled_e2fsprogs() below and https://bugs.gentoo.org/641560 +E2FS_P="e2fsprogs-1.42.13" + +DESCRIPTION="PPC Bootloader" +HOMEPAGE="http://yaboot.ozlabs.org" +SRC_URI=" + http://yaboot.ozlabs.org/releases/${P}.tar.gz + mirror://sourceforge/e2fsprogs/${E2FS_P}.tar.gz +" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="-* ~ppc -ppc64" +IUSE="ibm" + +DEPEND="" +RDEPEND=" + !sys-boot/yaboot-static + sys-apps/ibm-powerpc-utils + !ibm? ( + sys-fs/hfsutils + sys-fs/hfsplusutils + sys-fs/mac-fdisk + )" + +PATCHES=( + # dual boot patch + "${FILESDIR}/yabootconfig-1.3.13.patch" + "${FILESDIR}/chrpfix.patch" + "${FILESDIR}/${P}-nopiessp-gcc4.patch" + "${FILESDIR}/${PN}-stubfuncs.patch" + + # Fix the devspec path on newer kernels + "${FILESDIR}/new-ofpath-devspec.patch" +) + +src_prepare() { + # has to be copied before 'new-ofpath-devspec' + cp "${FILESDIR}/new-ofpath" "${S}/ybin/ofpath" || die + default + + pushd "${WORKDIR}/${E2FS_P}" + eapply "${FILESDIR}"/e2fsprogs-1.42.13-sysmacros.h.patch + popd + + # No need to hardcode this path -- the compiler already knows to use it. + # Error only on real errors, for prom printing format compile failure. + sed -i \ + -e 's:-I/usr/include::' \ + -e 's:-Werror:-Wno-error:g' \ + Makefile || die + + # We'll install bundled libext2fs.a here + DEPS_DIR="${T}"/bundled-deps + export DEPS_DIR +} + +src_configure() { + # ld.gold fails to link yaboot as: + # sorry, I can't find space in second/yaboot.chrp to put the note + # bug #678710 + tc-ld-disable-gold + + pushd "${WORKDIR}/${E2FS_P}" || die + econf \ + --enable-libblkid \ + --enable-libuuid \ + --disable-fsck \ + --disable-quota + popd + + default +} + +src_compile() { + # Note: we use unmodified host's CFLAGS to build depends. + emake -C "${WORKDIR}/${E2FS_P}" V=1 + # install-libs to install libext2fs.a for yaboot to statically link against + emake -C "${WORKDIR}/${E2FS_P}" DESTDIR="${DEPS_DIR}" install-libs V=1 + + unset CFLAGS CXXFLAGS CPPFLAGS LDFLAGS + # -std=gnu90 is needed to preserve 'inline' semantics + # of pre-c99 (always-inline) to avoid duplicate symbol + # definition, bug #641560. + # -L${deps_prefix}/usr/lib is needed to inject known + # working libext2fs.a as yaboot bundles header overrides + # that assume matcking implementation. System's version + # frequently does not work like in bug #641560. + emake \ + PREFIX=/usr \ + MANDIR=share/man \ + CC="$(tc-getCC) -std=gnu90" \ + LD="$(tc-getLD) -L${DEPS_DIR}/usr/lib" +} + +src_install() { + sed -i -e 's/\/local//' etc/yaboot.conf || die + emake \ + ROOT="${D}" \ + PREFIX=/usr \ + MANDIR=share/man \ + CC="$(tc-getCC) -std=gnu90" \ + LD="$(tc-getLD) -L${DEPS_DIR}/usr/lib" \ + \ + install + mv "${ED}"/etc/yaboot.conf{,.sample} || die +}