image_optim_pack 0.5.3-x86-darwin → 0.5.5-x86-darwin

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 44634909aef9c8d1dab455bb675b68fa3f0689b53973a76cb9df1819d5c31803
4
- data.tar.gz: 06a34b77d5904475c674fe44cd6fcb6db26fc79f92e1047dc96307da20bc1323
3
+ metadata.gz: 3cac00814e56651b491ebd408d157a873723b7b020a46745e63ad5a13ef5f8c2
4
+ data.tar.gz: 7bcdba4fa1914b4110ac60ac4db52981cfafcfe200d245c440150f82c351ce4e
5
5
  SHA512:
6
- metadata.gz: f7f41d94a1f187d634795e192b472ae1e5a93cc7793997f09713047372d403605f95f9e7b75291e112dcd5e675b8f39a7be30bc71d5b49c415b5a9a9493beb98
7
- data.tar.gz: c648b5b7d58045a850ba7c6a995a00fb9be7879eacb2eee99901656cec0b38e2354e000685130f22f50c30fe3f73cc4833f8ecfd72766ed6b5f4f683a2a6bffb
6
+ metadata.gz: 1c4a1ba43b3af9c6d35bfd52a09e0799622a70457ec2981ea8531c3e8995731ef022e2892c73fcf599aedf83a4e769375e4f4d84e6075360c36c813fe50c0366
7
+ data.tar.gz: 536d9b096bfe75854eafc7b9aa1b84bf492f282cd15804029770d18db3e36695eaa3379c33ccc0a9ed56ac5109b5c6eda8938fd81f9bfe05b70ced6ebfcce1a5
data/CHANGELOG.markdown CHANGED
@@ -2,6 +2,14 @@
2
2
 
3
3
  ## unreleased
4
4
 
5
+ ## v0.5.5 (2019-07-14)
6
+
7
+ * Fix specifying platform in gemspec for platform specific gems [@toy](https://github.com/toy)
8
+
9
+ ## v0.5.4 (2019-07-14)
10
+
11
+ * Remove deprecated `rubyforge_project` attribute from gemspec [rubygems/rubygems#2436](https://github.com/rubygems/rubygems/pull/2436) [@toy](https://github.com/toy)
12
+
5
13
  ## v0.5.3 (2019-05-25)
6
14
 
7
15
  * pngquant 2.12.3 [@toy](https://github.com/toy)
@@ -1,3 +1,3 @@
1
1
  # encoding: UTF-8
2
2
 
3
- eval "gem_platform = 'x86-darwin'; #{File.read('image_optim_pack.gemspec')}"
3
+ eval "gemspec_path = #{__FILE__.inspect}; #{File.read('image_optim_pack.gemspec')}"
@@ -1,3 +1,3 @@
1
1
  # encoding: UTF-8
2
2
 
3
- eval "gem_platform = 'x86_64-darwin'; #{File.read('image_optim_pack.gemspec')}"
3
+ eval "gemspec_path = #{__FILE__.inspect}; #{File.read('image_optim_pack.gemspec')}"
@@ -0,0 +1,3 @@
1
+ # encoding: UTF-8
2
+
3
+ eval "gemspec_path = #{__FILE__.inspect}; #{File.read('image_optim_pack.gemspec')}"
@@ -1,3 +1,3 @@
1
1
  # encoding: UTF-8
2
2
 
3
- eval "gem_platform = 'amd64-freebsd'; #{File.read('image_optim_pack.gemspec')}"
3
+ eval "gemspec_path = #{__FILE__.inspect}; #{File.read('image_optim_pack.gemspec')}"
@@ -1,3 +1,3 @@
1
1
  # encoding: UTF-8
2
2
 
3
- eval "gem_platform = 'x86-freebsd'; #{File.read('image_optim_pack.gemspec')}"
3
+ eval "gemspec_path = #{__FILE__.inspect}; #{File.read('image_optim_pack.gemspec')}"
@@ -1,3 +1,3 @@
1
1
  # encoding: UTF-8
2
2
 
3
- eval "gem_platform = 'x86-linux'; #{File.read('image_optim_pack.gemspec')}"
3
+ eval "gemspec_path = #{__FILE__.inspect}; #{File.read('image_optim_pack.gemspec')}"
@@ -1,3 +1,3 @@
1
1
  # encoding: UTF-8
2
2
 
3
- eval "gem_platform = 'x86_64-linux'; #{File.read('image_optim_pack.gemspec')}"
3
+ eval "gemspec_path = #{__FILE__.inspect}; #{File.read('image_optim_pack.gemspec')}"
@@ -1,3 +1,3 @@
1
1
  # encoding: UTF-8
2
2
 
3
- eval "gem_platform = 'x86-openbsd'; #{File.read('image_optim_pack.gemspec')}"
3
+ eval "gemspec_path = #{__FILE__.inspect}; #{File.read('image_optim_pack.gemspec')}"
@@ -1,3 +1,3 @@
1
1
  # encoding: UTF-8
2
2
 
3
- eval "gem_platform = 'x86_64-openbsd'; #{File.read('image_optim_pack.gemspec')}"
3
+ eval "gemspec_path = #{__FILE__.inspect}; #{File.read('image_optim_pack.gemspec')}"
@@ -2,14 +2,12 @@
2
2
 
3
3
  Gem::Specification.new do |s|
4
4
  s.name = 'image_optim_pack'
5
- s.version = '0.5.3'
5
+ s.version = '0.5.5'
6
6
  s.summary = %q{Precompiled binaries for image_optim: advpng, gifsicle, jhead, jpeg-recompress, jpegoptim, jpegtran, optipng, pngcrush, pngquant}
7
7
  s.homepage = "http://github.com/toy/#{s.name}"
8
8
  s.authors = ['Ivan Kuchin']
9
9
  s.license = 'MIT'
10
10
 
11
- s.rubyforge_project = s.name
12
-
13
11
  s.metadata = {
14
12
  'bug_tracker_uri' => "https://github.com/toy/#{s.name}/issues",
15
13
  'changelog_uri' => "https://github.com/toy/#{s.name}/blob/master/CHANGELOG.markdown",
@@ -18,17 +16,31 @@ Gem::Specification.new do |s|
18
16
  }
19
17
 
20
18
  s.files = `git ls-files`.split("\n")
21
- if defined?(gem_platform)
22
- s.platform = gem_platform
23
-
24
- vendor_dir = {
25
- 'x86-linux' => 'linux-i686',
26
- 'x86_64-openbsd' => 'openbsd-amd64',
27
- }[gem_platform] || begin
28
- gem_platform.sub(/^x86-/, 'i386-').split('-').reverse.join('-')
19
+ if defined?(gemspec_path)
20
+ gem_os, gem_cpu = File.basename(gemspec_path, File.extname(gemspec_path)).split('-').drop(1)
21
+
22
+ s.platform = Gem::Platform.new([gem_cpu, gem_os])
23
+
24
+ cpu_aliases = {
25
+ 'x86' => %w[i386 i686],
26
+ 'x86_64' => %w[x86_64 amd64],
27
+ }[gem_cpu] || [gem_cpu]
28
+
29
+ possible_vendor_dirs = cpu_aliases.map do |cpu_alias|
30
+ "#{gem_os}-#{cpu_alias}"
29
31
  end
30
- vendor_path = File.join('vendor', vendor_dir)
31
- fail "#{vendor_path} is not a dir" unless File.directory?(vendor_path)
32
+
33
+ existing_vendor_dirs = possible_vendor_dirs.select do |vendor_dir|
34
+ File.directory?(File.join('vendor', vendor_dir))
35
+ end
36
+
37
+ vendor_dir = if existing_vendor_dirs.length == 1
38
+ existing_vendor_dirs.first
39
+ else
40
+ message = existing_vendor_dirs.empty? ? 'no vendor dir' : 'multiple vendor dirs'
41
+ fail "#{message} found for os #{gem_os} and cpu #{gem_cpu} out of: #{possible_vendor_dirs.join(', ')}"
42
+ end
43
+
32
44
  s.files.reject! do |path|
33
45
  parts = path.split('/')
34
46
  parts[0] == 'vendor' && parts[1] != vendor_dir
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: image_optim_pack
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.3
4
+ version: 0.5.5
5
5
  platform: x86-darwin
6
6
  authors:
7
7
  - Ivan Kuchin
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-05-25 00:00:00.000000000 Z
11
+ date: 2019-07-14 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: image_optim
@@ -130,6 +130,7 @@ files:
130
130
  - checksums.mk
131
131
  - image_optim_pack-darwin-x86.gemspec
132
132
  - image_optim_pack-darwin-x86_64.gemspec
133
+ - image_optim_pack-fake-x42.gemspec
133
134
  - image_optim_pack-freebsd-amd64.gemspec
134
135
  - image_optim_pack-freebsd-x86.gemspec
135
136
  - image_optim_pack-linux-x86.gemspec
@@ -163,7 +164,7 @@ licenses:
163
164
  metadata:
164
165
  bug_tracker_uri: https://github.com/toy/image_optim_pack/issues
165
166
  changelog_uri: https://github.com/toy/image_optim_pack/blob/master/CHANGELOG.markdown
166
- documentation_uri: https://www.rubydoc.info/gems/image_optim_pack/0.5.3
167
+ documentation_uri: https://www.rubydoc.info/gems/image_optim_pack/0.5.5
167
168
  source_code_uri: https://github.com/toy/image_optim_pack
168
169
  post_install_message:
169
170
  rdoc_options: []