sys-cpu 1.0.4 → 1.0.5

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: 7624e670375df3b2fd1055c43ac391b592c9288462fbaf2687b3c94d149434e2
4
- data.tar.gz: d9b4acf3a644bed915050950bbdd19136700ddc544f7b2de06a1a54af3910411
3
+ metadata.gz: 7093a05a67945ccf9980c070421462c4a30a40d72ba9645230fad1d86381c0c1
4
+ data.tar.gz: e411d1a7f0ce381fcd8660e9b7654d60c21c03459b25cb6cdd1b46c379196b10
5
5
  SHA512:
6
- metadata.gz: f4ff44d8420830dd6cc1da28a8c016587226a38870612c3858dc4fee9f9c2038615c2cc7f24160a00467f9bde67ac45a174d5dff80d7b22682dd7399969ce061
7
- data.tar.gz: a2c59fd8f0243d97fdddcb8ea333a27a71028c19218fc4ebedde57b209d5f6f970f1e21c3798fbcaacc387becfd1895cf78b2b3e035f8f2c50778e31a7a8d808
6
+ metadata.gz: ff952395b1f70fedc9f01818efff2c4655ed19f2120351a84eec82690176a6de5664ca1b17648656b8eeaacaccc805c5077f4c50d79ad2983f1b3df92f14e6a8
7
+ data.tar.gz: 07344e7816c0ccb3bc2217c4563d2c3c97875bd3e45cc8b463cd516b44f2cc38ba94df7798ae9e086886bd0bbcdae5da514244a19165f0d732c2ddb5179d85ca
checksums.yaml.gz.sig CHANGED
Binary file
data/CHANGES.md CHANGED
@@ -1,3 +1,7 @@
1
+ ## 1.0.5 - 10-Aug-2022
2
+ * Updated the cpu detection handling for Mac M1 systems. Thanks go to
3
+ Julien W for the spot.
4
+
1
5
  ## 1.0.4 - 10-Jun-2022
2
6
  * The OSX code for the CPU.freq method was updated for arm64 systems.
3
7
  * Some refactoring to the specs and uses shared examples now.
data/README.md CHANGED
@@ -71,7 +71,7 @@ https://github.com/djberg96/sys-cpu
71
71
  Apache-2.0
72
72
 
73
73
  ## Copyright
74
- (C) 2003-2021 Daniel J. Berger, All Rights Reserved
74
+ (C) 2003-2022 Daniel J. Berger, All Rights Reserved
75
75
 
76
76
  ## Warranty
77
77
  This package is provided "as is" and without any express or
data/lib/sys/cpu.rb CHANGED
@@ -10,7 +10,7 @@ module Sys
10
10
  # This class is reopened for each of the supported platforms/operating systems.
11
11
  class CPU
12
12
  # The version of the sys-cpu gem.
13
- VERSION = '1.0.4'
13
+ VERSION = '1.0.5'
14
14
 
15
15
  private_class_method :new
16
16
  end
@@ -158,7 +158,7 @@ module Sys
158
158
 
159
159
  size.write_long(optr.size)
160
160
 
161
- if RbConfig::CONFIG['host_cpu'].downcase == 'arm64'
161
+ if RbConfig::CONFIG['host_cpu'] =~ /^arm|^aarch/i
162
162
  if sysctlbyname('hw.tbfrequency', optr, size, nil, 0) < 0
163
163
  raise Error, 'sysctlbyname failed on hw.tbfrequency'
164
164
  end
@@ -194,5 +194,3 @@ module Sys
194
194
  end
195
195
  end
196
196
  end
197
-
198
- p Sys::CPU.freq
@@ -11,7 +11,7 @@ require 'rspec'
11
11
 
12
12
  RSpec.shared_examples Sys::CPU do
13
13
  example 'version number is set to the expected value' do
14
- expect(Sys::CPU::VERSION).to eq('1.0.4')
14
+ expect(Sys::CPU::VERSION).to eq('1.0.5')
15
15
  end
16
16
 
17
17
  example 'version number is frozen' do
data/sys-cpu.gemspec CHANGED
@@ -2,7 +2,7 @@ require 'rubygems'
2
2
 
3
3
  Gem::Specification.new do |spec|
4
4
  spec.name = 'sys-cpu'
5
- spec.version = '1.0.4'
5
+ spec.version = '1.0.5'
6
6
  spec.author = 'Daniel J. Berger'
7
7
  spec.email = 'djberg96@gmail.com'
8
8
  spec.license = 'Apache-2.0'
@@ -23,12 +23,13 @@ Gem::Specification.new do |spec|
23
23
  spec.add_development_dependency('rubocop-rspec')
24
24
 
25
25
  spec.metadata = {
26
- 'homepage_uri' => 'https://github.com/djberg96/sys-cpu',
27
- 'bug_tracker_uri' => 'https://github.com/djberg96/sys-cpu/issues',
28
- 'changelog_uri' => 'https://github.com/djberg96/sys-cpu/blob/main/CHANGES.md',
29
- 'documentation_uri' => 'https://github.com/djberg96/sys-cpu/wiki',
30
- 'source_code_uri' => 'https://github.com/djberg96/sys-cpu',
31
- 'wiki_uri' => 'https://github.com/djberg96/sys-cpu/wiki'
26
+ 'homepage_uri' => 'https://github.com/djberg96/sys-cpu',
27
+ 'bug_tracker_uri' => 'https://github.com/djberg96/sys-cpu/issues',
28
+ 'changelog_uri' => 'https://github.com/djberg96/sys-cpu/blob/main/CHANGES.md',
29
+ 'documentation_uri' => 'https://github.com/djberg96/sys-cpu/wiki',
30
+ 'source_code_uri' => 'https://github.com/djberg96/sys-cpu',
31
+ 'wiki_uri' => 'https://github.com/djberg96/sys-cpu/wiki',
32
+ 'rubygems_mfa_required' => 'true'
32
33
  }
33
34
 
34
35
  spec.description = <<-EOF
data.tar.gz.sig CHANGED
Binary file
metadata CHANGED
@@ -1,11 +1,11 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sys-cpu
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.4
4
+ version: 1.0.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Daniel J. Berger
8
- autorequire:
8
+ autorequire:
9
9
  bindir: bin
10
10
  cert_chain:
11
11
  - |
@@ -35,7 +35,7 @@ cert_chain:
35
35
  ORVCZpRuCPpmC8qmqxUnARDArzucjaclkxjLWvCVHeFa9UP7K3Nl9oTjJNv+7/jM
36
36
  WZs4eecIcUc4tKdHxcAJ0MO/Dkqq7hGaiHpwKY76wQ1+8xAh
37
37
  -----END CERTIFICATE-----
38
- date: 2022-06-10 00:00:00.000000000 Z
38
+ date: 2022-08-10 00:00:00.000000000 Z
39
39
  dependencies:
40
40
  - !ruby/object:Gem::Dependency
41
41
  name: ffi
@@ -158,7 +158,8 @@ metadata:
158
158
  documentation_uri: https://github.com/djberg96/sys-cpu/wiki
159
159
  source_code_uri: https://github.com/djberg96/sys-cpu
160
160
  wiki_uri: https://github.com/djberg96/sys-cpu/wiki
161
- post_install_message:
161
+ rubygems_mfa_required: 'true'
162
+ post_install_message:
162
163
  rdoc_options: []
163
164
  require_paths:
164
165
  - lib
@@ -173,15 +174,15 @@ required_rubygems_version: !ruby/object:Gem::Requirement
173
174
  - !ruby/object:Gem::Version
174
175
  version: '0'
175
176
  requirements: []
176
- rubygems_version: 3.3.7
177
- signing_key:
177
+ rubygems_version: 3.2.32
178
+ signing_key:
178
179
  specification_version: 4
179
180
  summary: A Ruby interface for providing CPU information
180
181
  test_files:
181
182
  - spec/spec_helper.rb
182
183
  - spec/sys_cpu_bsd_spec.rb
183
- - spec/sys_cpu_hpux_spec.rb
184
- - spec/sys_cpu_linux_spec.rb
185
184
  - spec/sys_cpu_shared.rb
186
185
  - spec/sys_cpu_sunos_spec.rb
186
+ - spec/sys_cpu_hpux_spec.rb
187
+ - spec/sys_cpu_linux_spec.rb
187
188
  - spec/sys_cpu_windows_spec.rb
metadata.gz.sig CHANGED
Binary file