[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: flymake support in gnulib
From: |
Ralf Wildenhues |
Subject: |
Re: flymake support in gnulib |
Date: |
Sun, 22 May 2011 15:34:50 +0200 |
Hi Reuben,
* Reuben Thomas wrote on Fri, May 20, 2011 at 11:32:29PM CEST:
> I've just been playing with flymake. To make it work at all I copied
> the following rule into my src/Makefile.am from the flymake manual:
>
> check-syntax:
> gcc -o nul -S ${CHK_SOURCES}
>
> It would be nice to put this in maint.mk, but then it wouldn't be
> picked up by make in src/, only at the top-level, which doesn't work
> with flymake (by default). Suggestions?
>
> The first error I noticed was that config.h was not found. There are
> two obvious ways to fix this. The first is to implement a dumpvars
> target, so that flymake-get-project-include-dirs-tmp works. This
> appears to be undocumented in the flymake manual, but it just tries to
> run:
>
> make DUMPVARS=INCLUDE_DIRS dumpvars
>
> dumpvars:
> echo -e $(foreach var, ${DUMPVARS}, "\n$(var)=$($(var))")
>
> seems to produce the required output, but, because it uses a GNU Make
> feature, isn't accepted by automake,
Why should this rule not be accepted by automake? Just turn off the
warning about non-portable make constructs.
Other than that, -e is not portable for echo, and I'm sure there are
other ways to transport an include directory list into the tool.
http://www.emacswiki.org/emacs/FlyMake has suggestions.
Haven't tried them, however.
> so has to be in cfg.mk/maint.mk,
> and hence isn't available to flymake by default.
Cheers,
Ralf :wq