From 90101b871648df439a1a52efb57f9c74529ba69f Mon Sep 17 00:00:00 2001 From: mschmitt Date: Tue, 28 Mar 2000 20:25:20 +0000 Subject: [PATCH] fix for makefile git-svn-id: https://sdcc.svn.sourceforge.net/svnroot/sdcc/trunk/sdcc@213 4a8a32a2-be11-0410-ad9d-d568d2c75423 --- ...e_describtion.h => hardware_description.h} | 4 ++ .../examples/startupcode/inc/startup_code.h | 2 +- device/examples/startupcode/src/cpu_c515a.c | 4 +- device/examples/startupcode/src/makefile | 42 +++++++++---------- device/examples/startupcode/src/makefile.dep | 5 +++ 5 files changed, 33 insertions(+), 24 deletions(-) rename device/examples/startupcode/inc/{hardware_describtion.h => hardware_description.h} (91%) create mode 100644 device/examples/startupcode/src/makefile.dep diff --git a/device/examples/startupcode/inc/hardware_describtion.h b/device/examples/startupcode/inc/hardware_description.h similarity index 91% rename from device/examples/startupcode/inc/hardware_describtion.h rename to device/examples/startupcode/inc/hardware_description.h index d60e0979..af89fb8c 100644 --- a/device/examples/startupcode/inc/hardware_describtion.h +++ b/device/examples/startupcode/inc/hardware_description.h @@ -48,6 +48,10 @@ // disable the above three lines and enable the next one if polling method is used //#define SERIAL_VIA_POLLING +// The Siemens CPU C515A has a build in Baudrategenerator, therefore we use it instead +// of timer 1 this gives a better resolution +#define BAUDRATEGENENATOR_USED + // to measure time and delays we include a 1msec timer #define USE_SYSTEM_TIMER diff --git a/device/examples/startupcode/inc/startup_code.h b/device/examples/startupcode/inc/startup_code.h index 95ab0391..a1955a02 100644 --- a/device/examples/startupcode/inc/startup_code.h +++ b/device/examples/startupcode/inc/startup_code.h @@ -4,7 +4,7 @@ #ifndef __FILE_WSI_128KFLASH_H #define __FILE_WSI_128KFLASH_H -#include "..\inc\hardware_describtion.h" +#include "..\inc\hardware_description.h" // place all 8051-CPU depending tools ISR and functions here diff --git a/device/examples/startupcode/src/cpu_c515a.c b/device/examples/startupcode/src/cpu_c515a.c index 6333a4f3..098f6f4b 100644 --- a/device/examples/startupcode/src/cpu_c515a.c +++ b/device/examples/startupcode/src/cpu_c515a.c @@ -18,7 +18,7 @@ // All that has to be included and / or defined is done here -#include "../inc/hardware_describtion.h" +#include "../inc/hardware_description.h" // END INCLUDES & DEFINES =========================================== @@ -129,7 +129,7 @@ volatile xdata static unsigned char SERIAL_VIA_INTERRUPT_BUSY; #endif // The Siemens CPU C515A has a build in Baudrategenerator, therefore we use it instead // of timer 1 this gives a better resolution -#define BAUDRATEGENENATOR_USED + #define BAUDRATEGENRELOADVALUE (1024-(2*CPUCLKHZ/64/BAUDRATE)) #define TIMER1MODE2RELOADVALUE (256-(2*CPUCLKHZ/32/12/BAUDRATE)) diff --git a/device/examples/startupcode/src/makefile b/device/examples/startupcode/src/makefile index c806bb86..ce26a37a 100644 --- a/device/examples/startupcode/src/makefile +++ b/device/examples/startupcode/src/makefile @@ -8,38 +8,38 @@ RM = rm -f CFLAGS = --debug --stack-after-data --model-large LDFLAGS = --debug --stack-after-data -COBJECTS = startup_code.rel \ - cpu_c515a.rel +COBJECTS = startup_code.rel \ + cpu_c515a.rel CSOURCES = $(patsubst %.rel,%.c,$(COBJECTS)) .SUFFIXES: .rel .c.rel: - $(SDCC) $(CFLAGS) -c $< + $(SDCC) $(CFLAGS) -c $< all: startup - $(SDCC) $(LDFLAGS) $(COBJECTS) + $(SDCC) $(LDFLAGS) $(COBJECTS) c: $(COBJECTS) startup: $(COBJECTS) clean: - $(RM) *.lst - $(RM) *.asm - $(RM) *.bak - $(RM) *.rst - $(RM) *.sym - $(RM) *.hex - $(RM) *.map - -include Makefile.dep - -dep: Makefile.dep - -Makefile.dep: $(CSOURCES) - rm -f Makefile.dep - for csrc in $(CSOURCES) ;do\ - $(SDCC) -MM $$csrc >>Makefile.dep ;\ - done + $(RM) *.lst + $(RM) *.asm + $(RM) *.bak + $(RM) *.rst + $(RM) *.sym + $(RM) *.hex + $(RM) *.map + +include makefile.dep + +dep: makefile.dep + +makefile.dep: $(CSOURCES) + rm -f makefile.dep + for csrc in $(CSOURCES) ;do\ + $(SDCC) -MM $$csrc >>makefile.dep ;\ + done diff --git a/device/examples/startupcode/src/makefile.dep b/device/examples/startupcode/src/makefile.dep new file mode 100644 index 00000000..37237eb3 --- /dev/null +++ b/device/examples/startupcode/src/makefile.dep @@ -0,0 +1,5 @@ +startup_code.rel: startup_code.c ../inc/startup_code.h \ + ../inc/..\inc\hardware_description.h ../inc/..\inc\c515a.h \ + ../inc/..\inc\cpu_c515a.h +cpu_c515a.rel: cpu_c515a.c ../inc/hardware_description.h \ + ../inc/..\inc\c515a.h ../inc/..\inc\cpu_c515a.h -- 2.47.2