NAME	= simplehist

CFLAGS	= -g -O2 -Wall -Wextra
LDFLAGS	= 

OBJS	= ppm.o simplehist.o
SRCS	= $(OBJS:.o=.c)

.PHONY: all
all: dep $(NAME)

.PHONY: dep
dep:	.depend

.depend:
	$(CC) -MM $(CFLAGS) $(SRCS) 1> .depend

$(NAME): $(OBJS)
	$(CC) $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) $(TARGET_ARCH) -o $(NAME) $(OBJS)

.PHONY: clean
clean:
	$(RM) $(OBJS) $(NAME) .depend

.PHONY: install
install:

ifneq ($(wildcard .depend),)
include .depend
endif
