Skip to content

Commit

Permalink
Move truffle to truffleruby
Browse files Browse the repository at this point in the history
  • Loading branch information
chrisseaton committed Jan 26, 2017
1 parent 2f08d6b commit 008fa07
Show file tree
Hide file tree
Showing 1,129 changed files with 27 additions and 27 deletions.
4 changes: 2 additions & 2 deletions doc/legal/jruby-copying.txt
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,11 @@ The Truffle component also distributes:
truffle-api and truffle-debug (Copyright Oracle and/or its affiliates, GPL
v2, with classpath exception)

Parts of the core library implementation in truffle/src/main/ruby/core
Parts of the core library implementation in truffleruby/src/main/ruby/core
are copyright (c) 2011, Evan Phoenix, and released under the 3-clause BSD
license.

Parts of the core library implementation in truffle/src/main/ruby/core
Parts of the core library implementation in truffleruby/src/main/ruby/core
are copyright (c) 2007-2015, Evan Phoenix and contributors, and released under
the 3-clause BSD license.

Expand Down
2 changes: 1 addition & 1 deletion lib/jruby-truffle-tool/lib/truffle_tool.rb
Original file line number Diff line number Diff line change
Expand Up @@ -657,7 +657,7 @@ def subcommand_run(rest)
end
end

core_load_path = jruby_path.join 'truffle/src/main/ruby'
core_load_path = jruby_path.join 'truffleruby/src/main/ruby'

missing_core_load_path = !File.exists?(core_load_path)
log "Core load path: #{core_load_path} does not exist, fallbacking to --no-use-fs-core" if missing_core_load_path
Expand Down
8 changes: 4 additions & 4 deletions mx.jruby/suite.py
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@ def mavenLib(mavenDep, sha1, sourceSha1, license):
# ------------- Projects -------------

"jruby-truffle": {
"dir": "truffle/src/main",
"dir": "truffleruby/src/main",
"sourceDirs": [ "java" ],
"dependencies": [
"truffle:TRUFFLE_API",
Expand All @@ -178,13 +178,13 @@ def mavenLib(mavenDep, sha1, sourceSha1, license):

"jruby-truffle-ruby": {
"class": "ArchiveProject",
"outputDir": "truffle/src/main/ruby",
"outputDir": "truffleruby/src/main/ruby",
"prefix": "jruby-truffle",
"license": [ "EPL-1.0", "BSD-new" ],
},

"jruby-truffle-test": {
"dir": "truffle/src/test",
"dir": "truffleruby/src/test",
"sourceDirs": ["java"],
"dependencies": [
"jruby-truffle",
Expand All @@ -198,7 +198,7 @@ def mavenLib(mavenDep, sha1, sourceSha1, license):

"jruby-truffle-ruby-test": {
"class": "ArchiveProject",
"outputDir": "truffle/src/test/ruby",
"outputDir": "truffleruby/src/test/ruby",
"prefix": "src/test/ruby",
"license": "EPL-1.0",
},
Expand Down
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<artifactId>truffleruby-parent</artifactId>
<version>0-SNAPSHOT</version>
<modules>
<module>truffle</module>
<module>truffleruby</module>
</modules>
<build>
<defaultGoal>package</defaultGoal>
Expand Down
2 changes: 1 addition & 1 deletion spec/truffle.mspec
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ class MSpecScript
-J-Xmx2G
-Xgraal.warn_unless=false
]
core_path = "#{JRUBY_DIR}/truffle/src/main/ruby"
core_path = "#{JRUBY_DIR}/truffleruby/src/main/ruby"
if File.directory?(core_path)
flags << "-Xcore.load_path=#{core_path}"
flags << "-Xbacktraces.hide_core_files=false"
Expand Down
2 changes: 1 addition & 1 deletion test/check_versions.sh
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,6 @@ check maven/jruby-dist/target/jruby-dist-$jar_version-bin200.tar.gz 20 jruby-$ja
check maven/jruby-dist/target/jruby-dist-$jar_version-src.zip 20 jruby-$jar_version
check maven/jruby-dist/target/jruby-dist-$jar_version-bin.zip 45 jruby-$jar_version
check core/target/jruby-core-$jar_version.jar 9
check truffle/target/jruby-truffle-$jar_version.jar 15
check truffleruby/target/jruby-truffle-$jar_version.jar 15

exit "${failed[0]}"
4 changes: 2 additions & 2 deletions tool/generate-options.rb
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@
)
end

File.write('truffle/src/main/java/org/truffleruby/options/Options.java', ERB.new(<<JAVA).result)
File.write('truffleruby/src/main/java/org/truffleruby/options/Options.java', ERB.new(<<JAVA).result)
/*
* Copyright (c) 2016 Oracle and/or its affiliates. All rights reserved. This
* code is released under a tri EPL/GPL/LGPL license. You can use it,
Expand Down Expand Up @@ -114,7 +114,7 @@
}
JAVA

File.write('truffle/src/main/java/org/truffleruby/options/OptionsCatalog.java', ERB.new(<<JAVA).result)
File.write('truffleruby/src/main/java/org/truffleruby/options/OptionsCatalog.java', ERB.new(<<JAVA).result)
/*
* Copyright (c) 2016 Oracle and/or its affiliates. All rights reserved. This
* code is released under a tri EPL/GPL/LGPL license. You can use it,
Expand Down
2 changes: 1 addition & 1 deletion tool/generate_parser
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ fi

echo "Generating Parser '$PARSER_BASE' w/ YYTable prefix of '$YYTABLE_PREFIX'"

PARSER_DIR=truffle/src/main/java/org/jruby/truffle/parser/parser
PARSER_DIR=truffleruby/src/main/java/org/jruby/truffle/parser/parser

pushd $PARSER_DIR

Expand Down
2 changes: 1 addition & 1 deletion tool/java-coverage/build.xml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
</classfiles>
<sourcefiles encoding="UTF-8">
<fileset dir="../../../core/src/main/java" />
<fileset dir="../../../truffle/src/main/java" />
<fileset dir="../../../truffleruby/src/main/java" />
</sourcefiles>
</structure>
<html destdir="../../../jacoco" />
Expand Down
18 changes: 9 additions & 9 deletions tool/jt.rb
Original file line number Diff line number Diff line change
Expand Up @@ -520,13 +520,13 @@ def build(*options)
no_openssl = options.delete('--no-openssl')
build_ruby_su
unless no_openssl
cextc "#{JRUBY_DIR}/truffle/src/main/c/openssl"
cextc "#{JRUBY_DIR}/truffleruby/src/main/c/openssl"
end
when 'parser'
jay = Utilities.find_repo('jay')
ENV['PATH'] = "#{jay}/src:#{ENV['PATH']}"
sh 'sh', 'tool/generate_parser'
yytables = 'truffle/src/main/java/org/jruby/truffle/parser/parser/YyTables.java'
yytables = 'truffleruby/src/main/java/org/jruby/truffle/parser/parser/YyTables.java'
File.write(yytables, File.read(yytables).gsub('package org.jruby.parser;', 'package org.truffleruby.parser.parser;'))
when 'options'
sh 'tool/generate-options.rb'
Expand Down Expand Up @@ -567,7 +567,7 @@ def run(*args)
end

unless args.delete('--no-core-load-path')
jruby_args << "-Xcore.load_path=#{JRUBY_DIR}/truffle/src/main/ruby"
jruby_args << "-Xcore.load_path=#{JRUBY_DIR}/truffleruby/src/main/ruby"
end

if args.delete('--graal')
Expand Down Expand Up @@ -672,8 +672,8 @@ def build_ruby_su(cext_dir=nil)
abort "You need to set SULONG_HOME" unless SULONG_HOME

# Ensure ruby.su is up-to-date
ruby_cext_api = "#{JRUBY_DIR}/truffle/src/main/c/cext"
ruby_c = "#{JRUBY_DIR}/truffle/src/main/c/cext/ruby.c"
ruby_cext_api = "#{JRUBY_DIR}/truffleruby/src/main/c/cext"
ruby_c = "#{JRUBY_DIR}/truffleruby/src/main/c/cext/ruby.c"
ruby_h = "#{JRUBY_DIR}/lib/cext/ruby.h"
ruby_su = "#{JRUBY_DIR}/lib/cext/ruby.su"
if cext_dir != ruby_cext_api and (newer?(ruby_h, ruby_su) or newer?(ruby_c, ruby_su))
Expand All @@ -686,14 +686,14 @@ def build_ruby_su(cext_dir=nil)
def cextc(cext_dir, test_gem=false, *clang_opts)
build_ruby_su(cext_dir)

is_ruby = cext_dir == "#{JRUBY_DIR}/truffle/src/main/c/cext"
is_ruby = cext_dir == "#{JRUBY_DIR}/truffleruby/src/main/c/cext"
gem_name = if is_ruby
"ruby"
else
File.basename(cext_dir)
end

gem_dir = if cext_dir.start_with?("#{JRUBY_DIR}/truffle/src/main/c")
gem_dir = if cext_dir.start_with?("#{JRUBY_DIR}/truffleruby/src/main/c")
cext_dir
elsif test_gem
"#{JRUBY_DIR}/test/truffle/cexts/#{gem_name}/ext/#{gem_name}/"
Expand All @@ -704,8 +704,8 @@ def cextc(cext_dir, test_gem=false, *clang_opts)
end
copy_target = if is_ruby
"#{JRUBY_DIR}/lib/cext/ruby.su"
elsif cext_dir == "#{JRUBY_DIR}/truffle/src/main/c/openssl"
"#{JRUBY_DIR}/truffle/src/main/c/openssl/openssl.su"
elsif cext_dir == "#{JRUBY_DIR}/truffleruby/src/main/c/openssl"
"#{JRUBY_DIR}/truffleruby/src/main/c/openssl/openssl.su"
else
"#{JRUBY_DIR}/test/truffle/cexts/#{gem_name}/lib/#{gem_name}/#{gem_name}.su"
end
Expand Down
2 changes: 1 addition & 1 deletion tool/missing-copyright-info.rb
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
failures = false

Dir.glob('truffle/**/*').each do |file|
next if file.start_with? 'truffle/target/generated-sources'
next if file.start_with? 'truffleruby/target/generated-sources'
next if file == 'truffle/pom.rb'
if file =~ /.*\.(rb|java)/
lines = IO.readlines(file)
Expand Down
6 changes: 3 additions & 3 deletions tool/update_copyright.rb
Original file line number Diff line number Diff line change
Expand Up @@ -49,19 +49,19 @@
]

truffle_paths = %w[
truffle/src
truffleruby/src
test/truffle
spec/
] + [__FILE__]

excludes = %w[
test/truffle/pack-real-usage.rb
test/truffle/cexts
truffle/src/main/c/openssl
truffleruby/src/main/c/openssl
]

# Until those all have copyright headers
excludes << "truffle/src/main/java/org/jruby/truffle/parser"
excludes << "truffleruby/src/main/java/org/jruby/truffle/parser"

truffle_paths.each do |path|
puts "WARNING: incorrect path #{path}" unless File.exist? path
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Loading

0 comments on commit 008fa07

Please sign in to comment.