2022-12-05 02:37:25 +01:00
|
|
|
NAME := macros
|
|
|
|
|
|
|
|
SRC_DIR := src
|
|
|
|
SRCS := main.c event.c read_events.c read_file.c
|
|
|
|
OBJS := main.o event.o read_events.o read_file.o
|
|
|
|
|
|
|
|
CC := gcc
|
2022-12-12 19:55:22 +01:00
|
|
|
CCXX := g++
|
|
|
|
CFLAGS := -Wall -Wextra -g -I.
|
|
|
|
CXXFLAGS := -fpermissive -DIMGUI_IMPL_OPENGL_LOADER_GLFW -DIMGUI_IMPL_API="" -Wall -Wextra -g -I.
|
|
|
|
#CFLAGS := -ansi -pedantic -Wall -Wextra -g -I.
|
2022-12-05 02:37:25 +01:00
|
|
|
#CFLAGS := -Wall -ansi -g -I.
|
2022-12-12 19:55:22 +01:00
|
|
|
LDLIBS := -lxdo -lX11 -lglfw -lGL -lcimgui
|
2022-12-05 02:37:25 +01:00
|
|
|
|
|
|
|
all: $(NAME)
|
|
|
|
|
|
|
|
$(NAME): $(OBJS)
|
|
|
|
$(CC) $(OBJS) $(LDLIBS) -o $(NAME)
|
|
|
|
|
2022-12-12 19:55:22 +01:00
|
|
|
main.o: $(SRC_DIR)/main.c
|
|
|
|
$(CCXX) -I$(SRC_DIR) $(CXXFLAGS) -c -o $@ $<
|
|
|
|
|
2022-12-05 02:37:25 +01:00
|
|
|
%.o: $(SRC_DIR)/%.c
|
2022-12-12 19:55:22 +01:00
|
|
|
$(CC) -I$(SRC_DIR) $(CFLAGS) -c -o $@ $<
|
2022-12-05 02:37:25 +01:00
|
|
|
|
|
|
|
clean:
|
|
|
|
rm $(OBJS)
|