From: Uwe Hermann Date: Fri, 10 May 2013 18:59:42 +0000 (+0200) Subject: Always link against the math library. X-Git-Tag: libsigrok-0.2.1~89 X-Git-Url: https://sigrok.org/gitaction?a=commitdiff_plain;h=ee8ddd8f5aadee71749882ba897c29e3c12fe1ed;p=libsigrok.git Always link against the math library. This fixes bug #115. --- diff --git a/configure.ac b/configure.ac index b5610187..7c88dc71 100644 --- a/configure.ac +++ b/configure.ac @@ -197,6 +197,9 @@ AC_ARG_ENABLE(zeroplus-logic-cube, # libsigrok.pc file. SR_PKGLIBS="" +# libm (the standard math library) is always needed. +AC_SEARCH_LIBS([pow], [m]) + # libglib-2.0 is always needed. Abort if it's not found. # Note: glib-2.0 is part of the libsigrok API (hard pkg-config requirement). # We require at least 2.32.0 due to e.g. g_variant_new_fixed_array(). diff --git a/libsigrok.pc.in b/libsigrok.pc.in index 251411cd..219f7c3b 100644 --- a/libsigrok.pc.in +++ b/libsigrok.pc.in @@ -10,6 +10,6 @@ Requires: glib-2.0 Requires.private: @SR_PKGLIBS@ Version: @VERSION@ Libs: -L${libdir} -lsigrok -Libs.private: +Libs.private: -lm Cflags: -I${includedir}