Don't override MacPorts environment variables. Remove optimization flag so that the one from MacPorts is used. --- config.mk.orig 2019-02-02 06:55:02.000000000 -0600 +++ config.mk 2020-06-15 19:12:12.000000000 -0500 @@ -23,9 +23,9 @@ LIBS = -L$(X11LIB) -lX11 $(XINERAMALIBS) $(FREETYPELIBS) # flags -CPPFLAGS = -D_DEFAULT_SOURCE -D_BSD_SOURCE -D_XOPEN_SOURCE=700 -D_POSIX_C_SOURCE=200809L -DVERSION=\"$(VERSION)\" $(XINERAMAFLAGS) -CFLAGS = -std=c99 -pedantic -Wall -Os $(INCS) $(CPPFLAGS) -LDFLAGS = $(LIBS) +CPPFLAGS += -D_DEFAULT_SOURCE -D_BSD_SOURCE -D_XOPEN_SOURCE=700 -D_POSIX_C_SOURCE=200809L -DVERSION=\"$(VERSION)\" $(XINERAMAFLAGS) +CFLAGS += -std=c99 -pedantic -Wall $(INCS) $(CPPFLAGS) +LDFLAGS += $(LIBS) # compiler and linker CC = cc