help-make
[Top][All Lists]
Advanced

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

Re: Request for help in setting a variable in GNU Make.


From: Paul D. Smith
Subject: Re: Request for help in setting a variable in GNU Make.
Date: Thu, 6 Apr 2006 08:48:35 -0400

%% Alexey Neyman <address@hidden> writes:

  an> Paul,
  an> On Thursday 06 April 2006 16:18, Paul D. Smith wrote:
  >> $(PROG): $(SRC)
  >>        gcc -o $@ $? $(patsubst %.c,%.o,$(filter-out $?,$^))

  an> Nitpicking: this will change the linking order, depending on what 
  an> objects were modified since the most recent linkage. Portable 
  an> programs should not depend on this. Though I have encountered the 
  an> ones that did :)

If these were libraries you would definitely be correct: we'd need to
preserve the order.

But there's no linking order issue with .o files, because they are all
linked all the time anyway.

-- 
-------------------------------------------------------------------------------
 Paul D. Smith <address@hidden>          Find some GNU make tips at:
 http://www.gnu.org                      http://make.paulandlesley.org
 "Please remain calm...I may be mad, but I am a professional." --Mad Scientist




reply via email to

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