1 |
flameeyes 10/08/22 15:14:11 |
2 |
|
3 |
Modified: ChangeLog |
4 |
Added: jruby-1.5.2.ebuild |
5 |
Removed: jruby-1.4.1-r1.ebuild jruby-1.5.1-r2.ebuild |
6 |
Log: |
7 |
Version bump to fix the Webrick security issue; remove non-stable-candidate vulnerable ebuilds. |
8 |
(Portage version: 2.2_rc67/cvs/Linux x86_64) |
9 |
|
10 |
Revision Changes Path |
11 |
1.68 dev-java/jruby/ChangeLog |
12 |
|
13 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-java/jruby/ChangeLog?rev=1.68&view=markup |
14 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-java/jruby/ChangeLog?rev=1.68&content-type=text/plain |
15 |
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-java/jruby/ChangeLog?r1=1.67&r2=1.68 |
16 |
|
17 |
Index: ChangeLog |
18 |
=================================================================== |
19 |
RCS file: /var/cvsroot/gentoo-x86/dev-java/jruby/ChangeLog,v |
20 |
retrieving revision 1.67 |
21 |
retrieving revision 1.68 |
22 |
diff -u -r1.67 -r1.68 |
23 |
--- ChangeLog 30 Jun 2010 20:53:35 -0000 1.67 |
24 |
+++ ChangeLog 22 Aug 2010 15:14:11 -0000 1.68 |
25 |
@@ -1,6 +1,13 @@ |
26 |
# ChangeLog for dev-java/jruby |
27 |
# Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2 |
28 |
-# $Header: /var/cvsroot/gentoo-x86/dev-java/jruby/ChangeLog,v 1.67 2010/06/30 20:53:35 caster Exp $ |
29 |
+# $Header: /var/cvsroot/gentoo-x86/dev-java/jruby/ChangeLog,v 1.68 2010/08/22 15:14:11 flameeyes Exp $ |
30 |
+ |
31 |
+*jruby-1.5.2 (22 Aug 2010) |
32 |
+ |
33 |
+ 22 Aug 2010; Diego E. Pettenò <flameeyes@g.o> |
34 |
+ -jruby-1.4.1-r1.ebuild, -jruby-1.5.1-r2.ebuild, +jruby-1.5.2.ebuild: |
35 |
+ Version bump to fix the Webrick security issue; remove |
36 |
+ non-stable-candidate vulnerable ebuilds. |
37 |
|
38 |
30 Jun 2010; Vlastimil Babka <caster@g.o> jruby-1.3.1-r1.ebuild, |
39 |
-jruby-1.4.0-r6.ebuild: |
40 |
|
41 |
|
42 |
|
43 |
1.1 dev-java/jruby/jruby-1.5.2.ebuild |
44 |
|
45 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-java/jruby/jruby-1.5.2.ebuild?rev=1.1&view=markup |
46 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-java/jruby/jruby-1.5.2.ebuild?rev=1.1&content-type=text/plain |
47 |
|
48 |
Index: jruby-1.5.2.ebuild |
49 |
=================================================================== |
50 |
# Copyright 1999-2010 Gentoo Foundation |
51 |
# Distributed under the terms of the GNU General Public License v2 |
52 |
# $Header: /var/cvsroot/gentoo-x86/dev-java/jruby/jruby-1.5.2.ebuild,v 1.1 2010/08/22 15:14:11 flameeyes Exp $ |
53 |
|
54 |
EAPI="2" |
55 |
JAVA_PKG_IUSE="doc source test" |
56 |
inherit eutils java-pkg-2 java-ant-2 |
57 |
|
58 |
MY_PV="${PV/_rc1/RC1}" |
59 |
|
60 |
DESCRIPTION="Java-based Ruby interpreter implementation" |
61 |
HOMEPAGE="http://jruby.codehaus.org/" |
62 |
SRC_URI="http://jruby.org.s3.amazonaws.com/downloads/${PV}/${PN}-src-${PV}.tar.gz" |
63 |
LICENSE="|| ( CPL-1.0 GPL-2 LGPL-2.1 )" |
64 |
SLOT="0" |
65 |
KEYWORDS="~amd64 ~x86" |
66 |
IUSE="bsf ssl" |
67 |
|
68 |
CDEPEND=">=dev-java/bytelist-1.0.6:0 |
69 |
>=dev-java/constantine-0.6:0 |
70 |
>=dev-java/jline-0.9.94:0 |
71 |
>=dev-java/joni-1.1.3:0 |
72 |
>=dev-java/jnr-posix-1.1.3:0 |
73 |
>=dev-java/jnr-netdb-1.0:0 |
74 |
>=dev-java/jvyamlb-0.2.5:0 |
75 |
>=dev-java/asm-3.2:3 |
76 |
dev-java/jcodings:0 |
77 |
>=dev-java/jffi-0.7_pre:0.4 |
78 |
dev-java/joda-time:0 |
79 |
dev-util/jay:0[java] |
80 |
dev-java/nailgun:0 |
81 |
dev-java/jaffl:0 |
82 |
dev-java/jgrapht:0 |
83 |
dev-java/ant-core:0 |
84 |
dev-java/bsf:2.3" |
85 |
|
86 |
RDEPEND="${CDEPEND} |
87 |
>=virtual/jre-1.6" |
88 |
|
89 |
DEPEND="${CDEPEND} |
90 |
>=virtual/jdk-1.6 |
91 |
test? ( |
92 |
dev-java/ant-junit4:0 |
93 |
dev-java/ant-trax:0 |
94 |
dev-java/junit:4 |
95 |
java-virtuals/jdk-with-com-sun |
96 |
dev-java/commons-logging:0 |
97 |
dev-java/xalan:0 |
98 |
>=dev-java/jna-posix-1.0.1:0 |
99 |
) |
100 |
!!<dev-ruby/jruby-1.3.1-r1" |
101 |
|
102 |
PDEPEND="ssl? ( dev-ruby/jruby-openssl )" |
103 |
|
104 |
# Tests fail. |
105 |
# Need to stop injecting jar's into classpath. |
106 |
RESTRICT="test" |
107 |
|
108 |
S="${WORKDIR}/${PN}-${MY_PV}" |
109 |
|
110 |
RUBY_HOME=/usr/share/${PN}/lib/ruby |
111 |
SITE_RUBY=${RUBY_HOME}/site_ruby |
112 |
GEMS=${RUBY_HOME}/gems |
113 |
|
114 |
JAVA_ANT_REWRITE_CLASSPATH="true" |
115 |
JAVA_ANT_IGNORE_SYSTEM_CLASSES="true" |
116 |
EANT_GENTOO_CLASSPATH="ant-core asm-3 bsf-2.3 bytelist constantine jay \ |
117 |
jcodings jffi-0.4 jline constantine \ |
118 |
joda-time joni jnr-posix jnr-netdb jvyamlb nailgun jaffl jgrapht" |
119 |
EANT_NEEDS_TOOLS="true" |
120 |
|
121 |
pkg_setup() { |
122 |
java-pkg-2_pkg_setup |
123 |
|
124 |
local fail |
125 |
|
126 |
for directory in "${GEMS}" "${SITE_RUBY}"; do |
127 |
if [[ -L ${directory} ]]; then |
128 |
eerror "${directory} is a symlink. Please do the following to resolve the situation:" |
129 |
echo 'emerge -an app-portage/gentoolkit' |
130 |
echo 'equery -qC b '"${directory}"' | sort | uniq | sed s/^/=/ > ~/jruby.fix' |
131 |
echo 'emerge -1C $(< ~/jruby.fix)' |
132 |
echo "rm ${directory}" |
133 |
echo 'emerge -1 $(< ~/jruby.fix)' |
134 |
echo 'rm ~/jruby.fix' |
135 |
|
136 |
eerror "For more information, please see http://bugs.gentoo.org/show_bug.cgi?id=302187" |
137 |
fail="true" |
138 |
fi |
139 |
done |
140 |
|
141 |
if [[ -n ${fail} ]]; then |
142 |
die "Please address the above errors, then run emerge --resume" |
143 |
fi |
144 |
} |
145 |
|
146 |
java_prepare() { |
147 |
epatch "${FILESDIR}"/${PN}-1.5.0-system-jars.patch |
148 |
epatch "${FILESDIR}/1.5.1/build.xml.patch" |
149 |
epatch "${FILESDIR}/1.5.1/testfixes.patch" |
150 |
|
151 |
# We don't need to use Retroweaver. There is a jarjar and a regular jar |
152 |
# target but even with jarjarclean, both are a pain. The latter target |
153 |
# is slightly easier so go with this one. |
154 |
sed -r -i \ |
155 |
-e 's/maxmemory="128m"/maxmemory="192m"/' \ |
156 |
-e "/RetroWeaverTask/d" \ |
157 |
-e "/<zipfileset .+\/>/d" \ |
158 |
build.xml || die |
159 |
|
160 |
sed -i -e '/Arndt/d' src/org/jruby/RubyBigDecimal.java |
161 |
|
162 |
# Delete the bundled JARs but keep invokedynamic.jar. |
163 |
# No source is available and it's only a dummy anyway. |
164 |
find build_lib -name "*.jar" ! -name "jsr292-mock.jar" -delete || die |
165 |
rm lib/profile.jar || die |
166 |
|
167 |
# change some defaults for Gentoo to work properly |
168 |
cat - >> src/org/jruby/jruby.properties <<EOF |
169 |
jruby.bindir = /usr/bin |
170 |
EOF |
171 |
} |
172 |
|
173 |
src_compile() { |
174 |
local flags="" |
175 |
use bsf && flags="-Dbsf.present=true" |
176 |
|
177 |
eant jar $(use_doc apidocs) -Djdk1.5+=true ${flags} |
178 |
} |
179 |
|
180 |
src_test() { |
181 |
if [ ${UID} == 0 ] ; then |
182 |
ewarn 'The tests will fail if run as root so skipping them.' |
183 |
ewarn 'Enable FEATURES="userpriv" if you want to run them.' |
184 |
return |
185 |
fi |
186 |
# Our jruby.jar is unbundled so we need to add the classpath to this test. |
187 |
sed -i "s:java -jar:java -Xbootclasspath/a\:#{ENV['JRUBY_CP']} -jar:g" test/test_load_compiled_ruby_class_from_classpath.rb || die |
188 |
sed -i "s@:refid => 'build.classpath'@:path =>\"#{ENV['JRUBY_CP']}:lib/jruby.jar\"@g" \ |
189 |
rakelib/commands.rake || die |
190 |
#sed -i "s@:refid => 'test.class.path'@:path => \"#{ENV['JRUBY_CP']}@g" \ |
191 |
# rakelib/commands.rake || die |
192 |
|
193 |
#bsf optionally depends on jruby, which means that the previously |
194 |
#installed jruby will be added to classpath, nasty things will happen. |
195 |
local cpath=`java-pkg_getjars ${EANT_GENTOO_CLASSPATH// /,},junit-4` |
196 |
cpath="$(echo ${cpath} | sed -e "s_${ROOT}/usr/share/jruby/lib/jruby.jar:__g")" |
197 |
cpath="${cpath}:$(java-pkg_getjars --build-only commons-logging,xalan)" |
198 |
EANT_GENTOO_CLASSPATH="" |
199 |
|
200 |
local flags="" |
201 |
use bsf && flags="-Dbsf.present=true" |
202 |
|
203 |
#Clear RUBYOPT |
204 |
export RUBYOPT="" |
205 |
export JRUBY_CP="${cpath}" |
206 |
ANT_TASKS="ant-junit4 ant-trax" \ |
207 |
JRUBY_OPTS="" eant test -Djdk1.5+=true -Djruby.bindir=bin \ |
208 |
-Dgentoo.classpath="${cpath}" ${flags} |
209 |
} |
210 |
|
211 |
src_install() { |
212 |
local bin |
213 |
|
214 |
java-pkg_dojar lib/${PN}.jar |
215 |
dodoc README docs/{*.txt,README.*} || die |
216 |
|
217 |
use doc && java-pkg_dojavadoc docs/api |
218 |
use source && java-pkg_dosrc src/org |
219 |
|
220 |
# We run the sed here in install so that we don't get the wrong |
221 |
# data during the test phase! |
222 |
sed \ |
223 |
-e '/++ebuild-cut-here++/, /--ebuild-cut-here--/ d' \ |
224 |
-e '/^JRUBY_HOME=/s:=:=/usr/share/jruby:' \ |
225 |
bin/jruby > "${T}"/jruby |
226 |
|
227 |
dobin "${T}"/jruby "${S}"/bin/j{irb{,_swing},rubyc} || die |
228 |
|
229 |
insinto "${RUBY_HOME}" |
230 |
doins -r "${S}"/lib/ruby/{1.8,1.9,site_ruby} || die |
231 |
|
232 |
# Remove all the references to RubyGems as we're just going to |
233 |
# install it through dev-ruby/rubygems. |
234 |
find "${D}${RUBY_HOME}" -type f \ |
235 |
'(' '(' -path '*rubygems*' -not -name 'jruby.rb' ')' -or -name 'ubygems.rb' -or -name 'datadir.rb' ')' \ |
236 |
-delete || die |
237 |
} |
238 |
|
239 |
pkg_postinst() { |
240 |
ewarn "If you're updating from <=jruby-1.4.0, you're going to get errors related" |
241 |
ewarn "to gentoo.rb load failure." |
242 |
ewarn "This is due to a stray definition of JRUBY_OPTS variable from the previous ebuilds." |
243 |
ewarn "To solve the problem, either login in a new shell, use 'env -i ${SHELL} --login'" |
244 |
ewarn "or explicitly unset the variable before running jruby." |
245 |
} |