On Thursday, 1 December 2016 at 22:05:06 UTC, Timothee Cour wrote:
I want to update a library with new symbols (ie partial
libmylib.so : compiled from bar.d and foo.d
now update the file foo.d
dmd -c -fPIC foo.d -offoo.o
clang++ -o libmylib_update.so foo.o -shared -Wl,-lmylib
When trying to dlopen libmylib_update.so from C++ it fails
with: The module 'foo' is already defined in 'libmylib.so'
(it somehow works when the dlopen is called from D)
How would I achieve that?
Have a look at what `trace -E d_executable args` and `trace -E
print on startup and grep for dlopen calls and the like.