Gentoo Archives: gentoo-commits

From: "Alistair Bush (ali_bush)" <ali_bush@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in dev-lang/scala: ChangeLog scala-2.7.4-r1.ebuild
Date: Fri, 01 May 2009 07:44:42
Message-Id: E1LznQF-0008Tw-FY@stork.gentoo.org
1 ali_bush 09/05/01 07:44:39
2
3 Modified: ChangeLog
4 Added: scala-2.7.4-r1.ebuild
5 Log:
6 Version bump again.
7 (Portage version: 2.1.6.11/cvs/Linux x86_64)
8
9 Revision Changes Path
10 1.16 dev-lang/scala/ChangeLog
11
12 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-lang/scala/ChangeLog?rev=1.16&view=markup
13 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-lang/scala/ChangeLog?rev=1.16&content-type=text/plain
14 diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-lang/scala/ChangeLog?r1=1.15&r2=1.16
15
16 Index: ChangeLog
17 ===================================================================
18 RCS file: /var/cvsroot/gentoo-x86/dev-lang/scala/ChangeLog,v
19 retrieving revision 1.15
20 retrieving revision 1.16
21 diff -u -r1.15 -r1.16
22 --- ChangeLog 30 Apr 2009 19:29:39 -0000 1.15
23 +++ ChangeLog 1 May 2009 07:44:39 -0000 1.16
24 @@ -1,6 +1,11 @@
25 # ChangeLog for dev-lang/scala
26 # Copyright 1999-2009 Gentoo Foundation; Distributed under the GPL v2
27 -# $Header: /var/cvsroot/gentoo-x86/dev-lang/scala/ChangeLog,v 1.15 2009/04/30 19:29:39 ali_bush Exp $
28 +# $Header: /var/cvsroot/gentoo-x86/dev-lang/scala/ChangeLog,v 1.16 2009/05/01 07:44:39 ali_bush Exp $
29 +
30 +*scala-2.7.4-r1 (01 May 2009)
31 +
32 + 01 May 2009; Alistair Bush <ali_bush@g.o> +scala-2.7.4-r1.ebuild:
33 + Bump scala again. this time based on 2.7.3-r1.
34
35 *scala-2.7.4 (30 Apr 2009)
36
37
38
39
40 1.1 dev-lang/scala/scala-2.7.4-r1.ebuild
41
42 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-lang/scala/scala-2.7.4-r1.ebuild?rev=1.1&view=markup
43 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-lang/scala/scala-2.7.4-r1.ebuild?rev=1.1&content-type=text/plain
44
45 Index: scala-2.7.4-r1.ebuild
46 ===================================================================
47 # Copyright 1999-2009 Gentoo Foundation
48 # Distributed under the terms of the GNU General Public License v2
49 # $Header: /var/cvsroot/gentoo-x86/dev-lang/scala/scala-2.7.4-r1.ebuild,v 1.1 2009/05/01 07:44:39 ali_bush Exp $
50
51 JAVA_PKG_IUSE="doc examples source"
52 WANT_ANT_TASKS="ant-nodeps"
53 inherit eutils check-reqs java-pkg-2 java-ant-2 versionator
54
55 MY_P="${P}.final-sources"
56
57 # creating the binary:
58 # JAVA_PKG_FORCE_VM="$available-1.5" USE="doc examples source" ebuild scala-*.ebuild compile
59 # cd $WORDKIR
60 # fix dist/latest link.
61 # tar -cjf $DISTDIR/scala-$PN-gentoo-binary.tar.bz2 ${MY_P}/dists ${MY_P}/docs/TODO
62
63 DESCRIPTION="The Scala Programming Language"
64 HOMEPAGE="http://www.scala-lang.org/"
65 SRC_URI="!binary? ( http://www.scala-lang.org/downloads/distrib/files/${MY_P}.tgz )
66 binary? ( mirror://gentoo/${P}-gentoo-binary.tar.bz2 )"
67 LICENSE="BSD"
68 SLOT="0"
69 KEYWORDS="~amd64 ~x86"
70 IUSE="binary emacs"
71 # one fails with 1.7, two with 1.4 (blackdown)
72 RESTRICT="test"
73
74 DEPEND=">=virtual/jdk-1.5
75 !binary? (
76 dev-java/ant-contrib
77 dev-java/jline
78 )"
79 RDEPEND=">=virtual/jre-1.5
80 dev-java/jline
81 !dev-java/scala-bin"
82
83 PDEPEND="emacs? ( app-emacs/scala-mode )"
84
85 S="${WORKDIR}/${MY_P}"
86
87 pkg_setup() {
88 java-pkg-2_pkg_setup
89
90 if ! use binary; then
91 debug-print "Checking for sufficient physical RAM"
92
93 ewarn "This package can fail to build with memory allocation errors in some cases."
94 ewarn "If you are unable to build from sources, please try USE=binary"
95 ewarn "for this package. See bug #181390 for more information."
96 ebeep 3
97 epause 5
98
99 if use amd64; then
100 CHECKREQS_MEMORY="1024"
101 else
102 CHECKREQS_MEMORY="512"
103 fi
104
105 check_reqs
106 fi
107 }
108
109 src_unpack() {
110 unpack ${A}
111 cd "${S}"
112
113 if ! use binary; then
114
115 epatch "${FILESDIR}/${PN}-2.7.3-build.xml.patch"
116
117 cd lib || die
118 # other jars are needed for bootstrap
119 rm -v jline.jar #cldcapi10.jar midpapi10.jar msil.jar *.dll || die
120 java-pkg_jar-from --build-only ant-contrib
121 java-pkg_jar-from jline
122 fi
123 }
124
125 src_compile() {
126 if ! use binary; then
127 eant all.clean dist.done
128 else
129 einfo "Skipping compilation, USE=binary is set."
130 fi
131 }
132
133 src_test() {
134 eant test.suite || die "Some tests aren't passed"
135 }
136
137 scala_launcher() {
138 local SCALADIR="/usr/share/${PN}"
139 local bcp="${SCALADIR}/lib/scala-library.jar"
140 java-pkg_dolauncher "${1}" --main "${2}" \
141 --java_args "-Xmx256M -Xms32M -Dscala.home=\\\"${SCALADIR}\\\" -Denv.emacs=\\\"\${EMACS}\\\""
142 }
143
144 src_install() {
145 cd dists/latest || die
146
147 local SCALADIR="/usr/share/${PN}/"
148
149 #sources are .scala so no use for java-pkg_dosrc
150 if use source; then
151 dodir "${SCALADIR}/src"
152 insinto "${SCALADIR}/src"
153 doins src/*-src.jar
154 fi
155
156 java-pkg_dojar lib/*.jar
157 use binary && java-pkg_register-dependency jline
158
159 doman man/man1/*.1 || die
160
161 local docdir="doc/${PN}-devel-docs"
162 dodoc doc/README ../../docs/TODO || die
163 if use doc; then
164 java-pkg_dojavadoc "${docdir}/api"
165 dohtml -r "${docdir}/tools" || die
166 fi
167
168 use examples && java-pkg_doexamples "${docdir}/examples"
169
170 scala_launcher fsc scala.tools.nsc.CompileClient
171 scala_launcher scala scala.tools.nsc.MainGenericRunner
172 scala_launcher scalac scala.tools.nsc.Main
173 scala_launcher scaladoc scala.tools.nsc.ScalaDoc
174 }