1 |
From: Daniel Cordero <catalyst@××××.io> |
2 |
|
3 |
If decompressor != compressor, the options given to the programs may not |
4 |
be understood, causing runtime errors. |
5 |
|
6 |
Allow the compression arguments to be overridden in a specfile. |
7 |
Compressor can already be configured with compression_mode. |
8 |
|
9 |
For decompression, while the decompressor is detected by the file |
10 |
extension, use the separate decomp_opts so there is no argument |
11 |
conflicts. |
12 |
--- |
13 |
Note: compressor_options can't be empty, as catalyst just drops the key. |
14 |
|
15 |
catalyst/base/stagebase.py | 3 ++- |
16 |
catalyst/defaults.py | 2 +- |
17 |
2 files changed, 3 insertions(+), 2 deletions(-) |
18 |
|
19 |
diff --git a/catalyst/base/stagebase.py b/catalyst/base/stagebase.py |
20 |
index 5a8cd1df..6efcf0d1 100644 |
21 |
--- a/catalyst/base/stagebase.py |
22 |
+++ b/catalyst/base/stagebase.py |
23 |
@@ -48,6 +48,7 @@ class StageBase(TargetBase, ClearBase, GenBase): |
24 |
"cflags", |
25 |
"common_flags", |
26 |
"compression_mode", |
27 |
+ "compressor_options", |
28 |
"cxxflags", |
29 |
"decompressor_search_order", |
30 |
"distcc_hosts", |
31 |
@@ -677,7 +678,7 @@ class StageBase(TargetBase, ClearBase, GenBase): |
32 |
source=self.settings["source_path"], |
33 |
destination=self.settings["chroot_path"], |
34 |
arch=self.settings["compressor_arch"], |
35 |
- other_options=self.settings["compressor_options"], |
36 |
+ other_options=self.settings["decomp_opt"], |
37 |
) |
38 |
|
39 |
display_msg = ( |
40 |
diff --git a/catalyst/defaults.py b/catalyst/defaults.py |
41 |
index c153fcc4..fbf406b2 100644 |
42 |
--- a/catalyst/defaults.py |
43 |
+++ b/catalyst/defaults.py |
44 |
@@ -30,7 +30,7 @@ confdefaults = { |
45 |
"compression_mode": 'lbzip2', |
46 |
"compressor_arch": None, |
47 |
"compressor_options": XATTRS_OPTIONS['linux'], |
48 |
- "decomp_opt": DECOMPRESSOR_PROGRAM_OPTIONS['linux'], |
49 |
+ "decomp_opt": XATTRS_OPTIONS['linux'], |
50 |
"decompressor_search_order": DECOMPRESSOR_SEARCH_ORDER, |
51 |
"distdir": portage.settings['DISTDIR'], |
52 |
"icecream": "/var/cache/icecream", |
53 |
-- |
54 |
2.26.2 |