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 0814E138330 for ; Thu, 24 May 2018 15:31:41 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id EE1B8E0821; Thu, 24 May 2018 15:31:39 +0000 (UTC) Received: from smtp.gentoo.org (dev.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 A8374E0821 for ; Thu, 24 May 2018 15:31:39 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (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 1E9A7335C0C for ; Thu, 24 May 2018 15:31:38 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 75146257 for ; Thu, 24 May 2018 15:31:36 +0000 (UTC) From: "Andreas Sturmlechner" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Andreas Sturmlechner" Message-ID: <1527175881.041cd55b5dc192e9e6b1133a08e4279ea3674476.asturm@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: kde-apps/dolphin/files/, kde-apps/dolphin/ X-VCS-Repository: repo/gentoo X-VCS-Files: kde-apps/dolphin/dolphin-18.04.1.ebuild kde-apps/dolphin/files/dolphin-18.04.1-flto.patch X-VCS-Directories: kde-apps/dolphin/ kde-apps/dolphin/files/ X-VCS-Committer: asturm X-VCS-Committer-Name: Andreas Sturmlechner X-VCS-Revision: 041cd55b5dc192e9e6b1133a08e4279ea3674476 X-VCS-Branch: master Date: Thu, 24 May 2018 15:31:36 +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-Archives-Salt: c34a757e-d4db-44bd-b473-5524f7910b0b X-Archives-Hash: 5bec68ddc84a2c3e1fccd7a76811b93e commit: 041cd55b5dc192e9e6b1133a08e4279ea3674476 Author: Andreas Sturmlechner gentoo org> AuthorDate: Thu May 24 15:29:51 2018 +0000 Commit: Andreas Sturmlechner gentoo org> CommitDate: Thu May 24 15:31:21 2018 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=041cd55b kde-apps/dolphin: Fix build with -flto Thanks-to: Alexander Miller gmx.de> Closes: https://bugs.gentoo.org/655710 Package-Manager: Portage-2.3.38, Repoman-2.3.9 kde-apps/dolphin/dolphin-18.04.1.ebuild | 2 + kde-apps/dolphin/files/dolphin-18.04.1-flto.patch | 96 +++++++++++++++++++++++ 2 files changed, 98 insertions(+) diff --git a/kde-apps/dolphin/dolphin-18.04.1.ebuild b/kde-apps/dolphin/dolphin-18.04.1.ebuild index 256cdd94762..6814ee4e99c 100644 --- a/kde-apps/dolphin/dolphin-18.04.1.ebuild +++ b/kde-apps/dolphin/dolphin-18.04.1.ebuild @@ -62,6 +62,8 @@ RDEPEND="${DEPEND} RESTRICT+=" test" +PATCHES=( "${FILESDIR}/${P}-flto.patch" ) + src_configure() { local mycmakeargs=( $(cmake-utils_use_find_package semantic-desktop KF5Baloo) diff --git a/kde-apps/dolphin/files/dolphin-18.04.1-flto.patch b/kde-apps/dolphin/files/dolphin-18.04.1-flto.patch new file mode 100644 index 00000000000..8edef6b3601 --- /dev/null +++ b/kde-apps/dolphin/files/dolphin-18.04.1-flto.patch @@ -0,0 +1,96 @@ +From b607091c3982f6b84732fcf0c23c1c3f0054f203 Mon Sep 17 00:00:00 2001 +From: Alexander Miller +Date: Fri, 18 May 2018 22:43:25 +0200 +Subject: [PATCH 1/2] Remove main.cpp from dolphinstatic_SRCS + +Summary: +The file main.cpp is already in dolphin_SRCS and doesn't +belong in dolphinstatic_SRCS. + +Normally the duplicate object is simply ignored, but with +link time optimization (LTO), linking dolphin can fail. +Apparently, the compiler tries to inline inline kdemain() +in this case. That is undesirable anyway and it ultimately +fails because the DBusInterface definition is not available: + +.../ccHEv6cl.ltrans0.ltrans.o: In function `DBusInterface::~DBusInterface()': +:(.text+0x2583): undefined reference to `vtable for DBusInterface' +.../ccHEv6cl.ltrans0.ltrans.o: In function `DBusInterface::~DBusInterface()': +:(.text+0x5aa3): undefined reference to `vtable for DBusInterface' +.../ccHEv6cl.ltrans0.ltrans.o: In function `kdemain': +:(.text+0x7686): undefined reference to `DBusInterface::DBusInterface()' +:(.text+0x7b64): undefined reference to `vtable for DBusInterface' +collect2: error: ld returned 1 exit status + +See also . + +Reviewers: #dolphin, elvisangelaccio + +Reviewed By: elvisangelaccio + +Subscribers: elvisangelaccio, asturmlechner, kfm-devel + +Tags: #dolphin + +Differential Revision: https://phabricator.kde.org/D12929 +--- + src/CMakeLists.txt | 1 - + 1 file changed, 1 deletion(-) + +diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt +index 263b3ff0c..e8fe719a4 100644 +--- a/src/CMakeLists.txt ++++ b/src/CMakeLists.txt +@@ -207,7 +207,6 @@ set(dolphinstatic_SRCS + dolphintabwidget.cpp + trash/dolphintrash.cpp + filterbar/filterbar.cpp +- main.cpp + panels/information/filemetadataconfigurationdialog.cpp + panels/information/informationpanel.cpp + panels/information/informationpanelcontent.cpp +-- +2.17.0 + + +From 8e6f4eecd318041d2e4e6386d1660742dd4ddd89 Mon Sep 17 00:00:00 2001 +From: Alexander Miller +Date: Fri, 18 May 2018 22:44:52 +0200 +Subject: [PATCH 2/2] Make target_link_libraries for kdeinit_dolphin PRIVATE + +Summary: +There is no need to add all of kdeinit_dolphin's +dependencies (including the static archive) when +linking dolphin; kdemain is the only needed symbol. +Mark the link libraries PRIVATE to simplify the +link command for dolphin. + +Reviewers: #dolphin, elvisangelaccio + +Reviewed By: elvisangelaccio + +Subscribers: asturmlechner, kfm-devel + +Tags: #dolphin + +Differential Revision: https://phabricator.kde.org/D12931 +--- + src/CMakeLists.txt | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt +index e8fe719a4..beaa0ec50 100644 +--- a/src/CMakeLists.txt ++++ b/src/CMakeLists.txt +@@ -299,7 +299,7 @@ ecm_add_app_icon(dolphin_SRCS ICONS ${ICONS_SRCS}) + kf5_add_kdeinit_executable(dolphin ${dolphin_SRCS}) + + +-target_link_libraries(kdeinit_dolphin ++target_link_libraries(kdeinit_dolphin PRIVATE + dolphinstatic + dolphinprivate + ) +-- +2.17.0 +