From e5454e63a086e549f54c23a686ff300b99a83b58 Mon Sep 17 00:00:00 2001 From: "@syxhe" Date: Fri, 4 Apr 2025 21:04:18 -0500 Subject: Make decryptto function also use named temporary files for writing --- src/Makefile | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) (limited to 'src/Makefile') diff --git a/src/Makefile b/src/Makefile index 4450727..53cd9fd 100644 --- a/src/Makefile +++ b/src/Makefile @@ -9,22 +9,24 @@ CFLAGS = -std=c2x -Wall -Wextra -Wpedantic -pedantic-errors -fanalyzer -Wanalyze LDLIBS += $$(pkg-config --libs-only-l libsodium) LDFLAGS += $$(pkg-config --libs-only-L libsodium) - -BINARIES := main +OBJECTS := $(patsubst %.c,%.o, $(wildcard *.c)) .PHONY: all c clean val +.DELETE_ON_ERROR: all: main +main: main.o encryption.o shared.o ll.o arena.o -main: main.o shared.o ll.o arena.o -ll.o: ll.c ll.h shared.h -main.o: main.c shared.h -arena.o: arena.c arena.h shared.h -shared.o: shared.c shared.h +$(OBJECTS): shared.h +ll.o: ll.c ll.h +main.o: main.c +arena.o: arena.c arena.h +shared.o: shared.c shared.h # Might as well put shared.h in here explicitly +encryption.o: encryption.c encryption.h c clean: - rm -rvf $(BINARIES) $(wildcard *.o) $(wildcard *.test*) $(wildcard *.enc) + -rm -rv main $(OBJECTS) $(wildcard *.test*) $(wildcard *.enc) val: $(MAKE) all -- cgit v1.2.3