Skip to content

Commit

Permalink
[CLI] error on not finding symbol (JuliaLang#38994)
Browse files Browse the repository at this point in the history
Also removes some excess exports that are not in julia.h, including
intrinsics and the unused `jl_cpuid` function (only defined on Intel
processors).
  • Loading branch information
vchuravy committed Apr 16, 2021
1 parent fbffe7c commit 67f29d8
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 222 deletions.
7 changes: 6 additions & 1 deletion cli/loader_lib.c
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,12 @@ __attribute__((constructor)) void jl_load_libjulia_internal(void) {

// Once we have libjulia-internal loaded, re-export its symbols:
for (unsigned int symbol_idx=0; jl_exported_func_names[symbol_idx] != NULL; ++symbol_idx) {
(*jl_exported_func_addrs[symbol_idx]) = lookup_symbol(libjulia_internal, jl_exported_func_names[symbol_idx]);
void *addr = lookup_symbol(libjulia_internal, jl_exported_func_names[symbol_idx]);
if (addr == NULL) {
jl_loader_print_stderr3("ERROR: Unable to load ", jl_exported_func_names[symbol_idx], " from libjulia-internal");
exit(1);
}
(*jl_exported_func_addrs[symbol_idx]) = addr;
}
}

Expand Down
Loading

0 comments on commit 67f29d8

Please sign in to comment.