source: trunk/libs/libalmosmkh/Makefile @ 665

Last change on this file since 665 was 445, checked in by alain, 6 years ago

Restructure the mini_libc.

File size: 1.1 KB
Line 
1############################################################################
2#                  Makefile for the ALMOS-MKH specific library             #
3############################################################################
4
5-include ../../params-soft.mk
6
7ifeq ($(ARCH_NAME),)
8$(error Please define in ARCH_NAME parameter in params-soft.mk!)
9endif
10
11SRCS = almosmkh.c
12
13OBJS = $(addprefix build/, $(SRCS:.c=.o)) \
14       $(HAL_ARCH)/build/core/hal_user.o
15
16INCLUDES = -I.                     \
17           -I$(LIBC_PATH)          \
18           -I$(LIBPTHREAD_PATH)    \
19           -I$(SHARED_INCLUDE)     \
20           -I$(HAL)/generic        \
21           -I$(HAL_ARCH)/core      \
22           -I$(KERNEL) 
23
24libs : build/lib/libalmosmkh.a  headers
25
26build :
27        @mkdir build
28        @mkdir build/lib
29        @mkdir build/include
30
31$(HAL_ARCH)/build/core/hal_user.o :
32        $(MAKE) -C $(HAL_ARCH)
33
34build/%.o : %.c %.h
35        $(CC) $(INCLUDES) $(CFLAGS) -c -o  $@ $<
36        $(DU) -D $@ > $@.txt
37
38headers: build
39        cp $(SRCS:.c=.h)  build/include/.
40
41build/lib/libalmosmkh.a: build  $(OBJS)
42        $(AR) rc $@ $(OBJS)
43        $(RANLIB) $@
44
45.PHONY = build clean headers
46
47clean:
48        rm -rf build/
Note: See TracBrowser for help on using the repository browser.