X-Git-Url: https://git.gag.com/?a=blobdiff_plain;f=Makefile;h=fe11386e14f05206b1899645aa110e5ba2c3d21a;hb=b959c345475d3e78b9ce7e449e3f5aa043788c88;hp=81db02c1f59985c2c495b9afe2fcf1a41e29f493;hpb=1b58a9f40c8a8dd9437a998365111b7a56282d03;p=fw%2Fsdcc diff --git a/Makefile b/Makefile index 81db02c1..fe11386e 100644 --- a/Makefile +++ b/Makefile @@ -2,31 +2,34 @@ # # +CFLAGS+=-g + SHELL = /bin/sh AUTOCONF = autoconf PRJDIR = . +srcdir = . +include $(srcdir)/Makefile.common + SDCC_MISC = debugger/mcs51 sim/ucsim SDCC_LIBS = support/cpp SDCC_ASLINK = as/mcs51 as link +SDCC_PACKIHX = packihx PKGS = $(SDCC_MISC) $(SDCC_LIBS) $(SDCC_ASLINK) \ - src device/include device/lib - -PORTS = mcs51 z80 - -srcdir = . + src device/include device/lib $(SDCC_PACKIHX) +PKGS_TINI = $(SDCC_LIBS) $(SDCC_ASLINK) \ + src device/include $(SDCC_PACKIHX) +PORTS = $(shell cat ports.build) +ALLPORTS = $(shell cat ports.all) # Compiling entire program or any subproject # ------------------------------------------ all: checkconf sdcc +tini: checkconf sdcc-tini + sdcc-libs: -ifeq ($(CROSS_LIBGC),1) - $(MAKE) -C support/gc -f Makefile.cross -else - $(MAKE) -C support/gc -endif for lib in $(SDCC_LIBS); do $(MAKE) -C $$lib; done sdcc-cc: sdcc-libs @@ -38,16 +41,28 @@ sdcc-aslink: sdcc-misc: for misc in $(SDCC_MISC); do $(MAKE) -C $$misc; done +sdcc-packihx: + $(MAKE) -C $(SDCC_PACKIHX) + sdcc-device: $(MAKE) -C device/include $(MAKE) -C device/lib -sdcc: sdcc-cc sdcc-aslink sdcc-misc sdcc-device +sdcc-device-tini: + $(MAKE) -C device/include + $(MAKE) -C device/lib modelDS390 + +sdcc: sdcc-cc sdcc-aslink sdcc-misc sdcc-device sdcc-packihx + $(MAKE) -f main.mk all + +sdcc-tini: sdcc-cc sdcc-aslink sdcc-device-tini sdcc-packihx $(MAKE) -f main.mk all # Some interesting sub rules sdcc-bin: sdcc-cc sdcc-aslink sdcc-misc +sdcc-base: sdcc-cc sdcc-aslink + # Compiling and installing everything and runing test # --------------------------------------------------- install: @@ -56,6 +71,14 @@ install: $(MAKE) -C $$pkg install ;\ done +install-tini: + $(MAKE) -f main.mk install + @for pkg in $(PKGS_TINI); do\ + $(MAKE) -C $$pkg install ;\ + done + $(MAKE) -C device/lib installDS390 + + # Deleting all the installed files # --------------------------------