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.
This commit is contained in:
Robert Morrison 2023-12-30 18:15:48 +00:00
parent ba0fbf7a8b
commit 08be352d99
Signed by: robert
GPG Key ID: 73E012EB3F4EC696

View File

@ -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