diff --git a/Makefile.include b/Makefile.include index 699ff7931b..50cb94a6cf 100644 --- a/Makefile.include +++ b/Makefile.include @@ -565,15 +565,8 @@ objdump: $(call check_cmd,$(OBJDUMP),Objdump program) $(OBJDUMP) $(OBJDUMPFLAGS) $(ELFFILE) | less -# Generate an XML file containing all macro definitions and include paths for -# use in Eclipse CDT -.PHONY: eclipsesym eclipsesym.xml -eclipsesym: $(CURDIR)/eclipsesym.xml -eclipsesym.xml: $(CURDIR)/eclipsesym.xml - -$(CURDIR)/eclipsesym.xml: FORCE - $(Q)printf "%s\n" $(CC) $(CFLAGS_WITH_MACROS) $(INCLUDES) | \ - $(RIOTTOOLS)/eclipsesym/cmdline2xml.sh > $@ +# Support Eclipse IDE. +include $(RIOTMAKE)/eclipse.inc.mk # Export variables used throughout the whole make system: include $(RIOTMAKE)/vars.inc.mk diff --git a/makefiles/eclipse.inc.mk b/makefiles/eclipse.inc.mk new file mode 100644 index 0000000000..3d54417167 --- /dev/null +++ b/makefiles/eclipse.inc.mk @@ -0,0 +1,9 @@ +# Generate an XML file containing all macro definitions and include paths for +# use in Eclipse CDT +.PHONY: eclipsesym eclipsesym.xml +eclipsesym: $(CURDIR)/eclipsesym.xml +eclipsesym.xml: eclipsesym + +$(CURDIR)/eclipsesym.xml: FORCE + $(Q)printf "%s\n" $(CC) $(CFLAGS_WITH_MACROS) $(INCLUDES) | \ + $(RIOTTOOLS)/eclipsesym/cmdline2xml.sh > $@