help-make
[Top][All Lists]
Advanced

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

Re: Static pattern and $$(@F)


From: Paul D. Smith
Subject: Re: Static pattern and $$(@F)
Date: Tue, 10 Sep 2002 23:10:06 -0400

%% Yogesh Bhagwat <address@hidden> writes:

  yb> I was wondering if the issue regarding static pattern rule
  yb> and $$(@F) as in System V make was ever resolved. Is there
  yb> a way to achieve the same efffect in gnu make.

There is a way to achieve half of the effect, as described in the manual
using static pattern rules.  But, static pattern rules are not a 100%
replacement.

  yb> ${FILES_IN_DIR_A} : % : ${DIR_B}/$(notdir %)
  yb>        do_something

  yb> does not work.

If all of your $(FILES_IN_DIR_A) are of the form $(DIR_A)/somefile, then
you can use static pattern rules as follows:

  $(FILES_IN_DIR_A): $(DIR_A)/% : $(DIR_B)/%
          do_something

  yb> I am using 3.79.1 version of gnu make.

The next version of GNU make (3.80) does support this strange SysV
construct--at least to some extent.

-- 
-------------------------------------------------------------------------------
 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]