1 |
commit: 5320229523ad830f0410b30a44475e32edb6a372 |
2 |
Author: Alexey Sokolov <sokolov <AT> google <DOT> com> |
3 |
AuthorDate: Sat Oct 3 12:49:03 2020 +0000 |
4 |
Commit: James Le Cuirot <chewi <AT> gentoo <DOT> org> |
5 |
CommitDate: Sat Oct 3 13:14:07 2020 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=53202295 |
7 |
|
8 |
games-sports/gracer: fix build with gcc10 |
9 |
|
10 |
Bug: https://bugs.gentoo.org/744745 |
11 |
Package-Manager: Portage-3.0.4, Repoman-3.0.1 |
12 |
Signed-off-by: Alexey Sokolov <alexey+gentoo <AT> asokolov.org> |
13 |
Signed-off-by: James Le Cuirot <chewi <AT> gentoo.org> |
14 |
|
15 |
games-sports/gracer/files/gracer-0.1.5-gcc10.patch | 14 ++++++ |
16 |
games-sports/gracer/gracer-0.1.5-r2.ebuild | 51 ++++++++++++++++++++++ |
17 |
2 files changed, 65 insertions(+) |
18 |
|
19 |
diff --git a/games-sports/gracer/files/gracer-0.1.5-gcc10.patch b/games-sports/gracer/files/gracer-0.1.5-gcc10.patch |
20 |
new file mode 100644 |
21 |
index 00000000000..a7539248e50 |
22 |
--- /dev/null |
23 |
+++ b/games-sports/gracer/files/gracer-0.1.5-gcc10.patch |
24 |
@@ -0,0 +1,14 @@ |
25 |
+Fix -fno-common |
26 |
+ |
27 |
+diff -r c259e312716e vehicle.h |
28 |
+--- a/src/vehicle.h Sat Oct 03 12:42:08 2020 +0000 |
29 |
++++ b/src/vehicle.h Sat Oct 03 12:44:13 2020 +0000 |
30 |
+@@ -70,7 +70,7 @@ |
31 |
+ |
32 |
+ /* constants */ |
33 |
+ float mu[128]; /* friction factor */ |
34 |
+-} GrBreak; |
35 |
++}; |
36 |
+ |
37 |
+ struct _GrTireData { |
38 |
+ GrRef ref; |
39 |
|
40 |
diff --git a/games-sports/gracer/gracer-0.1.5-r2.ebuild b/games-sports/gracer/gracer-0.1.5-r2.ebuild |
41 |
new file mode 100644 |
42 |
index 00000000000..80f3d160674 |
43 |
--- /dev/null |
44 |
+++ b/games-sports/gracer/gracer-0.1.5-r2.ebuild |
45 |
@@ -0,0 +1,51 @@ |
46 |
+# Copyright 1999-2020 Gentoo Authors |
47 |
+# Distributed under the terms of the GNU General Public License v2 |
48 |
+ |
49 |
+EAPI=7 |
50 |
+ |
51 |
+DESCRIPTION="3D motor sports simulator" |
52 |
+HOMEPAGE="http://gracer.sourceforge.net/" |
53 |
+SRC_URI="mirror://sourceforge/gracer/${P}.tar.gz" |
54 |
+ |
55 |
+LICENSE="GPL-2" |
56 |
+SLOT="0" |
57 |
+KEYWORDS="~amd64 ~x86" |
58 |
+IUSE="joystick" |
59 |
+ |
60 |
+DEPEND=" |
61 |
+ dev-lang/tcl:0= |
62 |
+ media-libs/freeglut |
63 |
+ media-libs/giflib:= |
64 |
+ media-libs/libpng:0= |
65 |
+ media-libs/plib |
66 |
+ virtual/glu |
67 |
+ virtual/jpeg:0 |
68 |
+ virtual/opengl |
69 |
+ x11-libs/libXi |
70 |
+ x11-libs/libXmu |
71 |
+" |
72 |
+ |
73 |
+RDEPEND="${DEPEND}" |
74 |
+ |
75 |
+PATCHES=( |
76 |
+ "${FILESDIR}"/${PV}-gldefs.patch |
77 |
+ "${FILESDIR}"/${PN}-gcc-3.4.patch |
78 |
+ "${FILESDIR}/${P}"-gcc41.patch |
79 |
+ "${FILESDIR}"/${P}-as-needed.patch |
80 |
+ "${FILESDIR}"/${P}-libpng14.patch |
81 |
+ "${FILESDIR}"/${P}-png15.patch |
82 |
+ "${FILESDIR}"/${P}-giflib.patch |
83 |
+ "${FILESDIR}"/${P}-warnings.patch |
84 |
+ "${FILESDIR}"/${P}-gcc10.patch |
85 |
+) |
86 |
+ |
87 |
+src_configure() { |
88 |
+ econf \ |
89 |
+ --enable-gif \ |
90 |
+ --enable-jpeg \ |
91 |
+ --enable-png \ |
92 |
+ $(use_enable joystick) |
93 |
+ sed -i \ |
94 |
+ -e 's:-lplibsl:-lplibsl -lplibul:' \ |
95 |
+ $(find -name Makefile) || die |
96 |
+} |