Geoffrey Frogeye
2af24e2cc8
* Ajout de la fonction pivoter() * Ajout de Image::g_dupplicata() * Corrections diverses, au Makefile notamment
37 lines
984 B
Makefile
37 lines
984 B
Makefile
# Variables
|
|
## Pour make
|
|
.PHONY: clean, mrproper
|
|
## Compilation
|
|
CXX = g++
|
|
CXXFLAGS = -lSDL -lSDLmain
|
|
CXXFLAGSDEBUG = -lSDL -lSDLmain -DDEBUG
|
|
## Chemins
|
|
EXEPATH = bin/
|
|
OBJPATH = obj/
|
|
SRCPATH = src/
|
|
|
|
# Programmes possibles
|
|
main: $(EXEPATH)main
|
|
testing: $(EXEPATH)testing
|
|
|
|
# Éxecutables
|
|
$(EXEPATH)main: $(OBJPATH)main.o $(OBJPATH)image.o
|
|
$(CXX) $^ -o $@ $(CXXFLAGS)
|
|
|
|
$(EXEPATH)testing: $(OBJPATH)testing.o $(OBJPATH)image.o
|
|
$(CXX) $^ -o $@ $(CXXFLAGSDEBUG)
|
|
|
|
# Dépendances
|
|
## Fichiers executables
|
|
$(OBJPATH)main.o: $(SRCPATH)main.cpp $(SRCPATH)affichageFenetre.cpp $(SRCPATH)image.cpp $(SRCPATH)traitementImage.cpp $(SRCPATH)analyserCommande.cpp
|
|
$(CXX) -c $< -o $@ $(CXXFLAGS)
|
|
|
|
$(OBJPATH)testing.o: $(SRCPATH)testing.cpp $(SRCPATH)affichageFenetre.cpp $(SRCPATH)image.cpp $(SRCPATH)traitementImage.cpp $(SRCPATH)analyserCommande.cpp
|
|
$(CXX) -c $< -o $@ $(CXXFLAGSDEBUG)
|
|
## Bibliothèques
|
|
$(OBJPATH)image.o: $(SRCPATH)image.cpp
|
|
$(CXX) -c $< -o $@
|
|
|
|
# Meta
|
|
clean:
|
|
rm -rf $(OBJPATH)*.o
|