bejhan
asked on
Force gmake to excute under bash instead of sh
How can I force gmake to execute under bash instead of sh?
I have tried entering a bash shell (by typing bash), but gmake still uses sh.
I have tried aliasing sh to bash, same result.
I have tried adding #!/bin/sh to the top of the make file, same result.
I have tried entering a bash shell (by typing bash), but gmake still uses sh.
I have tried aliasing sh to bash, same result.
I have tried adding #!/bin/sh to the top of the make file, same result.
ASKER
Just tries, doesn't seem to work:
jetha@mustang(inhouse)> gmake
/bin/sh: syntax error at line 1: `(' unexpected
gmake: *** [obj/util/arena.o] Error 2
jetha@mustang(inhouse)> export SHELL=/bin/bash
jetha@mustang(inhouse)> echo $SHELL
/bin/bash
jetha@mustang(inhouse)> gmake
/bin/sh: syntax error at line 1: `(' unexpected
gmake: *** [obj/util/arena.o] Error 2
ASKER
After using the truss command to investigate what is going on with gmake, I see that gmake actually executes bin/sh on its own so I do not think there is a way to change the shell used without recompile gmake.
ASKER
I've requested that this question be closed as follows:
Accepted answer: 0 points for bejhan's comment http:/Q_27241012.html#36318519
for the following reason:
Found own solution.
Accepted answer: 0 points for bejhan's comment http:/Q_27241012.html#36318519
for the following reason:
Found own solution.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
You are correct! I was hasty in closing this question.
I see why they call you a genius ;)
I see why they call you a genius ;)
Since there are two "flavors" of variables in the Makefile, you can also try
SHELL := /bin/bash
export SHELL
SHELL := /bin/bash
export SHELL
ASKER
Thank you! I have been trying to get this library to compile for days!
export SHELL=/bin/bash
?