diff --git a/3d-viewer/makefile.gtk b/3d-viewer/makefile.gtk index 50a949e0e4..be576ae53a 100644 --- a/3d-viewer/makefile.gtk +++ b/3d-viewer/makefile.gtk @@ -11,8 +11,11 @@ FINAL = 1 all: $(TARGET).a -include makefile.include +deps: + $(CXX) $(CPPFLAGS) -E -MMD -MG *.cpp >/dev/null +include makefile.include +-include *.d $(TARGET).a: $(OBJECTS3D) makefile.gtk makefile.include rm -f $@ @@ -22,10 +25,7 @@ $(TARGET).a: $(OBJECTS3D) makefile.gtk makefile.include install:$(TARGET).a clean: - rm -f *.o - rm -f *.exe - rm -f *.res - rm -f *.map + rm -f *.o *.exe *.res *.map *.d rm -f $(TARGET).a diff --git a/common/makefile.gtk b/common/makefile.gtk index 9597a08ecd..10c653f47a 100644 --- a/common/makefile.gtk +++ b/common/makefile.gtk @@ -11,7 +11,11 @@ EDACPPFLAGS = $(CPPFLAGS) all: common.a +deps: + $(CXX) $(CPPFLAGS) -E -MMD -MG *.cpp >/dev/null + include makefile.include +-include *.d CPPFLAGS += $(EXTRACPPFLAGS) -fno-strict-aliasing EDACPPFLAGS = $(CPPFLAGS) @@ -25,11 +29,7 @@ common.a: $(OBJECTS) makefile.gtk makefile.include install:common.a clean: - rm -f *.o - rm -f *~ - rm -f core - rm -f *.bak - rm -f *.obj + rm -f *.o *~ core *.bak *.obj *.d rm -f common.a diff --git a/cvpcb/makefile.gtk b/cvpcb/makefile.gtk index 5e27f266a4..d7bf1a882a 100644 --- a/cvpcb/makefile.gtk +++ b/cvpcb/makefile.gtk @@ -14,7 +14,11 @@ TARGET = cvpcb all: $(TARGET) +deps: + $(CXX) $(CPPFLAGS) -E -MMD -MG *.cpp >/dev/null + include makefile.include +-include *.d CPPFLAGS += $(EXTRACPPFLAGS) EDACPPFLAGS = $(CPPFLAGS) @@ -29,6 +33,6 @@ install: $(TARGET) cp -f $(TARGET) $(KICAD_BIN) clean: - rm -f *.o + rm -f *.o *.d rm -f $(TARGET) diff --git a/eeschema/makefile.gtk b/eeschema/makefile.gtk index a1d482fcd5..4864049922 100644 --- a/eeschema/makefile.gtk +++ b/eeschema/makefile.gtk @@ -13,7 +13,11 @@ TARGET = eeschema all: $(TARGET) +deps: + $(CXX) $(CPPFLAGS) -E -MMD -MG *.cpp >/dev/null + include makefile.include +-include *.d CPPFLAGS += $(EXTRACPPFLAGS) EDACPPFLAGS = $(CPPFLAGS) @@ -31,10 +35,7 @@ install: $(TARGET) clean: - rm -f *.o - rm -f *~ - rm -f core - rm -f *.bak + rm -f *.o *.d *~ core *.bak rm -f $(TARGET) diff --git a/eeschema/plugins/makefile.gtk b/eeschema/plugins/makefile.gtk index b8bea52afb..feebba028e 100644 --- a/eeschema/plugins/makefile.gtk +++ b/eeschema/plugins/makefile.gtk @@ -15,6 +15,11 @@ endif all: netlist_form_pads-pcb +deps: + $(CXX) $(CPPFLAGS) -E -MMD -MG *.cpp >/dev/null + +-include *.d + netlist_form_pads-pcb: netlist_form_pads-pcb.cpp makefile.gtk gcc -D__UNIX__ -Wall netlist_form_pads-pcb.cpp -o netlist_form_pads-pcb $(LIBSTDC) @@ -24,9 +29,5 @@ install: netlist_form_pads-pcb clean : rm -f netlist_form_pads-pcb - rm -f *.o - rm -f *.rsc - rm -f *.res - rm -f *.exe - rm -f *.bak + rm -f *.o *.rsc *.res *.exe *.bak *.d diff --git a/gerbview/makefile.gtk b/gerbview/makefile.gtk index 65772f9d59..26e35cd52b 100644 --- a/gerbview/makefile.gtk +++ b/gerbview/makefile.gtk @@ -11,7 +11,11 @@ TARGET = gerbview all: $(TARGET) +deps: + $(CXX) $(CPPFLAGS) -E -MMD -MG *.cpp >/dev/null + include makefile.include +-include *.d CPPFLAGS += $(EXTRACPPFLAGS) EDACPPFLAGS = $(CPPFLAGS) @@ -26,10 +30,6 @@ install: $(TARGET) clean: - rm -f *.o - rm -f *.exe - rm -f *.res - rm -f *.map + rm -f *.o *.exe *.res *.map *.d rm -f $(TARGET) - \ No newline at end of file diff --git a/kicad/makefile.gtk b/kicad/makefile.gtk index 2eac152003..7a265efdd5 100644 --- a/kicad/makefile.gtk +++ b/kicad/makefile.gtk @@ -12,7 +12,11 @@ TARGET = kicad all: $(TARGET) +deps: + $(CXX) $(CPPFLAGS) -E -MMD -MG *.cpp >/dev/null + include makefile.include +-include *.d CPPFLAGS += $(EXTRACPPFLAGS) EDACPPFLAGS = $(CPPFLAGS) @@ -26,15 +30,6 @@ install: $(TARGET) cp -f $(TARGET) $(KICAD_BIN) clean: - rm -f *.o; - rm -f *~; - rm -f core; - rm -f *.bak + rm -f *.o *.d *~ *.bak core rm -f $(TARGET) - - - - - - diff --git a/makefile.gtk b/makefile.gtk index b4ead3822e..cbec5064c7 100644 --- a/makefile.gtk +++ b/makefile.gtk @@ -10,6 +10,11 @@ all: $(MAKEGTK) -C $$dir; \ done +deps: + @for dir in $(KICAD_SUBDIRS); do \ + $(MAKEGTK) -k -C $$dir deps; \ + done + install-bin: @for dir in $(KICAD_SUBDIRS_BIN); do \ $(MAKEGTK) -C $$dir install; \ diff --git a/pcbnew/dialog_edit_module.cpp b/pcbnew/dialog_edit_module.cpp index a56009f32d..1c16a6f0bb 100644 --- a/pcbnew/dialog_edit_module.cpp +++ b/pcbnew/dialog_edit_module.cpp @@ -5,6 +5,7 @@ /************************************************/ #include "dialog_edit_module.h" +#include /**************************************/ /* class WinEDA_ModulePropertiesFrame */ diff --git a/pcbnew/makefile.gtk b/pcbnew/makefile.gtk index ad7ccee12e..bb1eeaf453 100644 --- a/pcbnew/makefile.gtk +++ b/pcbnew/makefile.gtk @@ -11,7 +11,11 @@ TARGET = pcbnew all: $(TARGET) +deps: + $(CXX) $(CPPFLAGS) -E -MMD -MG *.cpp >/dev/null + include makefile.include +-include *.d CPPFLAGS += $(EXTRACPPFLAGS) EDACPPFLAGS = $(CPPFLAGS) @@ -28,8 +32,7 @@ install: $(TARGET) clean: - rm -f *.o - rm -f *.map + rm -f *.o *.map *.d rm -f $(TARGET)