[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: make and ~ expansion
From: |
Eli Zaretskii |
Subject: |
Re: make and ~ expansion |
Date: |
Sat, 20 Oct 2001 08:49:10 +0200 |
> From: Dan Jacobson <address@hidden>
> Newsgroups: gnu.utils.bug
> Date: 20 Oct 2001 07:21:44 +0800
>
> Paul> static char sh_chars[] = "#;\"*?[]&|<>(){}$`^~";
> Paul> ^
> Paul> |
> Paul> This will ensure that when you invoke a command with a ~ in it, make
> Paul> will start a shell to handle it rather than try to fork/exec the command
> Paul> directly.
>
> You know, this all seems like a hack to speed things up... wouldn't it
> be more elegant to just pass each line to the shell no matter what.
GNU Make intentionally avoids shell invocation when that's possible,
because direct invocation of subprograms is much faster. In a typical
Makefile, most commands don't need the shell at all.