1 |
On 5/30/21 2:55 PM, Ionen Wolkens wrote: |
2 |
> On Sun, May 30, 2021 at 02:42:01PM -0400, Mike wrote: |
3 |
>> |
4 |
>> |
5 |
>> On 5/30/21 2:28 PM, Ionen Wolkens wrote: |
6 |
>>> On Sun, May 30, 2021 at 01:29:12PM -0400, mpagano@g.o wrote: |
7 |
>>>> From: Mike Pagano <mpagano@g.o> |
8 |
>>>> |
9 |
>>>> As the purpose of pkg_pretend is to run sanity checks during |
10 |
>>>> dependency calculation time, provide the default implementation |
11 |
>>>> and perform CONFIG_CHECK within it. |
12 |
>>>> |
13 |
>>>> See bug #759238 |
14 |
>>>> |
15 |
>>> [...] |
16 |
>>>> |
17 |
>>>> +# @FUNCTION: linux-mod_pkg_pretend |
18 |
>>>> +# @DESCRIPTION: |
19 |
>>>> +# Check the CONFIG_CHECK options |
20 |
>>>> +linux-mod_pkg_pretend() { |
21 |
>>>> + |
22 |
>>>> + debug-print-function ${FUNCNAME} $* |
23 |
>>>> + # External modules use kernel symbols (bug #591832, #759238) |
24 |
>>>> + CONFIG_CHECK+=" !TRIM_UNUSED_KSYMS" |
25 |
>>>> +} |
26 |
>>> |
27 |
>>> Is this not supposed to actually run the checks? Correct me if I'm |
28 |
>>> missing something but it's just setting the value. linux-mod normally |
29 |
>>> run the checks through linux-info_pkg_setup and its check_extra_config. |
30 |
>> |
31 |
>> Thanks for the analysis, Ionen. |
32 |
>> The eclass does not actually run the check as it exists today. |
33 |
>> Maybe there was a reason for that when it was originally coded? |
34 |
> |
35 |
> It does indirectly: |
36 |
> # External modules use kernel symbols (bug #591832) |
37 |
> CONFIG_CHECK+=" !TRIM_UNUSED_KSYMS" |
38 |
> |
39 |
> linux-info_pkg_setup; |
40 |
> ^^^^^ checks ran here |
41 |
> |
42 |
> Older nvidia-drivers ebuild was kind of nasty with that, it did its |
43 |
> own checks then the linux-mod.eclass' linux-info call did as well |
44 |
> (duplicate messages), which I now let linux-mod handle. |
45 |
> |
46 |
>> |
47 |
>> |
48 |
>>> For nvidia-drivers, this value will also be lost for the pkg_setup test |
49 |
>>> (needed to check, say.. gentoo-kernel emerged in-between) because I |
50 |
>>> currently set a local CONFIG_CHECK="..." inside pkg_setup() |
51 |
>>> (there's also a conditional CONFIG_CHECK, part of why not global) |
52 |
>>> |
53 |
>>> Some other ebuilds set CONFIG_CHECK in pkg_setup I believe. |
54 |
>> |
55 |
>> Maybe virtualbox-modules should do it's own CONFIG_CHECK as nvidia-drivers does. |
56 |
>> As that package is the impetus of this patch. |
57 |
>> |
58 |
>>> Not that I can't change this for nvidia, I guess I could set a global |
59 |
>>> scope CONFIG_CHECK with !FATAL-only and += the non-fatal ones in |
60 |
>>> pkg_setup to avoid message duplication. |
61 |
>>> |
62 |
>>> Have same concerns as mgorny wrt exported pkg_pretend, plus I'd also |
63 |
>>> need to add my own pkg_pretend wrapper to check MODULES_OPTIONAL_USE |
64 |
>>> |
65 |
>> |
66 |
> |
67 |
|
68 |
Going to rescind this patch from consideration. |
69 |
|
70 |
Mike |