Execute pkg-config(1) through shell not make

`VAR != val' in make(1) executes `val' everytime the makefile is parsed,
which a) slows down operations across the whole ports tree and b) may print
warnings from such commands.

`VAR = $$(val)', given VAR ends up in a shell command, will be run during
builds.

Switch to the latter to avoid slowdown/noise for porters, even though this
means that ports like devel/xsd now run the same pkg-config command on
every cc(1) invocation rather than just ones in the makefile.

(Most but not all ports do it this way.)

Pointed out by naddy
OK rsadowski naddy
This commit is contained in:
kn 2022-07-01 11:51:25 +00:00
parent 9df6c1205d
commit 0f7d604198
1 changed files with 2 additions and 2 deletions

View File

@ -45,10 +45,10 @@ MAKE_FLAGS = AS=${AS:Q} \
# show compiler lines
MAKE_FLAGS += verbose=1
XERCES_CFLAGS != pkg-config --cflags xerces-c
XERCES_CFLAGS = `pkg-config --cflags xerces-c`
CXXFLAGS += ${XERCES_CFLAGS}
XERCES_LIBS != pkg-config --libs xerces-c
XERCES_LIBS = `pkg-config --libs xerces-c`
LDFLAGS += ${XERCES_LIBS}
# using PREFIX in FAKE_FLAGS is not enough