mirror of
https://github.com/LibreELEC/LibreELEC.tv.git
synced 2025-07-24 11:16:51 +00:00
uClibc: When DEBUG=yes in config/options, allows creation of the file
/dlsym.log which contains all the symbols from libraries that are accessed via dlopen()/dlsym()/dlclose() procedure (and so the symbols are not directly accessible from the resulting binary). Intended use is to create a file which can be sort|uniq'd into an alphabetically-ordered list, so that libstrip can be used on those libraries that are used by programs that use dlsym(), without stripping out required symbols.
This commit is contained in:
parent
543075c36a
commit
7468fd1a59
@ -0,0 +1,26 @@
|
||||
* When DEBUG=yes in config/options, allows creation of the file
|
||||
/dlsym.log which contains all the symbols from libraries that
|
||||
are accessed via dlopen()/dlsym()/dlclose() procedure (and so
|
||||
the symbols are not directly accessible from the resulting binary).
|
||||
|
||||
Intended use is to create a file which can be sort|uniq'd into an
|
||||
alphabetically-ordered list, so that libstrip can be used on those
|
||||
libraries that are used by programs that use dlsym(), without
|
||||
stripping out required symbols.
|
||||
|
||||
--- uClibc/ldso/libdl/libdl.c 2007-02-05 03:01:12.000000000 +0900
|
||||
+++ uClibc/ldso/libdl/libdl.c 2007-02-05 03:05:10.000000000 +0900
|
||||
@@ -406,6 +406,13 @@
|
||||
#else
|
||||
const char *name2 = name;
|
||||
#endif
|
||||
+#ifdef _DLSYM_TRACE_NAME
|
||||
+ FILE *log = fopen("/var/log/dlsym.log", "a");
|
||||
+
|
||||
+ fprintf(log, "%s\n", name);
|
||||
+ fflush(log);
|
||||
+ fclose(log);
|
||||
+#endif
|
||||
handle = (struct dyn_elf *) vhandle;
|
||||
|
||||
/* First of all verify that we have a real handle
|
Loading…
x
Reference in New Issue
Block a user