/[gentoo-x86]/dev-java/jna/jna-3.2.4.ebuild
Gentoo

Contents of /dev-java/jna/jna-3.2.4.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.6 - (show annotations) (download)
Thu May 3 07:42:50 2012 UTC (2 years, 4 months ago) by jdhore
Branch: MAIN
CVS Tags: HEAD
Changes since 1.5: +2 -2 lines
dev-util/pkgconfig -> virtual/pkgconfig

(Portage version: 2.2.0_alpha101/cvs/Linux i686)

1 # Copyright 1999-2012 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/dev-java/jna/jna-3.2.4.ebuild,v 1.5 2012/03/22 13:27:46 sera Exp $
4
5 EAPI=2
6
7 JAVA_PKG_IUSE="test doc source"
8 WANT_ANT_TASKS="ant-nodeps"
9
10 inherit java-pkg-2 java-ant-2 toolchain-funcs flag-o-matic
11
12 DESCRIPTION="Java Native Access (JNA)"
13 HOMEPAGE="https://jna.dev.java.net/"
14 # repack and mirror
15 #SRC_URI="http://jna.dev.java.net/source/browse/*checkout*/jna/tags/${PV}/jnalib/dist/src.zip"
16 SRC_URI="mirror://gentoo/${P}.tar.bz2"
17 LICENSE="LGPL-2.1"
18 SLOT="0"
19 KEYWORDS="amd64 ppc x86"
20 IUSE=""
21
22 RDEPEND="virtual/libffi
23 >=virtual/jre-1.4"
24
25 DEPEND="virtual/libffi
26 virtual/pkgconfig
27 !test? ( >=virtual/jdk-1.4 )
28 test? (
29 dev-java/junit:0
30 dev-java/ant-junit:0
31 dev-java/ant-trax:0
32 >=virtual/jdk-1.5
33 )"
34
35 JAVA_ANT_REWRITE_CLASSPATH="true"
36
37 java_prepare() {
38 # remove bundled libffi
39 rm -rf native/libffi || die
40
41 # respect CFLAGS, don't inhibit warnings, honour CC
42 epatch "${FILESDIR}/${PV}-makefile-flags.patch"
43
44 sed -i -e '/profiler-build-impl.xml/d' build.xml || die
45 sed -i -e '/clover.jar"/d' build.xml || die
46 sed -i -e 's:,clover.jar::' build.xml || die
47 sed -i -e '/signjar/d' build.xml || die
48
49 # Fetch our own prebuilt libffi.
50 mkdir -p build/native/libffi/.libs || die
51 ln -snf "/usr/$(get_libdir)/libffi.so" \
52 build/native/libffi/.libs/libffi_convenience.a || die
53
54 # Build to same directory on 64-bit archs.
55 ln -snf build build-d64 || die
56 }
57
58 EANT_EXTRA_ARGS="-Ddynlink.native=true"
59
60 src_install() {
61 java-pkg_dojar build/${PN}.jar
62 java-pkg_doso build/native/libjnidispatch.so
63 use source && java-pkg_dosrc src/com
64 use doc && java-pkg_dojavadoc doc/javadoc
65 }
66
67 src_test() {
68 unset DISPLAY
69
70 mkdir -p lib
71 java-pkg_jar-from --into lib --build-only junit
72
73 ANT_TASKS="ant-junit ant-nodeps ant-trax" \
74 ANT_OPTS="-Djava.awt.headless=true" eant \
75 ${EANT_EXTRA_ARGS} test
76 }

  ViewVC Help
Powered by ViewVC 1.1.20