Linking failure on aarch64
FX
fxcoudert at gmail.com
Fri Jul 3 17:32:31 UTC 2020
> Fixing that, it builds fine and all checks pass. Thanks!
With the patch, we are seeing an issue when static linking, however:
Undefined symbols for architecture arm64:
"__gmpn_pi1_bdiv_q_1", referenced from:
___gmpn_bdiv_q_1 in libgmp.a(bdiv_q_1.o)
(maybe you meant: ___gmpn_pi1_bdiv_q_1)
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
This happens when linking this test source code:
#include <gmp.h>
#include <stdlib.h>
int main() {
mpz_t i, j, k;
mpz_init_set_str (i, "1a", 16);
mpz_init (j);
mpz_init (k);
mpz_sqrtrem (j, k, i);
if (mpz_get_si (j) != 5 || mpz_get_si (k) != 1) abort();
return 0;
}
FX
More information about the gmp-bugs
mailing list