Commit before breaking everything
[matches/honours.git] / research / transmission_spectroscopy / universesim / src / Makefile
diff --git a/research/transmission_spectroscopy/universesim/src/Makefile b/research/transmission_spectroscopy/universesim/src/Makefile
new file mode 100644 (file)
index 0000000..0ee6099
--- /dev/null
@@ -0,0 +1,31 @@
+
+MAKEDEP := $(CC) -M
+
+CPPFLAGS := -I include -I ~/Projects/Libraries
+CFLAGS := $(CPPFLAGS) -Wall -g -O3
+LDFLAGS := -L ~/Projects/Libraries -llargeint
+LDFLAGS += -lSDL -lz
+
+OBJ := main.o update.o visualise.o video.o
+OBJ += vector.o
+
+BIN := ../universe
+
+.PHONY: all clean
+
+all: $(BIN)
+
+clean:
+       $(RM) $(BIN) $(OBJ) $(OBJ:%.o=%.d)
+
+../viewer:  visualise.o video.o viewer.o vector.o
+       $(CC) -o ../viewer visualise.o video.o viewer.o vector.o $(LDFLAGS)
+
+$(BIN):        $(OBJ)
+       $(CC) -o $(BIN) $(OBJ) $(LDFLAGS) -g
+
+%.o: %.c
+       $(CC) -c $< -o $@ $(CFLAGS)
+       @$(MAKEDEP) $(CPPFLAGS) -MT $@ -o $*.d $<
+
+-include $(OBJ:%.o=%.d)

UCC git Repository :: git.ucc.asn.au