source: svn/trunk/newcon3bcm2_21bu/dst/build/ucos.mk @ 45

Last change on this file since 45 was 2, checked in by phkim, 11 years ago

1.phkim

  1. revision copy newcon3sk r27
  • Property svn:executable set to *
File size: 880 bytes
RevLine 
[2]1
2ifeq ($(MAKELEVEL),1)
3# Base flags and variables for all modules
4include platform.inc
5endif
6
7ifndef TOPDIR
8LIBDIR := $(shell cd ../lib ; /bin/pwd)
9DTADIR := $(shell cd ../src ; /bin/pwd)
10UCOSDIR := $(shell cd ../src/ucos_ii ; /bin/pwd)
11else
12LIBDIR := $(TOPDIR)/dta/lib
13DTADIR := $(TOPDIR)/dta/src
14UCOSDIR := $(TOPDIR)/dta/src/ucos_ii
15endif
16
17CFLAGS += -I$(UCOSDIR)
18
19ifeq ($(BUILD_UCOS),y)
20
21CFLAGS += -I$(DTADIR)
22
23UCOS_SOURCES = $(UCOSDIR)/ucos_ii.c \
24        $(UCOSDIR)/os_cpu_c.c \
25        $(UCOSDIR)/os_cpu_a.S
26
27UCOS_OBJECTS = $(patsubst %.c,%.o,$(filter %.c,$(UCOS_SOURCES))) $(patsubst %.S,%.o,$(filter %.S,$(UCOS_SOURCES)))
28
29UCOS_DEPENDS = $(UCOS_OBJECTS:.o=.d)
30
31all : $(LIBDIR)/libucos_ii.a
32
33$(LIBDIR)/libucos_ii.a : $(UCOS_OBJECTS)
34        $(AR) $(ARFLAGS) $@ $?
35
36clean : clean_ucos
37
38clean_ucos :
39        $(RM) -f $(LIBDIR)/libucos_ii.a $(UCOS_OBJECTS) $(UCOS_DEPENDS)
40
41-include $(UCOS_DEPENDS)
42endif
Note: See TracBrowser for help on using the repository browser.