You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When launching with no parameters (all modules), modules benchmark.so and computer.so failed to be loaded due to undefined symbols (see log below) which are in devices.so. This leads to an unexpected prompt asking user to load computer.so, along with the missing of benchmark.so-related features.
while ((filename= (gchar*) g_dir_read_name(dir))) {
if (g_strrstr(filename, "."G_MODULE_SUFFIX) &&
module_in_module_list(filename, module_list) &&
((module=module_load(filename)))) {
modules=g_slist_prepend(modules, module);
}
I think this may be caused by an undefined order returned from g_dir_read_name(). Document (see references) says "The order of entries returned from this function is not defined", and make other modules load before devices.so.
I managed to write a patch as a workaround which may fix the problem, but I am not confident about it and not going to create a pull request about this. The patch makes function modules_load() call module_load((gchar *) "devices.so") before traversing modules directory.
* Introduced a new patch to fix problematic loading order of modules. See
... upstream issue lpereira/hardinfo#676
* Dropped unneeded prepare file
* Updated dependency list
Signed-off-by: Camber Huang <[email protected]>
CamberLoid
added a commit
to AOSC-Dev/aosc-os-abbs
that referenced
this issue
Oct 9, 2022
* Introduced a new patch to fix problematic loading order of modules. See
... upstream issue lpereira/hardinfo#676
* Dropped unneeded prepare file
* Updated dependency list
Signed-off-by: Camber Huang <[email protected]>
Description
When launching with no parameters (all modules), modules
benchmark.so
andcomputer.so
failed to be loaded due to undefined symbols (see log below) which are indevices.so
. This leads to an unexpected prompt asking user to loadcomputer.so
, along with the missing ofbenchmark.so
-related features.In
hardinfo/utils.c
:hardinfo/hardinfo/util.c
Lines 966 to 971 in 10f9789
I think this may be caused by an undefined order returned from
g_dir_read_name()
. Document (see references) says "The order of entries returned from this function is not defined", and make other modules load beforedevices.so
.I managed to write a patch as a workaround which may fix the problem, but I am not confident about it and not going to create a pull request about this. The patch makes function
modules_load()
callmodule_load((gchar *) "devices.so")
before traversing modules directory.Build with
-DHARDINFO_GTK3='ON'
References:
Log
(full: https://gist.github.com/CamberLoid/c597378249c693749f953c90caea90b2)
The text was updated successfully, but these errors were encountered: