diff options
| -rw-r--r-- | Makefile | 36 | ||||
| -rw-r--r-- | meson.build | 20 | 
2 files changed, 20 insertions, 36 deletions
| diff --git a/Makefile b/Makefile deleted file mode 100644 index 12c2a23..0000000 --- a/Makefile +++ /dev/null @@ -1,36 +0,0 @@ -NAME            = $(notdir $(CURDIR)) -SRC             = $(addprefix src/,main.c init.c move.c flip.c flag.c xSDL.c) - -CPPFLAGS        = -I./include $(shell sdl-config --cflags) -CPPFLAGS	   += -I/usr/include/sdl-digit -LDFLAGS         = $(shell sdl-config --libs) -lsdl-digit -CFLAGS          = -W -Wall -Wextra -std=gnu99 $(shell sdl-config --cflags) - -CC              = gcc - -OBJ             = $(SRC:.c=.o) -DEP             = $(SRC:.c=.d) - -all: $(NAME) - -$(NAME): $(OBJ) -	$(CC) -o "$@" $^ $(LDFLAGS) - --include $(DEP) - -%.d: %.c -	$(CC) -MM $(CPPFLAGS) $(CFLAGS) $< -MF $@ -MT "$*.o $@" - -clean: -	$(RM) $(OBJ) -	$(RM) $(NAME) - -mrproper: clean -	$(RM) $(DEP) - -distclean: mrproper -	$(RM) $(addsuffix ~,$(SRC)) -	$(RM) $(wildcard $(addsuffix .sw*,$(addprefix .,$(SRC)))) - -.PHONY: all clean mrproper distclean - diff --git a/meson.build b/meson.build new file mode 100644 index 0000000..34e85a0 --- /dev/null +++ b/meson.build @@ -0,0 +1,20 @@ +project('camelsweeper', 'c') + +src_camelsweeper = [ +  'src/flag.c', +  'src/flip.c', +  'src/init.c', +  'src/main.c', +  'src/move.c', +  'src/xSDL.c', +] + +deps_camelsweeper = [ +  dependency('libsdl-digit'), +  dependency('sdl'), +] + +executable('camelsweeper', src_camelsweeper, +  include_directories: ['include'], +  dependencies: deps_camelsweeper, +  install: true) | 
