purge remaining gpl code from clib, and make clib build again
[tangerine.git] / compiler / clib / stubs / mmakefile.src
bloba8a9a68b702810f6ffde335d7f120b1b584d93a5
1 # $Id$
2 include $(TOP)/config/make.cfg
4 STUBSDIR        := $(GENDIR)/compiler/clib/stubs
5 FILES           := $(shell ($(ECHO) '\#define SYSTEM_CALL(x, y...) x'; $(CAT) $(AROS_INCLUDES)/sys/syscall.def) | $(CPP) -P -)
6 FILES           := $(foreach f,$(FILES), $(STUBSDIR)/$(f))
7 OBJS            := $(foreach f,$(FILES), $(f).o)
8 STUBS           := $(foreach f,$(FILES), $(f).S)
9 GENSTUBS        := genstubs
11 #MM
12 clib-stubs : $(OBJS)
14 #MM
15 clib-stubs-clean : clean
17 #MM
18 clean ::
19         -$(RM) $(STUBSDIR)
21 $(OBJS) $(STUBS) : | $(STUBSDIR)
22 %rule_makedirs dirs=$(STUBSDIR)
24 $(OBJS) : $(STUBSDIR)/%.o : $(STUBSDIR)/%.S
25         %assemble_q
27 $(STUBSDIR)/%.S: $(STUBSDIR)/$(GENSTUBS)
28         @$(ECHO) Generating stub function for \'$$(basename $(notdir $@))\'...
29         @$(STUBSDIR)/$(GENSTUBS) $(basename $(notdir $@)) >$@
31 $(STUBSDIR)/$(GENSTUBS) : $(GENSTUBS).c $(AROS_INCLUDES)/sys/syscall.def $(AROS_INCLUDES)/aros/cpu.h | $(STUBSDIR)
32         @$(HOST_CC) $(HOST_CFLAGS) -I$(GENINCDIR) $< -o $@
34 %common