image_optim_pack 0.5.3-x86-freebsd → 0.5.5-x86-freebsd

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: 2c30c65330fc932a6087b9186dd9bb4b7609e0e21615e1edab35d4386aae6175
4
- data.tar.gz: 349067156f97b30e88bf0942725464b5c1bf23bd7820fb24a966437cf336f642
3
+ metadata.gz: ed9241528bb7bc834237ac95fc87a2613781f693ad5668c77663e7efdfa759fd
4
+ data.tar.gz: c506d4cf44a4438876e1177e5502882cf0d23aa7716e5c5b486cbf06d5db9d2c
5
5
  SHA512:
6
- metadata.gz: fe71fbf0f3ecf75d96622adce8c3d237478405fbdcfb65cad134d4fdf7fbfa210fd98fc4fd64aa1d63d937e249822c9fb463ac2f1970b0749b0850ab71718a6b
7
- data.tar.gz: 25b07c7a19ff3cd5f35293e56cf94c9a4e47869098d8f40e3bdc301fdf22022eb10befb01654fb1197ed6904857885840455810128844345cd5f7dff0b0a78c2
6
+ metadata.gz: 56e190dc32813a8184cd21b904f61dcb2f46908008177cdb112b8b76952c5b0a84e4aa42b87946d04de35f6dafa9d10efba0e7e70a0dacbfa8116997e7f29216
7
+ data.tar.gz: b7247029e5b7d87476edfb7eed4f2eed5048fa0430aa25d980e3e2be3781dea4b844831df0c54eb604685d6784e8396733d36fa3847674018f9ed4531aee6573
@@ -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-freebsd
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: []