Last change
on this file since 444 was
444,
checked in by satin@…, 7 years ago
|
add newlib,libalmos-mkh, restructure shared_syscalls.h and mini-libc
|
File size:
1.0 KB
|
Rev | Line | |
---|
[439] | 1 | ############################################################################ |
---|
| 2 | # Makefile for the ALMOS-MKH "mini-pthread" # |
---|
| 3 | ############################################################################ |
---|
| 4 | |
---|
| 5 | -include ../../params-soft.mk |
---|
| 6 | ifeq ($(ARCH_NAME),) |
---|
| 7 | $(error Please define in ARCH_NAME parameter in params-soft.mk!) |
---|
| 8 | endif |
---|
| 9 | |
---|
| 10 | SRCS = pthread.c |
---|
[444] | 11 | OBJS = $(addprefix build/, $(SRCS:.c=.o)) |
---|
| 12 | # $(HAL_ARCH)/build/core/hal_user.o |
---|
[439] | 13 | |
---|
[444] | 14 | INCLUDES = -I. -I$(HAL)/generic -I$(LIBC_INCLUDE) -I$(LIBALMOSMKH_INCLUDE) -I$(SHARED_INCLUDE) |
---|
[439] | 15 | |
---|
[444] | 16 | libs : build/lib/libpthread.a headers |
---|
[439] | 17 | |
---|
| 18 | build : |
---|
| 19 | @mkdir build |
---|
| 20 | @mkdir build/lib |
---|
| 21 | @mkdir build/include |
---|
| 22 | |
---|
| 23 | $(HAL_ARCH)/build/core/hal_user.o : |
---|
| 24 | $(MAKE) -C $(HAL_ARCH) |
---|
| 25 | |
---|
| 26 | ../mini-libc/build/%.o: |
---|
| 27 | $(MAKE) -C ../libc -f Makefile.tsar |
---|
| 28 | |
---|
| 29 | build/%.o : %.c %.h |
---|
| 30 | $(CC) $(INCLUDES) $(CFLAGS) -c -o $@ $< |
---|
| 31 | $(DU) -D $@ > $@.txt |
---|
| 32 | |
---|
[444] | 33 | headers: build |
---|
| 34 | cp $(SRCS:.c=.h) build/include/. |
---|
| 35 | |
---|
| 36 | |
---|
[439] | 37 | build/lib/libpthread.a: build $(OBJS) |
---|
[444] | 38 | $(AR) rc $@ $(OBJS) #$(OBJS_LIBC) |
---|
[440] | 39 | $(RANLIB) $@ |
---|
[439] | 40 | |
---|
[444] | 41 | .PHONY = build clean headers |
---|
[439] | 42 | |
---|
| 43 | |
---|
| 44 | clean: |
---|
[444] | 45 | rm -rf build/ |
---|
Note: See
TracBrowser
for help on using the repository browser.