Просмотр исходного кода

Fix detection of qb_log_thread_priority_set

This fixes detection of libqb function qb_log_thread_priority_set
if it was installed outside of the standard library search
path, in my case /opt.

Signed-off-by: Ruben Kerkhof <ruben@rubenkerkhof.com>
Reviewed-by: Jan Friesse <jfriesse@redhat.com>
Ruben Kerkhof 10 лет назад
Родитель
Сommit
e69f0a4e19
1 измененных файлов с 6 добавлено и 0 удалено
  1. 6 0
      configure.ac

+ 6 - 0
configure.ac

@@ -152,13 +152,19 @@ AC_TYPE_SIGNAL
 
 
 # Checks for libraries.
 # Checks for libraries.
 PKG_CHECK_MODULES([nss],[nss])
 PKG_CHECK_MODULES([nss],[nss])
+SAVE_CPPFLAGS="$CPPFLAGS"
+SAVE_LIBS="$LIBS"
 PKG_CHECK_MODULES([LIBQB], [libqb])
 PKG_CHECK_MODULES([LIBQB], [libqb])
+CPPFLAGS="$CPPFLAGS $LIBQB_CFLAGS"
+LIBS="$LIBS $LIBQB_LIBS"
 AC_CHECK_LIB([qb], [qb_log_thread_priority_set], \
 AC_CHECK_LIB([qb], [qb_log_thread_priority_set], \
 	     have_qb_log_thread_priority_set="yes", \
 	     have_qb_log_thread_priority_set="yes", \
 	     have_qb_log_thread_priority_set="no")
 	     have_qb_log_thread_priority_set="no")
 if test "x${have_qb_log_thread_priority_set}" = xyes; then
 if test "x${have_qb_log_thread_priority_set}" = xyes; then
 	AC_DEFINE_UNQUOTED([HAVE_QB_LOG_THREAD_PRIORITY_SET], 1, [have qb_log_thread_priority_set])
 	AC_DEFINE_UNQUOTED([HAVE_QB_LOG_THREAD_PRIORITY_SET], 1, [have qb_log_thread_priority_set])
 fi
 fi
+CPPFLAGS="$SAVE_CPPFLAGS"
+LIBS="$SAVE_LIBS"
 AC_CHECK_LIB([pthread], [pthread_create])
 AC_CHECK_LIB([pthread], [pthread_create])
 AC_CHECK_LIB([socket], [socket])
 AC_CHECK_LIB([socket], [socket])
 AC_CHECK_LIB([nsl], [t_open])
 AC_CHECK_LIB([nsl], [t_open])