glib2 1.1.2-x86-mingw32 → 1.1.3-x86-mingw32

Sign up to get free protection for your applications and to get access to all the features.
data/lib/1.8/glib2.so CHANGED
Binary file
data/lib/1.9/glib2.so CHANGED
Binary file
data/lib/glib-mkenums.rb CHANGED
@@ -40,7 +40,7 @@ module GLib
40
40
  end
41
41
  constants = []
42
42
  const_lines.scan(/^\s*([^\s,]*).*\n/) do |name|
43
- constants << name[0] unless name[0] =~ /(^[\/\*]|^$)/
43
+ constants << name[0] unless name[0] =~ /(^[\/\*]|^#|^$)/
44
44
  end
45
45
  @prefix = extract_prefix(constants)
46
46
  constants.each do |name|
@@ -13,7 +13,7 @@ require 'rake/extensiontask'
13
13
  class GNOME2Package
14
14
  include Rake::DSL
15
15
 
16
- attr_accessor :name, :summary, :description, :author, :email, :homepage, :post_install_message
16
+ attr_accessor :name, :summary, :description, :author, :email, :homepage, :required_ruby_version, :post_install_message
17
17
  def initialize
18
18
  initialize_variables
19
19
  initialize_configurations
@@ -97,6 +97,7 @@ class GNOME2Package
97
97
  "{ext,sample,test,test-unit}/**/*"]
98
98
  files.existing!
99
99
  s.files = files
100
+ s.required_ruby_version = @required_ruby_version || ">= 1.8.5"
100
101
  s.post_install_message = @post_install_message
101
102
  @dependency_configuration.apply(s)
102
103
  end
@@ -158,7 +159,6 @@ class GNOME2Package
158
159
  def initialize(package)
159
160
  @package = package
160
161
  @platform = Gem::Platform::RUBY
161
- @ruby = ">=1.8.5"
162
162
  @gem_configuration = GemConfiguration.new(@package)
163
163
  end
164
164
 
@@ -168,7 +168,6 @@ class GNOME2Package
168
168
 
169
169
  def apply(spec)
170
170
  spec.platform = @platform
171
- spec.required_ruby_version = @ruby
172
171
  @gem_configuration.apply(spec)
173
172
  end
174
173
 
data/test/test_unicode.rb CHANGED
@@ -351,7 +351,11 @@ class TestGLibUnicode < Test::Unit::TestCase
351
351
 
352
352
  def utf8_to_utf32(string)
353
353
  if string.respond_to?(:encode)
354
- string.encode("UTF-32LE")
354
+ if little_endian?
355
+ string.encode("UTF-32LE")
356
+ else
357
+ string.encode("UTF-32BE")
358
+ end
355
359
  else
356
360
  require_uconv
357
361
  Uconv.u8tou4(string)
@@ -360,7 +364,11 @@ class TestGLibUnicode < Test::Unit::TestCase
360
364
 
361
365
  def utf8_to_utf16(string)
362
366
  if string.respond_to?(:encode)
363
- string.encode("UTF-16LE")
367
+ if little_endian?
368
+ string.encode("UTF-16LE")
369
+ else
370
+ string.encode("UTF-16BE")
371
+ end
364
372
  else
365
373
  require_uconv
366
374
  Uconv.u8tou16(string)
@@ -379,4 +387,8 @@ class TestGLibUnicode < Test::Unit::TestCase
379
387
  end
380
388
  string
381
389
  end
390
+
391
+ def little_endian?
392
+ [1].pack("v") == [1].pack("S")
393
+ end
382
394
  end
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: glib2
3
3
  version: !ruby/object:Gem::Version
4
- hash: 23
4
+ hash: 21
5
5
  prerelease:
6
6
  segments:
7
7
  - 1
8
8
  - 1
9
- - 2
10
- version: 1.1.2
9
+ - 3
10
+ version: 1.1.3
11
11
  platform: x86-mingw32
12
12
  authors:
13
13
  - The Ruby-GNOME2 Project Team
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2012-01-15 00:00:00 Z
18
+ date: 2012-04-08 00:00:00 Z
19
19
  dependencies:
20
20
  - !ruby/object:Gem::Dependency
21
21
  name: pkg-config
@@ -999,7 +999,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
999
999
  requirements: []
1000
1000
 
1001
1001
  rubyforge_project:
1002
- rubygems_version: 1.8.12
1002
+ rubygems_version: 1.8.15
1003
1003
  signing_key:
1004
1004
  specification_version: 3
1005
1005
  summary: Ruby/GLib2 is a Ruby binding of GLib-2.x.