From: Bart Van Assche Date: Mon, 6 Jan 2020 18:55:48 +0000 (-0800) Subject: configure: Improve the ibverbs test X-Git-Tag: fio-3.18~18^2~9 X-Git-Url: https://git.kernel.dk/?a=commitdiff_plain;h=40dae137d10e4053993599b4d85f351468b1b5df;hp=97f3eddce4d181f3ca378621642be7455c2f1fa1;p=fio.git configure: Improve the ibverbs test This patch fixes the following configure test build error if configure is invoked with --extra-cflags=-Werror: /tmp/fio-conf-14710-130227-4466.c: In function 'main': /tmp/fio-conf-14710-130227-4466.c:4:18: error: unused variable 'pd' [-Werror=unused-variable] struct ibv_pd *pd = ibv_alloc_pd(NULL); ^~ cc1: all warnings being treated as errors Signed-off-by: Bart Van Assche --- diff --git a/configure b/configure index fa6df532..65ce3662 100755 --- a/configure +++ b/configure @@ -841,7 +841,7 @@ cat > $TMPC << EOF int main(int argc, char **argv) { struct ibv_pd *pd = ibv_alloc_pd(NULL); - return 0; + return pd != NULL; } EOF if test "$disable_rdma" != "yes" && compile_prog "" "-libverbs" "libverbs" ; then