Gentoo Archives: gentoo-commits

From: Ionen Wolkens <ionen@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: games-sports/stormbaancoureur/files/, games-sports/stormbaancoureur/
Date: Thu, 08 Jul 2021 10:15:39
Message-Id: 1625739200.7112bef07ba3aa74123af01328c7a7a1088a5fd3.ionen@gentoo
1 commit: 7112bef07ba3aa74123af01328c7a7a1088a5fd3
2 Author: Alexey Sokolov <alexey+gentoo <AT> asokolov <DOT> org>
3 AuthorDate: Wed Jul 7 22:47:37 2021 +0000
4 Commit: Ionen Wolkens <ionen <AT> gentoo <DOT> org>
5 CommitDate: Thu Jul 8 10:13:20 2021 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=7112bef0
7
8 games-sports/stormbaancoureur: bump EAPI, fix build
9
10 Closes: https://bugs.gentoo.org/739386
11 Package-Manager: Portage-3.0.20, Repoman-3.0.2
12 Signed-off-by: Alexey Sokolov <alexey+gentoo <AT> asokolov.org>
13 Signed-off-by: Ionen Wolkens <ionen <AT> gentoo.org>
14
15 .../files/stormbaancoureur-2.1.6-clang.patch | 47 +++++++++++++++++++++
16 .../stormbaancoureur-2.1.6-r2.ebuild | 48 ++++++++++++++++++++++
17 2 files changed, 95 insertions(+)
18
19 diff --git a/games-sports/stormbaancoureur/files/stormbaancoureur-2.1.6-clang.patch b/games-sports/stormbaancoureur/files/stormbaancoureur-2.1.6-clang.patch
20 new file mode 100644
21 index 00000000000..7ef2a8e6920
22 --- /dev/null
23 +++ b/games-sports/stormbaancoureur/files/stormbaancoureur-2.1.6-clang.patch
24 @@ -0,0 +1,47 @@
25 +Fix build with clang
26 +Bug: https://bugs.gentoo.org/739386
27 +
28 +--- a/carpettrack.h
29 ++++ b/carpettrack.h
30 +@@ -15,7 +15,7 @@ class CarpetTrack
31 + trackspace = dSimpleSpaceCreate(staticspace);
32 + track = new StaticWorldObject(trackmodel, trackspace, initialpos);
33 + sgVec3 sz = { 2.0, 1.2, 0.08 };
34 +- sgVec3 cpos = { initialpos[0]+5, initialpos[1], initialpos[2]+0.6 };
35 ++ sgVec3 cpos = { initialpos[0]+5, initialpos[1], initialpos[2]+0.6f };
36 + carpet = new DynamicBoxObject(carpetmodel, world, trackspace, cpos, sz);
37 + carpet->name = "carpet";
38 + carpet->SetMass(1.0);
39 +--- a/doorstand.h
40 ++++ b/doorstand.h
41 +@@ -63,7 +63,7 @@ class DoorStand : public WorldObject
42 +
43 + // Do the door
44 + dReal sz[3] = { 0.1, 1.4, 1.6 };
45 +- dReal ps[3] = { initialpos[0], initialpos[1], initialpos[2]+0.85 };
46 ++ dReal ps[3] = { initialpos[0], initialpos[1], initialpos[2]+0.85f };
47 + door_body = dBodyCreate(world);
48 + dBodySetAutoDisableFlag(door_body, false);
49 + dBodySetPosition(door_body, ps[0], ps[1], ps[2]);
50 +--- a/spikejump.h
51 ++++ b/spikejump.h
52 +@@ -17,7 +17,7 @@ class SpikeJump
53 + spikespace = dSimpleSpaceCreate(staticspace);
54 + spikegate = new StaticWorldObject(spikemodel, spikespace, initialpos);
55 + sgVec3 sz = { 2.0, 1.2, 0.08 };
56 +- sgVec3 cpos = { initialpos[0], initialpos[1], initialpos[2]+0.6 };
57 ++ sgVec3 cpos = { initialpos[0], initialpos[1], initialpos[2]+0.6f };
58 + jumpboard = new DynamicBoxObject(boardmodel, world, spikespace, cpos, sz);
59 + jumpboard->name = "jumpboard";
60 + jumpboard->SetMass(1.0);
61 +--- a/ferriswheel.h
62 ++++ b/ferriswheel.h
63 +@@ -20,7 +20,7 @@ class FerrisWheelCart : public DynamicObject
64 + dBodySetPosition (body,initialpos[0],initialpos[1],initialpos[2]-1.45);
65 +
66 + dReal sizes[2][3] = {{ 2.0, 2.9, 0.1 }, {0.2, 0.3, 1.5}};
67 +- dReal xlats[2][4] = {{initialpos[0], initialpos[1], initialpos[2]-1.45}, {0,0,0.70}};
68 ++ dReal xlats[2][4] = {{initialpos[0], initialpos[1], initialpos[2]-1.45f}, {0,0,0.70}};
69 +
70 + dMass m;
71 + dMassSetZero(&m);
72
73 diff --git a/games-sports/stormbaancoureur/stormbaancoureur-2.1.6-r2.ebuild b/games-sports/stormbaancoureur/stormbaancoureur-2.1.6-r2.ebuild
74 new file mode 100644
75 index 00000000000..a1239ecaa18
76 --- /dev/null
77 +++ b/games-sports/stormbaancoureur/stormbaancoureur-2.1.6-r2.ebuild
78 @@ -0,0 +1,48 @@
79 +# Copyright 1999-2021 Gentoo Authors
80 +# Distributed under the terms of the GNU General Public License v2
81 +
82 +EAPI=8
83 +
84 +inherit desktop toolchain-funcs
85 +
86 +DESCRIPTION="Simulated obstacle course for automobiles"
87 +HOMEPAGE="http://www.stolk.org/stormbaancoureur/"
88 +SRC_URI="http://www.stolk.org/stormbaancoureur/download/${P}.tar.gz"
89 +S="${WORKDIR}/${P}/src-stormbaancoureur"
90 +
91 +LICENSE="GPL-3"
92 +SLOT="0"
93 +KEYWORDS="~amd64 ~x86"
94 +
95 +DEPEND="
96 + >=dev-games/ode-0.8[-double-precision]
97 + media-libs/alsa-lib
98 + media-libs/freeglut
99 + >=media-libs/plib-1.8.4
100 + virtual/glu
101 + virtual/opengl"
102 +RDEPEND="${DEPEND}"
103 +
104 +PATCHES=(
105 + "${FILESDIR}"/${P}-gentoo.patch
106 + "${FILESDIR}"/${P}-clang.patch
107 +)
108 +
109 +src_prepare() {
110 + default
111 +
112 + sed -ie "s:GENTOODIR:/usr/share/${PN}:" main.cxx || die
113 +}
114 +
115 +src_compile() {
116 + tc-export CXX
117 + emake LIBDIRNAME=$(get_libdir)
118 +}
119 +
120 +src_install() {
121 + dobin ${PN}
122 + insinto /usr/share/${PN}
123 + doins -r images/ models/ sounds/ shaders/
124 + dodoc JOYSTICKS README TODO
125 + make_desktop_entry ${PN} "Stormbaan Coureur"
126 +}