blob: 925630b13d0a25eca9339f924616173a1b9a6ea4 [file] [log] [blame]
# makewce.rules - common build rules for wce
#
# modification history
# --------------------
# 04-25-02,mj created
#
########################################################################
# Set searching directories for target and dependencies
vpath %.obj $(OBJDIR)
# Include RULES file if it exists
#ifeq ($(shell if exist RULES $(ECHO) 1),1)
#include RULES
#endif
# Accumulate source files specified in each directory makefile
COBJECTS = $(CSOURCES:.c=.obj)
AOBJECTS = $(ASOURCES:.s=.obj)
ifeq ($(OBJECTS),)
OBJECTS = $(COBJECTS) $(AOBJECTS)
endif
$(TARGET).lib : $(OBJECTS) $(CSOURCES)
@ $(ECHO) 'Building $@'
$(LD) $(LDFLAGS) -ignore:4001 -out:$(OBJDIR)\$(TARGET).lib $(addprefix $(OBJDIR)\,$(notdir $(OBJECTS)))
$(OBJECTS) : %.obj : %.c
@if not exist $(OBJDIR) mkdir $(OBJDIR)
$(CC) $(CFLAGS) $(EXTRA_DEFINE) $(EXTRA_INCLUDE) $(ADDED_CFLAGS) -c $< -Fo$(OBJDIR)\$(notdir $@)
#deps : $(CSOURCES)
# @$(ECHO) '##' >> RULES
# @$(ECHO) '## This file is generated by \"make\" - DO NOT EDIT !' >> RULES
# @$(ECHO) '## $(shell $(DATE))' >> RULES
# @$(ECHO) '##' >> RULES
# @for %x in ($^) do \
# @$(ECHO) " %x" & \
# $(CC) -M -MG $(CFLAGS) %x >> RULES & \
# $(ECHO) >> RULES
.PHONY: clean
clean:
- ($(CD) $(OBJDIR)) && $(RM) *.obj
- ($(CD) $(OBJDIR)) && $(RM) *.lib
FORCE :
# end of file