Gentoo Archives: gentoo-commits

From: James Le Cuirot <chewi@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-games/ogre/files/, dev-games/ogre/
Date: Tue, 07 Jan 2020 22:58:37
Message-Id: 1578437879.60fd22922ec02d9a74c22c6cb6dad58c79092dae.chewi@gentoo
1 commit: 60fd22922ec02d9a74c22c6cb6dad58c79092dae
2 Author: Sven Eden <yamakuzure <AT> gmx <DOT> net>
3 AuthorDate: Wed Nov 6 23:12:03 2019 +0000
4 Commit: James Le Cuirot <chewi <AT> gentoo <DOT> org>
5 CommitDate: Tue Jan 7 22:57:59 2020 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=60fd2292
7
8 dev-games/ogre: New ebuild for latest stable release 1.12.4
9
10 Also moved to github.
11
12 In this release we have to also fetch the current release of imlib, as the tree
13 has it as a submodule which is not included in the ogre release zip.
14
15 And finally I have put myself into metadata.xml, as I am proxy-
16 maintaining ogre.
17
18 Package-Manager: Portage-2.3.84, Repoman-2.3.20
19 Bug: https://bugs.gentoo.org/699770
20 Closes: https://bugs.gentoo.org/699770
21 Signed-off-by: Sven Eden <sven.eden <AT> gmx.de>
22 Signed-off-by: James Le Cuirot <chewi <AT> gentoo.org>
23
24 dev-games/ogre/Manifest | 2 +
25 .../ogre-1.12.4-fix_sample_source_install.patch | 15 +++
26 dev-games/ogre/files/ogre-1.12.4-media_path.patch | 14 +++
27 .../ogre/files/ogre-1.12.4-resource_path.patch | 13 +++
28 dev-games/ogre/metadata.xml | 12 ++-
29 dev-games/ogre/ogre-1.10.12.ebuild | 4 +-
30 dev-games/ogre/ogre-1.11.2.ebuild | 6 +-
31 .../{ogre-1.11.2.ebuild => ogre-1.12.4.ebuild} | 107 ++++++++++++++++-----
32 dev-games/ogre/ogre-2.1_pre20180901.ebuild | 6 +-
33 9 files changed, 146 insertions(+), 33 deletions(-)
34
35 diff --git a/dev-games/ogre/Manifest b/dev-games/ogre/Manifest
36 index 1b26aeec681..aa4b1ac188e 100644
37 --- a/dev-games/ogre/Manifest
38 +++ b/dev-games/ogre/Manifest
39 @@ -1,4 +1,6 @@
40 +DIST imgui-1.74.tar.gz 1224024 BLAKE2B 794bd9aa0fdd1793fe9fa012c4b915731e3fe43ad32315421c2f5da2c2225f5dc6eb2c9618b999e0a4b8922b7a2b74fe2dbc5b5dc19de5aa0b6cee9d2ea67154 SHA512 e49e5cbe55899c0d0abc9b66c4e6e3e9941542af542d0ed3304bd3bde34c769baa2367355b77b91acb7fca56f9bcfd233dfc99881cfc8f5f6a2e2e6839990832
41 DIST ogre-1.10.12.zip 133067192 BLAKE2B 188437153969504b169970d14c39d47c9e666308bf65412018f42ba8ad108876f164733fe2004ea31941ab5db534766c10b871b34ef525522d1120b175530b87 SHA512 63998ea4940d04adfc179a94aa91bb2598692307b429f4c7e5b86a1519c13817035de4c71afc9e4b33fde35e962504373d152de9b9cc8eebbbeb78b2c1942041
42 DIST ogre-1.11.2.zip 127409383 BLAKE2B 7493892f434847ea4afda580868b2a8572d65c9ea9de3709aacd789229531803450dbd78994ff0fae29a9435912a80029edba51db035c7a175c860ce07912968 SHA512 dc6a7e14ee515d5a5c218aa3f31cefc8ad95a175604fb5fb252185220c6fd537f7094d3a1086d5eb5e9515f8c528c7f6e2ccc95594ef9882204c666b87fae4e2
43 +DIST ogre-1.12.4.tar.gz 127168699 BLAKE2B 40040f3a514aef449615203c327728d2b990be82b43ef0129192f20bd0f603b284906af94286ba7902bae96c657aba99d4f4f3f93580d249733af951e9bb902e SHA512 46406be3b57bd1aea8f657802e2d63f777dd4a723b291c5bb6c8f9eac62ba27fe18d43260093f1120ce75fc32997feb72b10388e8983b9c9d2b7cdb15231cdd8
44 DIST ogre-1.9.0.tar.bz2 128098305 BLAKE2B 6e67a5b60a6606a910e099f1c7ba736eb525f079f3aba5cfb362329b9130059d303fc9df6f7b8611c0ba75e1e207fa018e543e93c9f5ce39a6621e4c72ed4a83 SHA512 b1ea93d80ac0978a7c228460a6714f8d17797450efd5af6765c9fa4402e9060a8ef3a700d2757593a3016fdc32276722c8f4a5d9889a3e2eb424f16162a52bde
45 DIST ogre-2.1_pre20180901.tar.bz2 152746767 BLAKE2B 758d31fca2e5e31080c688ba758948fb5998a8fe49b9052f79de6791786501d02d7079e8f55ed37dc1a93f360af1003d2a28a260ba687c60c75a1340b95232a7 SHA512 c3cb5630a35e0ddf8c688a972ab5f2821d62545b4febc013235157eaf5268b3ceac1b94c403d0298131991f3d80d1c9b3800212a49647c652ba02bd176f6cc04
46
47 diff --git a/dev-games/ogre/files/ogre-1.12.4-fix_sample_source_install.patch b/dev-games/ogre/files/ogre-1.12.4-fix_sample_source_install.patch
48 new file mode 100644
49 index 00000000000..616a5e33680
50 --- /dev/null
51 +++ b/dev-games/ogre/files/ogre-1.12.4-fix_sample_source_install.patch
52 @@ -0,0 +1,15 @@
53 +The SDK_CMakeLists.txt.in file does not exist at the moment (sed - 2018-04-25)
54 +
55 +--- a/Samples/CMakeLists.txt 2018-04-25 07:30:38.211048775 +0200
56 ++++ b/Samples/CMakeLists.txt 2018-04-25 07:32:32.842049802 +0200
57 +@@ -97,10 +97,6 @@
58 + PATTERN "scripts" EXCLUDE
59 + )
60 + # install a new CMakeLists.txt file to allow building of samples
61 +- configure_file(${OGRE_TEMPLATES_DIR}/SDK_CMakeLists.txt.in ${CMAKE_CURRENT_BINARY_DIR}/../CMakeLists.txt @ONLY)
62 +- configure_file(${OGRE_TEMPLATES_DIR}/SDK_Samples_CMakeLists.txt.in ${CMAKE_CURRENT_BINARY_DIR}/CMakeLists.txt @ONLY)
63 +- install(FILES ${CMAKE_CURRENT_BINARY_DIR}/../CMakeLists.txt DESTINATION ${OGRE_SAMPLES_DIR}/../)
64 +- install(FILES ${CMAKE_CURRENT_BINARY_DIR}/CMakeLists.txt DESTINATION ${OGRE_SAMPLES_DIR})
65 + endif ()
66 +
67 + # Install sample headers, some people rely on these
68
69 diff --git a/dev-games/ogre/files/ogre-1.12.4-media_path.patch b/dev-games/ogre/files/ogre-1.12.4-media_path.patch
70 new file mode 100644
71 index 00000000000..3030cc5b9fa
72 --- /dev/null
73 +++ b/dev-games/ogre/files/ogre-1.12.4-media_path.patch
74 @@ -0,0 +1,14 @@
75 +Media paths are fine already, the removed lines would screw them up.
76 +
77 +--- a/CMake/InstallResources.cmake 2019-11-06 08:09:15.185821495 +0100
78 ++++ b/CMake/InstallResources.cmake 2019-11-06 08:10:41.169819050 +0100
79 +@@ -145,9 +145,6 @@
80 +
81 + # CREATE CONFIG FILES - BUILD DIR VERSIONS
82 + if (NOT (APPLE_IOS OR WINDOWS_STORE OR WINDOWS_PHONE))
83 +- set(OGRE_MEDIA_DIR_REL "${PROJECT_SOURCE_DIR}/Samples/Media")
84 +- set(OGRE_CORE_MEDIA_DIR "${PROJECT_SOURCE_DIR}/Media")
85 +- set(OGRE_TEST_MEDIA_DIR_REL "${PROJECT_SOURCE_DIR}/Tests/Media")
86 + else ()
87 + # iOS needs to use relative paths in the config files
88 + set(OGRE_MEDIA_DIR_REL "${OGRE_MEDIA_PATH}")
89
90 diff --git a/dev-games/ogre/files/ogre-1.12.4-resource_path.patch b/dev-games/ogre/files/ogre-1.12.4-resource_path.patch
91 new file mode 100644
92 index 00000000000..cf35e2f99e8
93 --- /dev/null
94 +++ b/dev-games/ogre/files/ogre-1.12.4-resource_path.patch
95 @@ -0,0 +1,13 @@
96 +These was already configured above, the BINARY paths are wrong!
97 +
98 +--- a/CMake/InstallResources.cmake 2019-11-06 08:12:01.271816772 +0100
99 ++++ b/CMake/InstallResources.cmake 2019-11-06 08:13:15.623814658 +0100
100 +@@ -163,8 +163,6 @@
101 + set(OGRE_PLUGIN_DIR_REL "Contents/Frameworks/")
102 + set(OGRE_SAMPLES_DIR_REL "Contents/Plugins/")
103 + elseif (UNIX)
104 +- set(OGRE_PLUGIN_DIR_REL "${PROJECT_BINARY_DIR}/lib")
105 +- set(OGRE_SAMPLES_DIR_REL "${PROJECT_BINARY_DIR}/lib")
106 + endif ()
107 +
108 + if (WINDOWS_STORE OR WINDOWS_PHONE OR EMSCRIPTEN)
109
110 diff --git a/dev-games/ogre/metadata.xml b/dev-games/ogre/metadata.xml
111 index 841aaefd7dc..4c31c236ea0 100644
112 --- a/dev-games/ogre/metadata.xml
113 +++ b/dev-games/ogre/metadata.xml
114 @@ -1,6 +1,14 @@
115 <?xml version="1.0" encoding="UTF-8"?>
116 <!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
117 <pkgmetadata>
118 + <maintainer type="person">
119 + <email>yamakuzure@×××.net</email>
120 + <name>Sven Eden</name>
121 + </maintainer>
122 + <maintainer type="project">
123 + <email>proxy-maint@g.o</email>
124 + <name>Proxy Maintainers</name>
125 + </maintainer>
126 <maintainer type="project">
127 <email>games@g.o</email>
128 <name>Gentoo Games Project</name>
129 @@ -109,7 +117,7 @@ Exporters
130 sensitive lookup. Some demos might not work with this setting.
131 (default: case-insensitive + sensitive lookup in all groups)
132 </flag>
133 - <flag name="resman-strict">
134 + <flag name="resman-strict" restrict="&lt;dev-games/ogre-1.12">
135 Resource Manager STRICT : search in default group if not specified otherwise.
136 Case sensitive lookup. Some demos might not work with this setting.
137 (default: case-insensitive + sensitive lookup in all groups)
138 @@ -119,5 +127,7 @@ Exporters
139 </use>
140 <upstream>
141 <remote-id type="bitbucket">sinbad/ogre</remote-id>
142 + <remote-id type="github">OGRECave/ogre</remote-id>
143 + <remote-id type="github">OGRECave/ogre-next</remote-id>
144 </upstream>
145 </pkgmetadata>
146
147 diff --git a/dev-games/ogre/ogre-1.10.12.ebuild b/dev-games/ogre/ogre-1.10.12.ebuild
148 index 34a0952245b..91e3b9f49d5 100644
149 --- a/dev-games/ogre/ogre-1.10.12.ebuild
150 +++ b/dev-games/ogre/ogre-1.10.12.ebuild
151 @@ -1,7 +1,7 @@
152 -# Copyright 1999-2018 Gentoo Foundation
153 +# Copyright 1999-2019 Gentoo Authors
154 # Distributed under the terms of the GNU General Public License v2
155
156 -EAPI=6
157 +EAPI=7
158
159 CMAKE_REMOVE_MODULES="yes"
160 CMAKE_REMOVE_MODULES_LIST="FindFreetype FindDoxygen FindZLIB"
161
162 diff --git a/dev-games/ogre/ogre-1.11.2.ebuild b/dev-games/ogre/ogre-1.11.2.ebuild
163 index e3f452d99e9..0de0b6eb487 100644
164 --- a/dev-games/ogre/ogre-1.11.2.ebuild
165 +++ b/dev-games/ogre/ogre-1.11.2.ebuild
166 @@ -1,7 +1,7 @@
167 -# Copyright 1999-2018 Gentoo Foundation
168 +# Copyright 1999-2019 Gentoo Authors
169 # Distributed under the terms of the GNU General Public License v2
170
171 -EAPI=6
172 +EAPI=7
173
174 CMAKE_REMOVE_MODULES="yes"
175 CMAKE_REMOVE_MODULES_LIST="FindFreetype FindDoxygen FindZLIB"
176 @@ -13,7 +13,7 @@ SRC_URI="https://github.com/OGRECave/${PN}/archive/v${PV}.zip -> ${P}.zip"
177
178 LICENSE="MIT public-domain"
179 SLOT="0/1.11"
180 -KEYWORDS="~amd64 ~x86"
181 +KEYWORDS="~amd64 ~arm ~x86"
182
183 IUSE="+cache cg debug doc double-precision egl examples experimental +freeimage
184 gles2 json openexr +opengl pch profile resman-pedantic resman-strict tools"
185
186 diff --git a/dev-games/ogre/ogre-1.11.2.ebuild b/dev-games/ogre/ogre-1.12.4.ebuild
187 similarity index 56%
188 copy from dev-games/ogre/ogre-1.11.2.ebuild
189 copy to dev-games/ogre/ogre-1.12.4.ebuild
190 index e3f452d99e9..7d8c48cadd8 100644
191 --- a/dev-games/ogre/ogre-1.11.2.ebuild
192 +++ b/dev-games/ogre/ogre-1.12.4.ebuild
193 @@ -1,32 +1,36 @@
194 -# Copyright 1999-2018 Gentoo Foundation
195 +# Copyright 1999-2020 Gentoo Authors
196 # Distributed under the terms of the GNU General Public License v2
197
198 -EAPI=6
199 +EAPI=7
200
201 -CMAKE_REMOVE_MODULES="yes"
202 CMAKE_REMOVE_MODULES_LIST="FindFreetype FindDoxygen FindZLIB"
203 -inherit cmake-utils
204 +inherit cmake
205 +
206 +IMGUI_PN="imgui"
207 +IMGUI_PV="1.74"
208 +IMGUI_P="${IMGUI_PN}-${IMGUI_PV}"
209
210 DESCRIPTION="Object-oriented Graphics Rendering Engine"
211 HOMEPAGE="https://www.ogre3d.org/"
212 -SRC_URI="https://github.com/OGRECave/${PN}/archive/v${PV}.zip -> ${P}.zip"
213 +SRC_URI="https://github.com/OGRECave/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz
214 + https://github.com/ocornut/${IMGUI_PN}/archive/v${IMGUI_PV}.tar.gz -> ${IMGUI_P}.tar.gz"
215
216 LICENSE="MIT public-domain"
217 -SLOT="0/1.11"
218 -KEYWORDS="~amd64 ~x86"
219 +SLOT="0/1.12"
220 +KEYWORDS="~amd64 ~arm ~x86"
221
222 IUSE="+cache cg debug doc double-precision egl examples experimental +freeimage
223 - gles2 json openexr +opengl pch profile resman-pedantic resman-strict tools"
224 + gles2 json openexr +opengl pch profile resman-pedantic tools"
225
226 REQUIRED_USE="
227 || ( gles2 opengl )
228 - ?? ( resman-pedantic resman-strict )
229 "
230
231 RESTRICT="test" #139905
232
233 RDEPEND="
234 dev-games/ois
235 + dev-libs/pugixml
236 dev-libs/zziplib
237 media-libs/freetype:2
238 x11-libs/libX11
239 @@ -51,40 +55,82 @@ DEPEND="${RDEPEND}
240 doc? ( app-doc/doxygen )"
241
242 PATCHES=(
243 - "${FILESDIR}/${P}-media_path.patch"
244 - "${FILESDIR}/${P}-resource_path.patch"
245 - "${FILESDIR}/${P}-fix_sample_source_install.patch"
246 - "${FILESDIR}/${PN}-1.10.12-use_system_tinyxml.patch"
247 + "${FILESDIR}"/${P}-media_path.patch
248 + "${FILESDIR}"/${P}-resource_path.patch
249 + "${FILESDIR}"/${P}-fix_sample_source_install.patch
250 + "${FILESDIR}"/${PN}-1.10.12-use_system_tinyxml.patch
251 )
252
253 +src_unpack() {
254 + unpack ${P}.tar.gz || die "Unpacking ${P}.zip failed"
255 +
256 + # Ogre 1.12.3 includes imgui, but as a submodule, it is not included
257 + # in the release.
258 + cd "${S}"/Components/Overlay/src || die "Unpack incomplete"
259 + unpack ${IMGUI_P}.tar.gz || die "Unpacking ${IMGUI_P}.zip failed"
260 +
261 + # Without this 'rm', mv puts imgui-1.73 *into* imgui/ instead of renaming.
262 + rm -rf "${IMGUI_PN}" || die "Removing ${IMGUI_PN} failed"
263 + mv "${IMGUI_P}" "${IMGUI_PN}" || die "Moving ${IMGUI_P} to ${IMGUI_PN} failed"
264 +}
265 +
266 src_prepare() {
267 + local broken_png=(
268 + Icon@×××××.png
269 + Default-Portrait~ipad.png
270 + Default-Portrait@2x~ipad.png
271 + Default-Landscape@2x~ipad.png
272 + )
273 +
274 sed -i \
275 - -e "s:share/OGRE/docs:share/doc/${PF}:" \
276 + -e "s:share/doc/OGRE:share/doc/${PF}:" \
277 Docs/CMakeLists.txt || die
278 # In this series, the CMAKE_BUILD_TARGET is hard-wired to the
279 # installation. And only Debug, MinSizeRel and RelWithDebInfo
280 # are supported.
281 if use debug; then
282 + sed -i \
283 + -e 's/Debug/Gentoo/g' \
284 + CMake/InstallResources.cmake \
285 + || die
286 sed -i \
287 -e 's/Debug/Gentoo/g' \
288 CMake/Utils/OgreConfigTargets.cmake \
289 || die
290 else
291 + sed -i \
292 + -e 's/MinSizeRel/Gentoo/g' \
293 + CMake/InstallResources.cmake \
294 + || die
295 sed -i \
296 -e 's/MinSizeRel/Gentoo/g' \
297 CMake/Utils/OgreConfigTargets.cmake \
298 || die
299 fi
300 +
301 + # Fix broken png files
302 + einfo "Fixing broken png files."
303 + pushd "${S}"/Samples/Common/misc 1>/dev/null 2>&1
304 + for png in "${broken_png[@]}"; do
305 + pngfix -q --out=out.png ${png}
306 + mv -f out.png "${png}" || die
307 + done
308 + popd 1>/dev/null 2>&1
309 + einfo "done ..."
310 +
311 # Fix some path issues
312 - cmake-utils_src_prepare
313 + cmake_src_prepare
314 }
315
316 src_configure() {
317 local mycmakeargs=(
318 -DCMAKE_SKIP_INSTALL_RPATH=yes
319 -DOGRE_BUILD_COMPONENT_BITES=yes
320 + -DOGRE_BUILD_COMPONENT_CSHARP=no
321 -DOGRE_BUILD_COMPONENT_HLMS=$(usex experimental)
322 -DOGRE_BUILD_COMPONENT_JAVA=no
323 + -DOGRE_BUILD_COMPONENT_OVERLAY=yes
324 + -DOGRE_BUILD_COMPONENT_OVERLAY_IMGUI=yes
325 -DOGRE_BUILD_COMPONENT_PAGING=yes
326 -DOGRE_BUILD_COMPONENT_PROPERTY=yes
327 -DOGRE_BUILD_COMPONENT_PYTHON=no
328 @@ -113,31 +159,44 @@ src_configure() {
329 -DOGRE_INSTALL_SAMPLES=$(usex examples)
330 -DOGRE_INSTALL_SAMPLES_SOURCE=$(usex examples)
331 -DOGRE_PROFILING=$(usex profile)
332 - -DOGRE_RESOURCEMANAGER_STRICT=$(\
333 - usex resman-pedantic 1 $(\
334 - usex resman-strict 2 0))
335 + -DOGRE_RESOURCEMANAGER_STRICT=$(usex resman-pedantic 1 2)
336 )
337
338 - cmake-utils_src_configure
339 + cmake_src_configure
340 +}
341 +
342 +src_compile() {
343 + cmake_src_compile
344 +
345 + if use doc ; then
346 + eninja -C "${BUILD_DIR}" OgreDoc
347 + fi
348 }
349
350 src_install() {
351 - cmake-utils_src_install
352 + cmake_src_install
353
354 CONFIGDIR=/etc/OGRE
355 SHAREDIR=/usr/share/OGRE
356
357 # plugins and resources are the main configuration
358 insinto "${CONFIGDIR}"
359 - doins "${CMAKE_BUILD_DIR}"/bin/plugins.cfg
360 - doins "${CMAKE_BUILD_DIR}"/bin/resources.cfg
361 + doins "${BUILD_DIR}"/bin/plugins.cfg
362 + doins "${BUILD_DIR}"/bin/resources.cfg
363 dosym "${CONFIGDIR}"/plugins.cfg "${SHAREDIR}"/plugins.cfg
364 dosym "${CONFIGDIR}"/resources.cfg "${SHAREDIR}"/resources.cfg
365
366 # These are only for the sample browser
367 if use examples ; then
368 insinto "${SHAREDIR}"
369 - doins "${CMAKE_BUILD_DIR}"/bin/quakemap.cfg
370 - doins "${CMAKE_BUILD_DIR}"/bin/samples.cfg
371 + doins "${BUILD_DIR}"/bin/quakemap.cfg
372 + doins "${BUILD_DIR}"/bin/samples.cfg
373 fi
374 }
375 +
376 +pkg_postinst() {
377 + elog "If you experience crashes when starting /usr/bin/SampleBrowser,"
378 + elog "remove the cache directory at:"
379 + elog " '~/.cache/OGRE Sample Browser'"
380 + elog "first, before filling a bug report."
381 +}
382
383 diff --git a/dev-games/ogre/ogre-2.1_pre20180901.ebuild b/dev-games/ogre/ogre-2.1_pre20180901.ebuild
384 index 9249788cc20..f7805764e6e 100644
385 --- a/dev-games/ogre/ogre-2.1_pre20180901.ebuild
386 +++ b/dev-games/ogre/ogre-2.1_pre20180901.ebuild
387 @@ -1,7 +1,7 @@
388 -# Copyright 1999-2018 Gentoo Foundation
389 +# Copyright 1999-2019 Gentoo Authors
390 # Distributed under the terms of the GNU General Public License v2
391
392 -EAPI=6
393 +EAPI=7
394
395 CMAKE_REMOVE_MODULES="yes"
396 CMAKE_REMOVE_MODULES_LIST="FindFreetype FindDoxygen FindZLIB"
397 @@ -16,7 +16,7 @@ SRC_URI="https://bitbucket.org/sinbad/ogre/get/${MY_COMMIT}.tar.bz2 -> ${P}.tar.
398
399 LICENSE="MIT public-domain"
400 SLOT="0/2.1"
401 -KEYWORDS=""
402 +KEYWORDS="~amd64"
403
404 IUSE="+cache debug doc egl examples +freeimage gles2 json +legacy-animations
405 mobile +opengl profile tools"