strange install directory

Marc Glisse marc.glisse at inria.fr
Sat Feb 27 10:11:10 UTC 2021


On Sat, 27 Feb 2021, Paul Zimmermann wrote:

> thank you all for your answers. Maybe the solution would be to check for
> $prefix/lib64 (and $prefix/lib32) if we don't find libgmp in $prefix/lib.

That would help for this case. Of course, it might end up in 
$prefix/libx32 (X32 ABI on x86_64), $prefix/lib64le (some 64-bit 
little-endian ABI), $prefix/lib/$triplet (debian and derived 
distributions), etc... $prefix/*lib*/ + $prefix/lib/*/ roughly seems to 
cover it for now (I may be missing more). Or you could consider that 
people in this situation should use --with-gmp-lib and avoid guessing. I 
think it could be interesting if you asked on the autoconf list what they 
think.


(I just realized that we can bypass the lib->lib64 renaming by specifying 
libdir with an extra '/' in the name, say at the beginning or the end, 
although that doesn't solve your problem)

With recent GMP, you can also get some information with `pkg-config --libs 
gmp` (or other options than --libs), but that requires that the .pc file 
be in PKG_CONFIG_PATH, which just shifts the issue.

-- 
Marc Glisse


More information about the gmp-devel mailing list