]> Dogcows Code - chaz/rasterize/blobdiff - Makefile
fixes for compiling with mingw32
[chaz/rasterize] / Makefile
index d361c49d719b3d7cfe5a69a3f468c67c729d14b4..1dee42f0110eb896d8a4ce9ca83d0d0d5b159b00 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -6,6 +6,7 @@ IUSE    = BACKFACE_CULLING BLENDING DEPTH_TEST EXTRA_INLINE NDEBUG \
 VIEWER  = feh
 
 CC      = gcc
+EXEEXT  =
 CFLAGS  = -std=c99 -O2 -g -pg
 CPPFLAGS= -MMD $(IUSE:%=-D%)
 LDLIBS  = -lm
@@ -13,14 +14,15 @@ LDLIBS  = -lm
 SRCS    = main.c array.c common.c list.c model.c raster.c rbtree.c scene.c
 OBJS    = $(SRCS:%.c=%.o)
 DEPS    = $(OBJS:%.o=%.d)
+PROG    = $(PROJECT)$(EXEEXT)
 
-all: $(PROJECT)
+all: $(PROG)
 
-$(PROJECT): $(OBJS)
+$(PROG): $(OBJS)
        $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $^ $(LDLIBS)
 
 clean:
-       rm -f $(PROJECT) $(OBJS) $(DEPS)
+       rm -f $(PROG) $(OBJS) $(DEPS)
 
 distclean: clean
        rm -f tags gmon.out
@@ -31,10 +33,10 @@ realclean: distclean
 dist:
        git archive HEAD --prefix=$(PROJECT)/ --output=$(PROJECT).zip
 
-run: $(PROJECT)
+run: $(PROG)
        ./$< && $(VIEWER) scene.ppm
 
-debug: $(PROJECT)
+debug: $(PROG)
        gdb ./$<
 
 -include $(DEPS)
This page took 0.017393 seconds and 4 git commands to generate.