RubyInline 3.11.2 → 3.11.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (5) hide show
  1. data.tar.gz.sig +2 -1
  2. data/History.txt +6 -0
  3. data/lib/inline.rb +24 -11
  4. metadata +13 -13
  5. metadata.gz.sig +0 -0
data.tar.gz.sig CHANGED
@@ -1 +1,2 @@
1
- ��d6��jmM�
1
+ r�Cۊ��u�ؗ��4�ܙ,�kl��#�룈�H�H�A�*F�xE+*gB���zU1Ŷ������#6txv…I�$#���.���⎕.:��
2
+ �"*eo��K��#���n�0M
data/History.txt CHANGED
@@ -1,3 +1,9 @@
1
+ === 3.11.3 / 2012-07-05
2
+
3
+ * 1 bug fix:
4
+
5
+ * Fixes for non-mingw windoze builds. (imperator)
6
+
1
7
  === 3.11.2 / 2012-02-22
2
8
 
3
9
  * 1 bug fix:
data/lib/inline.rb CHANGED
@@ -65,7 +65,7 @@ class CompilationError < RuntimeError; end
65
65
  # the current namespace.
66
66
 
67
67
  module Inline
68
- VERSION = '3.11.2'
68
+ VERSION = '3.11.3'
69
69
 
70
70
  WINDOZE = /mswin|mingw/ =~ RUBY_PLATFORM
71
71
  RUBINIUS = defined? RUBY_ENGINE
@@ -293,7 +293,8 @@ module Inline
293
293
  0
294
294
  end
295
295
 
296
- file, line = caller[1].split(/:/)
296
+ file, line = $1, $2 if caller[1] =~ /(.*?):(\d+)/
297
+
297
298
  result = "# line #{line.to_i + delta} \"#{file}\"\n" + result unless
298
299
  $DEBUG and not $TESTING
299
300
 
@@ -567,32 +568,44 @@ VALUE #{method}_equals(VALUE value) {
567
568
  nil
568
569
  end
569
570
 
571
+ windoze = WINDOZE and RUBY_PLATFORM =~ /mswin/
572
+ sane = ! windoze
570
573
  cmd = [ RbConfig::CONFIG['LDSHARED'],
571
574
  flags,
572
- RbConfig::CONFIG['DLDFLAGS'],
573
- RbConfig::CONFIG['CCDLFLAGS'],
575
+ (RbConfig::CONFIG['DLDFLAGS'] if sane),
576
+ (RbConfig::CONFIG['CCDLFLAGS'] if sane),
574
577
  RbConfig::CONFIG['CFLAGS'],
575
- RbConfig::CONFIG['LDFLAGS'],
578
+ (RbConfig::CONFIG['LDFLAGS'] if sane),
576
579
  '-I', hdrdir,
577
580
  config_hdrdir,
578
581
  '-I', RbConfig::CONFIG['includedir'],
579
- "-L#{RbConfig::CONFIG['libdir']}",
580
- '-o', so_name.inspect,
582
+ ("-L#{RbConfig::CONFIG['libdir']}" if sane),
583
+ (['-o', so_name.inspect] if sane),
581
584
  File.expand_path(src_name).inspect,
582
585
  libs,
583
- crap_for_windoze ].join(' ')
586
+ crap_for_windoze,
587
+ (RbConfig::CONFIG['LDFLAGS'] if windoze),
588
+ (RbConfig::CONFIG['CCDLFLAGS'] if windoze),
589
+ ].compact.join(' ')
584
590
 
585
591
  # strip off some makefile macros for mingw 1.9
586
592
  cmd = cmd.gsub(/\$\(.*\)/, '') if RUBY_PLATFORM =~ /mingw/
587
-
593
+
588
594
  # TODO: remove after osx 10.5.2
589
595
  cmd += ' -flat_namespace -undefined suppress' if
590
596
  RUBY_PLATFORM =~ /darwin9\.[01]/
591
597
  cmd += " 2> #{DEV_NULL}" if $TESTING and not $DEBUG
592
598
 
593
599
  warn "Building #{so_name} with '#{cmd}'" if $DEBUG
594
- result = `#{cmd}`
600
+
601
+ result = if WINDOZE
602
+ Dir.chdir(Inline.directory) { `#{cmd}` }
603
+ else
604
+ `#{cmd}`
605
+ end
606
+
595
607
  warn "Output:\n#{result}" if $DEBUG
608
+
596
609
  if $? != 0 then
597
610
  bad_src_name = src_name + ".bad"
598
611
  File.rename src_name, bad_src_name
@@ -630,7 +643,7 @@ VALUE #{method}_equals(VALUE value) {
630
643
  # gawd windoze land sucks
631
644
  case RUBY_PLATFORM
632
645
  when /mswin32/ then
633
- " -link /LIBPATH:\"#{RbConfig::CONFIG['libdir']}\" /DEFAULTLIB:\"#{RbConfig::CONFIG['LIBRUBY']}\" /INCREMENTAL:no /EXPORT:Init_#{module_name}"
646
+ " -link /OUT:\"#{self.so_name}\" /LIBPATH:\"#{RbConfig::CONFIG['libdir']}\" /DEFAULTLIB:\"#{RbConfig::CONFIG['LIBRUBY']}\" /INCREMENTAL:no /EXPORT:Init_#{module_name}"
634
647
  when /mingw32/ then
635
648
  c = RbConfig::CONFIG
636
649
  " -Wl,--enable-auto-import -L#{c['libdir']} -l#{c['RUBY_SO_NAME']}"
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: RubyInline
3
3
  version: !ruby/object:Gem::Version
4
- hash: 47
4
+ hash: 45
5
5
  prerelease:
6
6
  segments:
7
7
  - 3
8
8
  - 11
9
- - 2
10
- version: 3.11.2
9
+ - 3
10
+ version: 3.11.3
11
11
  platform: ruby
12
12
  authors:
13
13
  - Ryan Davis
@@ -36,7 +36,7 @@ cert_chain:
36
36
  FBHgymkyj/AOSqKRIpXPhjC6
37
37
  -----END CERTIFICATE-----
38
38
 
39
- date: 2012-02-22 00:00:00 Z
39
+ date: 2012-07-05 00:00:00 Z
40
40
  dependencies:
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: ZenTest
@@ -61,11 +61,11 @@ dependencies:
61
61
  requirements:
62
62
  - - ~>
63
63
  - !ruby/object:Gem::Version
64
- hash: 21
64
+ hash: 7
65
65
  segments:
66
- - 2
67
- - 11
68
- version: "2.11"
66
+ - 3
67
+ - 0
68
+ version: "3.0"
69
69
  type: :development
70
70
  version_requirements: *id002
71
71
  - !ruby/object:Gem::Dependency
@@ -91,11 +91,11 @@ dependencies:
91
91
  requirements:
92
92
  - - ~>
93
93
  - !ruby/object:Gem::Version
94
- hash: 31
94
+ hash: 7
95
95
  segments:
96
- - 2
97
- - 14
98
- version: "2.14"
96
+ - 3
97
+ - 0
98
+ version: "3.0"
99
99
  type: :development
100
100
  version_requirements: *id004
101
101
  description: |-
@@ -161,7 +161,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
161
161
  requirements:
162
162
  - A POSIX environment and a compiler for your language.
163
163
  rubyforge_project: rubyinline
164
- rubygems_version: 1.8.12
164
+ rubygems_version: 1.8.24
165
165
  signing_key:
166
166
  specification_version: 3
167
167
  summary: Inline allows you to write foreign code within your ruby code
metadata.gz.sig CHANGED
Binary file