QEMU uses non-conventional makefile filenames. Ease the life of emacs developpers a bit by appending to the auto-mode-alist.
Signed-off-by: Marc-André Lureau <marcandre.lur...@redhat.com> --- .dir-locals.el | 7 ++++++- Makefile.target | 2 -- trace/Makefile.objs | 2 -- 3 files changed, 6 insertions(+), 5 deletions(-) diff --git a/.dir-locals.el b/.dir-locals.el index 3ac0cfc6f0..13ec483765 100644 --- a/.dir-locals.el +++ b/.dir-locals.el @@ -1,2 +1,7 @@ ((c-mode . ((c-file-style . "stroustrup") - (indent-tabs-mode . nil)))) + (indent-tabs-mode . nil))) + (nil . ((eval . (setq auto-mode-alist (append + '(("Makefile.*" . makefile-gmake-mode) + ("\\.mak\\'" . makefile-gmake-mode)) + auto-mode-alist)))) + )) diff --git a/Makefile.target b/Makefile.target index 7f42c45db8..159602c83c 100644 --- a/Makefile.target +++ b/Makefile.target @@ -1,5 +1,3 @@ -# -*- Mode: makefile -*- - BUILD_DIR?=$(CURDIR)/.. include ../config-host.mak diff --git a/trace/Makefile.objs b/trace/Makefile.objs index afd571c3ec..d1f1e646e5 100644 --- a/trace/Makefile.objs +++ b/trace/Makefile.objs @@ -1,5 +1,3 @@ -# -*- mode: makefile -*- - $(BUILD_DIR)/trace-events-all: $(trace-events-files) $(call quiet-command,cat $^ > $@) -- 2.14.1.146.gd35faa819