From 230d6f3e4c7e7504d06e4df52b3870a76cd526ee Mon Sep 17 00:00:00 2001 From: GRISHNOV Date: Fri, 20 Nov 2020 16:45:09 +0300 Subject: [PATCH] add makefile and directory for project build --- Makefile | 20 ++++++++++++++++++++ build/.gitkeep | 0 2 files changed, 20 insertions(+) create mode 100644 Makefile create mode 100644 build/.gitkeep diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..f197775 --- /dev/null +++ b/Makefile @@ -0,0 +1,20 @@ +.PHONY: all clean + +CC = gcc +CFLAGS = -c -Wall -Wextra -Wpedantic + +all: buildProject + +buildProject: ./build/PKCS7.o ./build/PKCS7_test.out + +./build/PKCS7.o: ./src/PKCS7.c ./include/PKCS7.h + $(CC) $(CFLAGS) ./src/PKCS7.c -o ./build/PKCS7.o + +./build/PKCS7_test.o: ./test/PKCS7_test.c ./test/PKCS7_test.h ./include/PKCS7.h + $(CC) $(CFLAGS) ./test/PKCS7_test.c -o ./build/PKCS7_test.o + +./build/PKCS7_test.out: ./build/PKCS7_test.o ./build/PKCS7.o + $(CC) ./build/PKCS7_test.o ./build/PKCS7.o -o ./build/PKCS7_test.out + +clean: + rm -f ./build/*.o ./build/*.out \ No newline at end of file diff --git a/build/.gitkeep b/build/.gitkeep new file mode 100644 index 0000000..e69de29