libyajl2 0.1.0 → 0.1.1

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
- ---
2
- SHA512:
3
- metadata.gz: 5dbedf1028114881a28ab6fc7b925d207690d7073eca4d73357844584ad9a76af5697ab06a505c5ae89d138ca53660bdc2cc40392f9df50ed9c2825a53c512e6
4
- data.tar.gz: 1fbcf514126955bd725b0d5b75c115218d742794decfe3a24b4075ccb7d14c95840eacbf3c7bd03c5706b0029fff8577e1aec00f4dc0db13e72f753d92f8366b
5
- SHA1:
6
- metadata.gz: d7f4f98a8b1c0f6a2d8cf44edd8ece0cabd35dc0
7
- data.tar.gz: 3f63bf8fa8e558b4efa3141e7ec834934d5e413c
1
+ ---
2
+ SHA1:
3
+ metadata.gz: b20f419f27c045bd88357a6a08a40d6d1be8700f
4
+ data.tar.gz: a7da02a958918fa084a1fb39513cf1e3bfd1be6e
5
+ SHA512:
6
+ metadata.gz: 6661966c7d6ac9884dca7bb0262c1f91db71180e9112033c4a4e55a6a8caf7075b29f13158d8e8e0fcc22a0de40909fed1810d854f7d1cb9ceffffa6a729ef96
7
+ data.tar.gz: 4c9afd6f51c00697135b59240b1e77372de0d0992a14a8ccac3492d85471366a1f1fd74170cdb5ec3b9038f5fc56fba41155843084935eb11ca59b27319d11fb
@@ -23,20 +23,25 @@ module Libyajl2Build
23
23
  end
24
24
 
25
25
  def self.setup_env
26
+ if config['CC'] =~ /gcc/ || config['CC'] =~ /clang/
27
+ config['CFLAGS'] << " -std=c99 -pedantic -Wpointer-arith -Wno-format-y2k -Wstrict-prototypes -Wmissing-declarations -Wnested-externs -Wextra -Wundef -Wwrite-strings -Wold-style-definition -Wredundant-decls -Wno-unused-parameter -Wno-sign-compare -Wmissing-prototypes"
28
+ end
26
29
  end
27
30
 
28
31
  # for mkmf.rb compat
29
- CONFIG = RbConfig::MAKEFILE_CONFIG
32
+ def self.config
33
+ @config ||= RbConfig::MAKEFILE_CONFIG.dup
34
+ end
30
35
 
31
36
  def self.mkintpath(path)
32
- case CONFIG['build_os']
37
+ case config['build_os']
33
38
  when 'mingw32'
34
39
  path = path.dup
35
40
  path.tr!('\\', '/')
36
41
  path.sub!(/\A([A-Za-z]):(?=\/)/, '/\1')
37
42
  path
38
43
  when 'cygwin'
39
- if CONFIG['target_os'] != 'cygwin'
44
+ if config['target_os'] != 'cygwin'
40
45
  IO.popen(["cygpath", "-u", path], &:read).chomp
41
46
  else
42
47
  path
@@ -90,7 +95,7 @@ ECHO = $(ECHO1:0=@echo)
90
95
  #### Start of system configuration section. ####
91
96
 
92
97
  srcdir = .
93
- prefix = #{mkintpath(CONFIG['prefix'])}
98
+ prefix = #{mkintpath(config['prefix'])}
94
99
  rubylibprefix = $(libdir)/$(RUBY_BASE_NAME)
95
100
  exec_prefix = $(prefix)
96
101
  sitearchdir = $(sitelibdir)/$(sitearch)
@@ -98,36 +103,36 @@ sitelibdir = $(sitedir)/$(ruby_version)
98
103
  sitedir = $(rubylibprefix)/site_ruby
99
104
  libdir = $(exec_prefix)/lib
100
105
 
101
- CC = #{CONFIG['CC']}
106
+ CC = #{config['CC']}
102
107
  COUTFLAG = '-o'
103
108
 
104
- cflags = #{CONFIG['cflags']}
105
- optflags = #{CONFIG['optflags']}
106
- debugflags = #{CONFIG['debugflags']}
107
- warnflags = #{CONFIG['warnflags']}
108
- CCDLFLAGS = #{CONFIG['CCDLFLAGS']}
109
- CFLAGS = $(CCDLFLAGS) -I#{libyajl2_vendor_dir}/src/api -I. #{CONFIG['CFLAGS']} $(ARCH_FLAG)
109
+ cflags = #{config['cflags']}
110
+ optflags = #{config['optflags']}
111
+ debugflags = #{config['debugflags']}
112
+ warnflags = #{config['warnflags']}
113
+ CCDLFLAGS = #{config['CCDLFLAGS']}
114
+ CFLAGS = $(CCDLFLAGS) -I#{libyajl2_vendor_dir}/src/api -I. #{config['CFLAGS']} $(ARCH_FLAG)
110
115
  INCFLAGS = -I. -I$(srcdir)
111
- DEFS = #{CONFIG['DEFS']}
112
- CPPFLAGS = #{CONFIG['CPPFLAGS']} $(cppflags)
113
- ldflags = #{CONFIG['LDFLAGS']}
116
+ DEFS = #{config['DEFS']}
117
+ CPPFLAGS = #{config['CPPFLAGS']} $(cppflags)
118
+ ldflags = #{config['LDFLAGS']}
114
119
  #dldflags = -Wl,-undefined,dynamic_lookup -Wl,-multiply_defined,suppress
115
- dldflags = #{CONFIG['DLDFLAGS']} #{CONFIG['EXTDLDFLAGS']}
116
- ARCH_FLAG = #{CONFIG['ARCH_FLAG']}
120
+ dldflags = #{config['DLDFLAGS']} #{config['EXTDLDFLAGS']}
121
+ ARCH_FLAG = #{config['ARCH_FLAG']}
117
122
  DLDFLAGS = $(ldflags) $(dldflags) $(ARCH_FLAG)
118
- LDSHARED = #{CONFIG['LDSHARED']}
123
+ LDSHARED = #{config['LDSHARED']}
119
124
 
120
- RUBY_INSTALL_NAME = #{CONFIG['RUBY_INSTALL_NAME']}
121
- RUBY_SO_NAME = #{CONFIG['RUBY_SO_NAME']}
122
- RUBYW_INSTALL_NAME = #{CONFIG['RUBYW_INSTALL_NAME']}
123
- RUBY_VERSION_NAME = #{CONFIG['RUBY_VERSION_NAME']}
124
- RUBYW_BASE_NAME = #{CONFIG['RUBYW_BASE_NAME']}
125
- RUBY_BASE_NAME = #{CONFIG['RUBY_BASE_NAME']}
125
+ RUBY_INSTALL_NAME = #{config['RUBY_INSTALL_NAME']}
126
+ RUBY_SO_NAME = #{config['RUBY_SO_NAME']}
127
+ RUBYW_INSTALL_NAME = #{config['RUBYW_INSTALL_NAME']}
128
+ RUBY_VERSION_NAME = #{config['RUBY_VERSION_NAME']}
129
+ RUBYW_BASE_NAME = #{config['RUBYW_BASE_NAME']}
130
+ RUBY_BASE_NAME = #{config['RUBY_BASE_NAME']}
126
131
 
127
- arch = #{CONFIG['arch']}
128
- sitearch = #{CONFIG['sitearch']}
132
+ arch = #{config['arch']}
133
+ sitearch = #{config['sitearch']}
129
134
  ruby_version = #{RbConfig::CONFIG['ruby_version']}
130
- ruby = #{File.join(RbConfig::CONFIG["bindir"], CONFIG["ruby_install_name"])}
135
+ ruby = #{File.join(RbConfig::CONFIG["bindir"], config["ruby_install_name"])}
131
136
  RUBY = $(ruby)
132
137
 
133
138
  RM = $(RUBY) -run -e rm -- -f
@@ -144,13 +149,13 @@ LIBPATH = -L. -L$(libdir)
144
149
  CLEANFILES = mkmf.log
145
150
 
146
151
  target_prefix =
147
- LIBS = #{CONFIG['LIBS']} #{CONFIG['DLDLIBS']}
152
+ LIBS = #{config['LIBS']} #{config['DLDLIBS']}
148
153
  ORIG_SRCS = yajl.c yajl_alloc.c yajl_buf.c yajl_encode.c yajl_gen.c yajl_lex.c yajl_parser.c yajl_tree.c yajl_version.c
149
154
  SRCS = $(ORIG_SRCS)
150
155
  OBJS = yajl.o yajl_alloc.o yajl_buf.o yajl_encode.o yajl_gen.o yajl_lex.o yajl_parser.o yajl_tree.o yajl_version.o
151
156
  HDRS = yajl_alloc.h yajl_buf.h yajl_bytestack.h yajl_encode.h yajl_lex.h yajl_parser.h
152
157
  TARGET = libyajl
153
- DLLIB = $(TARGET).#{CONFIG['DLEXT']}
158
+ DLLIB = $(TARGET).#{config['DLEXT']}
154
159
 
155
160
  TIMESTAMP_DIR = .
156
161
  RUBYARCHDIR = $(sitearchdir)$(target_prefix)
@@ -203,7 +208,7 @@ EOF
203
208
  File.open("Makefile", "w+") do |f|
204
209
  f.write <<EOF
205
210
  TARGET = libyajl
206
- DLLIB = $(TARGET).#{CONFIG['DLEXT']}
211
+ DLLIB = $(TARGET).#{config['DLEXT']}
207
212
  all:
208
213
  \tcd #{libyajl2_vendor_dir}/src && make
209
214
  \tcp #{libyajl2_vendor_dir}/src/$(DLLIB) .
@@ -1,3 +1,3 @@
1
1
  module Libyajl2
2
- VERSION = "0.1.0"
2
+ VERSION = "0.1.1"
3
3
  end
metadata CHANGED
@@ -1,91 +1,115 @@
1
- --- !ruby/object:Gem::Specification
1
+ --- !ruby/object:Gem::Specification
2
2
  name: libyajl2
3
- version: !ruby/object:Gem::Version
4
- version: 0.1.0
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.1.1
5
5
  platform: ruby
6
- authors:
6
+ authors:
7
7
  - lamont-granquist
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
-
12
- date: 2014-05-14 00:00:00 Z
13
- dependencies:
14
- - !ruby/object:Gem::Dependency
15
- requirement: &id001 !ruby/object:Gem::Requirement
16
- requirements:
17
- - &id002
18
- - ">="
19
- - !ruby/object:Gem::Version
20
- version: "0"
21
- version_requirements: *id001
22
- prerelease: false
23
- type: :development
11
+ date: 2014-05-14 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
24
14
  name: bundler
25
- - !ruby/object:Gem::Dependency
26
- requirement: &id003 !ruby/object:Gem::Requirement
27
- requirements:
28
- - *id002
29
- version_requirements: *id003
30
- prerelease: false
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - ">="
18
+ - !ruby/object:Gem::Version
19
+ version: '0'
31
20
  type: :development
32
- name: rake
33
- - !ruby/object:Gem::Dependency
34
- requirement: &id004 !ruby/object:Gem::Requirement
35
- requirements:
36
- - *id002
37
- version_requirements: *id004
38
21
  prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - ">="
25
+ - !ruby/object:Gem::Version
26
+ version: '0'
27
+ - !ruby/object:Gem::Dependency
28
+ name: rake
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - ">="
32
+ - !ruby/object:Gem::Version
33
+ version: '0'
39
34
  type: :development
40
- name: rake-compiler
41
- - !ruby/object:Gem::Dependency
42
- requirement: &id005 !ruby/object:Gem::Requirement
43
- requirements:
44
- - - ~>
45
- - !ruby/object:Gem::Version
46
- version: "1.16"
47
- version_requirements: *id005
48
35
  prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - ">="
39
+ - !ruby/object:Gem::Version
40
+ version: '0'
41
+ - !ruby/object:Gem::Dependency
42
+ name: rake-compiler
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - ">="
46
+ - !ruby/object:Gem::Version
47
+ version: '0'
49
48
  type: :development
50
- name: mime-types
51
- - !ruby/object:Gem::Dependency
52
- requirement: &id006 !ruby/object:Gem::Requirement
53
- requirements:
54
- - - ~>
55
- - !ruby/object:Gem::Version
56
- version: "2.14"
57
- version_requirements: *id006
58
49
  prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - ">="
53
+ - !ruby/object:Gem::Version
54
+ version: '0'
55
+ - !ruby/object:Gem::Dependency
56
+ name: mime-types
57
+ requirement: !ruby/object:Gem::Requirement
58
+ requirements:
59
+ - - "~>"
60
+ - !ruby/object:Gem::Version
61
+ version: '1.16'
59
62
  type: :development
60
- name: rspec
61
- - !ruby/object:Gem::Dependency
62
- requirement: &id007 !ruby/object:Gem::Requirement
63
- requirements:
64
- - - ~>
65
- - !ruby/object:Gem::Version
66
- version: "1.9"
67
- version_requirements: *id007
68
63
  prerelease: false
64
+ version_requirements: !ruby/object:Gem::Requirement
65
+ requirements:
66
+ - - "~>"
67
+ - !ruby/object:Gem::Version
68
+ version: '1.16'
69
+ - !ruby/object:Gem::Dependency
70
+ name: rspec
71
+ requirement: !ruby/object:Gem::Requirement
72
+ requirements:
73
+ - - "~>"
74
+ - !ruby/object:Gem::Version
75
+ version: '2.14'
69
76
  type: :development
77
+ prerelease: false
78
+ version_requirements: !ruby/object:Gem::Requirement
79
+ requirements:
80
+ - - "~>"
81
+ - !ruby/object:Gem::Version
82
+ version: '2.14'
83
+ - !ruby/object:Gem::Dependency
70
84
  name: ffi
85
+ requirement: !ruby/object:Gem::Requirement
86
+ requirements:
87
+ - - "~>"
88
+ - !ruby/object:Gem::Version
89
+ version: '1.9'
90
+ type: :development
91
+ prerelease: false
92
+ version_requirements: !ruby/object:Gem::Requirement
93
+ requirements:
94
+ - - "~>"
95
+ - !ruby/object:Gem::Version
96
+ version: '1.9'
71
97
  description: Installs a vendored copy of libyajl2 for distributions which lack it
72
- email:
98
+ email:
73
99
  - lamont@scriptkiddie.org
74
100
  executables: []
75
-
76
- extensions:
101
+ extensions:
77
102
  - ext/libyajl2/extconf.rb
78
103
  extra_rdoc_files: []
79
-
80
- files:
81
- - .gitignore
82
- - .gitmodules
83
- - .kitchen.cloud.yml
84
- - .kitchen.yml
85
- - .reek.yml
86
- - .rspec
87
- - .rubocop.yml
88
- - .travis.yml
104
+ files:
105
+ - ".gitignore"
106
+ - ".gitmodules"
107
+ - ".kitchen.cloud.yml"
108
+ - ".kitchen.yml"
109
+ - ".reek.yml"
110
+ - ".rspec"
111
+ - ".rubocop.yml"
112
+ - ".travis.yml"
89
113
  - CONTRIBUTING.md
90
114
  - Gemfile
91
115
  - LICENSE
@@ -94,13 +118,6 @@ files:
94
118
  - bootstrap.sh
95
119
  - ext/libyajl2/Makefile
96
120
  - ext/libyajl2/extconf.rb
97
- - lib/libyajl2.rb
98
- - lib/libyajl2/vendored-libyajl2/.gitkeep
99
- - lib/libyajl2/version.rb
100
- - libyajl2.gemspec
101
- - spec/ffi_spec.rb
102
- - spec/path_spec.rb
103
- - spec/spec_helper.rb
104
121
  - ext/libyajl2/vendor/yajl/.gitignore
105
122
  - ext/libyajl2/vendor/yajl/BUILDING
106
123
  - ext/libyajl2/vendor/yajl/BUILDING.win32
@@ -270,30 +287,38 @@ files:
270
287
  - ext/libyajl2/vendor/yajl/test/parsing/yajl_test.c
271
288
  - ext/libyajl2/vendor/yajl/verify/CMakeLists.txt
272
289
  - ext/libyajl2/vendor/yajl/verify/json_verify.c
290
+ - lib/libyajl2.rb
291
+ - lib/libyajl2/vendored-libyajl2/.gitkeep
292
+ - lib/libyajl2/version.rb
293
+ - libyajl2.gemspec
294
+ - spec/ffi_spec.rb
295
+ - spec/path_spec.rb
296
+ - spec/spec_helper.rb
273
297
  homepage: https://github.com/lamont-granquist/libyajl2-gem
274
- licenses:
298
+ licenses:
275
299
  - Apache 2.0
276
300
  metadata: {}
277
-
278
301
  post_install_message:
279
302
  rdoc_options: []
280
-
281
- require_paths:
303
+ require_paths:
282
304
  - lib
283
- required_ruby_version: !ruby/object:Gem::Requirement
284
- requirements:
285
- - *id002
286
- required_rubygems_version: !ruby/object:Gem::Requirement
287
- requirements:
288
- - *id002
305
+ required_ruby_version: !ruby/object:Gem::Requirement
306
+ requirements:
307
+ - - ">="
308
+ - !ruby/object:Gem::Version
309
+ version: '0'
310
+ required_rubygems_version: !ruby/object:Gem::Requirement
311
+ requirements:
312
+ - - ">="
313
+ - !ruby/object:Gem::Version
314
+ version: '0'
289
315
  requirements: []
290
-
291
316
  rubyforge_project:
292
- rubygems_version: 2.0.12
317
+ rubygems_version: 2.2.2
293
318
  signing_key:
294
319
  specification_version: 4
295
320
  summary: Installs a vendored copy of libyajl2 for distributions which lack it
296
- test_files:
321
+ test_files:
297
322
  - spec/ffi_spec.rb
298
323
  - spec/path_spec.rb
299
324
  - spec/spec_helper.rb