| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
If a build wishes to generate some of the extension source files then
the pattern input is insufficient. Provide a place to stash an
additional FileList that will then become a dependency of the compile
tasks.
Example:
```ruby
file 'ext/libfoo/generated.c' do |t|
open(t.name, 'w+) { |f| f << '#include <foo.h>' }
end
Rake::ExtensionTask.new('foo') do |ext|
ext.extra_sources << 'generated.c'
end
```
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Since Rubygems 3.3.21, the Gem::Platform name always contains the
library version for gnu platforms. So where the rake-compiler config
entries previously were:
```yaml
---
rbconfig-x86_64-linux-gnu-2.7.0: "/usr/local/rake-compiler/ruby/x86_64-redhat-linux/ruby-2.7.0/lib/ruby/2.7.0/x86_64-linux-gnu/rbconfig.rb"
rbconfig-x86_64-linux-2.7.0: "/usr/local/rake-compiler/ruby/x86_64-redhat-linux/ruby-2.7.0/lib/ruby/2.7.0/x86_64-linux-gnu/rbconfig.rb"
```
with later versions of rubygems, it is only
```yaml
---
rbconfig-x86_64-linux-gnu-2.7.0: "/usr/local/rake-compiler/ruby/x86_64-redhat-linux/ruby-2.7.0/lib/ruby/2.7.0/x86_64-linux-gnu/rbconfig.rb"
```
This means that the current way of finding a matching runtime, by doing
a string comparison on the config keys, is no longer appropriate. This
is causing failing builds downstream in `rake-compiler-dock`.
This PR:
- extracts a new CompilerConfig class to encapsulate the logic
- uses `Gem::Platform#=~` to tell if the gem platform matches the
runtime platform
|
| |
|
| |
|
|
|
|
|
|
|
| |
(#199)
The required_ruby_version was set twice, although one in define_native_tasks is enough.
Fixes #198
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Make customizable compiler Xlint option for JRuby native extension
* [CS] restructure and fix indentation of (defaults) spec
* Add specs for lint_option
* [DOC] CHANGELOG: stub changelog entry for the next release
* [DOC] CHANGELOG: Make customizable compiler Xlint option for JRuby native extension
* Use "-Xlint" option for JRuby native extension by default.
`javac -help -X`
> -Xlint Enable recommended warnings
|
|
|
|
|
|
| |
GitHub: fix #150
Reported by MSP-Greg. Thanks!!!
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
| |
One spec is obsolete now, since we no longer generate rbconfig.rb
|
|
|
|
| |
Resolves #98
|
| |
|
| |
|
|
|
|
|
|
|
|
| |
add Ruby 2.1 support in Spec tests
Debian bugs:
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=746084
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=747723
|
|
|
|
|
| |
These known/unknown platform pairs are required for tests to run
under Ruby 2.0.0
|
|
|
|
|
|
|
|
|
|
|
| |
Building gems for distinct platforms within one rake run conflicted
in the lib/ directory, because all binary extensions were stored
there and were copied from there to become packaged.
This resulted in storing a binary extension of a wrong platform in
a gem.
To avoid this, the files to package are now stored in a platform specific
stage directory and are used to package the specific gem.
|
|
|
|
|
| |
This is especially useful to set distinct library paths for different
target platforms.
|
|
|
|
|
|
|
|
|
| |
Also prefix the selection of rbconfig in config.yml with the corresponding
Ruby platform.
This allowes to use cross compiled Ruby-builds for multiple target
architectures on the same machine. This is especially usefull to compile
for Ruby-2.0 i386-mingw32 and x64-mingw32 platforms.
|
| |
|
| |
|
|
|
|
| |
This fixes issue #16.
|
| |
|
| |
|
| |
|
| |
|
|
|
|
| |
Minor adjustment and completion of JavaExtensionTask specs.
|
|
|
|
|
|
|
|
|
|
|
|
| |
This is useful to indicate a custom requirement message, like DLLs
installation or similar.
Rake::ExtensionTask.new('my_extension', GEM_SPEC) do |ext|
ext.cross_compile = true
ext.cross_compiling do |gem_spec|
gem_spec.post_install_message = "You've installed a binary version of this gem"
end
end
|
|
|
|
| |
Please read History entry about usage of RUBY_CC_VERSION.
|
|
|
|
|
|
|
|
| |
This is in preparation for fat-binaries work.
rake cross compile RUBY_CC_VERSION=1.8.6:1.9.1
Will generate binaries for both 1.8.6 and 1.9.1 compilers.
|
| |
|
|
|
|
|
|
| |
Be warned: works from 1.8 to 1.9, but not if your default ruby is 1.9.
There are some issues inside mkmf.rb that limits this, needs further
investigation.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
- This allows build gems for both VC6 and MinGW builts of Ruby.
Rake::ExtensionTask.new('my_extension', GEM_SPEC) do |ext|
ext.cross_compile = true
ext.cross_platform = ['i386-mswin32', 'i386-mingw32']
end
This is highly experimental and exposed the need to refactor
ExtensionTask internals. Right now it fires the compilation
process twice, which is suboptimal.
|
|
|
|
| |
Made more sense for nested example groups.
|
|
|
|
|
| |
- It no longer raises an error, but instead a warning.
- Uses captured console output.
|
|
|
|
|
|
|
|
|
| |
During cross compilation, rake-compiler will create a fake.rb
file to mimic a different version than the one used to execute
the build process.
Yet still, there are some changes between 1.9 and 1.8 not yet
ironed.
|
|
|
|
|
| |
This is part of the work required for getting you
compile a extension from one version of ruby targetting another.
|
|
|
|
| |
This allow define ext_dir for custom extension location.
|
|
|
|
|
| |
This makes 'rake cross compile' more flexible when multiple Ruby versions
exists into rake-compiler directory.
|
|
|
|
|
| |
This broke execution on Windows.
Yet still 'cross' should only be defined certain platforms.
|
|
|
|
|
|
|
|
|
|
| |
Now is possible to rely on rake-compiler to cross compile extensions.
rake compile #=> builds binaries for current platform
rake cross compile #=> builds binaries using cross-ruby
rake native gem #=> generates ruby and native gems.
rake cross native gem #=> generates ruby and cross platform native gems.
|
| |
|
|
|
|
|
| |
* It now only chains for current platform, open the door for cross compilation.
* Ensure proper binary gets copied to lib folder prior generation of gem.
|