/[gentoo-x86]/dev-lang/v8/v8-3.0.0.1.ebuild
Gentoo

Contents of /dev-lang/v8/v8-3.0.0.1.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.4 - (hide annotations) (download)
Thu Jan 6 10:11:17 2011 UTC (7 years, 7 months ago) by phajdan.jr
Branch: MAIN
CVS Tags: HEAD
Changes since 1.3: +1 -1 lines
FILE REMOVED
Backport an upstream patch that is needed to fix bug #348609 reported by redneb <redneb@gmx.com>.

(Portage version: 2.1.9.25/cvs/Linux i686)

1 phajdan.jr 1.3 # Copyright 1999-2011 Gentoo Foundation
2 phajdan.jr 1.1 # Distributed under the terms of the GNU General Public License v2
3 phajdan.jr 1.4 # $Header: /var/cvsroot/gentoo-x86/dev-lang/v8/v8-3.0.0.1.ebuild,v 1.3 2011/01/02 15:51:34 phajdan.jr Exp $
4 phajdan.jr 1.1
5     EAPI="2"
6    
7     inherit eutils flag-o-matic multilib scons-utils toolchain-funcs
8    
9     DESCRIPTION="Google's open source JavaScript engine"
10     HOMEPAGE="http://code.google.com/p/v8"
11     SRC_URI="mirror://gentoo/${P}.tar.gz"
12     LICENSE="BSD"
13    
14     SLOT="0"
15     KEYWORDS="~amd64 ~arm ~x86"
16     IUSE="readline"
17    
18     RDEPEND="readline? ( >=sys-libs/readline-6.1 )"
19     DEPEND="${RDEPEND}"
20    
21     EXTRA_ESCONS="library=shared soname=on importenv=\"LINKFLAGS\""
22    
23     pkg_setup() {
24     tc-export AR CC CXX RANLIB
25    
26     # Make the build respect LDFLAGS.
27     export LINKFLAGS="${LDFLAGS}"
28     }
29    
30     src_prepare() {
31     # Stop -Werror from breaking the build.
32     epatch "${FILESDIR}"/${PN}-no-werror-r0.patch
33    
34     # Respect the user's CFLAGS, including the optimization level.
35     epatch "${FILESDIR}"/${PN}-no-O3-r0.patch
36    
37 phajdan.jr 1.2 # Fix a compile error (bug #349794), to be upstreamed.
38     epatch "${FILESDIR}"/${PN}-gentoo-bug-349794-r0.patch
39    
40 phajdan.jr 1.1 # Remove a test that is known to fail:
41     # http://groups.google.com/group/v8-users/browse_thread/thread/b8a3f42b5aa18d06
42     rm test/mjsunit/debug-script.js || die
43 phajdan.jr 1.3
44     # Remove a test that behaves differently depending on FEATURES="userpriv",
45     # see bug #348558.
46     rm test/mjsunit/d8-os.js || die
47 phajdan.jr 1.1 }
48    
49     src_configure() {
50     # GCC issues multiple warnings about strict-aliasing issues in v8 code.
51     append-flags -fno-strict-aliasing
52     }
53    
54     src_compile() {
55     local myconf=""
56    
57     # Use target arch detection logic from bug #296917.
58     local myarch="$ABI"
59     [[ $myarch = "" ]] && myarch="$ARCH"
60    
61     if [[ $myarch = amd64 ]] ; then
62     myconf+=" arch=x64"
63     elif [[ $myarch = x86 ]] ; then
64     myconf+=" arch=ia32"
65     elif [[ $myarch = arm ]] ; then
66     myconf+=" arch=arm"
67     else
68     die "Failed to determine target arch, got '$myarch'."
69     fi
70    
71     escons $(use_scons readline console readline dumb) ${myconf} . || die
72     }
73    
74     src_install() {
75     insinto /usr
76     doins -r include || die
77    
78     dobin d8 || die
79    
80     dolib libv8-${PV}.so || die
81     dosym libv8-${PV}.so /usr/$(get_libdir)/libv8.so || die
82    
83     dodoc AUTHORS ChangeLog || die
84     }
85    
86     src_test() {
87     tools/test.py --no-build -p dots --shell d8 || die
88     }

  ViewVC Help
Powered by ViewVC 1.1.20