mirror of
https://github.com/Ed94/Odin.git
synced 2026-08-05 23:28:48 +00:00
dynlib: unload library before loading again & add LIBRARY_FILE_EXTENSION constant
This commit is contained in:
@@ -7,6 +7,8 @@ import "base:runtime"
|
||||
import "core:strings"
|
||||
import "core:sys/posix"
|
||||
|
||||
_LIBRARY_FILE_EXTENSION :: "dylib" when ODIN_OS == .Darwin else "so"
|
||||
|
||||
_load_library :: proc(path: string, global_symbols: bool, allocator: runtime.Allocator) -> (Library, bool) {
|
||||
flags := posix.RTLD_Flags{.NOW}
|
||||
if global_symbols {
|
||||
|
||||
Reference in New Issue
Block a user