This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
Re: make and addprefix
- From: y2bismil at engmail dot uwaterloo dot ca
- To: gcc-help at gcc dot gnu dot org
- Date: Thu, 9 Oct 2003 15:02:31 -0400
- Subject: Re: make and addprefix
- References: <20031009152131.GA15549@redhat.com> <3F857E11.9080401@unitus.it> <Pine.BSF.4.58.0310091730320.90326@naos.dbai.tuwien.ac.at> <1065724336.3f85a9b02f7f5@www.nexusmail.uwaterloo.ca>
Never mind,
I just did it with a foreach loop...It's working now, but my question is still
valid. It's just not urgent :)
Quoting y2bismil@engmail.uwaterloo.ca:
> Hi all,
>
> I've got this weird problem using the addprefix function in GNU make. The
> documentation makes it seem simple enough:
>
> $(addprefix prefix,names...)
>
> But when I try to do it, it always returns nothing.
> For example, I have a file list declared as follows:
> ****************************************
> FileList := one.ob3 \
> two.ob3 \
> three.ob3 \
>
> Then when I do get to my target
> runTarget :
> %exec echo $(FileList)
> #This works fine and the first line is as expected.
> #Now I try to add a prefix
> %exec echo $(addprefix Pre, $(FileList) )
> #it prints an empty line.
> ****************************************
> Any ideas?
> Or can anyone think of another easy way to prefix a list of files separated
> by
> white space?
>
>
> Yamin
>
>
> BTW...my previous problem was caused by the fact that compl was a c++
> keyword
> Thanks Eljay
>
> ----------------------------------------
> This mail sent through www.mywaterloo.ca
>
----------------------------------------
This mail sent through www.mywaterloo.ca