rake-compiler-dock 1.9.1 → 1.11.0.rc1
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 +4 -4
- checksums.yaml.gz.sig +0 -0
- data/.github/workflows/ci.yml +74 -74
- data/.github/workflows/publish-images.yml +798 -46
- data/.github/workflows/publish-images.yml.erb +121 -0
- data/.github/workflows/release-images.yml +854 -45
- data/{History.md → CHANGELOG.md} +37 -0
- data/CONTRIBUTING.md +44 -1
- data/Dockerfile.jruby +3 -3
- data/Dockerfile.mri.erb +103 -58
- data/README.md +48 -6
- data/Rakefile +143 -40
- data/build/buildkitd.toml +2 -0
- data/build/gem_helper.rb +2 -2
- data/build/mk_musl_cross.sh +1 -1
- data/build/parallel_docker_build.rb +64 -23
- data/build/patches/{rake-compiler-1.2.9 → rake-compiler-1.3.1}/0004-Enable-build-of-static-libruby.patch +4 -2
- data/build/patches/{rake-compiler-1.2.9 → rake-compiler-1.3.1}/0005-build-miniruby-first.patch +2 -3
- data/build/patches/rake-compiler-1.3.1/0006-ruby-4-rubyspec-capiext.patch +16 -0
- data/build/sudoers +1 -1
- data/lib/rake_compiler_dock/starter.rb +11 -1
- data/lib/rake_compiler_dock/version.rb +2 -2
- data/lib/rake_compiler_dock.rb +12 -17
- data/mingw64-ucrt/README.md +0 -44
- data/test/env/Dockerfile.alpine +1 -1
- data/test/fixtures/mig_test_rpc.defs +8 -0
- data/test/rcd_test/Rakefile +1 -0
- data/test/rcd_test/ext/mri/extconf.rb +2 -0
- data/test/rcd_test/rcd_test.gemspec +1 -1
- data/test/rcd_test/test/test_basic.rb +11 -0
- data/test/test_environment_variables.rb +13 -0
- data/test/test_mig.rb +18 -0
- data/test/test_parallel_docker_build.rb +2 -2
- data/test/test_starter.rb +6 -0
- data/test/test_versions.rb +1 -1
- data.tar.gz.sig +0 -0
- metadata +39 -9
- metadata.gz.sig +0 -0
- data/test/env/Dockerfile.centos +0 -24
|
@@ -85,6 +85,19 @@ class TestEnvironmentVariables
|
|
|
85
85
|
end
|
|
86
86
|
end
|
|
87
87
|
|
|
88
|
+
class UsingWrapperSpecifyingRuby < UsingWrapper
|
|
89
|
+
include Common
|
|
90
|
+
|
|
91
|
+
def invocation(command)
|
|
92
|
+
idir = File.join(File.dirname(__FILE__), '../lib')
|
|
93
|
+
"RCD_RUBY_VERSION=3.1.6 RCD_PLATFORM=#{TEST_PLATFORM} RCD_RUBYVM=#{IS_JRUBY ? 'jruby' : 'mri'} #{RbConfig::CONFIG['RUBY_INSTALL_NAME']} -I#{idir.inspect} bin/rake-compiler-dock bash -c '#{command}'"
|
|
94
|
+
end
|
|
95
|
+
|
|
96
|
+
def test_RUBY_VERSION
|
|
97
|
+
assert_equal "3.1.6", rcd_env['RBENV_VERSION']
|
|
98
|
+
end
|
|
99
|
+
end
|
|
100
|
+
|
|
88
101
|
class AsIfContinuousIntegration < Test::Unit::TestCase
|
|
89
102
|
include Common
|
|
90
103
|
|
data/test/test_mig.rb
ADDED
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
require 'rake_compiler_dock'
|
|
2
|
+
require 'test/unit'
|
|
3
|
+
|
|
4
|
+
class TestMigCompile < Test::Unit::TestCase
|
|
5
|
+
TEST_PLATFORM = ENV["TEST_PLATFORM"] || 'arm64-darwin'
|
|
6
|
+
|
|
7
|
+
def test_mig_compile
|
|
8
|
+
omit "only on darwin platform" unless TEST_PLATFORM =~ /darwin/
|
|
9
|
+
|
|
10
|
+
RakeCompilerDock::Starter.sh "mig -header tmp/mig_test_rpc.h -user tmp/mig_test_rpc.c -sheader /dev/null -server /dev/null -I. test/fixtures/mig_test_rpc.defs ", platform: TEST_PLATFORM, verbose: false
|
|
11
|
+
|
|
12
|
+
h_file = File.read("tmp/mig_test_rpc.h")
|
|
13
|
+
assert_match /Request_mig_test_call/, h_file
|
|
14
|
+
|
|
15
|
+
c_file = File.read("tmp/mig_test_rpc.c")
|
|
16
|
+
assert_match /Reply__mig_test_call/, c_file
|
|
17
|
+
end
|
|
18
|
+
end
|
|
@@ -39,12 +39,12 @@ class TestParallelDockerBuild < Test::Unit::TestCase
|
|
|
39
39
|
end
|
|
40
40
|
|
|
41
41
|
private def hd(str)
|
|
42
|
-
"y" + Digest::SHA1.hexdigest(str)
|
|
42
|
+
"y" + Digest::SHA1.hexdigest(str)[0, 7]
|
|
43
43
|
end
|
|
44
44
|
|
|
45
45
|
def test_tasks
|
|
46
46
|
Dir.chdir(@tmpdir) do
|
|
47
|
-
RakeCompilerDock::ParallelDockerBuild.new(%w[ File0 File1 File2 File3 ], task_prefix: "y")
|
|
47
|
+
RakeCompilerDock::ParallelDockerBuild.new(%w[ File0 File1 File2 File3 ], task_prefix: "y").define_rake_tasks
|
|
48
48
|
end
|
|
49
49
|
|
|
50
50
|
assert_operator Rake::Task["File0"].prerequisites, :include?, hd("File0File1")
|
data/test/test_starter.rb
CHANGED
|
@@ -38,6 +38,12 @@ class TestStarter < Test::Unit::TestCase
|
|
|
38
38
|
with_env({"RAKE_COMPILER_DOCK_IMAGE" => "env-var-value"}) do
|
|
39
39
|
assert_equal("env-var-value", Starter.container_image_name)
|
|
40
40
|
end
|
|
41
|
+
with_env({"CONTAINER_REGISTRY" => "env-var-value"}) do
|
|
42
|
+
assert_match(/env-var-value\//, Starter.container_image_name(platform: "x64-mingw-ucrt"))
|
|
43
|
+
end
|
|
44
|
+
with_env({"RCD_IMAGE_VERSION" => "env-var-value"}) do
|
|
45
|
+
assert_match(/:env-var-value-/, Starter.container_image_name(platform: "x64-mingw-ucrt"))
|
|
46
|
+
end
|
|
41
47
|
|
|
42
48
|
# with image option
|
|
43
49
|
assert_equal("option-value", Starter.container_image_name({:image => "option-value"}))
|
data/test/test_versions.rb
CHANGED
|
@@ -55,7 +55,7 @@ class TestVersions < Test::Unit::TestCase
|
|
|
55
55
|
assert_equal(expected, RakeCompilerDock.ruby_cc_version("~> 3.2.0", "~> 3.4.0"))
|
|
56
56
|
assert_equal(expected, RakeCompilerDock.ruby_cc_version(Gem::Requirement.new("~> 3.2.0"), Gem::Requirement.new("~> 3.4.0")))
|
|
57
57
|
|
|
58
|
-
expected = [cross["3.4"], cross["3.3"], cross["3.2"]].join(":")
|
|
58
|
+
expected = [cross["4.0"], cross["3.4"], cross["3.3"], cross["3.2"]].join(":")
|
|
59
59
|
assert_equal(expected, RakeCompilerDock.ruby_cc_version(">= 3.2"))
|
|
60
60
|
assert_equal(expected, RakeCompilerDock.ruby_cc_version(Gem::Requirement.new(">= 3.2")))
|
|
61
61
|
|
data.tar.gz.sig
ADDED
|
Binary file
|
metadata
CHANGED
|
@@ -1,13 +1,38 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: rake-compiler-dock
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.
|
|
4
|
+
version: 1.11.0.rc1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Lars Kanis
|
|
8
8
|
bindir: bin
|
|
9
|
-
cert_chain:
|
|
10
|
-
|
|
9
|
+
cert_chain:
|
|
10
|
+
- |
|
|
11
|
+
-----BEGIN CERTIFICATE-----
|
|
12
|
+
MIIEBDCCAmygAwIBAgIBAzANBgkqhkiG9w0BAQsFADAoMSYwJAYDVQQDDB1sYXJz
|
|
13
|
+
L0RDPWdyZWl6LXJlaW5zZG9yZi9EQz1kZTAeFw0yNDEyMjkxOTU2NTZaFw0yNTEy
|
|
14
|
+
MjkxOTU2NTZaMCgxJjAkBgNVBAMMHWxhcnMvREM9Z3JlaXotcmVpbnNkb3JmL0RD
|
|
15
|
+
PWRlMIIBojANBgkqhkiG9w0BAQEFAAOCAY8AMIIBigKCAYEAwum6Y1KznfpzXOT/
|
|
16
|
+
mZgJTBbxZuuZF49Fq3K0WA67YBzNlDv95qzSp7V/7Ek3NCcnT7G+2kSuhNo1FhdN
|
|
17
|
+
eSDO/moYebZNAcu3iqLsuzuULXPLuoU0GsMnVMqV9DZPh7cQHE5EBZ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32
|
+
DrkJ9tVlPQtJB0LqT0tvBap4upnwT1xYq721b5dwH6AF4Pi6iz/dc5vnq1/MH8bV
|
|
33
|
+
8VbbBzzeE7MsvgkP3sHlLmY8PtuyViJ8
|
|
34
|
+
-----END CERTIFICATE-----
|
|
35
|
+
date: 1980-01-02 00:00:00.000000000 Z
|
|
11
36
|
dependencies:
|
|
12
37
|
- !ruby/object:Gem::Dependency
|
|
13
38
|
name: bundler
|
|
@@ -70,25 +95,28 @@ files:
|
|
|
70
95
|
- ".dockerignore"
|
|
71
96
|
- ".github/workflows/ci.yml"
|
|
72
97
|
- ".github/workflows/publish-images.yml"
|
|
98
|
+
- ".github/workflows/publish-images.yml.erb"
|
|
73
99
|
- ".github/workflows/release-images.yml"
|
|
74
100
|
- ".gitignore"
|
|
101
|
+
- CHANGELOG.md
|
|
75
102
|
- CONTRIBUTING.md
|
|
76
103
|
- Dockerfile.jruby
|
|
77
104
|
- Dockerfile.mri.erb
|
|
78
105
|
- Gemfile
|
|
79
|
-
- History.md
|
|
80
106
|
- LICENSE.txt
|
|
81
107
|
- README.md
|
|
82
108
|
- Rakefile
|
|
83
109
|
- bin/rake-compiler-dock
|
|
110
|
+
- build/buildkitd.toml
|
|
84
111
|
- build/gem_helper.rb
|
|
85
112
|
- build/mk_i686.rb
|
|
86
113
|
- build/mk_musl_cross.sh
|
|
87
114
|
- build/mk_osxcross.sh
|
|
88
115
|
- build/mk_pkg_config.sh
|
|
89
116
|
- build/parallel_docker_build.rb
|
|
90
|
-
- build/patches/rake-compiler-1.
|
|
91
|
-
- build/patches/rake-compiler-1.
|
|
117
|
+
- build/patches/rake-compiler-1.3.1/0004-Enable-build-of-static-libruby.patch
|
|
118
|
+
- build/patches/rake-compiler-1.3.1/0005-build-miniruby-first.patch
|
|
119
|
+
- build/patches/rake-compiler-1.3.1/0006-ruby-4-rubyspec-capiext.patch
|
|
92
120
|
- build/rcd-env.sh
|
|
93
121
|
- build/runas
|
|
94
122
|
- build/sigfw.c
|
|
@@ -108,8 +136,8 @@ files:
|
|
|
108
136
|
- mingw64-ucrt/mingw-w64-enable-ucrt.patch
|
|
109
137
|
- rake-compiler-dock.gemspec
|
|
110
138
|
- test/env/Dockerfile.alpine
|
|
111
|
-
- test/env/Dockerfile.centos
|
|
112
139
|
- test/env/Dockerfile.debian
|
|
140
|
+
- test/fixtures/mig_test_rpc.defs
|
|
113
141
|
- test/rcd_test/Gemfile
|
|
114
142
|
- test/rcd_test/Rakefile
|
|
115
143
|
- test/rcd_test/ext/java/RcdTestExtService.java
|
|
@@ -121,6 +149,7 @@ files:
|
|
|
121
149
|
- test/rcd_test/rcd_test.gemspec
|
|
122
150
|
- test/rcd_test/test/test_basic.rb
|
|
123
151
|
- test/test_environment_variables.rb
|
|
152
|
+
- test/test_mig.rb
|
|
124
153
|
- test/test_parallel_docker_build.rb
|
|
125
154
|
- test/test_starter.rb
|
|
126
155
|
- test/test_versions.rb
|
|
@@ -142,14 +171,14 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
142
171
|
- !ruby/object:Gem::Version
|
|
143
172
|
version: '0'
|
|
144
173
|
requirements: []
|
|
145
|
-
rubygems_version: 3.6.
|
|
174
|
+
rubygems_version: 3.6.9
|
|
146
175
|
specification_version: 4
|
|
147
176
|
summary: Easy to use and reliable cross compiler environment for building Windows
|
|
148
177
|
and Linux binary gems.
|
|
149
178
|
test_files:
|
|
150
179
|
- test/env/Dockerfile.alpine
|
|
151
|
-
- test/env/Dockerfile.centos
|
|
152
180
|
- test/env/Dockerfile.debian
|
|
181
|
+
- test/fixtures/mig_test_rpc.defs
|
|
153
182
|
- test/rcd_test/Gemfile
|
|
154
183
|
- test/rcd_test/Rakefile
|
|
155
184
|
- test/rcd_test/ext/java/RcdTestExtService.java
|
|
@@ -161,6 +190,7 @@ test_files:
|
|
|
161
190
|
- test/rcd_test/rcd_test.gemspec
|
|
162
191
|
- test/rcd_test/test/test_basic.rb
|
|
163
192
|
- test/test_environment_variables.rb
|
|
193
|
+
- test/test_mig.rb
|
|
164
194
|
- test/test_parallel_docker_build.rb
|
|
165
195
|
- test/test_starter.rb
|
|
166
196
|
- test/test_versions.rb
|
metadata.gz.sig
ADDED
|
Binary file
|
data/test/env/Dockerfile.centos
DELETED
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
ARG from_image
|
|
2
|
-
FROM ${from_image}
|
|
3
|
-
|
|
4
|
-
RUN uname -a
|
|
5
|
-
|
|
6
|
-
# Change download address of Centos-8 which is EOL
|
|
7
|
-
RUN sed -i 's/mirrorlist/#mirrorlist/g' /etc/yum.repos.d/CentOS-*
|
|
8
|
-
RUN sed -i 's|#baseurl=http://mirror.centos.org|baseurl=http://vault.centos.org|g' /etc/yum.repos.d/CentOS-*
|
|
9
|
-
|
|
10
|
-
RUN yum install -y ruby git
|
|
11
|
-
|
|
12
|
-
RUN ruby --version
|
|
13
|
-
RUN gem env
|
|
14
|
-
|
|
15
|
-
# centos-8 comes with Ruby 2.5, and this is the last version of bundler that supports it
|
|
16
|
-
RUN gem install bundler -v2.2.28
|
|
17
|
-
|
|
18
|
-
WORKDIR /build
|
|
19
|
-
|
|
20
|
-
CMD ruby -e "puts Gem::Platform.local.to_s" && \
|
|
21
|
-
gem install --local *.gem --verbose --no-document && \
|
|
22
|
-
cd test/rcd_test/ && \
|
|
23
|
-
bundle install && \
|
|
24
|
-
rake test
|