From e855eb72fd45d7a1cb013e658fdeb49636ffe7af Mon Sep 17 00:00:00 2001 From: Ionen Wolkens Date: Fri, 16 Sep 2022 11:48:13 -0400 Subject: [PATCH] dev-util/mingw64-toolchain: fix lto again Was wondering why AR was looking for the lto plugin in a non-existing bfd-plugins directory before, turned out it was because gcc resolved its location differently when set as a symlink. In commit c4262506ff492b96cddccb15e1fe1842d8d5a626, reverted to using upstream's intended hardlink but didn't notice this change in behavior and it broke lto again. Bug: https://bugs.gentoo.org/854516 Fixes: c4262506ff492b96cddccb15e1fe1842d8d5a626 Signed-off-by: Ionen Wolkens --- ...n-10.0.0-r1.ebuild => mingw64-toolchain-10.0.0-r2.ebuild} | 5 ++--- ...0.0.0_p1.ebuild => mingw64-toolchain-10.0.0_p1-r1.ebuild} | 5 ++--- 2 files changed, 4 insertions(+), 6 deletions(-) rename dev-util/mingw64-toolchain/{mingw64-toolchain-10.0.0-r1.ebuild => mingw64-toolchain-10.0.0-r2.ebuild} (98%) rename dev-util/mingw64-toolchain/{mingw64-toolchain-10.0.0_p1.ebuild => mingw64-toolchain-10.0.0_p1-r1.ebuild} (98%) diff --git a/dev-util/mingw64-toolchain/mingw64-toolchain-10.0.0-r1.ebuild b/dev-util/mingw64-toolchain/mingw64-toolchain-10.0.0-r2.ebuild similarity index 98% rename from dev-util/mingw64-toolchain/mingw64-toolchain-10.0.0-r1.ebuild rename to dev-util/mingw64-toolchain/mingw64-toolchain-10.0.0-r2.ebuild index e88628a96cfbe..a7fc75296ccc1 100644 --- a/dev-util/mingw64-toolchain/mingw64-toolchain-10.0.0-r1.ebuild +++ b/dev-util/mingw64-toolchain/mingw64-toolchain-10.0.0-r2.ebuild @@ -101,9 +101,8 @@ src_compile() { ) mwt-binutils() { # symlink gcc's lto plugin for AR (bug #854516) - mkdir "${sysroot}"/${CTARGET}/lib/bfd-plugins || die - ln -s ../../../libexec/gcc/${CTARGET}/${GCC_PV}/liblto_plugin.so \ - "${sysroot}"/${CTARGET}/lib/bfd-plugins || die + ln -s ../../libexec/gcc/${CTARGET}/${GCC_PV}/liblto_plugin.so \ + "${sysroot}"/lib/bfd-plugins || die } # gcc (minimal -- if need more, disable only in stage1 / enable in stage3) diff --git a/dev-util/mingw64-toolchain/mingw64-toolchain-10.0.0_p1.ebuild b/dev-util/mingw64-toolchain/mingw64-toolchain-10.0.0_p1-r1.ebuild similarity index 98% rename from dev-util/mingw64-toolchain/mingw64-toolchain-10.0.0_p1.ebuild rename to dev-util/mingw64-toolchain/mingw64-toolchain-10.0.0_p1-r1.ebuild index d5ea4cc5118d4..bc9e79c199db2 100644 --- a/dev-util/mingw64-toolchain/mingw64-toolchain-10.0.0_p1.ebuild +++ b/dev-util/mingw64-toolchain/mingw64-toolchain-10.0.0_p1-r1.ebuild @@ -102,9 +102,8 @@ src_compile() { ) mwt-binutils() { # symlink gcc's lto plugin for AR (bug #854516) - mkdir "${sysroot}"/${CTARGET}/lib/bfd-plugins || die - ln -s ../../../libexec/gcc/${CTARGET}/${GCC_PV}/liblto_plugin.so \ - "${sysroot}"/${CTARGET}/lib/bfd-plugins || die + ln -s ../../libexec/gcc/${CTARGET}/${GCC_PV}/liblto_plugin.so \ + "${sysroot}"/lib/bfd-plugins || die } # gcc (minimal -- if need more, disable only in stage1 / enable in stage3)