bug-make
[Top][All Lists]
Advanced

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

Re: problem computed variables


From: Paul D. Smith
Subject: Re: problem computed variables
Date: Sat, 1 Mar 2003 14:38:01 -0500

%% Duane Ellis <address@hidden> writes:

  de> DBG_ORDER=$(RAW_DBG_ORDER:%=$(%))
  de> REL_ORDER=$(RAW_REL_ORDER:%=$(%))

You can't do this: patterns don't replace before expansion, they replace
after expansion.

It's very easy, though, just do this:

  DBG_ORDER = $(foreach V,$(RAW_DBG_ORDER),$($(V)))

You can make a function out of it and use $(call ...) if that makes it
clearer in your makefile.

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