mini_portile2 2.7.1 → 2.8.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/FUNDING.yml +2 -1
- data/.github/workflows/ci.yml +4 -4
- data/CHANGELOG.md +9 -1
- data/README.md +10 -0
- data/lib/mini_portile2/mini_portile.rb +13 -3
- data/lib/mini_portile2/version.rb +1 -1
- data/mini_portile2.gemspec +5 -5
- metadata +13 -13
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2602d6374f46f2b14904b287999ca7da911a08b28fa75517e220796847cd9496
|
4
|
+
data.tar.gz: 450fc92cc01ae557e8ab7f43ddd241d479496160c2f759969531cfa6003321fd
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7ccfdbbb591033e43b155be58a3dd72145886a7c5b38e7f7ba4009adee5b76b6b33d3ee80d7b1d66be7160eeb6ffdf4d87dbd11898b3f624c56d91c316969d13
|
7
|
+
data.tar.gz: 7bd90d3d534b25097e38d748f59286385010ee05f9f4ee06a38b844379bf8fe10b604fe013cc716aa9deab72a02d7e704ef045825acd370db198ec8f1ccb9bea
|
data/.github/FUNDING.yml
CHANGED
@@ -1 +1,2 @@
|
|
1
|
-
|
1
|
+
github: flavorjones
|
2
|
+
tidelift: rubygems/mini_portile2
|
data/.github/workflows/ci.yml
CHANGED
@@ -24,8 +24,8 @@ jobs:
|
|
24
24
|
strategy:
|
25
25
|
fail-fast: false
|
26
26
|
matrix:
|
27
|
-
platform: [ubuntu-latest, windows-latest]
|
28
|
-
ruby: ["2.3", "2.4", "2.5", "2.6", "2.7", "3.0", "head"]
|
27
|
+
platform: [ubuntu-latest, windows-latest, macos-latest]
|
28
|
+
ruby: ["2.3", "2.4", "2.5", "2.6", "2.7", "3.0", "3.1", "head"]
|
29
29
|
runs-on: ${{ matrix.platform }}
|
30
30
|
steps:
|
31
31
|
- name: configure git crlf on windows
|
@@ -48,8 +48,8 @@ jobs:
|
|
48
48
|
strategy:
|
49
49
|
fail-fast: false
|
50
50
|
matrix:
|
51
|
-
platform: [ubuntu-latest, windows-latest]
|
52
|
-
ruby: ["3.
|
51
|
+
platform: [ubuntu-latest, windows-latest, macos-latest]
|
52
|
+
ruby: ["3.1"]
|
53
53
|
runs-on: ${{ matrix.platform }}
|
54
54
|
steps:
|
55
55
|
- name: configure git crlf on windows
|
data/CHANGELOG.md
CHANGED
@@ -1,5 +1,13 @@
|
|
1
1
|
## mini_portile changelog
|
2
2
|
|
3
|
+
### 2.8.0 / 2022-02-20
|
4
|
+
|
5
|
+
#### Added
|
6
|
+
|
7
|
+
- Support xz-compressed archives (recognized by an `.xz` file extension).
|
8
|
+
- When downloading a source archive, default open_timeout and read_timeout to 10 seconds, but allow configuration via open_timeout and read_timeout config parameters.
|
9
|
+
|
10
|
+
|
3
11
|
### 2.7.1 / 2021-10-20
|
4
12
|
|
5
13
|
#### Packaging
|
@@ -9,7 +17,7 @@ A test artifact that has been included in the gem was being flagged by some user
|
|
9
17
|
|
10
18
|
### 2.7.0 / 2021-08-31
|
11
19
|
|
12
|
-
|
20
|
+
#### Added
|
13
21
|
|
14
22
|
The commands used for "make", "compile", and "cmake" are configurable via keyword arguments. [#107] (Thanks, @cosmo0920!)
|
15
23
|
|
data/README.md
CHANGED
@@ -115,6 +115,15 @@ You can pass it in like so:
|
|
115
115
|
MiniPortile.new("libiconv", "1.13.1", make_command: "nmake")
|
116
116
|
```
|
117
117
|
|
118
|
+
#### `open_timeout`, `read_timeout`
|
119
|
+
|
120
|
+
By default, when downloading source archives, MiniPortile will use a timeout value of 10
|
121
|
+
seconds. This can be overridden by passing a different value (in seconds):
|
122
|
+
|
123
|
+
``` ruby
|
124
|
+
MiniPortile.new("libiconv", "1.13.1", open_timeout: 99, read_timeout: 2)
|
125
|
+
```
|
126
|
+
|
118
127
|
|
119
128
|
### How to use (for cmake projects)
|
120
129
|
|
@@ -138,6 +147,7 @@ You can pass it in like so:
|
|
138
147
|
MiniPortileCMake.new("libfoobar", "1.3.5", cmake_command: "cmake3")
|
139
148
|
```
|
140
149
|
|
150
|
+
|
141
151
|
### Local source directories
|
142
152
|
|
143
153
|
Instead of downloading a remote file, you can also point mini_portile2 at a local source
|
@@ -28,6 +28,8 @@ class Net::HTTP
|
|
28
28
|
end
|
29
29
|
|
30
30
|
class MiniPortile
|
31
|
+
DEFAULT_TIMEOUT = 10
|
32
|
+
|
31
33
|
attr_reader :name, :version, :original_host
|
32
34
|
attr_writer :configure_options
|
33
35
|
attr_accessor :host, :files, :patch_files, :target, :logger, :source_directory
|
@@ -60,6 +62,8 @@ class MiniPortile
|
|
60
62
|
|
61
63
|
@gcc_command = kwargs[:gcc_command]
|
62
64
|
@make_command = kwargs[:make_command]
|
65
|
+
@open_timeout = kwargs[:open_timeout] || DEFAULT_TIMEOUT
|
66
|
+
@read_timeout = kwargs[:read_timeout] || DEFAULT_TIMEOUT
|
63
67
|
end
|
64
68
|
|
65
69
|
def source_directory=(path)
|
@@ -358,6 +362,8 @@ private
|
|
358
362
|
'z'
|
359
363
|
when '.bz2', '.tbz2'
|
360
364
|
'j'
|
365
|
+
when '.xz'
|
366
|
+
'J'
|
361
367
|
when '.Z'
|
362
368
|
'Z'
|
363
369
|
else
|
@@ -512,7 +518,9 @@ private
|
|
512
518
|
# Content-Length is unavailable because Transfer-Encoding is chunked
|
513
519
|
message "\rDownloading %s " % [filename]
|
514
520
|
end
|
515
|
-
}
|
521
|
+
},
|
522
|
+
:open_timeout => @open_timeout,
|
523
|
+
:read_timeout => @read_timeout,
|
516
524
|
}
|
517
525
|
proxy_uri = URI.parse(url).scheme.downcase == 'https' ?
|
518
526
|
ENV["https_proxy"] :
|
@@ -537,7 +545,7 @@ private
|
|
537
545
|
return download_file(redirect.url, full_path, count-1)
|
538
546
|
rescue => e
|
539
547
|
count = count - 1
|
540
|
-
puts "#{count} retrie(s) left for #{filename}"
|
548
|
+
puts "#{count} retrie(s) left for #{filename} (#{e.message})"
|
541
549
|
if count > 0
|
542
550
|
sleep 1
|
543
551
|
return download_file_http(url, full_path, count)
|
@@ -564,7 +572,9 @@ private
|
|
564
572
|
:progress_proc => lambda{|bytes|
|
565
573
|
new_progress = (bytes * 100) / total
|
566
574
|
message "\rDownloading %s (%3d%%) " % [filename, new_progress]
|
567
|
-
}
|
575
|
+
},
|
576
|
+
:open_timeout => @open_timeout,
|
577
|
+
:read_timeout => @read_timeout,
|
568
578
|
}
|
569
579
|
if ENV["ftp_proxy"]
|
570
580
|
_, userinfo, _p_host, _p_port = URI.split(ENV['ftp_proxy'])
|
data/mini_portile2.gemspec
CHANGED
@@ -33,10 +33,10 @@ Gem::Specification.new do |spec|
|
|
33
33
|
|
34
34
|
spec.required_ruby_version = ">= 2.3.0"
|
35
35
|
|
36
|
-
spec.add_development_dependency "bundler", "~> 2.
|
37
|
-
spec.add_development_dependency "minitar", "~> 0.
|
38
|
-
spec.add_development_dependency "minitest", "~> 5.
|
39
|
-
spec.add_development_dependency "minitest-hooks", "~> 1.5
|
36
|
+
spec.add_development_dependency "bundler", "~> 2.3"
|
37
|
+
spec.add_development_dependency "minitar", "~> 0.9"
|
38
|
+
spec.add_development_dependency "minitest", "~> 5.15"
|
39
|
+
spec.add_development_dependency "minitest-hooks", "~> 1.5"
|
40
40
|
spec.add_development_dependency "rake", "~> 13.0"
|
41
|
-
spec.add_development_dependency "webrick", "~> 1.
|
41
|
+
spec.add_development_dependency "webrick", "~> 1.7"
|
42
42
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: mini_portile2
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.
|
4
|
+
version: 2.8.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Luis Lavena
|
@@ -10,7 +10,7 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
|
-
date:
|
13
|
+
date: 2022-02-20 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: bundler
|
@@ -18,56 +18,56 @@ dependencies:
|
|
18
18
|
requirements:
|
19
19
|
- - "~>"
|
20
20
|
- !ruby/object:Gem::Version
|
21
|
-
version: '2.
|
21
|
+
version: '2.3'
|
22
22
|
type: :development
|
23
23
|
prerelease: false
|
24
24
|
version_requirements: !ruby/object:Gem::Requirement
|
25
25
|
requirements:
|
26
26
|
- - "~>"
|
27
27
|
- !ruby/object:Gem::Version
|
28
|
-
version: '2.
|
28
|
+
version: '2.3'
|
29
29
|
- !ruby/object:Gem::Dependency
|
30
30
|
name: minitar
|
31
31
|
requirement: !ruby/object:Gem::Requirement
|
32
32
|
requirements:
|
33
33
|
- - "~>"
|
34
34
|
- !ruby/object:Gem::Version
|
35
|
-
version: '0.
|
35
|
+
version: '0.9'
|
36
36
|
type: :development
|
37
37
|
prerelease: false
|
38
38
|
version_requirements: !ruby/object:Gem::Requirement
|
39
39
|
requirements:
|
40
40
|
- - "~>"
|
41
41
|
- !ruby/object:Gem::Version
|
42
|
-
version: '0.
|
42
|
+
version: '0.9'
|
43
43
|
- !ruby/object:Gem::Dependency
|
44
44
|
name: minitest
|
45
45
|
requirement: !ruby/object:Gem::Requirement
|
46
46
|
requirements:
|
47
47
|
- - "~>"
|
48
48
|
- !ruby/object:Gem::Version
|
49
|
-
version: '5.
|
49
|
+
version: '5.15'
|
50
50
|
type: :development
|
51
51
|
prerelease: false
|
52
52
|
version_requirements: !ruby/object:Gem::Requirement
|
53
53
|
requirements:
|
54
54
|
- - "~>"
|
55
55
|
- !ruby/object:Gem::Version
|
56
|
-
version: '5.
|
56
|
+
version: '5.15'
|
57
57
|
- !ruby/object:Gem::Dependency
|
58
58
|
name: minitest-hooks
|
59
59
|
requirement: !ruby/object:Gem::Requirement
|
60
60
|
requirements:
|
61
61
|
- - "~>"
|
62
62
|
- !ruby/object:Gem::Version
|
63
|
-
version: 1.5
|
63
|
+
version: '1.5'
|
64
64
|
type: :development
|
65
65
|
prerelease: false
|
66
66
|
version_requirements: !ruby/object:Gem::Requirement
|
67
67
|
requirements:
|
68
68
|
- - "~>"
|
69
69
|
- !ruby/object:Gem::Version
|
70
|
-
version: 1.5
|
70
|
+
version: '1.5'
|
71
71
|
- !ruby/object:Gem::Dependency
|
72
72
|
name: rake
|
73
73
|
requirement: !ruby/object:Gem::Requirement
|
@@ -88,14 +88,14 @@ dependencies:
|
|
88
88
|
requirements:
|
89
89
|
- - "~>"
|
90
90
|
- !ruby/object:Gem::Version
|
91
|
-
version: '1.
|
91
|
+
version: '1.7'
|
92
92
|
type: :development
|
93
93
|
prerelease: false
|
94
94
|
version_requirements: !ruby/object:Gem::Requirement
|
95
95
|
requirements:
|
96
96
|
- - "~>"
|
97
97
|
- !ruby/object:Gem::Version
|
98
|
-
version: '1.
|
98
|
+
version: '1.7'
|
99
99
|
description: Simplistic port-like solution for developers. It provides a standard
|
100
100
|
and simplified way to compile against dependency libraries without messing up your
|
101
101
|
system.
|
@@ -153,7 +153,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
153
153
|
- !ruby/object:Gem::Version
|
154
154
|
version: '0'
|
155
155
|
requirements: []
|
156
|
-
rubygems_version: 3.
|
156
|
+
rubygems_version: 3.3.5
|
157
157
|
signing_key:
|
158
158
|
specification_version: 4
|
159
159
|
summary: Simplistic port-like solution for developers
|