blob: 9960c58d28f4469e0d7617c2bec7aaf8636e43ea (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
|
CC := "gcc -Wall -Wextra -Wpedantic -std=c99"
# https://learnopengl.com/Getting-started/Creating-a-window
# For Linux users compiling with GCC, the following command line options may help you compile the project: -lglfw3 -lGL -lX11 -lpthread -lXrandr -lXi -ldl. Not correctly linking the corresponding libraries will generate many undefined reference errors.
# LIBS := `pkg-config --libs glfw3`
LIBS := `pkg-config --libs-only-l glfw3 gl`
INCLUDE := "include"
build:
@test -d out/ || mkdir -p out/
{{CC}} -o out/main {{LIBS}} -I{{INCLUDE}} src/main.c
run:
nixGL out/main
|