./configure with CC="ccache gcc" doesn't work

Carl Worth cworth at cworth.org
Wed Jan 26 05:38:29 PST 2011


On Thu, 20 Jan 2011 15:38:39 +0100, Michal Sojka <sojkam1 at fel.cvut.cz> wrote:
> On Thu, 20 Jan 2011, Andy Wingo wrote:
> > Sure.  But the ccache thing is fairly common, AFAIK, and IMO notmuch's
> > configure should either handle spaces in a non-absolute-path $CC or exit
> > with an error in that case.

Hi Andy,

Thanks for pointing out the bug. I didn't notice this because I get
ccache by putting a symlink in ~/bin/cc -> /usr/bin/ccache.

I hadn't expected the IFS change to cause any problem like this, but
there it is.

> I went through configure in notmuch and it seems that there is only one
> place where the value of IFS matters (the call to ldconfig), so we may
> want to apply the patch bellow. On the other hand, a brief look at
> Makefile reveals that there are many things that wont work if there are
> spaces in filanames[1], so I'm not sure whether to care about that
> single case at all.

Thanks for the analysis. I've committed this change now.

> [1]  For example most commands in install targets contain unquoted
>      parameters so if DESTDIR contains a space, it wont work.

I've run through and fixed all of these that I saw. And I did a quick
test with:

	make DESTDIR="/tmp/bar baz" install

and it at least seems to work.

I agree that this kind of thing is probably not likely to happen
often. But since I did decide to invent my own build system, I feel I
have an obligation to make it as "correct" as possible.

-Carl

-- 
carl.d.worth at intel.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: <http://notmuchmail.org/pipermail/notmuch/attachments/20110126/f8600308/attachment.pgp>


More information about the notmuch mailing list