wut/crt/Makefile

29 lines
502 B
Makefile
Raw Normal View History

2016-07-06 21:06:57 +01:00
include $(CURDIR)/../rules/ppc.mk
2015-12-26 18:10:38 -08:00
CFILES := $(wildcard *.c)
SFILES := $(wildcard *.S)
OFILES := $(CFILES:.c=.o) $(SFILES:.S=.o)
OUTPUT := libcrt
2015-12-26 18:10:38 -08:00
all: $(OUTPUT).a $(OFILES)
2015-12-26 18:10:38 -08:00
clean:
@echo "[RM] $(notdir $(OUTPUT))"
@rm -f $(OFILES) $(OUTPUT).a
2015-12-26 18:10:38 -08:00
install: all
@mkdir -p $(INSTALLDIR)/lib
@cp -f *.a $(INSTALLDIR)/lib
2015-12-26 18:10:38 -08:00
%.o: %.c
@echo "[CC] $(notdir $<)"
@$(CC) $(CFLAGS) -c $< -o $@
2015-12-26 18:10:38 -08:00
%.o: %.S
@echo "[CC] $(notdir $<)"
@$(CC) $(CFLAGS) -c $< -o $@
$(OUTPUT).a: $(OFILES)
2015-12-26 18:10:38 -08:00
.PHONY: all clean