Fixed binary search: no more infinite loops when vendor is unknown.
[tangerine.git] / compiler / c_lib / source / include / mmakefile
blob42f40c6285e760b46b99771b809683b0da2a493c
1 # $Id$
2 include $(TOP)/config/make.cfg
4 INCSUBDIRS      := libcore
5 INCLUDES        := $(wildcard $(foreach d,$(INCSUBDIRS),$(d)/*.[ch]))
6 DEST_INCLUDES   := $(foreach f,$(INCLUDES),$(AROS_INCLUDES)/$(f))
7 GEN_INCLUDES    := $(foreach f,$(INCLUDES),$(GENINCDIR)/$(f))
9 #MM includes-copy : setup-includes
10 includes-copy : $(DEST_INCLUDES) $(GEN_INCLUDES)
11         @$(NOP)
13 $(AROS_INCLUDES)/%.h : %.h
14         $(CP) $< $@
16 $(AROS_INCLUDES)/%.c : %.c
17         $(CP) $< $@
19 $(GENINCDIR)/%.h : %.h
20         $(CP) $< $@
22 $(GENINCDIR)/%.c : %.c
23         $(CP) $< $@
25 #MM
26 setup-includes :
27         @$(FOR) dir in $(AROS_INCLUDES)         \
28                 $(foreach f,$(INCSUBDIRS),$(AROS_INCLUDES)/$(f)) \
29                 $(GENINCDIR) \
30                 $(foreach f,$(INCSUBDIRS),$(GENINCDIR)/$(f)) \
31         ; do \
32            $(IF) $(TEST) ! -d "$$dir" ; then $(MKDIR) "$$dir" ; else true ; fi ;\
33         done
35 #MM
36 clean :
37         -$(RM) $(AROS_INCLUDES) $(GENINCDIR)