From: Lukel495 Date: Wed, 22 Nov 2023 14:30:42 +0000 (+0100) Subject: fixar grejer X-Git-Url: https://gitweb.forssennils.se/?a=commitdiff_plain;h=b5a369da41012071a4346427ffd15366ea62f3ca;p=TDDC76_proj.git fixar grejer --- diff --git a/.DS_Store b/.DS_Store index ad35bcf..6894944 100644 Binary files a/.DS_Store and b/.DS_Store differ diff --git a/.gitignore b/.gitignore index ee1e260..5b75a22 100644 --- a/.gitignore +++ b/.gitignore @@ -5,3 +5,5 @@ build # IDE-files .vscode +Makefile +.gitignore diff --git a/Makefile b/Makefile index bd5e408..6817806 100644 --- a/Makefile +++ b/Makefile @@ -1,6 +1,6 @@ CC := g++ -CCFLAGS := -std=c++17 -Wall -Wextra -pedantic -Weffc++ -Wold-style-cast -I src -LDFLAGS := -L${SFML_ROOT}/lib -I${SFML_ROOT}/include -lsfml-window -lsfml-graphics -lsfml-system +CCFLAGS := -std=c++17 -Wall -Wextra -pedantic -Weffc++ -Wold-style-cast -Wno-narrowing -I src +LDFLAGS := -L /opt/homebrew/Cellar/sfml/2.6.1/lib -I /opt/homebrew/Cellar/sfml/2.6.1/include -lsfml-window -lsfml-graphics -lsfml-system OBJDIR := build EXEDIR := build/exe @@ -9,7 +9,7 @@ TEST := $(EXEDIR)/test.out SRC := $(shell find src -type f -name '[^_]*.cc') SRC_H := $(shell find src -type f -name '[^_]*.h') -OBJECTS := $(addprefix $(OBJDIR)/, $(SRC:src/%.cc=%.o) ) +OBJECTS := $(addprefix $(OBJDIR)/, $(SRC:src/%.cc=%.o) ) vpath %.cc src @@ -34,7 +34,7 @@ test-target: $(OBJDIR)/_test.o $(OBJECTS) $(CC) $(LDFLAGS) $^ -o $(TEST) $(LDFLAGS) $(OBJDIR)/%.o: %.cc $(SRC_H) - $(CC) $(CCFLAGS) -c -o $@ $< + $(CC) $(CCFLAGS) $(LDFLAGS) -c -o $@ $< run: ./$(EXE) @@ -43,4 +43,4 @@ test: ./$(TEST) clean: - rm -rf $(OBJDIR)/* \ No newline at end of file + rm -rf $(OBJDIR)/*