From 08be352d99c697f4465d47d60fa78c37a1443a65 Mon Sep 17 00:00:00 2001 From: Robert Morrison Date: Sat, 30 Dec 2023 18:15:48 +0000 Subject: [PATCH] fix(Makefile): Ensure no clobber to environment To ensure my makefile doesn't clobber already set variables I ensure only to set them when needed. or otherwise append to what is there. --- Makefile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Makefile b/Makefile index adf787a..e58d148 100644 --- a/Makefile +++ b/Makefile @@ -1,11 +1,11 @@ # Define the variables for the compiler and the flags -CC = gcc -CFLAGS = -Wall -g -std=c99 -pedantic +CC ?= gcc +CFLAGS += -Wall -g -std=c99 -pedantic # Define the libraries to link LIBS = -lsystemd -lbsd -prefix = /usr/local +prefix ?= /usr/local exec_prefix = $(prefix) bindir = $(exec_prefix)/bin dexpath = $(bindir)/dexedrine