autoconf
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

how to check and add a library if it exists


From: Andrew Makhorin
Subject: how to check and add a library if it exists
Date: Mon, 6 Nov 2006 15:49:36 +0300

I made a mistake in my previous post, sorry.

My question is probably very simple to autoconf experts, however,
I could not find the answer in the autoconf documentation.

I need to include a check in configure.in to see if libgmp.a (the GNU
bignum library) exists. And if it exists, the configure script has to
do the following:

1) change one line in some header file (by sed, for example);

2) add the option '-lgmp' in makefiles, where binaries are compiled.

The trouble is that a check like AC_CHECK_LIB(gmp, mpq_init) fails,
because the header <gmp.h> should be included in a test program.
However, it is unclear how to do that.

Thank you,

Andrew Makhorin





reply via email to

[Prev in Thread] Current Thread [Next in Thread]