######################################################################## # # Makefile for tMCimg Monte Carlo modeling program. # ######################################################################## ######################################################################## # Generic compiler options # COPTS = -O2 -g # Link against the sytem math libraries # LIBS = -lm ######################################################################## # GCC specific flags. For other compilers, either change as appropriate # or just leave the fields blank. # Extra compiler warnings for GCC # WARNS = -Wall -pedantic # Extra optimizations for GCC # # Both -funroll-loops and -malign-double noticably speed up the program # OPTS = -funroll-loops -malign-double # Extra debugging flags, # DBUG = -ggdb # Put the flags together # CFLAGS = $(COPTS) $(WARNS) $(OPTS) $(DBUG) ########################################################################### # You shouldn't need to change anything from here on OBJFILE = tMCimg.o ran.o ran2.o ran3.o TARGET = tMCimg all: $(TARGET) $(TARGET): $(OBJFILE) $(CC) $(DBUG) -o $(TARGET) $(OBJFILE) $(LIBS) ran2.o: ran2.c ran3.o: ran3.c ran.o: ran.c tMCimg.o: tMCimg.c .c.o: $(CC) $(CFLAGS) -c $*.c ########################################################################### clean: -/bin/rm core *.o $(TARGET)