From 85d8338a3ebc01a3ea7600aa602139c4eac3be07 Mon Sep 17 00:00:00 2001
From: Khem Raj <raj.khem@gmail.com>
Date: Thu, 6 Apr 2023 12:13:09 -0700
Subject: [PATCH] configure: Use pkg-config variable to find check include paths

Upstream-Status: Submitted [https://github.com/ofalk/libdnet/pull/85]
Signed-off-by: Khem Raj <raj.khem@gmail.com>
---
 configure.ac | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/configure.ac b/configure.ac
index 3f0c404..553b487 100644
--- a/configure.ac
+++ b/configure.ac
@@ -153,7 +153,7 @@ AC_ARG_WITH(check,
   esac ],
 [ PKG_CHECK_MODULES([CHECK], [check])
   if test -n "${CHECK_LIBS}"; then
-     CHECKINC="-I${prefix}/include"
+     CHECKINC="${CHECK_CFLAGS}"
      CHECKLIB="${CHECK_LIBS}"
      AC_MSG_RESULT(yes)
   else
-- 
2.40.0

