Maybe some one can stop me from going crazy. Maybe not.
I'm trying to test the contents of a variable, using ifeq, and I am not
getting the appropriate results. Here is what I am doing:
linux := linux
hp := hp
target_arch :=#Make sure its empty
ifndef target_arch #Is target_arch SET
target_arch := $(findstring $(linux), $(dir_tokens) ) # See if its linux
endif
ifndef target_arch #Is TARGET_ARCH SET
target_arch := $(findstring $(hp), $(dir_tokens) ) #See if it hp
endif
#target arch is set the way I think it should be: either linux or hp based on
#the directory
#now I test it:
ifeq ($(strip $(target_arch) ),$(strip $(hp) ) )
result1 := true
endif
# Linux specific stuff
ifeq ($(strip $(target_arch) ),$(strip $(linux) ) )
result2 := true
endif
neither result1 nor result2 are set. What am I doing wrong.
Here is the version of make.
$ make -v
GNU Make version 3.79.1, by Richard Stallman and Roland McGrath.
_______________________________________________
Help-make mailing list
[EMAIL PROTECTED]
http://mail.gnu.org/mailman/listinfo/help-make