From 7c9e5602362c8ec576abdd66b414d3824e6cc307 Mon Sep 17 00:00:00 2001 From: Philippe Pepiot Date: Thu, 11 Nov 2010 16:33:24 +0100 Subject: [PATCH] BuildSystem: Improve detection of optionals libs --- BSDmakefile | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/BSDmakefile b/BSDmakefile index ce1328a..6b17ea0 100644 --- a/BSDmakefile +++ b/BSDmakefile @@ -5,8 +5,9 @@ PROG= wmfs MAN1= wmfs.1 .for lib in xrandr xinerama imlib2 -HAVE_${lib:U}!= echo ${LIBS} | grep -q ${lib} && echo -DHAVE_${lib:U} -CFLAGS+= ${HAVE_${lib:U}} +.if !empty(LIBS:M${lib}) +CFLAGS+= -DHAVE_${lib:U} +.endif .endfor CFLAGS_LIB!= pkg-config --cflags-only-I ${LIBS}