You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

29 lines
463 B
Makefile

CC=gcc
CCFLAGS=-Wall -std=c99 -fopenmp
LDFLAGS=-lm -fopenmp
SOURCES=$(wildcard *.c)
OBJECTS=$(SOURCES:.c=.o)
TARGET=ShiTomasi
all: debug
debug: CCFLAGS += -DDEBUG -g
debug: $(TARGET)
release: CCFLAGS += -O2
release: $(TARGET)
benchmode: CCFLAGS += -O2 -DBENCHMARKMODE
benchmode: $(TARGET)
$(TARGET): $(OBJECTS) $(CXXOBJECTS)
$(CC) -o $@ $^ $(LDFLAGS)
%.o: %.c %.h
$(CC) $(CCFLAGS) -c $<
%.o: %.c
$(CC) $(CCFLAGS) -c $<
clean:
rm -f *.pgm *.o $(TARGET)