1 |
commit: 57873ee92cd02014079d597b28c57b1054281ede |
2 |
Author: Tupone Alfredo <tupone <AT> gentoo <DOT> org> |
3 |
AuthorDate: Wed Sep 26 09:35:13 2018 +0000 |
4 |
Commit: Alfredo Tupone <tupone <AT> gentoo <DOT> org> |
5 |
CommitDate: Wed Sep 26 09:35:13 2018 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=57873ee9 |
7 |
|
8 |
dev-tcltk/tcl3d: Fix missing RDEPEND and modularize |
9 |
|
10 |
Closes: https://bugs.gentoo.org/619410 |
11 |
Package-Manager: Portage-2.3.49, Repoman-2.3.10 |
12 |
|
13 |
dev-tcltk/tcl3d/metadata.xml | 8 ++++++++ |
14 |
dev-tcltk/tcl3d/tcl3d-0.5.0.ebuild | 39 ++++++++++++++++++++------------------ |
15 |
2 files changed, 29 insertions(+), 18 deletions(-) |
16 |
|
17 |
diff --git a/dev-tcltk/tcl3d/metadata.xml b/dev-tcltk/tcl3d/metadata.xml |
18 |
index 851c8cbb058..2b1fbebe51e 100644 |
19 |
--- a/dev-tcltk/tcl3d/metadata.xml |
20 |
+++ b/dev-tcltk/tcl3d/metadata.xml |
21 |
@@ -5,6 +5,14 @@ |
22 |
<email>tcltk@g.o</email> |
23 |
<name>Gentoo Tcltk Project</name> |
24 |
</maintainer> |
25 |
+<use> |
26 |
+ <flag name="ode"> |
27 |
+ Enable support for physics engine from <pkg>dev-games/ode</pkg> |
28 |
+ </flag> |
29 |
+ <flag name="osg"> |
30 |
+ Enable support for 3D toolkit from <pkg>dev-games/openscenegraph</pkg> |
31 |
+ </flag> |
32 |
+</use> |
33 |
<longdescription> |
34 |
Tcl3D offers the 3D functionality of OpenGL and other 3D libraries at the Tcl scripting level. |
35 |
The Tcl3D package currently consists of the following modules: |
36 |
|
37 |
diff --git a/dev-tcltk/tcl3d/tcl3d-0.5.0.ebuild b/dev-tcltk/tcl3d/tcl3d-0.5.0.ebuild |
38 |
index e9a64f8be86..1b077585124 100644 |
39 |
--- a/dev-tcltk/tcl3d/tcl3d-0.5.0.ebuild |
40 |
+++ b/dev-tcltk/tcl3d/tcl3d-0.5.0.ebuild |
41 |
@@ -1,4 +1,4 @@ |
42 |
-# Copyright 1999-2016 Gentoo Foundation |
43 |
+# Copyright 1999-2018 Gentoo Foundation |
44 |
# Distributed under the terms of the GNU General Public License v2 |
45 |
|
46 |
EAPI=6 |
47 |
@@ -12,26 +12,25 @@ SRC_URI="http://www.tcl3d.org/download/${P}.distrib/${PN}-src-${PV}.zip" |
48 |
LICENSE="BSD" |
49 |
SLOT="0" |
50 |
KEYWORDS="~amd64 ~x86" |
51 |
-IUSE="debug" |
52 |
+IUSE="debug ode osg sdl truetype" |
53 |
|
54 |
-DEPEND=" |
55 |
- >=dev-lang/swig-1.3.38:0= |
56 |
+RDEPEND="dev-lang/tcl:0= |
57 |
dev-lang/tk:0= |
58 |
- dev-lang/tcl:0= |
59 |
- dev-games/ode |
60 |
- dev-games/openscenegraph |
61 |
- media-libs/libsdl |
62 |
- media-libs/ftgl |
63 |
- virtual/opengl |
64 |
+ x11-libs/libXi |
65 |
x11-libs/libXmu |
66 |
-" |
67 |
+ virtual/opengl |
68 |
+ virtual/glu |
69 |
+ ode? ( dev-games/ode ) |
70 |
+ osg? ( dev-games/openscenegraph ) |
71 |
+ truetype? ( media-libs/ftgl ) |
72 |
+ sdl? ( media-libs/libsdl )" |
73 |
+DEPEND="${RDEPEND} |
74 |
+ >=dev-lang/swig-1.3.38:0=" |
75 |
|
76 |
S="${WORKDIR}/${PN}" |
77 |
PATCHES=( "${FILESDIR}/${P}-include-tk-dir-and-permissive.patch" ) |
78 |
|
79 |
-src_prepare() { |
80 |
- default |
81 |
- |
82 |
+src_configure() { |
83 |
local _TCL_V=( $(echo 'puts [info tclversion]' | tclsh | tr '.' ' ') ) |
84 |
local _TCL_FV="${_TCL_V[0]}.${_TCL_V[1]}" |
85 |
|
86 |
@@ -49,6 +48,13 @@ src_compile() { |
87 |
append-flags -fPIC |
88 |
use debug || append-flags -DNDEBUG |
89 |
|
90 |
+ # Configure wrapper |
91 |
+ local CONFIG_PLUGIN="WRAP_GL2PS=" |
92 |
+ use truetype || CONFIG_PLUGIN+=" WRAP_FTGL=" |
93 |
+ use ode || CONFIG_PLUGIN+=" WRAP_ODE=" |
94 |
+ use osg || CONFIG_PLUGIN+=" WRAP_OSG=" |
95 |
+ use sdl || CONFIG_PLUGIN+=" WRAP_SDL=" |
96 |
+ |
97 |
# Restricting build to -j1 since it seems that if we build it in parallel, |
98 |
# it fails with the "tcl3dOsg" project attempting to import glewdefs.i, |
99 |
# and not finding it. |
100 |
@@ -59,10 +65,7 @@ src_compile() { |
101 |
CC="$(tc-getCC) -c" \ |
102 |
CXX="$(tc-getCXX) -c" \ |
103 |
LD="$(tc-getLD)" \ |
104 |
- WRAP_FTGL=1 \ |
105 |
- WRAP_SDL=1 \ |
106 |
- WRAP_GL2PS=0 \ |
107 |
- WRAP_ODE=1 |
108 |
+ ${CONFIG_PLUGIN} |
109 |
} |
110 |
|
111 |
src_install() { |