use pkg-config for configuring x11

This commit is contained in:
Rachel Lambda Samuelsson 2021-01-27 23:42:59 +01:00
parent 3b20394635
commit 3d5e878ed6

View File

@ -1,9 +1,10 @@
#!/bin/sh #!/bin/sh
if command -V pkg-config >/dev/null 2>&1; then if command -V pkg-config >/dev/null 2>&1; then
printf '%s\n' "CONFIG=$(pkg-config libmpdclient --libs --cflags || exit printf '%s\n' "CONFIG=$(
) $(pkg-config imlib2 --libs --cflags || exit pkg-config libmpdclient --libs --cflags) $(
) -lX11" > config.mk pkg-config imlib2 --libs --cflags) $(
pkg-config x11 --libs --cflags)" > config.mk
else else
printf '%s\n' "CONFIG=-lmpdclient -lImlib2 -lX11" > config.mk printf '%s\n' "CONFIG=-lmpdclient -lImlib2 -lX11" > config.mk
fi fi