On Mon, 2022-12-19 at 10:57 -0500, Jeffrey Walton wrote: > ifeq ($(includedir),) > includedir := $(prefix)/include > PC_INCLUDEDIR = $${prefix}/include > else > PC_INCLUDEDIR = $(includedir) > endif
Maybe I'm misunderstanding some subtlety here but why not just: includedir := $(prefix)/include PC_INCLUDEDIR = $(includedir) ?? An assignment of includedir on the command line will override any setting in the makefile, so no need to use an ifeq etc.