[Top][All Lists]

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

Re: using autotools for a library project

From: Ralf Wildenhues
Subject: Re: using autotools for a library project
Date: Fri, 19 Oct 2007 20:24:15 +0200
User-agent: Mutt/1.5.13 (2006-08-11)

Hello Alejandro,

* aaragon wrote on Fri, Oct 19, 2007 at 06:09:29AM CEST:
> Hi everyone, I'm new in this group so I hope this is the right place
> to ask this question.
> I'm using autotools to write a library and now it seems that I need to
> use another library (the gmp for arbitrary precision arithmetic). Now,
> the problem is that when I create my library, all the functions that I
> use from the gmp are not "saved" in my library.

That's normal, and to be expected.  Are you talking about static or
shared libraries, by the way?  Do you use Libtool?

> Therefore, when I
> install the library on a different machine, it complains that it
> cannot find the gmp library or that the library has not the same
> version.

The usual way to solve this is to require the user to install gmp first.
It's common to add a test to configure that checks for installed library
and header files.  If I recall correctly, then the gmp distribution
provides a macro that you can use for this.

> So, I was wondering if there is a way to put the gmp functions that I
> use in my own library, like a bundle so I don't need to have the gmp
> library on other machines.

That would be rather uncommon.

> Thanks for any suggestions. I apologize if this is not the right place
> to ask this, but I didn't find a more autotools related group and I
> found some questions posted.

It's sure ok here.  {autoconf,automake,libtool} exist, but from
the generality of your question it's not clear which of those lists
would be most appropriate.  As long as you don't cross-post, you could
have picked either one of those.

Hope that helps.


reply via email to

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