jamie_lynn
asked on
Nested If in Makefiles
Hi,
I want to add a nested if in my makefile. How can I do something like this?
This is the pseudo code below.
ifneq '$(MODE)' 'unix'
ifneq '$(MODE)' 'solaris' && ifneq '$(MODE)' 'linux'
Do something there....
endif
endif
What is the best way to do this?
Thanks
Jamie
I want to add a nested if in my makefile. How can I do something like this?
This is the pseudo code below.
ifneq '$(MODE)' 'unix'
ifneq '$(MODE)' 'solaris' && ifneq '$(MODE)' 'linux'
Do something there....
endif
endif
What is the best way to do this?
Thanks
Jamie
Depends on which "make" you're using. All the "ifxxxx" commands are non-standard and they vary in syntax between makes.
ASKER
I am using GNU make
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.