2008-07-02 07:17:14 +00:00
|
|
|
#
|
|
|
|
# Makefile for hexameter
|
|
|
|
# @author Takahide Matsutsuka <markn@markn.org>
|
|
|
|
#
|
2009-12-15 07:13:14 +00:00
|
|
|
# $Id: Makefile,v 1.3 2009/12/15 07:13:14 matsutsuka Exp $
|
2008-07-02 07:17:14 +00:00
|
|
|
#
|
|
|
|
|
2009-12-15 07:13:14 +00:00
|
|
|
#CFLAGS = -std=c99 -g -mno-cygwin -Wall
|
|
|
|
CFLAGS = -g -Wall
|
2008-07-20 07:44:39 +00:00
|
|
|
SOURCEDIR = src
|
|
|
|
SOURCES = hexameter.c ihx2bin.c
|
|
|
|
OBJECTDIR = bin
|
|
|
|
OBJECTS = ${addprefix $(OBJECTDIR)/,$(SOURCES:.c=.o)}
|
2008-07-02 07:17:14 +00:00
|
|
|
|
|
|
|
vpath %.c $(SOURCEDIR)
|
|
|
|
|
2008-07-20 07:44:39 +00:00
|
|
|
ifeq (${wildcard $(OBJECTDIR)},)
|
|
|
|
DUMMY := ${shell mkdir $(OBJECTDIR)}
|
|
|
|
endif
|
|
|
|
|
|
|
|
hexameter: $(OBJECTS)
|
|
|
|
$(CC) $(CFLAGS) -o $@ $(OBJECTS)
|
2008-07-02 07:17:14 +00:00
|
|
|
|
|
|
|
clean:
|
2008-07-20 07:44:39 +00:00
|
|
|
rm -rf bin
|
|
|
|
rm -f *~ *.stackdump
|
2009-12-15 07:13:14 +00:00
|
|
|
rm -f *~ hexameter hexameter.exe
|
2008-07-20 07:44:39 +00:00
|
|
|
|
|
|
|
$(OBJECTDIR)/%.o: %.c
|
|
|
|
$(CC) $(CFLAGS) -c $< -o $@
|
|
|
|
|