std::rt: Fix crate_map on Win64
This commit is contained in:
parent
a130861d31
commit
472b618248
@ -56,7 +56,12 @@ pub fn get_crate_map() -> Option<&'static CrateMap<'static>> {
|
||||
|
||||
let sym = unsafe {
|
||||
let module = dl::open_internal();
|
||||
let sym = do "__rust_crate_map_toplevel".with_c_str |buf| {
|
||||
let rust_crate_map_toplevel = if cfg!(target_arch = "x86") {
|
||||
"__rust_crate_map_toplevel"
|
||||
} else {
|
||||
"_rust_crate_map_toplevel"
|
||||
};
|
||||
let sym = do rust_crate_map_toplevel.with_c_str |buf| {
|
||||
dl::symbol(module, buf)
|
||||
};
|
||||
dl::close(module);
|
||||
|
Loading…
Reference in New Issue
Block a user