emacs-pretest-bug
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: makefile-mode font-lock bugs and annoyances


From: Miles Bader
Subject: Re: makefile-mode font-lock bugs and annoyances
Date: Thu, 09 Jun 2005 18:32:40 +0900

Daniel Pfeiffer <address@hidden> writes:
>>2. Highlighting of conditional constructs is broken:
>>
>>ifdef FOO
>>   blah
>>else
>>   blah blah
>>endif
...
> This is correct, because ifdef et al. are not keywords for make! The old
> makefile-mode mixed up make, gmake and automake, not allowing you to see
> when you wrote stuff for the wrong make into a makefile. In Emacs' own
> makefiles for example ifdef must *not* get highlighted for this very
> reason.

It's a fact of life that many, many, people use the name "Makefile" for
GNU-make-only makefiles, and if anything this practice has spread
greatly in recent years (I think I've only seen "GNUmakefile" used once
or twice in my entire life!).

Luckily, there's a really easy way to automatically distinguish between
"bad old make" Makefiles and "GNU make" Makefiles:  the presence of GNU
make extensions in the file.  In other words, just highlight them by
default, and let the contents of the file determine what they mean; it's
much more accurate than the filename in this case.

If you want to provide a "old make only mode", that's OK of course, but
it should be off by default.

-Miles
-- 
It wasn't the Exxon Valdez captain's driving that caused the Alaskan oil spill.
It was yours.  [Greenpeace advertisement, New York Times, 25 February 1990]




reply via email to

[Prev in Thread] Current Thread [Next in Thread]