Skip to content

Commit 8a1ede8

Browse files
committed
Remove java 8 logic for building javac command-line
1 parent 1df8df4 commit 8a1ede8

File tree

1 file changed

+5
-11
lines changed

1 file changed

+5
-11
lines changed

Rakefile

Lines changed: 5 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -262,18 +262,12 @@ if defined? JRUBY_VERSION
262262
end
263263

264264
classpath = []
265-
[ 'java.class.path', 'sun.boot.class.path' ].map { |key| ENV_JAVA[key] }.each do |v|
266-
classpath += v.split(File::PATH_SEPARATOR).find_all { |jar| jar =~ /jruby/i } if v
265+
require 'rbconfig'
266+
libdir = RbConfig::CONFIG['libdir']
267+
if libdir.start_with? 'classpath:'
268+
error "Cannot build activerecord-jdbc with jruby-complete"
267269
end
268-
# Using Java 9+. Let's try and infer jruby.jar location from rbconfig
269-
if classpath.empty?; require 'rbconfig'
270-
libdir = RbConfig::CONFIG['libdir']
271-
if libdir.start_with? 'classpath:'
272-
error "Cannot build activerecord-jdbc with jruby-complete"
273-
end
274-
classpath << File.join(libdir, 'jruby.jar')
275-
end
276-
270+
classpath << File.join(libdir, 'jruby.jar')
277271
classpath += driver_jars
278272
classpath = classpath.compact.join(File::PATH_SEPARATOR)
279273

0 commit comments

Comments
 (0)