]> begriffs open source - cmsis-freertos/blob - Demo/Cygnal/Makefile
osEventFlagsWait: Fix flag comparison
[cmsis-freertos] / Demo / Cygnal / Makefile
1 #/*
2 # * FreeRTOS Kernel V10.2.1
3 # * Copyright (C) 2019 Amazon.com, Inc. or its affiliates.  All Rights Reserved.
4 # *
5 # * Permission is hereby granted, free of charge, to any person obtaining a copy of
6 # * this software and associated documentation files (the "Software"), to deal in
7 # * the Software without restriction, including without limitation the rights to
8 # * use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
9 # * the Software, and to permit persons to whom the Software is furnished to do so,
10 # * subject to the following conditions:
11 # *
12 # * The above copyright notice and this permission notice shall be included in all
13 # * copies or substantial portions of the Software.
14 # *
15 # * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16 # * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
17 # * FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
18 # * COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
19 # * IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
20 # * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
21 # *
22 # * http://www.FreeRTOS.org
23 # * http://aws.amazon.com/freertos
24 # *
25 # * 1 tab == 4 spaces!
26 # */
27
28
29 CC=sdcc
30 NO_OPT=--nogcse --noinvariant --noinduction --nojtbound --noloopreverse --nolabelopt --nooverlay --peep-asm
31 DEBUG=--debug
32
33 CFLAGS=--model-large -I. -I../Common/include -I../include -I../../Source/include \
34                 -DSDCC_CYGNAL $(DEBUG) --less-pedantic --xram-size 8448 --stack-auto \
35                 --no-peep --int-long-reent --float-reent
36
37 DEMO_DIR = ../Common
38 SOURCE_DIR = ../../Source
39 PORT_DIR = ../../Source/portable/SDCC/Cygnal
40
41 SRC     = \
42 ParTest/ParTest.c \
43 serial/serial.c \
44 $(DEMO_DIR)/Full/flash.c \
45 $(DEMO_DIR)/Full/print.c \
46 $(DEMO_DIR)/Minimal/integer.c \
47 $(DEMO_DIR)/Minimal/PollQ.c \
48 $(DEMO_DIR)/Minimal/comtest.c \
49 $(DEMO_DIR)/Full/semtest.c \
50 $(SOURCE_DIR)/tasks.c \
51 $(SOURCE_DIR)/queue.c \
52 $(SOURCE_DIR)/list.c \
53 $(SOURCE_DIR)/portable/MemMang/heap_1.c \
54 $(PORT_DIR)/port.c
55
56
57 # Define all object files.
58 OBJ = $(SRC:.c=.rel)
59
60
61
62
63
64 ######################################
65 # THIS VERSION WILL ONLY BUILD FILES THAT HAVE CHANGED, BUT MAY HAVE A DANGEROUS
66 # COMMAND LINE.  IT WORKS FINE UNDER WINDOWS, BUT I HAVE COMMENTED IT OUT IN
67 # CASE IT CAUSES PROBLEMS ON OTHER SYSTEMS.
68
69 #main : main.c Makefile ../../Source/portable/SDCC/Cygnal/portmacro.h $(OBJ)
70 #       $(CC) $(CFLAGS) main.c $(OBJ)
71
72 #%.rel : %.c Makefile ../../Source/portable/SDCC/Cygnal/portmacro.h
73 #       $(CC) -c $(CFLAGS) -o$< $<
74
75
76
77
78
79 ######################################
80 # INSTEAD OF THE FOUR LINES ABOVE, THIS VERSION CAN BE USED BUT WILL CAUSE ALL
81 # FILES TO BUILD EVERY TIME.
82
83 main : main.c Makefile ../../Source/portable/SDCC/Cygnal/portmacro.h $(OBJ)
84         $(CC) $(CFLAGS) main.c $(OBJ)
85
86 %.rel : %.c Makefile ../../Source/portable/SDCC/Cygnal/portmacro.h
87         $(CC) -c $(CFLAGS) $<
88
89
90
91
92
93
94
95
96         
97
98