File conky-1.9.0-libiw_with_libm.patch of Package conky

--- configure.orig
+++ configure
@@ -14867,7 +14867,7 @@ if ${ac_cv_lib_iw_iw_sockets_open+:} fal
   $as_echo_n "(cached) " >&6
 else
   ac_check_lib_save_LIBS=$LIBS
-LIBS="-liw $conky_LIBS $LIBS"
+LIBS="-liw -lm $conky_LIBS $LIBS"
 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 /* end confdefs.h.  */
 
@@ -14898,7 +14898,7 @@ fi
 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_iw_iw_sockets_open" >&5
 $as_echo "$ac_cv_lib_iw_iw_sockets_open" >&6; }
 if test "x$ac_cv_lib_iw_iw_sockets_open" = xyes; then :
-  conky_LIBS="-liw $conky_LIBS"
+  conky_LIBS="-liw -lm $conky_LIBS"
 else
   as_fn_error $? "iw_sockets_open not found" "$LINENO" 5
 fi
--- configure.ac.orig
+++ configure.ac
@@ -546,8 +546,8 @@ AC_ARG_ENABLE([wlan],
 AM_CONDITIONAL(BUILD_WLAN, test x$want_wlan = xyes)
 if test x$want_wlan = xyes; then
   AC_CHECK_HEADERS([iwlib.h], [], AC_MSG_ERROR([iwlib.h header not found]))
-  AC_CHECK_LIB([iw], [iw_sockets_open], [conky_LIBS="-liw $conky_LIBS"],
-               AC_MSG_ERROR([iw_sockets_open not found]), [$conky_LIBS])
+  AC_CHECK_LIB([iw], [iw_sockets_open], [conky_LIBS="-liw -lm $conky_LIBS"],
+               AC_MSG_ERROR([iw_sockets_open not found]), [-lm $conky_LIBS])
   AC_DEFINE(HAVE_IWLIB, 1, [Define if you want wireless support])
 fi
 
--- configure.ac.in.orig
+++ configure.ac.in
@@ -546,8 +546,8 @@ AC_ARG_ENABLE([wlan],
 AM_CONDITIONAL(BUILD_WLAN, test x$want_wlan = xyes)
 if test x$want_wlan = xyes; then
   AC_CHECK_HEADERS([iwlib.h], [], AC_MSG_ERROR([iwlib.h header not found]))
-  AC_CHECK_LIB([iw], [iw_sockets_open], [conky_LIBS="-liw $conky_LIBS"],
-               AC_MSG_ERROR([iw_sockets_open not found]), [$conky_LIBS])
+  AC_CHECK_LIB([iw], [iw_sockets_open], [conky_LIBS="-liw -lm $conky_LIBS"],
+               AC_MSG_ERROR([iw_sockets_open not found]), [-lm $conky_LIBS])
   AC_DEFINE(HAVE_IWLIB, 1, [Define if you want wireless support])
 fi
 
openSUSE Build Service is sponsored by