# Makefile for CS61c Proj1 # Add additional source files here. Each file should be seperated # by a space. For example: # # SRCFILES := i_memory.c core.c microscheme.c # SRCFILES := i_memory.c core.c microscheme.c # If you used additional C libraries, add them here. Each libary # should be seperated by a space. For example: # # ADDL_LIB := -lm -lcrypt -lzlib # ADDL_LIB := -lm ######################################################################## # You shouldn't need to modify below this line ######################################################################## EXEC := microscheme OBJS := $(SRCFILES:.c=.o) CC := gcc CFLAGS := -g -Wall -std=c99 LDFLAGS := -g -Wall -std=c99 $(ADDL_LIB) ifneq (,$(findstring CYGWIN,$(shell uname))) CFLAGS += -DCYGWIN LDFLAGS += -DCYGWIN EXEC := $(EXEC).exe endif proj1 : $(OBJS) $(CC) -Wall -g $(ADDL_LIB) -o $(EXEC) $(OBJS) clean : \rm -rf *~ *.o $(EXEC)