Merge remote branch 'origin/master' into dhcp-client
[ZeXOS.git] / libpthread / Makefile
blob1089d639562d4b8d64973b8ff706afb31845015c
1 .SUFFIXES: .asm
3 # defines
4 MAKEFILE=Makefile
5 MAKEDEP=$(MAKEFILE)
6 INCDIR =./include
7 NASM =nasm -f elf -i$(INCDIR)/
8 CC =gcc -m32 -g -Wall -W -O2 -nostdinc -fno-builtin -I$(INCDIR)
10 OBJS =create.o destroy.o
12 ifneq ($(V),1)
13 Q := @
14 endif
16 # targets
17 all: $(OBJS) libpthread.a
19 clean:
20 $(Q)rm -f libpthread.a $(OBJS)
21 @printf " CLEAN\n";
23 # implicit rules
24 .S.o:
25 @printf " ASM $(subst $(shell pwd)/,,$(@))\n";
26 $(Q)$(NASM) -o$@ $<
28 .c.o:
29 @printf " CC $(subst $(shell pwd)/,,$(@))\n";
30 $(Q)$(CC) -c -o$@ $<
32 # explicit rules
33 libpthread.a: $(OBJS) $(MAKEDEP)
34 @printf " AR $(subst $(shell pwd)/,,$(@))\n";
35 $(Q)ar rcs libpthread.a $(OBJS)