Results 1 to 3 of 3
Or my login shell or /bin/bash?
Background:
I have a variable in the Makefile:
C_FILES := $(patsubst %.c,%.o,$(shell ls *.c 2> /dev/null))
I want to make sure it's OK to ...
- 11-12-2008 #1Just Joined!
- Join Date
- Nov 2008
- Posts
- 2
Does GNU make $(shell ...) call /bin/sh ...
Or my login shell or /bin/bash?
Background:
I have a variable in the Makefile:
C_FILES := $(patsubst %.c,%.o,$(shell ls *.c 2> /dev/null))
I want to make sure it's OK to use "2>/dev/null" here. My login shell is /bin/bash so it's hard for me to tell if this is OK for all users, even those whose login shell is csh/tcsh, which don't have the "2>" syntax.
- 11-13-2008 #2Linux Engineer
- Join Date
- Apr 2006
- Location
- Saint Paul, MN, USA / CentOS, Debian, Solaris, SuSE
- Posts
- 1,117
Hi.
Welcome to the forum.
Best wishes ... cheers, drlThe program used as the shell is taken from the variable `SHELL'.
By default, the program `/bin/sh' is used.
-- excerpt from info make, GNU Make 3.80, q.v.Welcome - get the most out of the forum by reading forum basics and guidelines: click here.
90% of questions can be answered by using man pages, Quick Search, Advanced Search, Google search, Wikipedia.
We look forward to helping you with the challenge of the other 10%.
( Mn, 2.6.n, AMD-64 3000+, ASUS A8V Deluxe, 1 GB, SATA + IDE, Matrox G400 AGP )
- 11-13-2008 #3Just Joined!
- Join Date
- Nov 2008
- Posts
- 2
Thanks a bunch!


Reply With Quote