/[gentoo-x86]/media-gfx/freewrl/freewrl-1.22.10.ebuild
Gentoo

Contents of /media-gfx/freewrl/freewrl-1.22.10.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.5 - (hide annotations) (download)
Thu Jul 28 16:44:09 2011 UTC (9 years ago) by patrick
Branch: MAIN
CVS Tags: HEAD
Changes since 1.4: +1 -1 lines
FILE REMOVED
Remove old

(Portage version: 2.2.0_alpha47/cvs/Linux x86_64)

1 ssuominen 1.2 # Copyright 1999-2011 Gentoo Foundation
2 patrick 1.1 # Distributed under the terms of the GNU General Public License v2
3 patrick 1.5 # $Header: /var/cvsroot/gentoo-x86/media-gfx/freewrl/freewrl-1.22.10.ebuild,v 1.4 2011/04/02 14:29:43 ssuominen Exp $
4 patrick 1.1
5     EAPI="2"
6    
7     inherit nsplugins eutils flag-o-matic java-pkg-opt-2
8    
9     DESCRIPTION="VRML2 and X3D compliant browser"
10     SRC_URI="mirror://sourceforge/freewrl/${P}.tar.bz2"
11     HOMEPAGE="http://freewrl.sourceforge.net/"
12    
13     LICENSE="GPL-3"
14     SLOT="0"
15     KEYWORDS="~amd64 ~x86"
16 ssuominen 1.4 IUSE="curl debug libeai +glew +java +motif nsplugin +sox spidermonkey static-libs"
17 patrick 1.1
18     COMMONDEPEND="x11-libs/libXau
19     x11-libs/libXdmcp
20     x11-libs/libXext
21     x11-libs/libX11
22     motif? ( x11-libs/openmotif )
23     media-libs/mesa
24     glew? ( media-libs/glew )
25     virtual/opengl
26     media-libs/libpng
27 ssuominen 1.2 virtual/jpeg
28 patrick 1.1 media-libs/imlib2
29     >=media-libs/freetype-2
30     media-libs/fontconfig
31     curl? ( net-misc/curl )
32 patrick 1.3 !spidermonkey? ( <net-libs/xulrunner-2.0 )
33 patrick 1.1 spidermonkey? ( dev-lang/spidermonkey )
34     nsplugin? ( || (
35 patrick 1.3 <net-libs/xulrunner-2.0
36 patrick 1.1 www-client/firefox
37     ) )"
38     DEPEND="${COMMONDEPEND}
39     >=dev-util/pkgconfig-0.22
40     java? ( >=virtual/jdk-1.4 )"
41     RDEPEND="${COMMONDEPEND}
42     media-fonts/dejavu
43     || ( media-gfx/imagemagick
44     media-gfx/graphicsmagick[imagemagick] )
45     app-arch/unzip
46     java? ( >=virtual/jre-1.4 )
47     sox? ( media-sound/sox )"
48    
49     src_prepare() {
50     # A hack to get around expat being grabbed from xulrunner
51     mkdir "${S}/src/lib/include";
52     cp /usr/include/expat.h "${S}/src/lib/include/";
53     cp /usr/include/expat_external.h "${S}/src/lib/include/";
54     }
55    
56     src_configure() {
57     local myconf="--enable-fontconfig
58     --with-imageconvert=/usr/bin/convert
59     --with-unzip=/usr/bin/unzip"
60     if use motif; then
61     myconf="${myconf} --with-x --with-target=motif"
62     else
63     myconf="${myconf} --with-x --with-target=x11"
64     fi
65     if use nsplugin; then
66     myconf="${myconf} --with-plugindir=/usr/$(get_libdir)/${PLUGINS_DIR}"
67     fi
68     if use sox; then
69     myconf="${myconf} --with-soundconv=/usr/bin/sox"
70     fi
71     if use spidermonkey; then
72     # disable the checks for other js libs, in case they are installed
73     myconf="${myconf} --disable-mozilla-js --disable-xulrunner-js --disable-firefox-js --disable-seamonkey-js"
74     # spidermonkey has no pkg-config, so override ./configure
75     JAVASCRIPT_ENGINE_CFLAGS="-I/usr/include/js -DXP_UNIX"
76     JAVASCRIPT_ENGINE_LIBS="-ljs"
77     if has_version dev-lang/spidermonkey[threadsafe] ; then
78     JAVASCRIPT_ENGINE_CFLAGS="${JAVASCRIPT_ENGINE_CFLAGS} -DJS_THREADSAFE $(pkg-config --cflags nspr)"
79     JAVASCRIPT_ENGINE_LIBS="$(pkg-config --libs nspr) ${JAVASCRIPT_ENGINE_LIBS}"
80     fi
81     export JAVASCRIPT_ENGINE_CFLAGS
82     export JAVASCRIPT_ENGINE_LIBS
83     else
84     # more hack to get around expat being grabbed from xulrunner
85     myconf="${myconf} --with-expat=${S}/src/lib"
86     fi
87     econf ${myconf} \
88     $(use_enable curl libcurl) \
89     $(use_with glew) \
90     $(use_enable debug) $(use_enable debug thread_colorized) \
91     $(use_enable libeai) \
92     $(use_enable java) \
93     $(use_enable nsplugin plugin) \
94 ssuominen 1.4 $(use_enable static-libs static) \
95 patrick 1.1 $(use_enable sox sound)
96     }
97    
98     src_install() {
99     emake DESTDIR="${D}" install || die "emake install failed"
100    
101     if use java; then
102     java-pkg_dojar src/java/vrml.jar
103     insinto /usr/share/${PN}/lib
104     doins src/java/java.policy
105     elog "Because vrml.jar requires access to sockets, you will need to incorporate the"
106     elog "contents of /usr/share/${PN}/lib/java.policy into your system or user's default"
107     elog "java policy."
108     fi
109    
110     # remove unneeded .la files (as per Flameeyes' rant)
111     cd "${D}"
112     rm "usr/$(get_libdir)"/*.la "usr/$(get_libdir)/${PLUGINS_DIR}"/*.la
113     }

  ViewVC Help
Powered by ViewVC 1.1.20