mini_portile2 2.8.5.rc1 → 2.8.5.rc2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +3 -1
- data/lib/mini_portile2/mini_portile.rb +72 -24
- data/lib/mini_portile2/version.rb +1 -1
- data/test/test_mkmf_config.rb +88 -45
- data/test/test_recipe.rb +18 -0
- metadata +4 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ca5eb330aa4b2b6093e3cbe77641dfd14b3eff2601dce6c97f7de69f42fffcb5
|
4
|
+
data.tar.gz: ad64c2536ab3e978c22d71bc380144f1fa579cf01993e97bf63553ec4732b851
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 67530e1e366cb1605a272234bbfe7ccd6d8659ebd081352a93848de694c03ad0bac23425f2a13c94f67b5c0a55273f178577f31ad088d452f4bfa810e8445c45
|
7
|
+
data.tar.gz: 47e6b00a089e83e422f51c833744226c275af1a8700a21fa11a7f81c70b952da78fbf6df3a0cd8e1347be89b8c1ce6ac0f430a6339b3d0f3340aa2fe1efa0afb
|
data/CHANGELOG.md
CHANGED
@@ -1,12 +1,14 @@
|
|
1
1
|
## mini_portile changelog
|
2
2
|
|
3
|
-
### 2.8.5.
|
3
|
+
### 2.8.5.rc2 / 2023-09-17
|
4
4
|
|
5
5
|
#### Added
|
6
6
|
|
7
7
|
- New method `MiniPortile#mkmf_config` will set up MakeMakefile variables to properly link against the recipe. This should make it easier for C extensions to package third-party libraries.
|
8
8
|
- With no arguments, will set up just `$INCFLAGS`, `$libs`, and `$LIBPATH`.
|
9
9
|
- Optionally, if provided a pkg-config file, will use that config to more precisely set `$INCFLAGS`, `$libs`, `$LIBPATH`, and `$CFLAGS`/`$CXXFLAGS`.
|
10
|
+
- Optionally, if provided the name of a static archive, will rewrite linker flags to ensure correct linkage.
|
11
|
+
- New methods `#lib_path` and `#include_path` which point at the installed directories under `ports`.
|
10
12
|
|
11
13
|
|
12
14
|
### 2.8.4 / 2023-07-18
|
@@ -27,6 +27,8 @@ class Net::HTTP
|
|
27
27
|
end
|
28
28
|
end
|
29
29
|
|
30
|
+
$MINI_PORTILE_STATIC_LIBS = {}
|
31
|
+
|
30
32
|
class MiniPortile
|
31
33
|
DEFAULT_TIMEOUT = 10
|
32
34
|
|
@@ -237,11 +239,10 @@ class MiniPortile
|
|
237
239
|
end
|
238
240
|
|
239
241
|
def activate
|
240
|
-
lib_path = File.join(port_path, "lib")
|
241
242
|
vars = {
|
242
243
|
'PATH' => File.join(port_path, 'bin'),
|
243
|
-
'CPATH' =>
|
244
|
-
'LIBRARY_PATH' => lib_path
|
244
|
+
'CPATH' => include_path,
|
245
|
+
'LIBRARY_PATH' => lib_path,
|
245
246
|
}.reject { |env, path| !File.directory?(path) }
|
246
247
|
|
247
248
|
output "Activating #{@name} #{@version} (from #{port_path})..."
|
@@ -268,11 +269,19 @@ class MiniPortile
|
|
268
269
|
end
|
269
270
|
end
|
270
271
|
|
271
|
-
|
272
|
+
# pkg: the pkg-config file name (without the .pc extension)
|
273
|
+
# dir: inject the directory path for the pkg-config file (probably only useful for tests)
|
274
|
+
# static: the name of the static library archive (without the "lib" prefix or the file extension), or nil for dynamic linking
|
275
|
+
#
|
276
|
+
# we might be able to be terribly clever and infer the name of the static archive file, but
|
277
|
+
# unfortunately projects have so much freedom in what they can report (for name, for libs, etc.)
|
278
|
+
# that it feels unreliable to try to do so, so I'm preferring to just have the developer make it
|
279
|
+
# explicit.
|
280
|
+
def mkmf_config(pkg: nil, dir: nil, static: nil)
|
272
281
|
require "mkmf"
|
273
282
|
|
274
283
|
if pkg
|
275
|
-
dir ||= File.join(
|
284
|
+
dir ||= File.join(lib_path, "pkgconfig")
|
276
285
|
pcfile = File.join(dir, "#{pkg}.pc")
|
277
286
|
unless File.exist?(pcfile)
|
278
287
|
raise ArgumentError, "pkg-config file '#{pcfile}' does not exist"
|
@@ -288,42 +297,81 @@ class MiniPortile
|
|
288
297
|
|
289
298
|
incflags = minimal_pkg_config(pcfile, "cflags-only-I")
|
290
299
|
cflags = minimal_pkg_config(pcfile, "cflags-only-other")
|
291
|
-
|
292
|
-
|
300
|
+
if static
|
301
|
+
ldflags = minimal_pkg_config(pcfile, "libs-only-L", "static")
|
302
|
+
libflags = minimal_pkg_config(pcfile, "libs-only-l", "static")
|
303
|
+
else
|
304
|
+
ldflags = minimal_pkg_config(pcfile, "libs-only-L")
|
305
|
+
libflags = minimal_pkg_config(pcfile, "libs-only-l")
|
306
|
+
end
|
293
307
|
else
|
294
308
|
output "Configuring MakeMakefile for #{@name} #{@version} (from #{path})\n"
|
295
309
|
|
296
|
-
include_path = File.join(path, "include")
|
297
|
-
lib_path = File.join(path, "lib")
|
298
|
-
|
299
310
|
lib_name = name.sub(/\Alib/, "") # TODO: use delete_prefix when we no longer support ruby 2.4
|
300
311
|
|
301
|
-
incflags = "-I#{include_path}"
|
302
|
-
|
303
|
-
|
312
|
+
incflags = Dir.exist?(include_path) ? "-I#{include_path}" : ""
|
313
|
+
cflags = ""
|
314
|
+
ldflags = Dir.exist?(lib_path) ? "-L#{lib_path}" : ""
|
315
|
+
libflags = Dir.exist?(lib_path) ? "-l#{lib_name}" : ""
|
304
316
|
end
|
305
317
|
|
306
|
-
if
|
307
|
-
|
318
|
+
if static
|
319
|
+
libdir = lib_path
|
320
|
+
if pcfile
|
321
|
+
variables = minimal_pkg_config(pcfile, "print-variables").split("\n").map(&:strip)
|
322
|
+
if variables.include?("libdir")
|
323
|
+
libdir = minimal_pkg_config(pcfile, "variable=libdir")
|
324
|
+
end
|
325
|
+
end
|
326
|
+
|
327
|
+
#
|
328
|
+
# keep track of the libraries we're statically linking against, and fix up ldflags and
|
329
|
+
# libflags to make sure we link statically against the recipe's libaries.
|
330
|
+
#
|
331
|
+
# this avoids the unintentionally dynamically linking against system libraries, and makes sure
|
332
|
+
# that if multiple pkg-config files reference each other that we are able to intercept flags
|
333
|
+
# from dependent packages that reference the static archive.
|
334
|
+
#
|
335
|
+
$MINI_PORTILE_STATIC_LIBS[static] = libdir
|
336
|
+
static_ldflags = $MINI_PORTILE_STATIC_LIBS.values.map { |v| "-L#{v}" }
|
337
|
+
static_libflags = $MINI_PORTILE_STATIC_LIBS.keys.map { |v| "-l#{v}" }
|
338
|
+
|
339
|
+
# remove `-L#{libdir}` and `-lfoo`. we don't need them since we link against the static
|
340
|
+
# archive using the full path.
|
341
|
+
ldflags = ldflags.shellsplit.reject { |f| static_ldflags.include?(f) }.shelljoin
|
342
|
+
libflags = libflags.shellsplit.reject { |f| static_libflags.include?(f) }.shelljoin
|
343
|
+
|
344
|
+
# prepend the full path to the static archive to the linker flags
|
345
|
+
static_archive = File.join(libdir, "lib#{static}.#{$LIBEXT}")
|
346
|
+
libflags = [static_archive, libflags].join(" ").strip
|
308
347
|
end
|
309
348
|
|
310
|
-
# prefer this package by prepending
|
349
|
+
# prefer this package by prepending to search paths and library flags
|
311
350
|
#
|
312
|
-
#
|
313
|
-
# shared libraries
|
314
|
-
$INCFLAGS = [incflags, $INCFLAGS].join(" ").strip
|
315
|
-
|
351
|
+
# convert the ldflags into a list of directories and append to $LIBPATH (instead of just using
|
352
|
+
# $LDFLAGS) to ensure we get the `-Wl,-rpath` linker flag for re-finding shared libraries.
|
353
|
+
$INCFLAGS = [incflags, $INCFLAGS].join(" ").strip
|
354
|
+
libpaths = ldflags.shellsplit.map { |f| f.sub(/\A-L/, "") }
|
355
|
+
$LIBPATH = libpaths | $LIBPATH
|
356
|
+
$libs = [libflags, $libs].join(" ").strip
|
316
357
|
|
317
|
-
# prefer this package's flags by appending them to the command line
|
318
|
-
$CFLAGS = [$CFLAGS, cflags].join(" ").strip
|
319
|
-
$CXXFLAGS = [$CXXFLAGS, cflags].join(" ").strip
|
320
|
-
$libs = [$libs, libflags].join(" ").strip if libflags
|
358
|
+
# prefer this package's compiler flags by appending them to the command line
|
359
|
+
$CFLAGS = [$CFLAGS, cflags].join(" ").strip
|
360
|
+
$CXXFLAGS = [$CXXFLAGS, cflags].join(" ").strip
|
321
361
|
end
|
322
362
|
|
323
363
|
def path
|
324
364
|
File.expand_path(port_path)
|
325
365
|
end
|
326
366
|
|
367
|
+
def include_path
|
368
|
+
File.join(path, "include")
|
369
|
+
end
|
370
|
+
|
371
|
+
def lib_path
|
372
|
+
File.join(path, "lib")
|
373
|
+
end
|
374
|
+
|
327
375
|
def gcc_cmd
|
328
376
|
(ENV["CC"] || @gcc_command || RbConfig::CONFIG["CC"] || "gcc").dup
|
329
377
|
end
|
data/test/test_mkmf_config.rb
CHANGED
@@ -3,11 +3,17 @@ require File.expand_path('../helper', __FILE__)
|
|
3
3
|
require "mkmf" # initialize $LDFLAGS et al here, instead of in the middle of a test
|
4
4
|
|
5
5
|
class TestMkmfConfig < TestCase
|
6
|
-
attr_reader :recipe
|
6
|
+
attr_reader :recipe
|
7
7
|
|
8
8
|
LIBXML_PCP = File.join(__dir__, "assets", "pkgconf", "libxml2")
|
9
9
|
LIBXSLT_PCP = File.join(__dir__, "assets", "pkgconf", "libxslt")
|
10
10
|
|
11
|
+
def make_recipe(name, version)
|
12
|
+
MiniPortile.new(name, version).tap do |recipe|
|
13
|
+
recipe.logger = StringIO.new # hush output
|
14
|
+
end
|
15
|
+
end
|
16
|
+
|
11
17
|
def setup
|
12
18
|
super
|
13
19
|
|
@@ -19,14 +25,11 @@ class TestMkmfConfig < TestCase
|
|
19
25
|
$CFLAGS = "-xxx"
|
20
26
|
$CXXFLAGS = "-xxx"
|
21
27
|
$libs = "-lxxx"
|
28
|
+
$MINI_PORTILE_STATIC_LIBS = {}
|
22
29
|
|
23
30
|
FileUtils.rm_rf(["tmp", "ports"]) # remove any previous test files
|
24
31
|
|
25
|
-
@recipe =
|
26
|
-
recipe.logger = StringIO.new
|
27
|
-
end
|
28
|
-
@include_path = File.join(@recipe.path, "include")
|
29
|
-
@lib_path = File.join(@recipe.path, "lib")
|
32
|
+
@recipe = make_recipe("libfoo", "1.0.0")
|
30
33
|
end
|
31
34
|
|
32
35
|
def teardown
|
@@ -37,6 +40,7 @@ class TestMkmfConfig < TestCase
|
|
37
40
|
$CFLAGS = ""
|
38
41
|
$CXXFLAGS = ""
|
39
42
|
$libs = ""
|
43
|
+
$MINI_PORTILE_STATIC_LIBS = {}
|
40
44
|
@save_env.each do |var, val|
|
41
45
|
ENV[var] = val
|
42
46
|
end
|
@@ -47,35 +51,48 @@ class TestMkmfConfig < TestCase
|
|
47
51
|
def test_mkmf_config_recipe_LIBPATH_global_lib_dir_does_not_exist
|
48
52
|
recipe.mkmf_config
|
49
53
|
|
50
|
-
refute_includes($LIBPATH, lib_path)
|
51
|
-
refute_includes($libs.
|
54
|
+
refute_includes($LIBPATH, recipe.lib_path)
|
55
|
+
refute_includes($libs.shellsplit, "-lfoo")
|
52
56
|
end
|
53
57
|
|
54
|
-
def
|
55
|
-
FileUtils.mkdir_p(lib_path)
|
58
|
+
def test_mkmf_config_recipe_LIBPATH_global_not_static
|
59
|
+
FileUtils.mkdir_p(recipe.lib_path)
|
56
60
|
|
57
61
|
recipe.mkmf_config
|
58
62
|
|
59
|
-
assert_includes($LIBPATH, lib_path)
|
60
|
-
assert_operator($LIBPATH.index(lib_path), :<, $LIBPATH.index("xxx")) # prepend
|
63
|
+
assert_includes($LIBPATH, recipe.lib_path)
|
64
|
+
assert_operator($LIBPATH.index(recipe.lib_path), :<, $LIBPATH.index("xxx")) # prepend
|
65
|
+
|
66
|
+
assert_includes($libs.shellsplit, "-lfoo") # note the recipe name is "libfoo"
|
67
|
+
assert_match(%r{-lfoo.*-lxxx}, $libs) # prepend
|
68
|
+
end
|
69
|
+
|
70
|
+
def test_mkmf_config_recipe_LIBPATH_global_static
|
71
|
+
FileUtils.mkdir_p(recipe.lib_path)
|
72
|
+
static_lib_path = File.join(recipe.lib_path, "libfoo.#{$LIBEXT}")
|
73
|
+
|
74
|
+
recipe.mkmf_config(static: "foo")
|
75
|
+
|
76
|
+
refute_includes($LIBPATH, recipe.lib_path)
|
61
77
|
|
62
|
-
|
63
|
-
|
78
|
+
refute_includes($libs.shellsplit, "-lfoo") # note the recipe name is "libfoo"
|
79
|
+
assert_includes($libs.shellsplit, static_lib_path)
|
80
|
+
assert_match(%r{#{static_lib_path}.*-lxxx}, $libs) # prepend
|
64
81
|
end
|
65
82
|
|
66
83
|
def test_mkmf_config_recipe_INCFLAGS_global_include_dir_does_not_exist
|
67
84
|
recipe.mkmf_config
|
68
85
|
|
69
|
-
refute_includes($INCFLAGS.
|
86
|
+
refute_includes($INCFLAGS.shellsplit, "-I#{recipe.include_path}")
|
70
87
|
end
|
71
88
|
|
72
89
|
def test_mkmf_config_recipe_INCFLAGS_global
|
73
|
-
FileUtils.mkdir_p(include_path)
|
90
|
+
FileUtils.mkdir_p(recipe.include_path)
|
74
91
|
|
75
92
|
recipe.mkmf_config
|
76
93
|
|
77
|
-
assert_includes($INCFLAGS.
|
78
|
-
assert_match(%r{-I#{include_path}.*-I/xxx}, $INCFLAGS) # prepend
|
94
|
+
assert_includes($INCFLAGS.shellsplit, "-I#{recipe.include_path}")
|
95
|
+
assert_match(%r{-I#{recipe.include_path}.*-I/xxx}, $INCFLAGS) # prepend
|
79
96
|
end
|
80
97
|
|
81
98
|
def test_mkmf_config_pkgconf_does_not_exist
|
@@ -84,7 +101,7 @@ class TestMkmfConfig < TestCase
|
|
84
101
|
end
|
85
102
|
end
|
86
103
|
|
87
|
-
def
|
104
|
+
def test_mkmf_config_pkgconf_LIBPATH_global_not_static
|
88
105
|
# can't get the pkgconf utility to install on windows with ruby 2.3 in CI
|
89
106
|
skip if MiniPortile.windows? && RUBY_VERSION < "2.4"
|
90
107
|
|
@@ -92,9 +109,28 @@ class TestMkmfConfig < TestCase
|
|
92
109
|
|
93
110
|
assert_includes($LIBPATH, "/foo/libxml2/2.11.5/lib")
|
94
111
|
assert_operator($LIBPATH.index("/foo/libxml2/2.11.5/lib"), :<, $LIBPATH.index("xxx")) # prepend
|
112
|
+
refute_includes($LIBPATH, "/foo/zlib/1.3/lib")
|
113
|
+
|
114
|
+
assert_includes($libs.shellsplit, "-lxml2")
|
115
|
+
assert_match(%r{-lxml2.*-lxxx}, $libs) # prepend
|
116
|
+
refute_includes($libs.shellsplit, "-lz")
|
117
|
+
end
|
118
|
+
|
119
|
+
def test_mkmf_config_pkgconf_LIBPATH_global_static
|
120
|
+
# can't get the pkgconf utility to install on windows with ruby 2.3 in CI
|
121
|
+
skip if MiniPortile.windows? && RUBY_VERSION < "2.4"
|
122
|
+
|
123
|
+
static_lib_path = "/foo/libxml2/2.11.5/lib/libxml2.#{$LIBEXT}"
|
95
124
|
|
96
|
-
|
97
|
-
|
125
|
+
recipe.mkmf_config(pkg: "libxml-2.0", dir: LIBXML_PCP, static: "xml2")
|
126
|
+
|
127
|
+
refute_includes($LIBPATH, "/foo/libxml2/2.11.5/lib")
|
128
|
+
refute_includes($libs.shellsplit, "-lxml2")
|
129
|
+
assert_includes($libs.shellsplit, static_lib_path)
|
130
|
+
assert_match(%r{#{static_lib_path}.*-lxxx}, $libs) # prepend
|
131
|
+
|
132
|
+
assert_includes($LIBPATH, "/foo/zlib/1.3/lib") # from --static
|
133
|
+
assert_includes($libs.shellsplit, "-lz") # from --static
|
98
134
|
end
|
99
135
|
|
100
136
|
def test_mkmf_config_pkgconf_CFLAGS_global
|
@@ -103,14 +139,14 @@ class TestMkmfConfig < TestCase
|
|
103
139
|
|
104
140
|
recipe.mkmf_config(pkg: "libxml-2.0", dir: LIBXML_PCP)
|
105
141
|
|
106
|
-
assert_includes($INCFLAGS.
|
142
|
+
assert_includes($INCFLAGS.shellsplit, "-I/foo/libxml2/2.11.5/include/libxml2")
|
107
143
|
assert_match(%r{-I/foo/libxml2/2.11.5/include/libxml2.*-I/xxx}, $INCFLAGS) # prepend
|
108
144
|
|
109
|
-
assert_includes($CFLAGS.
|
110
|
-
assert_match(%r{-xxx.*-ggdb3}, $CFLAGS) #
|
145
|
+
assert_includes($CFLAGS.shellsplit, "-ggdb3")
|
146
|
+
assert_match(%r{-xxx.*-ggdb3}, $CFLAGS) # append
|
111
147
|
|
112
|
-
assert_includes($CXXFLAGS.
|
113
|
-
assert_match(%r{-xxx.*-ggdb3}, $CXXFLAGS) #
|
148
|
+
assert_includes($CXXFLAGS.shellsplit, "-ggdb3")
|
149
|
+
assert_match(%r{-xxx.*-ggdb3}, $CXXFLAGS) # append
|
114
150
|
end
|
115
151
|
|
116
152
|
def test_mkmf_config_pkgconf_path_accumulation
|
@@ -122,37 +158,44 @@ class TestMkmfConfig < TestCase
|
|
122
158
|
refute_includes(pcpaths, LIBXSLT_PCP)
|
123
159
|
end
|
124
160
|
|
125
|
-
|
161
|
+
make_recipe("libxml2", "2.11.5").tap do |recipe|
|
162
|
+
recipe.mkmf_config(pkg: "libxml-2.0", dir: LIBXML_PCP, static: "xml2")
|
126
163
|
|
127
|
-
|
128
|
-
|
129
|
-
|
164
|
+
ENV["PKG_CONFIG_PATH"].split(File::PATH_SEPARATOR).tap do |pcpaths|
|
165
|
+
assert_includes(pcpaths, LIBXML_PCP)
|
166
|
+
refute_includes(pcpaths, LIBXSLT_PCP)
|
167
|
+
end
|
130
168
|
end
|
131
169
|
|
132
|
-
|
170
|
+
make_recipe("libxslt", "1.13.8").tap do |recipe|
|
171
|
+
recipe.mkmf_config(pkg: "libxslt", dir: LIBXSLT_PCP, static: "xslt")
|
133
172
|
|
134
|
-
|
135
|
-
|
136
|
-
|
137
|
-
|
173
|
+
ENV["PKG_CONFIG_PATH"].split(File::PATH_SEPARATOR).tap do |pcpaths|
|
174
|
+
assert_includes(pcpaths, LIBXML_PCP)
|
175
|
+
assert_includes(pcpaths, LIBXSLT_PCP)
|
176
|
+
end
|
138
177
|
|
139
|
-
|
178
|
+
recipe.mkmf_config(pkg: "libexslt", dir: LIBXSLT_PCP, static: "exslt")
|
179
|
+
end
|
140
180
|
|
141
|
-
$INCFLAGS.
|
181
|
+
$INCFLAGS.shellsplit.tap do |incflags|
|
142
182
|
assert_includes(incflags, "-I/foo/libxml2/2.11.5/include/libxml2")
|
143
183
|
assert_includes(incflags, "-I/foo/libxslt/1.1.38/include")
|
144
184
|
end
|
145
|
-
|
146
|
-
assert_includes($LIBPATH, "/foo/libxslt/1.1.38/lib")
|
147
|
-
assert_includes($LIBPATH, "/foo/zlib/1.3/lib") # from `--static`
|
148
|
-
$CFLAGS.split.tap do |cflags|
|
185
|
+
$CFLAGS.shellsplit.tap do |cflags|
|
149
186
|
assert_includes(cflags, "-ggdb3")
|
150
187
|
assert_includes(cflags, "-Wno-deprecated-enum-enum-conversion")
|
151
188
|
end
|
152
|
-
$
|
153
|
-
|
154
|
-
|
155
|
-
|
189
|
+
refute_includes($LIBPATH, "/foo/libxml2/2.11.5/lib")
|
190
|
+
refute_includes($LIBPATH, "/foo/libxslt/1.1.38/lib")
|
191
|
+
assert_includes($LIBPATH, "/foo/zlib/1.3/lib") # from `--static`
|
192
|
+
$libs.shellsplit.tap do |libflags|
|
193
|
+
refute_includes(libflags, "-lxml2")
|
194
|
+
assert_includes(libflags, "/foo/libxml2/2.11.5/lib/libxml2.#{$LIBEXT}")
|
195
|
+
refute_includes(libflags, "-lxslt")
|
196
|
+
assert_includes(libflags, "/foo/libxslt/1.1.38/lib/libxslt.#{$LIBEXT}")
|
197
|
+
refute_includes(libflags, "-lexslt")
|
198
|
+
assert_includes(libflags, "/foo/libxslt/1.1.38/lib/libexslt.#{$LIBEXT}")
|
156
199
|
assert_includes(libflags, "-lz") # from `--static`
|
157
200
|
end
|
158
201
|
end
|
data/test/test_recipe.rb
ADDED
@@ -0,0 +1,18 @@
|
|
1
|
+
require File.expand_path('../helper', __FILE__)
|
2
|
+
|
3
|
+
class TestRecipe < TestCase
|
4
|
+
def test_path
|
5
|
+
recipe = MiniPortile.new("libfoo", "1.0.0")
|
6
|
+
assert_equal(File.expand_path(File.join(recipe.target, recipe.host, recipe.name, recipe.version)), recipe.path)
|
7
|
+
end
|
8
|
+
|
9
|
+
def test_lib_path
|
10
|
+
recipe = MiniPortile.new("libfoo", "1.0.0")
|
11
|
+
assert_equal(File.join(recipe.path, "lib"), recipe.lib_path)
|
12
|
+
end
|
13
|
+
|
14
|
+
def test_include_path
|
15
|
+
recipe = MiniPortile.new("libfoo", "1.0.0")
|
16
|
+
assert_equal(File.join(recipe.path, "include"), recipe.include_path)
|
17
|
+
end
|
18
|
+
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.8.5.
|
4
|
+
version: 2.8.5.rc2
|
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: 2023-09-
|
13
|
+
date: 2023-09-17 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: bundler
|
@@ -139,6 +139,7 @@ files:
|
|
139
139
|
- test/test_execute.rb
|
140
140
|
- test/test_mkmf_config.rb
|
141
141
|
- test/test_proxy.rb
|
142
|
+
- test/test_recipe.rb
|
142
143
|
homepage: https://github.com/flavorjones/mini_portile
|
143
144
|
licenses:
|
144
145
|
- MIT
|
@@ -184,3 +185,4 @@ test_files:
|
|
184
185
|
- test/test_execute.rb
|
185
186
|
- test/test_mkmf_config.rb
|
186
187
|
- test/test_proxy.rb
|
188
|
+
- test/test_recipe.rb
|