]> git.xolatile.top Git - public-libhl.git/commitdiff
Restructuring of build system
authorEmil <emilwilliams@tuta.io>
Mon, 21 Aug 2023 13:30:48 +0000 (07:30 -0600)
committerEmil <emilwilliams@tuta.io>
Mon, 21 Aug 2023 13:30:48 +0000 (07:30 -0600)
Makefile
chad.mk [new file with mode: 0644]
tests/chad.mk [deleted file]

index 7098c86c84204027bb3738240db063e537672b09..7d81f1a9ebe330de44ec1bfce9a2e03e1aaa4e82 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -1,8 +1,8 @@
 include config.mk
-include tests/chad.mk
+include chad.mk
 
 SRC.dir:=source
-OBJ.dir:=obj
+OBJ.dir:=object
 
 SRC:=$(shell find ${SRC.dir} -iname '*.c')
 HDR:=$(shell find ${SRC.dir} -iname '*.h')
diff --git a/chad.mk b/chad.mk
new file mode 100644 (file)
index 0000000..fe9fa97
--- /dev/null
+++ b/chad.mk
@@ -0,0 +1,18 @@
+# Programs to check warnings for as defined by the chad standard
+
+GCC:=gcc
+GCC.warnings:=-Wall -Wextra -Wpedantic -Wvla -Wshadow -Wundef
+
+CLANG:=clang
+CLANG.warnings:=-Weverything
+
+VALGRIND:=valgrind
+VALGRIND.flags:=--track-origins=yes --leak-check=full --show-leak-kinds=all
+
+TARGET:=hl
+ARGS:=${TARGET} < source/main.c
+
+chad_test:
+       ${GCC} ${GCC.warnings} ${SRC} -o ${TARGET}
+       ${CLANG} ${GCC.warnings} ${SRC} -o ${TARGET}
+       ${VALGRIND} ${VALGRIND.flags} $(shell pwd)/${TARGET} ${ARGS}
diff --git a/tests/chad.mk b/tests/chad.mk
deleted file mode 100644 (file)
index fe9fa97..0000000
+++ /dev/null
@@ -1,18 +0,0 @@
-# Programs to check warnings for as defined by the chad standard
-
-GCC:=gcc
-GCC.warnings:=-Wall -Wextra -Wpedantic -Wvla -Wshadow -Wundef
-
-CLANG:=clang
-CLANG.warnings:=-Weverything
-
-VALGRIND:=valgrind
-VALGRIND.flags:=--track-origins=yes --leak-check=full --show-leak-kinds=all
-
-TARGET:=hl
-ARGS:=${TARGET} < source/main.c
-
-chad_test:
-       ${GCC} ${GCC.warnings} ${SRC} -o ${TARGET}
-       ${CLANG} ${GCC.warnings} ${SRC} -o ${TARGET}
-       ${VALGRIND} ${VALGRIND.flags} $(shell pwd)/${TARGET} ${ARGS}