程式語言 - GNU - 關於musl libc: Share Library Unload問題



參考資訊:
https://wiki.musl-libc.org/functional-differences-from-glibc.html
https://coderedirect.com/questions/531347/destructor-of-a-global-static-variable-in-a-shared-library-is-not-called-on-dlcl

musl libc沒有保證呼叫dlclose()時,一定會做Unload的動作,因此,有些狀態仍然是處於上次dlopen()的狀態,如:static變數是上次dlopen()的內容,如果需要運用到Share Library的環境,建議使用glibc或uClibc-ng比較適當。