Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 637986 - games-emulation/dolphin-5.0 fix build error with gcc 6.2 (ish)
Summary: games-emulation/dolphin-5.0 fix build error with gcc 6.2 (ish)
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Devan Franchini (RETIRED)
URL: https://github.com/dolphin-emu/dolphi...
Whiteboard:
Keywords: PATCH
: 620446 638156 (view as bug list)
Depends on:
Blocks: gcc-6
  Show dependency tree
 
Reported: 2017-11-18 09:45 UTC by Sander Sweers
Modified: 2018-01-11 10:35 UTC (History)
6 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
gcc 6.2 build fix (dolphin-5.0-gcc-6.2-build-fix.patch,4.60 KB, patch)
2017-11-18 09:45 UTC, Sander Sweers
Details | Diff
ebuild with Sander Sweers's modifications (dolphin-5.0-r1.ebuild,4.63 KB, text/plain)
2017-12-30 22:03 UTC, Jason Oliveira
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Sander Sweers 2017-11-18 09:45:21 UTC
Created attachment 504596 [details, diff]
gcc 6.2 build fix

Fix taken from referenced url, patch attached. Also fix warning that cmake-utils_src_prepare was not run yet when configuring.

" * cmake-utils_src_prepare has not been run, please open a bug on https://bugs.gentoo.org/"

ebuild diff
-------------------------------
--- /usr/portage/games-emulation/dolphin/dolphin-5.0.ebuild	2017-02-28 20:50:50.000000000 +0100
+++ dolphin-5.0.ebuild	2017-11-18 10:34:57.974708113 +0100
@@ -86,6 +86,7 @@
 }
 
 src_prepare() {
+	epatch ${FILESDIR}/${PN}-5.0-gcc-6.2-build-fix.patch
 
 	# Remove automatic dependencies to prevent building without flags enabled.
 	if use !alsa; then
@@ -136,6 +137,8 @@
 
 	l10n_find_plocales_changes "Languages/po/" "" '.po'
 	l10n_for_each_disabled_locale_do remove_locale
+
+	cmake-utils_src_prepare
 }
 
 src_configure() {
-------------------------------
Comment 1 Jan Buecken 2017-12-03 18:31:29 UTC
Needed for gcc 7, too
Comment 2 Toralf Förster gentoo-dev 2017-12-03 19:13:12 UTC
*** Bug 620446 has been marked as a duplicate of this bug. ***
Comment 3 zlg (RETIRED) gentoo-dev 2017-12-08 09:09:37 UTC
I can confirm the changes result in a successful build, and I was able to play a few rounds in a game without any issues.
Comment 4 Sander Sweers 2017-12-08 12:31:34 UTC
Sorry, did not notice bug 620446 and had a fix :(
Comment 5 Herbert Wantesh 2017-12-13 02:02:15 UTC
works for me too, please add this patch to the tree
Comment 6 Sophie Hamilton 2017-12-15 04:07:34 UTC
Patch works for me too. I'm using gcc-4.9.4 still, so the error appears unrelated to which gcc version is in use.
Comment 7 Ilya Trukhanov 2017-12-15 12:33:09 UTC
This build error is completely unrelated to GCC. The problem is with glibc-2.25, specifically the header file <limits.h> which in this exact version got a new #define directive, CHAR_WIDTH. Dolphin's source code defines a constant with the same name, and so the compiler tries to create a variable with name "8", which is not allowed, and that triggers the build failure.
Comment 8 Jason Oliveira 2017-12-30 21:52:20 UTC
Sander Sweers' patch works in the 5.0 ebuild on my systems. Please merge, so that Dolphin is buildable again post-glibc updates. Thanks.
Comment 9 Jason Oliveira 2017-12-30 22:03:09 UTC
Created attachment 512100 [details]
ebuild with Sander Sweers's modifications

To save the maintainer time, just use this ebuild. All credit goes to Sander Sweers for the changes.
Comment 10 Simone Scanzoni 2018-01-09 01:42:58 UTC
(In reply to Jason Oliveira from comment #9)
> Created attachment 512100 [details]
> ebuild with Sander Sweers's modifications
> 
> To save the maintainer time, just use this ebuild. All credit goes to Sander
> Sweers for the changes.

This worked for me, together with the modified cflags described in bug 640124
Comment 11 David Seifert gentoo-dev 2018-01-11 10:11:01 UTC
*** Bug 638156 has been marked as a duplicate of this bug. ***
Comment 12 David Seifert gentoo-dev 2018-01-11 10:11:05 UTC
*** Bug 620446 has been marked as a duplicate of this bug. ***
Comment 13 Larry the Git Cow gentoo-dev 2018-01-11 10:35:56 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ef8bb10ad88faeaf84a9ff6133507413618bd41d

commit ef8bb10ad88faeaf84a9ff6133507413618bd41d
Author:     David Seifert <soap@gentoo.org>
AuthorDate: 2018-01-11 10:24:41 +0000
Commit:     David Seifert <soap@gentoo.org>
CommitDate: 2018-01-11 10:35:38 +0000

    games-emulation/dolphin: Fix building with new glibc
    
    Closes: https://bugs.gentoo.org/637986
    Package-Manager: Portage-2.3.19, Repoman-2.3.6

 games-emulation/dolphin/dolphin-5.0.ebuild         | 64 ++++++++--------------
 .../files/dolphin-5.0-CHAR_WIDTH-collision.patch   | 49 +++++++++++++++++
 2 files changed, 72 insertions(+), 41 deletions(-)