Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: jruby/jruby
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: b03e121b6d9e
Choose a base ref
...
head repository: jruby/jruby
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: aa596f445842
Choose a head ref
  • 7 commits
  • 49 files changed
  • 1 contributor

Commits on Mar 19, 2015

  1. create usual bin archive as well one where jar files are pack200 comp…

    …ressed
    
    added bin/unpack200.sh which can be used to unpack all the jar files after
    extracting the archive
    mkristian committed Mar 19, 2015
    Copy the full SHA
    d580ce3 View commit details
  2. added check of file size of distribtion artifacts

    granularity is 1M so if things fail is either because natural growth or
    something happened again which let the filesize explode.
    mkristian committed Mar 19, 2015
    Copy the full SHA
    e366b85 View commit details
  3. [build] generated pom.xml

    mkristian committed Mar 19, 2015
    Copy the full SHA
    8ae788d View commit details
  4. consolidated overall amount of artifacts

    no more jruby-core:noasm and jruby-core:complete attached artifacts, they
    were too complicated to be used properly.
    
    the jruby-core will have the asm + jnr-jffi (which uses asm) shaded into the jar
    
    no need for maven/jruby-noasm anymore
    
    added bin/jruby200.sh which is bin/jruby in jruby-bin200.tar.gz and this
    script will unpack all jars and then replace itself with bin/jruby.bash. i.e.
    the first call of bin/jruby will first finish the installation and then
    execute bin/jruby.bash. any further bin/jruby execution is as usual.
    
    the patch also reduces the total amount of distributed artifacts by a couple
    of MB
    mkristian committed Mar 19, 2015
    4
    Copy the full SHA
    bd59418 View commit details
  5. [build] cleanup

    mkristian committed Mar 19, 2015
    Copy the full SHA
    74e8a0e View commit details
  6. Copy the full SHA
    f381ec5 View commit details
  7. Copy the full SHA
    aa596f4 View commit details
Showing with 407 additions and 1,519 deletions.
  1. +11 −26 core/pom.rb
  2. +27 −458 core/pom.xml
  3. +0 −6 jruby.bnd.template
  4. +78 −10 lib/pom.rb
  5. +87 −18 lib/pom.xml
  6. BIN {maven/jruby-noasm → lib}/src/empty.jar
  7. +0 −17 maven/.project
  8. +0 −2 maven/.settings/org.eclipse.core.resources.prefs
  9. +0 −4 maven/.settings/org.eclipse.m2e.core.prefs
  10. +0 −23 maven/jruby-complete/.project
  11. +0 −2 maven/jruby-complete/.settings/org.eclipse.core.resources.prefs
  12. +0 −4 maven/jruby-complete/.settings/org.eclipse.m2e.core.prefs
  13. +1 −7 maven/jruby-complete/pom.rb
  14. +0 −29 maven/jruby-complete/pom.xml
  15. +0 −17 maven/jruby-dist/.project
  16. +0 −2 maven/jruby-dist/.settings/org.eclipse.core.resources.prefs
  17. +0 −4 maven/jruby-dist/.settings/org.eclipse.m2e.core.prefs
  18. +30 −47 maven/jruby-dist/pom.rb
  19. +32 −70 maven/jruby-dist/pom.xml
  20. +39 −0 maven/jruby-dist/src/main/assembly/bin.xml
  21. +45 −0 maven/jruby-dist/src/main/assembly/bin200.xml
  22. +9 −12 maven/jruby-dist/src/main/assembly/{jruby.xml → common.xml}
  23. +2 −2 maven/jruby-jars/Mavenfile
  24. +6 −1 maven/jruby-jars/pom.xml
  25. +0 −26 maven/jruby-noasm/.classpath
  26. +0 −23 maven/jruby-noasm/.project
  27. +0 −2 maven/jruby-noasm/.settings/org.eclipse.core.resources.prefs
  28. +0 −5 maven/jruby-noasm/.settings/org.eclipse.jdt.core.prefs
  29. +0 −4 maven/jruby-noasm/.settings/org.eclipse.m2e.core.prefs
  30. +0 −39 maven/jruby-noasm/pom.rb
  31. +0 −69 maven/jruby-noasm/pom.xml
  32. +0 −3 maven/jruby-noasm/src/it/integrity/invoker.properties
  33. +0 −164 maven/jruby-noasm/src/it/integrity/pom.xml
  34. +0 −45 maven/jruby-noasm/src/it/integrity/verify.bsh
  35. +0 −35 maven/jruby-noasm/src/it/settings.xml
  36. +0 −26 maven/jruby-stdlib/.classpath
  37. +0 −23 maven/jruby-stdlib/.project
  38. +0 −2 maven/jruby-stdlib/.settings/org.eclipse.core.resources.prefs
  39. +0 −5 maven/jruby-stdlib/.settings/org.eclipse.jdt.core.prefs
  40. +0 −4 maven/jruby-stdlib/.settings/org.eclipse.m2e.core.prefs
  41. +0 −101 maven/jruby-stdlib/pom.rb
  42. +0 −126 maven/jruby-stdlib/pom.xml
  43. BIN maven/jruby-stdlib/src/empty.jar
  44. +0 −12 maven/jruby-stdlib/src/main/resources/META-INF/MANIFEST.MF
  45. +4 −4 maven/jruby/src/it/integrity/pom.xml
  46. +1 −1 maven/jruby/src/it/integrity/verify.bsh
  47. +0 −2 maven/pom.rb
  48. +4 −17 maven/pom.xml
  49. +31 −20 test/check_versions.sh
37 changes: 11 additions & 26 deletions core/pom.rb
Original file line number Diff line number Diff line change
@@ -52,7 +52,7 @@

jar 'org.jruby.joni:joni:2.1.5'
jar 'org.jruby.extras:bytelist:1.0.12'
jar 'org.jruby.jcodings:jcodings:1.0.12'
jar 'org.jruby.jcodings:jcodings:1.0.13-SNAPSHOT'
jar 'org.jruby:dirgra:0.2'

jar 'com.headius:invokebinder:1.5'
@@ -255,31 +255,16 @@
'mainClass' => 'org.jruby.Main' } ] )
end

[ :osgi, :dist, :'jruby-jars', :main, :all, :complete, :release, :jruby_complete_jar_extended ].each do |name|
profile name do
plugin :shade do
execute_goals( 'shade',
:id => 'pack jruby-core-noasm.jar',
:phase => 'package',
'shadedArtifactAttached' => 'true',
'shadedClassifierName' => 'noasm',
'artifactSet' => {
'includes' => [ 'com.github.jnr:jnr-ffi',
'org.ow2.asm:*' ]
},
'relocations' => [ { 'pattern' => 'org.objectweb',
'shadedPattern' => 'org.jruby.org.objectweb' } ] )
execute_goals( 'shade',
:id => 'pack jruby-core-complete.jar',
:phase => 'package',
'shadedArtifactAttached' => 'true',
'shadedClassifierName' => 'complete',
'relocations' => [ { 'pattern' => 'org.objectweb',
'shadedPattern' => 'org.jruby.org.objectweb' } ],
'transformers' => [ { '@implementation' => 'org.apache.maven.plugins.shade.resource.ManifestResourceTransformer',
'mainClass' => 'org.jruby.Main' } ] )
end
end
plugin :shade do
execute_goals( 'shade',
:id => 'shade the asm classes',
:phase => 'verify',
'artifactSet' => {
'includes' => [ 'com.github.jnr:jnr-ffi',
'org.ow2.asm:*' ]
},
'relocations' => [ { 'pattern' => 'org.objectweb',
'shadedPattern' => 'org.jruby.org.objectweb' } ] )
end

profile 'jruby.bash' do
485 changes: 27 additions & 458 deletions core/pom.xml

Large diffs are not rendered by default.

6 changes: 0 additions & 6 deletions jruby.bnd.template

This file was deleted.

88 changes: 78 additions & 10 deletions lib/pom.rb
Original file line number Diff line number Diff line change
@@ -54,14 +54,18 @@ def to_pathname
version = File.read( File.join( basedir, '..', 'VERSION' ) ).strip

model_version '4.0.0'
id 'jruby-lib'
id 'jruby-stdlib'
inherit "org.jruby:jruby-parent", version
packaging 'pom'

properties( 'tesla.dump.pom' => 'pom.xml',
'tesla.dump.readonly' => true,
'tesla.version' => '0.1.1',
'jruby.plugins.version' => '1.0.5' )
'jruby.plugins.version' => '1.0.5',
'gem.home' => '${basedir}/ruby/gems/shared',
# we copy everything into the target/classes/META-INF
# so the jar plugin just packs it - see build/resources below
'jruby.complete.home' => '${project.build.outputDirectory}/META-INF/jruby.home',
'jruby.complete.gems' => '${jruby.complete.home}/lib/ruby/gems/shared' )

unless version =~ /-SNAPSHOT/
properties 'jruby.home' => '${basedir}/..'
@@ -86,18 +90,13 @@ def to_pathname
end
end

# this is not an artifact for maven central
plugin :deploy, :skip => true

plugin :invoker, :skipInstallation => true

gem 'ruby-maven', '3.1.1.0.8', :scope => :provided

plugin :dependency, :useRepositoryLayout => true, :outputDirectory => 'ruby/stdlib', :excludeGroupIds => 'rubygems', :includeScope => :runtime do
execute_goal 'copy-dependencies', :phase => 'package'
end

execute :install_gems, :'package' do |ctx|
execute :install_gems, :'initialize' do |ctx|
require 'fileutils'

puts "using jruby #{JRUBY_VERSION}"
@@ -233,5 +232,74 @@ def to_pathname
( Dir[ File.join( jruby_gems, '**/*' ) ] + Dir[ File.join( jruby_gems, '**/.*' ) ] ).each do |f|
File.chmod( 0644, f ) rescue nil if File.file?( f )
end
end
end

execute( 'fix shebang on gem bin files and add *.bat files',
'prepare-resources' ) do |ctx|

puts 'fix the gem stub files'
jruby_home = ctx.project.basedir.to_pathname + '/../'
bindir = File.join( jruby_home, 'lib', 'ruby', 'gems', 'shared', 'bin' )
Dir[ File.join( bindir, '*' ) ].each do |f|
content = File.read( f )
new_content = content.sub( /#!.*/, "#!/usr/bin/env jruby
" )
File.open( f, "w" ) { |file| file.print( new_content ) }
end

puts 'generate the missing bat files'
Dir[File.join( jruby_home, 'bin', '*' )].each do |fn|
next unless File.file?(fn)
next if fn =~ /.bat$/
next if File.exist?("#{fn}.bat")
next unless File.open(fn, 'r', :internal_encoding => 'ASCII-8BIT') do |io|
line = io.readline rescue ""
line =~ /^#!.*ruby/
end
puts "Generating #{File.basename(fn)}.bat"
File.open("#{fn}.bat", "wb") do |f|
f.print "@ECHO OFF\r\n"
f.print "@\"%~dp0jruby.exe\" -S #{File.basename(fn)} %*\r\n"
end
end
end

execute( 'copy bin/jruby.bash to bin/jruby',
'process-resources' ) do |ctx|
require 'fileutils'
jruby_complete = ctx.project.properties.get_property( 'jruby.complete.home' )
FileUtils.cp( File.join( jruby_complete, 'bin', 'jruby.bash' ),
File.join( jruby_complete, 'bin', 'jruby' ) )
end

execute 'jrubydir', 'prepare-package' do |ctx|
require( ctx.project.basedir.to_pathname + '/../core/src/main/ruby/jruby/commands.rb' )
JRuby::Commands.generate_dir_info( ctx.project.build.output_directory.to_pathname + '/META-INF/jruby.home' )
end

# we have no sources and attach an empty jar later in the build to
# satisfy oss.sonatype.org upload

plugin( :source, 'skipSource' => 'true' )

# this plugin is configured to attach empty jars for sources and javadocs
plugin( 'org.codehaus.mojo:build-helper-maven-plugin' )

build do

# both resources are includes for the $jruby_home/lib directory

resource do
directory '${gem.home}'
includes 'gems/rake-${rake.version}/bin/r*', 'gems/rdoc-${rdoc.version}/bin/r*', 'specifications/default/*.gemspec'
target_path '${jruby.complete.gems}'
end

resource do
directory '${basedir}/..'
includes 'bin/ast*', 'bin/gem*', 'bin/irb*', 'bin/jgem*', 'bin/jirb*', 'bin/jruby*', 'bin/rake*', 'bin/ri*', 'bin/rdoc*', 'bin/testrb*', 'lib/ruby/stdlib/**', 'lib/ruby/truffle/**'
excludes 'bin/jruby', 'bin/jruby*_*', 'bin/jruby*-*', '**/.*', 'lib/ruby/stdlib/rubygems/defaults/jruby_native.rb'
target_path '${jruby.complete.home}'
end
end
end
105 changes: 87 additions & 18 deletions lib/pom.xml
Original file line number Diff line number Diff line change
@@ -7,13 +7,15 @@
<artifactId>jruby-parent</artifactId>
<version>9.0.0.0-SNAPSHOT</version>
</parent>
<artifactId>jruby-lib</artifactId>
<packaging>pom</packaging>
<artifactId>jruby-stdlib</artifactId>
<name>JRuby Lib Setup</name>
<properties>
<tesla.dump.readonly>true</tesla.dump.readonly>
<jruby.complete.gems>${jruby.complete.home}/lib/ruby/gems/shared</jruby.complete.gems>
<gem.home>${basedir}/ruby/gems/shared</gem.home>
<jruby.plugins.version>1.0.5</jruby.plugins.version>
<tesla.dump.pom>pom.xml</tesla.dump.pom>
<jruby.complete.home>${project.build.outputDirectory}/META-INF/jruby.home</jruby.complete.home>
<tesla.version>0.1.1</tesla.version>
</properties>
<dependencies>
@@ -38,19 +40,7 @@
<dependency>
<groupId>rubygems</groupId>
<artifactId>jruby-readline</artifactId>
<version>1.0.dev-SNAPSHOT</version>
<type>gem</type>
<exclusions>
<exclusion>
<artifactId>jar-dependencies</artifactId>
<groupId>rubygems</groupId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>rubygems</groupId>
<artifactId>jruby-ripper</artifactId>
<version>2.1.0.dev-SNAPSHOT</version>
<version>1.0</version>
<type>gem</type>
<exclusions>
<exclusion>
@@ -170,6 +160,42 @@
</repository>
</repositories>
<build>
<resources>
<resource>
<targetPath>${jruby.complete.gems}</targetPath>
<directory>${gem.home}</directory>
<includes>
<include>gems/rake-${rake.version}/bin/r*</include>
<include>gems/rdoc-${rdoc.version}/bin/r*</include>
<include>specifications/default/*.gemspec</include>
</includes>
</resource>
<resource>
<targetPath>${jruby.complete.home}</targetPath>
<directory>${basedir}/..</directory>
<includes>
<include>bin/ast*</include>
<include>bin/gem*</include>
<include>bin/irb*</include>
<include>bin/jgem*</include>
<include>bin/jirb*</include>
<include>bin/jruby*</include>
<include>bin/rake*</include>
<include>bin/ri*</include>
<include>bin/rdoc*</include>
<include>bin/testrb*</include>
<include>lib/ruby/stdlib/**</include>
<include>lib/ruby/truffle/**</include>
</includes>
<excludes>
<exclude>bin/jruby</exclude>
<exclude>bin/jruby*_*</exclude>
<exclude>bin/jruby*-*</exclude>
<exclude>**/.*</exclude>
<exclude>lib/ruby/stdlib/rubygems/defaults/jruby_native.rb</exclude>
</excludes>
</resource>
</resources>
<plugins>
<plugin>
<artifactId>maven-clean-plugin</artifactId>
@@ -219,14 +245,24 @@
<includeScope>runtime</includeScope>
</configuration>
</plugin>
<plugin>
<artifactId>maven-source-plugin</artifactId>
<configuration>
<skipSource>true</skipSource>
</configuration>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>build-helper-maven-plugin</artifactId>
</plugin>
<plugin>
<groupId>io.tesla.polyglot</groupId>
<artifactId>tesla-polyglot-maven-plugin</artifactId>
<version>0.1.1</version>
<version>${tesla.version}</version>
<executions>
<execution>
<id>install_gems</id>
<phase>package</phase>
<phase>initialize</phase>
<goals>
<goal>execute</goal>
</goals>
@@ -235,12 +271,45 @@
<nativePom>pom.rb</nativePom>
</configuration>
</execution>
<execution>
<id>fix shebang on gem bin files and add *.bat files</id>
<phase>prepare-resources</phase>
<goals>
<goal>execute</goal>
</goals>
<configuration>
<taskId>fix shebang on gem bin files and add *.bat files</taskId>
<nativePom>pom.rb</nativePom>
</configuration>
</execution>
<execution>
<id>copy bin/jruby.bash to bin/jruby</id>
<phase>process-resources</phase>
<goals>
<goal>execute</goal>
</goals>
<configuration>
<taskId>copy bin/jruby.bash to bin/jruby</taskId>
<nativePom>pom.rb</nativePom>
</configuration>
</execution>
<execution>
<id>jrubydir</id>
<phase>prepare-package</phase>
<goals>
<goal>execute</goal>
</goals>
<configuration>
<taskId>jrubydir</taskId>
<nativePom>pom.rb</nativePom>
</configuration>
</execution>
</executions>
<dependencies>
<dependency>
<groupId>io.tesla.polyglot</groupId>
<artifactId>tesla-polyglot-ruby</artifactId>
<version>0.1.1</version>
<version>${tesla.version}</version>
</dependency>
</dependencies>
</plugin>
File renamed without changes.
17 changes: 0 additions & 17 deletions maven/.project

This file was deleted.

2 changes: 0 additions & 2 deletions maven/.settings/org.eclipse.core.resources.prefs

This file was deleted.

4 changes: 0 additions & 4 deletions maven/.settings/org.eclipse.m2e.core.prefs

This file was deleted.

23 changes: 0 additions & 23 deletions maven/jruby-complete/.project

This file was deleted.

This file was deleted.

4 changes: 0 additions & 4 deletions maven/jruby-complete/.settings/org.eclipse.m2e.core.prefs

This file was deleted.

8 changes: 1 addition & 7 deletions maven/jruby-complete/pom.rb
Original file line number Diff line number Diff line change
@@ -19,13 +19,7 @@
end

scope :provided do
jar( 'org.jruby:jruby-core:${project.version}:noasm',
:exclusions => [ 'com.github.jnr:jnr-ffi',
'org.ow2.asm:asm',
'org.ow2.asm:asm-commons',
'org.ow2.asm:asm-analysis',
'org.ow2.asm:asm-util' ] )
jar 'org.jruby:jruby-truffle:${project.version}'
jar 'org.jruby:jruby-core:${project.version}'
jar 'org.jruby:jruby-stdlib:${project.version}'
end

29 changes: 0 additions & 29 deletions maven/jruby-complete/pom.xml
Original file line number Diff line number Diff line change
@@ -22,35 +22,6 @@
<groupId>org.jruby</groupId>
<artifactId>jruby-core</artifactId>
<version>${project.version}</version>
<classifier>noasm</classifier>
<scope>provided</scope>
<exclusions>
<exclusion>
<artifactId>jnr-ffi</artifactId>
<groupId>com.github.jnr</groupId>
</exclusion>
<exclusion>
<artifactId>asm</artifactId>
<groupId>org.ow2.asm</groupId>
</exclusion>
<exclusion>
<artifactId>asm-commons</artifactId>
<groupId>org.ow2.asm</groupId>
</exclusion>
<exclusion>
<artifactId>asm-analysis</artifactId>
<groupId>org.ow2.asm</groupId>
</exclusion>
<exclusion>
<artifactId>asm-util</artifactId>
<groupId>org.ow2.asm</groupId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>org.jruby</groupId>
<artifactId>jruby-truffle</artifactId>
<version>${project.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
17 changes: 0 additions & 17 deletions maven/jruby-dist/.project

This file was deleted.

2 changes: 0 additions & 2 deletions maven/jruby-dist/.settings/org.eclipse.core.resources.prefs

This file was deleted.

4 changes: 0 additions & 4 deletions maven/jruby-dist/.settings/org.eclipse.m2e.core.prefs

This file was deleted.

77 changes: 30 additions & 47 deletions maven/jruby-dist/pom.rb
Original file line number Diff line number Diff line change
@@ -18,7 +18,7 @@
# pre-installed gems - not default gems !
gem 'ruby-maven', '3.1.1.0.8', :scope => 'provided'

# add torquebox repo only when building from filesystem
# HACK: add torquebox repo only when building from filesystem
# not when using the pom as "dependency" in some other projects
profile 'gem proxy' do

@@ -48,12 +48,26 @@
'outputDirectory' => '${project.build.directory}' } ] )
end

execute :pack200 do |ctx|
jruby_home = Dir[ File.join( ctx.project.build.directory.to_pathname,
'META-INF/jruby.home/**/*.jar' ) ]
gem_home = Dir[ File.join( ctx.project.build.directory.to_pathname,
'rubygems-provided/**/*.jar' ) ]
lib_dir = Dir[ File.join( ctx.basedir.to_pathname,
'../../lib/*.jar' ) ]

(jruby_home + gem_home + lib_dir).each do |f|
file = f.sub /.jar$/, ''
unless File.exists?( file + '.pack.gz' )
puts "pack200 #{f.sub(/.*jruby.home./, '').sub(/.*rubygems-provided./, '')}"
`pack200 #{file}.pack.gz #{file}.jar`
end
end
end

execute :fix_executable_bits do |ctx|
Dir[ File.join( ctx.project.build.directory.to_pathname,
'META-INF',
'jruby.home',
'bin',
'*' ) ].each do |f|
'META-INF/jruby.home/bin/*' ) ].each do |f|
unless f.match /.(bat|exe|dll)$/
puts f
File.chmod( 0755, f ) rescue nil
@@ -71,50 +85,18 @@

phase :package do
plugin( :assembly, '2.4',
'tarLongFileMode' => 'gnu',
'descriptors' => [ 'src/main/assembly/jruby.xml' ] ) do
execute_goals( 'single' )
:recompressZippedFiles => true,
:tarLongFileMode => 'gnu' ) do
execute_goals( :single, :id => 'bin.tar.gz and bin.zip',
:descriptors => [ 'src/main/assembly/bin.xml' ] )
execute_goals( :single, :id => 'bin200.tar.gz',
:attach => false,
:descriptors => [ 'src/main/assembly/bin200.xml' ] )
end
end

plugin( :invoker )

# for the release we do some extra IT by unzipping a source dist file
# and run the $ mvn -Pall from there and check a few things to be in place.
# add check for SNAPSHOT version in any of the modules !!!!

profile 'not-working-currently---release' do

plugin( :invoker, :pomIncludes => [ '*' ] )

phase 'pre-integration-test' do
plugin :dependency do
execute_goals( 'unpack',
:id => 'unpack jruby-dist',
'stripVersion' => 'true',
'artifactItems' => [ { 'groupId' => 'org.jruby',
'artifactId' => 'jruby-dist',
'version' => '${project.version}',
'type' => 'zip',
'classifier' => 'src',
'overWrite' => 'false',
'outputDirectory' => '${project.build.directory}' } ] )
end
end

execute :prepare_sources_for_it, 'pre-integration-test' do |ctx|
require 'fileutils'
dir = File.join( "#{ctx.project.build.directory}", 'it' )
FileUtils.mkdir_p dir
dir = File.join( dir, 'sources')
FileUtils.mv( "#{ctx.project.build.directory}/jruby-#{ctx.project.version}", "#{dir}" ) unless File.exists? "#{dir}"
File.open( "#{dir}/test.properties", 'w' ) do |f|
f.puts File.join( "outputFile=#{File.expand_path( dir )}", 'tree.txt' )
f.puts 'appendOutput=true'
end
end
end

# since the source packages are done from the git repository we need
# to be inside a git controlled directory. for example the source packages
# itself does not contain the git repository and can not pack
@@ -135,13 +117,14 @@
basefile = "#{ctx.project.build.directory}/#{ctx.project.artifactId}-#{ctx.project.version}-src"

FileUtils.cd( File.join( ctx.project.basedir.to_s, '..', '..' ) ) do
[ 'tar', 'zip' ].each do |format|
#[ 'tar', 'zip' ].each do |format|
[ 'zip' ].each do |format|
puts "create #{basefile}.#{format}"
system( "git archive --prefix 'jruby-#{ctx.project.version}/' --format #{format} #{revision} . -o #{basefile}.#{format}" ) || raise( "error creating #{format}-file" )
end
end
puts "zipping #{basefile}.tar"
system( "gzip #{basefile}.tar -f" ) || raise( "error zipping #{basefile}.tar" )
#puts "zipping #{basefile}.tar"
#system( "gzip #{basefile}.tar -f" ) || raise( "error zipping #{basefile}.tar" )
end
plugin 'org.codehaus.mojo:build-helper-maven-plugin' do
execute_goal( 'attach-artifact',
102 changes: 32 additions & 70 deletions maven/jruby-dist/pom.xml
Original file line number Diff line number Diff line change
@@ -12,7 +12,7 @@
<name>JRuby Dist</name>
<properties>
<tesla.dump.readonly>true</tesla.dump.readonly>
<jruby.plugins.version>1.0.3</jruby.plugins.version>
<jruby.plugins.version>1.0.8</jruby.plugins.version>
<main.basedir>${project.parent.parent.basedir}</main.basedir>
<tesla.dump.pom>pom.xml</tesla.dump.pom>
<tesla.version>0.1.1</tesla.version>
@@ -70,17 +70,34 @@
<version>2.4</version>
<executions>
<execution>
<id>bin.tar.gz and bin.zip</id>
<phase>package</phase>
<goals>
<goal>single</goal>
</goals>
<configuration>
<descriptors>
<descriptor>src/main/assembly/bin.xml</descriptor>
</descriptors>
</configuration>
</execution>
<execution>
<id>bin200.tar.gz</id>
<phase>package</phase>
<goals>
<goal>single</goal>
</goals>
<configuration>
<attach>false</attach>
<descriptors>
<descriptor>src/main/assembly/bin200.xml</descriptor>
</descriptors>
</configuration>
</execution>
</executions>
<configuration>
<recompressZippedFiles>true</recompressZippedFiles>
<tarLongFileMode>gnu</tarLongFileMode>
<descriptors>
<descriptor>src/main/assembly/jruby.xml</descriptor>
</descriptors>
</configuration>
</plugin>
<plugin>
@@ -91,6 +108,17 @@
<artifactId>tesla-polyglot-maven-plugin</artifactId>
<version>${tesla.version}</version>
<executions>
<execution>
<id>pack200</id>
<phase>prepare-package</phase>
<goals>
<goal>execute</goal>
</goals>
<configuration>
<taskId>pack200</taskId>
<nativePom>pom.rb</nativePom>
</configuration>
</execution>
<execution>
<id>fix_executable_bits</id>
<phase>prepare-package</phase>
@@ -139,72 +167,6 @@
</repository>
</repositories>
</profile>
<profile>
<id>not-working-currently---release</id>
<build>
<plugins>
<plugin>
<artifactId>maven-invoker-plugin</artifactId>
<configuration>
<pomIncludes>
<pomInclude>*</pomInclude>
</pomIncludes>
</configuration>
</plugin>
<plugin>
<artifactId>maven-dependency-plugin</artifactId>
<executions>
<execution>
<id>unpack jruby-dist</id>
<phase>pre-integration-test</phase>
<goals>
<goal>unpack</goal>
</goals>
<configuration>
<stripVersion>true</stripVersion>
<artifactItems>
<artifactItem>
<groupId>org.jruby</groupId>
<artifactId>jruby-dist</artifactId>
<version>${project.version}</version>
<type>zip</type>
<classifier>src</classifier>
<overWrite>false</overWrite>
<outputDirectory>${project.build.directory}</outputDirectory>
</artifactItem>
</artifactItems>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>io.tesla.polyglot</groupId>
<artifactId>tesla-polyglot-maven-plugin</artifactId>
<version>${tesla.version}</version>
<executions>
<execution>
<id>prepare_sources_for_it</id>
<phase>pre-integration-test</phase>
<goals>
<goal>execute</goal>
</goals>
<configuration>
<taskId>prepare_sources_for_it</taskId>
<nativePom>pom.rb</nativePom>
</configuration>
</execution>
</executions>
<dependencies>
<dependency>
<groupId>io.tesla.polyglot</groupId>
<artifactId>tesla-polyglot-ruby</artifactId>
<version>${tesla.version}</version>
</dependency>
</dependencies>
</plugin>
</plugins>
</build>
</profile>
<profile>
<id>source dist</id>
<activation>
39 changes: 39 additions & 0 deletions maven/jruby-dist/src/main/assembly/bin.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
<assembly xmlns="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.0 http://maven.apache.org/xsd/assembly-1.1.0.xsd">
<id>bin</id>
<baseDirectory>jruby-${project.version}</baseDirectory>

<formats>
<format>tar.gz</format>
<format>zip</format>
</formats>

<componentDescriptors>
<componentDescriptor>src/main/assembly/common.xml</componentDescriptor>
</componentDescriptors>

<fileSets>
<fileSet>
<directory>${project.build.directory}/META-INF/jruby.home</directory>
<outputDirectory>/</outputDirectory>
<includes>
<include>**/*.jar</include>
</includes>
</fileSet>
<fileSet>
<directory>${project.build.directory}/rubygems-provided</directory>
<outputDirectory>/lib/ruby/gems/shared</outputDirectory>
<includes>
<include>**/*.jar</include>
</includes>
</fileSet>
<fileSet>
<directory>${project.parent.parent.basedir}</directory>
<outputDirectory>/</outputDirectory>
<includes>
<include>lib/*.jar</include>
</includes>
</fileSet>
</fileSets>
</assembly>
45 changes: 45 additions & 0 deletions maven/jruby-dist/src/main/assembly/bin200.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
<assembly xmlns="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.0 http://maven.apache.org/xsd/assembly-1.1.0.xsd">
<id>bin200</id>
<baseDirectory>jruby-${project.version}</baseDirectory>

<formats>
<format>tar.gz</format>
</formats>

<componentDescriptors>
<componentDescriptor>src/main/assembly/common.xml</componentDescriptor>
</componentDescriptors>

<fileSets>
<fileSet>
<directory>${project.build.directory}/META-INF/jruby.home</directory>
<outputDirectory>/</outputDirectory>
<includes>
<include>**/*.pack.gz</include>
</includes>
</fileSet>
<fileSet>
<directory>${project.build.directory}/rubygems-provided</directory>
<outputDirectory>/lib/ruby/gems/shared</outputDirectory>
<includes>
<include>**/*.pack.gz</include>
</includes>
</fileSet>
<fileSet>
<directory>${project.parent.parent.basedir}</directory>
<outputDirectory>/</outputDirectory>
<includes>
<include>lib/*.pack.gz</include>
</includes>
</fileSet>
</fileSets>
<files>
<file>
<source>${project.build.directory}/META-INF/jruby.home/bin/jruby200.sh</source>
<outputDirectory>bin</outputDirectory>
<destName>jruby</destName>
</file>
</files>
</assembly>
Original file line number Diff line number Diff line change
@@ -1,18 +1,12 @@
<assembly xmlns="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.0 http://maven.apache.org/xsd/assembly-1.1.0.xsd">
<id>bin</id>
<baseDirectory>jruby-${project.version}</baseDirectory>
<formats>
<format>tar.gz</format>
<format>zip</format>
</formats>
<component>
<fileSets>
<fileSet>
<directory>${project.build.directory}/META-INF/jruby.home</directory>
<outputDirectory>/</outputDirectory>
<excludes>
<exclude>**/.jrubydir</exclude>
<exclude>**/*.pack.gz</exclude>
<exclude>**/*.jar</exclude>
</excludes>
</fileSet>
<fileSet>
@@ -23,15 +17,18 @@
<include>specifications/*</include>
<include>gems/**/*</include>
</includes>
<excludes>
<exclude>**/.jrubydir</exclude>
<exclude>**/*.pack.gz</exclude>
<exclude>**/*.jar</exclude>
</excludes>
</fileSet>
<fileSet>
<directory>${project.parent.parent.basedir}</directory>
<outputDirectory>/</outputDirectory>
<includes>
<include>LICENSE*</include>
<include>COPYING*</include>
<include>lib/jruby.jar</include>
<include>lib/jruby-truffle.jar</include>
<include>lib/jni/**/*</include>
<include>samples/**/*</include>
<include>docs/**/*</include>
@@ -48,4 +45,4 @@
</excludes>
</fileSet>
</fileSets>
</assembly>
</component>
4 changes: 2 additions & 2 deletions maven/jruby-jars/Mavenfile
Original file line number Diff line number Diff line change
@@ -40,11 +40,11 @@ properties( 'tesla.dump.pom' => 'pom.xml',
execute 'copy jruby.jar', 'prepare-package' do |ctx|
source = File.expand_path( ctx.project.properties[ 'jruby_home' ].to_pathname )
# TODO somehow the lib/jruby.jar gets moved away to avoid conflicts
FileUtils.cp( Dir[ File.join( source, "core/target/jruby-core-#{version}-complete.jar" ) ].first,
FileUtils.cp( Dir[ File.join( source, "lib/jruby.jar" ) ].first,
File.join( ctx.project.basedir.to_pathname,
'lib',
"jruby-core-#{ctx.project.version}-complete.jar" ) )
FileUtils.cp( Dir[ File.join( source, "truffle/target/jruby-truffle-#{version}-complete.jar" ) ].first,
FileUtils.cp( Dir[ File.join( source, "lib/jruby-truffle.jar" ) ].first,
File.join( ctx.project.basedir.to_pathname,
'lib',
"jruby-truffle-#{ctx.project.version}-complete.jar" ) )
7 changes: 6 additions & 1 deletion maven/jruby-jars/pom.xml
Original file line number Diff line number Diff line change
@@ -18,12 +18,18 @@ freezing to) a specific jruby-complete jar version.</description>
<licenses>
<license>
<name>EPL-1.0</name>
<url>http://opensource.org/licenses/EPL-1.0</url>
<comments>Eclipse Public License 1.0</comments>
</license>
<license>
<name>GPL-2.0</name>
<url>http://opensource.org/licenses/GPL-2.0</url>
<comments>GNU General Public License version 2.0</comments>
</license>
<license>
<name>LGPL-2.1</name>
<url>http://opensource.org/licenses/LGPL-2.1</url>
<comments>GNU Library or "Lesser" General Public License version 2.1</comments>
</license>
</licenses>
<developers>
@@ -41,7 +47,6 @@ freezing to) a specific jruby-complete jar version.</description>
<gem.home>${jruby.home}/lib/ruby/gems/shared</gem.home>
<jruby.plugins.version>1.0.7</jruby.plugins.version>
<tesla.dump.pom>pom.xml</tesla.dump.pom>
<project.build.sourceEncoding>utf-8</project.build.sourceEncoding>
<jruby_home>${basedir}/../../</jruby_home>
<tesla.version>0.1.1</tesla.version>
</properties>
26 changes: 0 additions & 26 deletions maven/jruby-noasm/.classpath

This file was deleted.

23 changes: 0 additions & 23 deletions maven/jruby-noasm/.project

This file was deleted.

2 changes: 0 additions & 2 deletions maven/jruby-noasm/.settings/org.eclipse.core.resources.prefs

This file was deleted.

5 changes: 0 additions & 5 deletions maven/jruby-noasm/.settings/org.eclipse.jdt.core.prefs

This file was deleted.

4 changes: 0 additions & 4 deletions maven/jruby-noasm/.settings/org.eclipse.m2e.core.prefs

This file was deleted.

39 changes: 0 additions & 39 deletions maven/jruby-noasm/pom.rb

This file was deleted.

69 changes: 0 additions & 69 deletions maven/jruby-noasm/pom.xml

This file was deleted.

3 changes: 0 additions & 3 deletions maven/jruby-noasm/src/it/integrity/invoker.properties

This file was deleted.

164 changes: 0 additions & 164 deletions maven/jruby-noasm/src/it/integrity/pom.xml

This file was deleted.

45 changes: 0 additions & 45 deletions maven/jruby-noasm/src/it/integrity/verify.bsh

This file was deleted.

35 changes: 0 additions & 35 deletions maven/jruby-noasm/src/it/settings.xml

This file was deleted.

26 changes: 0 additions & 26 deletions maven/jruby-stdlib/.classpath

This file was deleted.

23 changes: 0 additions & 23 deletions maven/jruby-stdlib/.project

This file was deleted.

2 changes: 0 additions & 2 deletions maven/jruby-stdlib/.settings/org.eclipse.core.resources.prefs

This file was deleted.

5 changes: 0 additions & 5 deletions maven/jruby-stdlib/.settings/org.eclipse.jdt.core.prefs

This file was deleted.

4 changes: 0 additions & 4 deletions maven/jruby-stdlib/.settings/org.eclipse.m2e.core.prefs

This file was deleted.

101 changes: 0 additions & 101 deletions maven/jruby-stdlib/pom.rb

This file was deleted.

126 changes: 0 additions & 126 deletions maven/jruby-stdlib/pom.xml

This file was deleted.

Binary file removed maven/jruby-stdlib/src/empty.jar
Binary file not shown.
12 changes: 0 additions & 12 deletions maven/jruby-stdlib/src/main/resources/META-INF/MANIFEST.MF

This file was deleted.

8 changes: 4 additions & 4 deletions maven/jruby/src/it/integrity/pom.xml
Original file line number Diff line number Diff line change
@@ -131,7 +131,7 @@
</configuration>
</execution>
<execution>
<id>there is org.objectweb.asm.ClassWriter</id>
<id>ensure there is no org.objectweb.asm.ClassWriter</id>
<phase>test</phase>
<goals>
<goal>exec</goal>
@@ -148,10 +148,10 @@
<!-- make sure openssl loads -->
<argument>
begin
java_import "org.objectweb.asm.ClassWriter"
puts "there is org.objectweb.asm.ClassWriter on the classpath"
import_java "org.objectweb.asm.ClassWriter"
raise "error there is org.objectweb.asm.ClassWriter on the classpath"
rescue NameError => e
raise "error there is NO org.objectweb.asm.ClassWriter on the classpath"
puts "there is NO org.objectweb.asm.ClassWriter on the classpath"
end
</argument>
</arguments>
2 changes: 1 addition & 1 deletion maven/jruby/src/it/integrity/verify.bsh
Original file line number Diff line number Diff line change
@@ -38,7 +38,7 @@ if ( !log.contains( expected ) )
{
throw new RuntimeException( "log file does not contain '" + expected + "'" );
}
expected = "there is org.objectweb.asm.ClassWriter on the classpath";
expected = "there is NO org.objectweb.asm.ClassWriter on the classpath";
if ( !log.contains( expected ) )
{
throw new RuntimeException( "log file does not contain '" + expected + "'" );
2 changes: 0 additions & 2 deletions maven/pom.rb
Original file line number Diff line number Diff line change
@@ -24,8 +24,6 @@

# module to profile map
map = { 'jruby' => [ :release, :main, :osgi, :j2ee ],
'jruby-noasm' => [ :release, :main, :osgi ],
'jruby-stdlib' => [ :release, :main, :complete, :dist, 'jruby-jars', :osgi, :j2ee, :'jruby_complete_jar_extended' ],
'jruby-complete' => [ :release, :complete, :osgi, :'jruby_complete_jar_extended'],
'jruby-jars' => [ :release, 'jruby-jars' ],
'jruby-dist' => [ :release, :dist ]
21 changes: 4 additions & 17 deletions maven/pom.xml
Original file line number Diff line number Diff line change
@@ -50,8 +50,6 @@
<id>all</id>
<modules>
<module>jruby</module>
<module>jruby-noasm</module>
<module>jruby-stdlib</module>
<module>jruby-complete</module>
<module>jruby-jars</module>
<module>jruby-dist</module>
@@ -61,8 +59,6 @@
<id>release</id>
<modules>
<module>jruby</module>
<module>jruby-noasm</module>
<module>jruby-stdlib</module>
<module>jruby-complete</module>
<module>jruby-jars</module>
<module>jruby-dist</module>
@@ -72,52 +68,43 @@
<id>main</id>
<modules>
<module>jruby</module>
<module>jruby-noasm</module>
<module>jruby-stdlib</module>
</modules>
</profile>
<profile>
<id>osgi</id>
<modules>
<module>jruby</module>
<module>jruby-noasm</module>
<module>jruby-stdlib</module>
<module>jruby-complete</module>
</modules>
</profile>
<profile>
<id>j2ee</id>
<modules>
<module>jruby</module>
<module>jruby-stdlib</module>
</modules>
</profile>
<profile>
<id>complete</id>
<modules>
<module>jruby-stdlib</module>
<module>jruby-complete</module>
</modules>
</profile>
<profile>
<id>dist</id>
<id>jruby_complete_jar_extended</id>
<modules>
<module>jruby-stdlib</module>
<module>jruby-dist</module>
<module>jruby-complete</module>
</modules>
</profile>
<profile>
<id>jruby-jars</id>
<modules>
<module>jruby-stdlib</module>
<module>jruby-jars</module>
</modules>
</profile>
<profile>
<id>jruby_complete_jar_extended</id>
<id>dist</id>
<modules>
<module>jruby-stdlib</module>
<module>jruby-complete</module>
<module>jruby-dist</module>
</modules>
</profile>
</profiles>
51 changes: 31 additions & 20 deletions test/check_versions.sh
Original file line number Diff line number Diff line change
@@ -20,14 +20,22 @@ failed[0]=0

function check {
archive=$1
unpackaged=$2

max=$2*1024*1024
unpackaged=$3
length=`cat $archive | wc -c`

if [ ! -f $archive ]
then
echo $archive was not found - check your version numbers
failed[0]=1
fi

if [[ $length -gt $max ]]
then
echo size of $archive expected smaller then $max but got $length
failed[0]=1
fi

if [[ $archive == *.tar.gz ]]
then
rm -rf $unpackaged
@@ -51,25 +59,28 @@ function check {
failed[0]=1
fi
fi

}

check test/target/jruby-tests-$jar_version.jar
check maven/jruby-stdlib/target/jruby-stdlib-$jar_version.jar
check maven/jruby-jars/pkg/jruby-jars-$gem_version.gem
check maven/jruby-jars/lib/jruby-core-$jar_version-complete.jar
check maven/jruby-jars/lib/jruby-truffle-$jar_version-complete.jar
check maven/jruby-jars/lib/jruby-stdlib-$jar_version.jar
check maven/jruby-complete/target/jruby-complete-$jar_version.jar
check maven/jruby/target/jruby-$jar_version.jar
check maven/jruby-noasm/target/jruby-noasm-$jar_version.jar
check maven/jruby-dist/target/jruby-dist-$jar_version-bin.tar.gz jruby-$jar_version
check maven/jruby-dist/target/jruby-dist-$jar_version-src.tar.gz jruby-$jar_version
check maven/jruby-dist/target/jruby-dist-$jar_version-src.zip jruby-$jar_version
check maven/jruby-dist/target/jruby-dist-$jar_version-bin.zip jruby-$jar_version
check core/target/jruby-core-$jar_version-noasm.jar
check core/target/jruby-core-$jar_version.jar
check core/target/jruby-core-$jar_version-complete.jar
check truffle/target/jruby-truffle-$jar_version.jar
check truffle/target/jruby-truffle-$jar_version-complete.jar
check test/target/jruby-tests-$jar_version.jar 1
check maven/jruby-stdlib/target/jruby-stdlib-$jar_version.jar 8
check maven/jruby-jars/pkg/jruby-jars-$gem_version.gem 25
check maven/jruby-jars/lib/jruby-core-$jar_version-complete.jar 12
check maven/jruby-jars/lib/jruby-truffle-$jar_version-complete.jar 9
check maven/jruby-jars/lib/jruby-stdlib-$jar_version.jar 8
check maven/jruby-complete/target/jruby-complete-$jar_version.jar 27
check maven/jruby/target/jruby-$jar_version.jar 1
check maven/jruby-noasm/target/jruby-noasm-$jar_version.jar 9
check maven/jruby-dist/target/jruby-dist-$jar_version-bin.tar.gz 37 jruby-$jar_version
check maven/jruby-dist/target/jruby-dist-$jar_version-bin200.tar.gz 17 jruby-$jar_version
check maven/jruby-dist/target/jruby-dist-$jar_version-src.tar.gz 8 jruby-$jar_version
check maven/jruby-dist/target/jruby-dist-$jar_version-src.zip 13 jruby-$jar_version
check maven/jruby-dist/target/jruby-dist-$jar_version-bin.zip 38 jruby-$jar_version
check maven/jruby-dist/target/jruby-dist-$jar_version-bin200.zip 18 jruby-$jar_version
check core/target/jruby-core-$jar_version-noasm.jar 9
check core/target/jruby-core-$jar_version.jar 9
check core/target/jruby-core-$jar_version-complete.jar 12
check truffle/target/jruby-truffle-$jar_version.jar 8
check truffle/target/jruby-truffle-$jar_version-complete.jar 8

exit "${failed[0]}"