@@ -17,6 +17,8 @@ config GCOV_BASE
bool "Enable gcov support (selectively)"
depends on DEBUG_INFO
depends on !KCOV && !GCOV_KERNEL
+ select CONSTRUCTORS
+ select WANT_MODULE_DESTRUCTORS
help
This option allows developers to retrieve coverage data from a UML
session, stored to disk just like with a regular userspace binary,
@@ -240,6 +240,8 @@ void do_uml_exitcalls(void)
call = &__uml_exitcall_end;
while (--call >= &__uml_exitcall_begin)
(*call)();
+
+ run_all_module_destructors();
}
char *uml_strdup(const char *string)