aboutsummaryrefslogtreecommitdiff
path: root/makefile
diff options
context:
space:
mode:
authorSan Jacobs2022-08-04 12:18:33 +0200
committerSan Jacobs2022-08-04 12:18:33 +0200
commit9a3c815b176598ed463a88f42dc6a5f8c6457d50 (patch)
tree0c8032a6c7b751631739895c68a43a62d42eada9 /makefile
parenta38359917d770156d8a5d5e8123074c54c8a0ab7 (diff)
downloadsatscalc-9a3c815b176598ed463a88f42dc6a5f8c6457d50.tar.gz
satscalc-9a3c815b176598ed463a88f42dc6a5f8c6457d50.tar.bz2
satscalc-9a3c815b176598ed463a88f42dc6a5f8c6457d50.zip
Move to C++17
I don't like this, but I wanted more <algorithm> stuff.
Diffstat (limited to 'makefile')
-rw-r--r--makefile9
1 files changed, 6 insertions, 3 deletions
diff --git a/makefile b/makefile
index e6d7637..a217299 100644
--- a/makefile
+++ b/makefile
@@ -1,7 +1,10 @@
-# INCLUDE is where you find the headerfiles for the libs you're using. They are used during compilation.
+# INCLUDE is where you find the header files for the libs you're using. They are used during compilation.
# Example: -I /usr/include/boost/
INCLUDE=
+# Enabling C++17 mode so I can have more <algorithm> stuff
+CFLAGS=-std=c++17
+
# LIBDIR is where you can find the linkable objects or whatever. They are used for the linking stage.
LIBDIR=-L /usr/lib/x86_64-linux-gnu/
@@ -16,11 +19,11 @@ OBJECTS=$(patsubst src/%.cpp, $(OBJDIR)%.o, $(SOURCES))
# This last line creates an identical list of objects based on the list of .cpp files.
a.out: $(OBJECTS)
- g++ $(LIBDIR) $(LIBS) $(OBJECTS)
+ g++ $(LIBDIR) $(CFLAGS) $(LIBS) $(OBJECTS)
$(OBJECTS): obj/%.o : src/%.cpp
mkdir -p obj
- g++ -g $(INCLUDE) -c $< -o $@
+ g++ -g $(INCLUDE) $(CFLAGS) -c $< -o $@
clean:
rm obj/*.o