use compiler's preprocessor rather than cpp explicitly

This commit is contained in:
Antonio SJ Musumeci 2017-04-06 21:08:55 -04:00
parent 3244314310
commit 1539aca3d8

View File

@ -1,7 +1,8 @@
#!/bin/sh
CXX="${CXX:-c++}"
FUSE_CFLAGS="$(pkg-config --cflags fuse) -DFUSE_USE_VERSION=29"
echo "#include <fuse.h>" | cpp ${FUSE_CFLAGS} | grep "${1}" > /dev/null
echo "#include <fuse.h>" | ${CXX} -E ${FUSE_CFLAGS} - | grep "${1}" > /dev/null
[ "$?" != "0" ]; echo $?