help-make
[Top][All Lists]
Advanced

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

Re: findstring & ifeq


From: Ken Mankoff
Subject: Re: findstring & ifeq
Date: Wed, 10 May 2006 17:07:14 -0400 (EDT)


On Wed, 10 May 2006, Ken Mankoff wrote:
I'm trying to do conditional compilation using findstring and ifeq in the makefile, but having errors. Can anyone advise how to best do this?

My apologies for not searching the list archives more thoroughly. The solution is like so:

%.o: %.f
        $(if $(findstring $@,$(OBJ)),   \
                $(FC) $(FFLAGS) $<,  \
                $(FCMP) $(FFLAGSMP) $<)


ifeq doesn't expand $@, so $(if) must be used...

  -k.





reply via email to

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