M2_SETI/A4/TP_A4/Modele_exo4/Makefile
2023-02-04 17:21:47 +01:00

29 lines
No EOL
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)