Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 8 additions & 7 deletions target/i386/latx/context/library.c
Original file line number Diff line number Diff line change
Expand Up @@ -240,19 +240,20 @@ static void initNativeLib(library_t *lib, box64context_t* context) {
return;
}

struct link_map *real_lm = NULL;
if(dlinfo(lib->priv.w.lib, RTLD_DI_LINKMAP, &real_lm) || !real_lm) {
printf_log(LOG_INFO, "Failed to dlinfo lib %s\n", lib->name);
break;
}
linkmap_t *lm = addLinkMapLib(lib);
if(!lm) {
// Crashed already
printf_log(LOG_INFO, "Failure to add lib %s linkmap\n", lib->name);
break;
}
struct link_map real_lm;
if(dlinfo(lib->priv.w.lib, RTLD_DI_LINKMAP, &real_lm)) {
printf_log(LOG_INFO, "Failed to dlinfo lib %s\n", lib->name);
}
lm->l_addr = real_lm.l_addr;
lm->l_name = real_lm.l_name;
lm->l_ld = real_lm.l_ld;
lm->l_addr = real_lm->l_addr;
lm->l_name = real_lm->l_name;
lm->l_ld = real_lm->l_ld;
kzt_groups_log_library(lib->name, true);
break;
}
Expand Down
8 changes: 2 additions & 6 deletions target/i386/latx/context/meson.build
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
latx_new_world = 'CONFIG_LOONGARCH_NEW_WORLD' in config_host
my_file = files(
'wrappedvulkan.c',
'wrappedlibc.c',
Expand Down Expand Up @@ -49,7 +48,6 @@ my_file = files(
'wrappedlibglx.c',
'wrappedlibxxf86vm.c',
'wrappedlibxau.c',
'wrappedlibxi.c',
'wrappedlibxdmcp.c',
'wrappedxshmfence.c',
'wrappedlibxfixes.c',
Expand All @@ -76,11 +74,9 @@ my_file = files(
'callback.c',
'kzt_public_loader_observer.c',
'kzt_relocation_transaction.c',
'wrappedlibdl.c',
'x86dlfun.c',
'wrappertbbridge.c'
)

if not latx_new_world
my_file += files('wrappedlibdl.c')
endif

i386_ss.add(when: 'CONFIG_LATX', if_true: my_file)
Loading