Skip to content
Snippets Groups Projects
Commit 5d9d8951 authored by Elias Pipping's avatar Elias Pipping Committed by Elias Pipping
Browse files

Use flymake

parent f3001679
No related branches found
No related tags found
No related merge requests found
# Taken from http://www.emacswiki.org/emacs/FlyMake#toc4
get_cs_flags = $(foreach target,$(subst .,_,$(subst -,_,$($(2)))),$($(target)_$(1)FLAGS))
get_cs_all_flags = $(foreach type,$(2),$(call get_cs_flags,$(1),$(type)))
get_cs_compile = $(if $(subst C,,$(1)),$($(1)COMPILE),$(COMPILE))
get_cs_cmdline = $(call get_cs_compile,$(1)) $(call get_cs_all_flags,$(1),check_PROGRAMS bin_PROGRAMS lib_LTLIBRARIES) -fsyntax-only
.PHONY: check-syntax
check-syntax:
s=$(suffix $(CHK_SOURCES));\
if [ "$$s" = ".c" ]; then LANG=C $(call get_cs_cmdline,C) $(CHK_SOURCES);\
elif [ "$$s" = ".cc" ]; then LANG=C $(call get_cs_cmdline,CXX) $(call get_cs_cmdline,CPP) $(CHK_SOURCES);\
else exit 1; fi
...@@ -39,3 +39,4 @@ DISTCHECK_CONFIGURE_FLAGS = --with-dune-common=$(DUNE_COMMON_ROOT) --with-dune-f ...@@ -39,3 +39,4 @@ DISTCHECK_CONFIGURE_FLAGS = --with-dune-common=$(DUNE_COMMON_ROOT) --with-dune-f
include $(top_srcdir)/am/global-rules include $(top_srcdir)/am/global-rules
include $(top_srcdir)/flymake.mk
/* -*- mode:c++; mode: flymake -*- */
#include <dune/fufem/interval.hh> #include <dune/fufem/interval.hh>
#include <dune/tnnmg/nonlinearities/smallfunctional.hh> #include <dune/tnnmg/nonlinearities/smallfunctional.hh>
......
/* -*- mode:c++; mode: flymake -*- */
// FIXME: is there a bette way to do this? // FIXME: is there a bette way to do this?
//#define DUNE_MINIMAL_DEBUG_LEVEL 2 //#define DUNE_MINIMAL_DEBUG_LEVEL 2
#include <dune/common/stdstreams.hh> #include <dune/common/stdstreams.hh>
......
/* -*- mode:c++; mode: flymake -*- */
#include <dune/fufem/interval.hh> #include <dune/fufem/interval.hh>
#include <dune/tnnmg/nonlinearities/smallfunctional.hh> #include <dune/tnnmg/nonlinearities/smallfunctional.hh>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment