help-make
[Top][All Lists]
Advanced

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

Re: Implicit rule cannot handle specific -lm?


From: Philip Guenther
Subject: Re: Implicit rule cannot handle specific -lm?
Date: Sun, 28 Feb 2010 22:22:01 -0800

On Sun, Feb 28, 2010 at 3:08 AM, Eus
<address@hidden> wrote:
> In my Makefile, there are three executables.
>
> One needs -lsqlite3 and -lm and the other two don't.
>
> Specifying "LDLIBS := $(LDLIBS) -lsqlite3 -lm" at the beginning of the
> Makefile will also affect the other two executables.
>
> Yes, I know that somehow redundant -l* does not affect the programs that
> do not need them. But, it causes a processing overhead.
>
> Therefore, what is the best practice for this case? The specified method
> above or another better method that you might know?

In the GNU make info pages, in section 6, "How to Use Variables",
you'll find a listing of sub-sections about various subtopics.  That
includes the entry:
---
* Target-specific::             Variable values can be defined on a per-target
                                  basis.
---

Perhaps what's described there could help?


Philip Guenther




reply via email to

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