Skip to content

Instantly share code, notes, and snippets.

@injust90
Created July 5, 2023 21:17
Show Gist options
  • Save injust90/0aa960002a5f372cf31e2b4f9c04b821 to your computer and use it in GitHub Desktop.
Save injust90/0aa960002a5f372cf31e2b4f9c04b821 to your computer and use it in GitHub Desktop.
#OBJS specifies which files to compile as part of the project
OBJS = main.cpp
#CC Specifies which compiler we're using
CC = g++
#COMPILER_FLAGS specifies the additional compilation options we're using
# -w suppressess all warnings
COMPILER_FLAGS = -w
#LINKER_FLAGS specifies the libraries we're linking against
LINKER_FLAGS = -lSDL2 -lGL
#OBJ_NAME specifies the name of our executable
OBJ_NAME = main
#The target that compiles our executable
all : $(OBJS)
$(CC) $(OBJS) $(COMPILER_FLAGS) $(LINKER_FLAGS) -o $(OBJ_NAME)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment