ffi 1.6.0-java → 1.7.0-java

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of ffi might be problematic. Click here for more details.

Files changed (3) hide show
  1. checksums.yaml +7 -0
  2. data/Rakefile +27 -32
  3. metadata +21 -42
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 91e33105d557f4deeaf616c0766a3eac33a21162
4
+ data.tar.gz: c1dd9d8aa3c421cfac9fc39c352ce2e546219ab2
5
+ SHA512:
6
+ metadata.gz: 23bf17b14f6a7ab9d340a832d46b987291ff77d806d19b286ef53efb9261e89526a06f56edb36048850dc44ddae67fd41a87b82db4612911a4e67a852b93d132
7
+ data.tar.gz: 403d77ed7b45c976910df7d302a7f78478c69477d2d7b9f7e84066eab661f2db4065c2fd487b827155160a8c077e501460140e4939dc494ab64d6c4d60880700
data/Rakefile CHANGED
@@ -1,5 +1,6 @@
1
1
  require 'rubygems'
2
2
  require 'rubygems/package_task'
3
+ require 'rubygems/tasks'
3
4
  require 'rbconfig'
4
5
 
5
6
  USE_RAKE_COMPILER = (RUBY_PLATFORM =~ /java/) ? false : true
@@ -64,8 +65,6 @@ OS = case RbConfig::CONFIG['host_os'].downcase
64
65
  RbConfig::CONFIG['host_os'].downcase
65
66
  end
66
67
 
67
- CC = ENV['CC'] || RbConfig::CONFIG['CC'] || "gcc"
68
-
69
68
  GMAKE = system('which gmake >/dev/null') && 'gmake' || 'make'
70
69
 
71
70
  LIBTEST = "build/libtest.#{LIBEXT}"
@@ -76,12 +75,6 @@ def gem_spec
76
75
  @gem_spec ||= Gem::Specification.load('ffi.gemspec')
77
76
  end
78
77
 
79
- Gem::PackageTask.new(gem_spec) do |pkg|
80
- pkg.need_zip = true
81
- pkg.need_tar = true
82
- pkg.package_dir = 'pkg'
83
- end
84
-
85
78
  TEST_DEPS = [ LIBTEST ]
86
79
  if RUBY_PLATFORM == "java"
87
80
  desc "Run all specs"
@@ -109,25 +102,15 @@ end
109
102
  desc "Build all packages"
110
103
  task :package => 'gem:package'
111
104
 
112
- desc "Install the gem locally"
113
- task :install => 'gem:install'
114
105
 
115
- namespace :gem do
116
- task :install => :gem do
117
- ruby %{ -S gem install pkg/ffi-#{gem_spec.version}.gem }
118
- end
119
- end
120
-
121
- desc "Clean all built files"
122
- task :distclean => :clobber do
123
- FileUtils.rm_rf('build')
124
- FileUtils.rm_rf(Dir["lib/**/ffi_c.#{RbConfig::CONFIG['DLEXT']}"])
125
- FileUtils.rm_rf(Dir["lib/**/ffi_c.so"])
126
- FileUtils.rm_rf('lib/ffi/types.conf')
127
- FileUtils.rm_rf('conftest.dSYM')
128
- FileUtils.rm_rf('pkg')
129
- end
106
+ CLOBBER.include 'build'
107
+ CLOBBER.include FileList['lib/**/ffi_c.so']
108
+ CLOBBER.include FileList["lib/**/ffi_c.#{RbConfig::CONFIG['DLEXT']}"]
109
+ CLOBBER.include 'lib/ffi/types.conf'
110
+ CLOBBER.include 'conftest.dSYM'
111
+ CLOBBER.include 'pkg'
130
112
 
113
+ task :distclean => :clobber
131
114
 
132
115
  desc "Build the native test lib"
133
116
  file "build/libtest.#{LIBEXT}" => FileList['libtest/**/*.[ch]'] do
@@ -200,18 +183,30 @@ if USE_RAKE_COMPILER
200
183
  # ext.lib_dir = BUILD_DIR # put binaries into this folder.
201
184
  ext.tmp_dir = BUILD_DIR # temporary folder used during compilation.
202
185
  ext.cross_compile = true # enable cross compilation (requires cross compile toolchain)
203
- ext.cross_platform = 'i386-mingw32' # forces the Windows platform instead of the default one
186
+ ext.cross_platform = %w[i386-mingw32 x64-mingw32] # forces the Windows platform instead of the default one
204
187
  end
205
188
 
206
- task 'copy:ffi_c:i386-mingw32:1.9.3' do |t|
207
- sh "i686-w64-mingw32-strip -S lib/1.9/ffi_c.so"
208
- end
209
-
210
- task 'copy:ffi_c:i386-mingw32:2.0.0' do |t|
211
- sh "i686-w64-mingw32-strip -S lib/2.0/ffi_c.so"
189
+ ENV['RUBY_CC_VERSION'].to_s.split(':').each do |ruby_version|
190
+ task "copy:ffi_c:i386-mingw32:#{ruby_version}" do |t|
191
+ %w[lib #{BUILD_DIR}/i386-mingw32/stage/lib].each do |dir|
192
+ if File.exists?("#{dir}/#{ruby_version[/^\d+\.\d+/]}/ffi_c.so")
193
+ sh "i686-w64-mingw32-strip -S #{dir}/#{ruby_version[/^\d+\.\d+/]}/ffi_c.so"
194
+ end
195
+ end
196
+ end
197
+
198
+ task "copy:ffi_c:x64-mingw32:#{ruby_version}" do |t|
199
+ if File.exists?("#{BUILD_DIR}/x64-mingw32/stage/lib/#{ruby_version[/^\d+\.\d+/]}/ffi_c.so")
200
+ sh "x86_64-w64-mingw32-strip -S #{dir}/#{ruby_version[/^\d+\.\d+/]}/ffi_c.so"
201
+ end
202
+ end
212
203
  end
213
204
  end
214
205
 
206
+ Gem::Tasks.new do |t|
207
+ t.scm.tag.format = '%s'
208
+ end
209
+
215
210
  begin
216
211
  require 'yard'
217
212
 
metadata CHANGED
@@ -1,32 +1,21 @@
1
- --- !ruby/object:Gem::Specification
1
+ --- !ruby/object:Gem::Specification
2
2
  name: ffi
3
- version: !ruby/object:Gem::Version
4
- hash: 15
5
- prerelease:
6
- segments:
7
- - 1
8
- - 6
9
- - 0
10
- version: 1.6.0
3
+ version: !ruby/object:Gem::Version
4
+ version: 1.7.0
11
5
  platform: java
12
- authors:
6
+ authors:
13
7
  - Wayne Meissner
14
8
  autorequire:
15
9
  bindir: bin
16
10
  cert_chain: []
17
-
18
- date: 2013-03-26 00:00:00 Z
11
+ date: 2013-04-12 00:00:00.000000000 Z
19
12
  dependencies: []
20
-
21
13
  description: Ruby FFI library
22
14
  email: wmeissner@gmail.com
23
15
  executables: []
24
-
25
16
  extensions: []
26
-
27
17
  extra_rdoc_files: []
28
-
29
- files:
18
+ files:
30
19
  - History.txt
31
20
  - LICENSE
32
21
  - COPYING
@@ -34,37 +23,27 @@ files:
34
23
  - README.md
35
24
  - Rakefile
36
25
  homepage: http://wiki.github.com/ffi/ffi
37
- licenses:
26
+ licenses:
38
27
  - LGPL-3
28
+ metadata: {}
39
29
  post_install_message:
40
30
  rdoc_options: []
41
-
42
- require_paths:
31
+ require_paths:
43
32
  - lib
44
- required_ruby_version: !ruby/object:Gem::Requirement
45
- none: false
46
- requirements:
47
- - - ">="
48
- - !ruby/object:Gem::Version
49
- hash: 3
50
- segments:
51
- - 0
52
- version: "0"
53
- required_rubygems_version: !ruby/object:Gem::Requirement
54
- none: false
55
- requirements:
56
- - - ">="
57
- - !ruby/object:Gem::Version
58
- hash: 3
59
- segments:
60
- - 0
61
- version: "0"
33
+ required_ruby_version: !ruby/object:Gem::Requirement
34
+ requirements:
35
+ - - '>='
36
+ - !ruby/object:Gem::Version
37
+ version: '0'
38
+ required_rubygems_version: !ruby/object:Gem::Requirement
39
+ requirements:
40
+ - - '>='
41
+ - !ruby/object:Gem::Version
42
+ version: '0'
62
43
  requirements: []
63
-
64
44
  rubyforge_project:
65
- rubygems_version: 1.8.24
45
+ rubygems_version: 2.0.0
66
46
  signing_key:
67
- specification_version: 3
47
+ specification_version: 4
68
48
  summary: Ruby FFI
69
49
  test_files: []
70
-