From: Anthony Liguori <anthony@codemonkey.ws>
To: qemu-devel@nongnu.org
Subject: [Qemu-devel] [5997] Make sure to link librt if we need to.
Date: Fri, 12 Dec 2008 20:02:52 +0000 [thread overview]
Message-ID: <E1LBEDs-00030a-Rl@cvs.savannah.gnu.org> (raw)
Revision: 5997
http://svn.sv.gnu.org/viewvc/?view=rev&root=qemu&revision=5997
Author: aliguori
Date: 2008-12-12 20:02:52 +0000 (Fri, 12 Dec 2008)
Log Message:
-----------
Make sure to link librt if we need to.
This is really a stop-gap. The recent thread pool changes uncovered a
deeper issue with how we use librt. We really should be probing for
timer_create and then conditionally enabling that code.
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Modified Paths:
--------------
trunk/configure
Modified: trunk/configure
===================================================================
--- trunk/configure 2008-12-12 16:41:40 UTC (rev 5996)
+++ trunk/configure 2008-12-12 20:02:52 UTC (rev 5997)
@@ -972,6 +972,26 @@
build_docs="yes"
fi
+##########################################
+# Do we need librt
+cat > $TMPC <<EOF
+#include <signal.h>
+#include <time.h>
+int main(void) { clockid_t id; return clock_gettime(id, NULL); }
+EOF
+
+rt=no
+if $cc $ARCH_CFLAGS -o $TMPE $TMPC 2> /dev/null ; then
+ :
+elif $cc $ARCH_CFLAGS -o $TMPE $TMPC -lrt 2> /dev/null ; then
+ rt=yes
+fi
+
+if test "$rt" = "yes" ; then
+ # Hack, we should have a general purpose LIBS for this sort of thing
+ AIOLIBS="$AIOLIBS -lrt"
+fi
+
if test "$mingw32" = "yes" ; then
if test -z "$prefix" ; then
prefix="c:\\\\Program Files\\\\Qemu"
reply other threads:[~2008-12-12 20:02 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=E1LBEDs-00030a-Rl@cvs.savannah.gnu.org \
--to=anthony@codemonkey.ws \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.