Skip to content
Snippets Groups Projects
Commit b3abf153 authored by Nick Mathewson's avatar Nick Mathewson :game_die:
Browse files

Fix --enable-static-tor on OpenBSD

Previously we'd been using "we have clock_gettime()" as a proxy for
"we need -lrt to link a static libevent".  But that's not really
accurate: we should only add -lrt if searching for clock_gettime
function adds -lrt to our libraries.
parent 61452299
No related branches found
No related tags found
No related merge requests found
o Minor bugfixes (build):
- When building with --enable-static-tor on OpenBSD, do not
erroneously attempt to link -lrt.
......@@ -280,7 +280,12 @@ AC_SEARCH_LIBS(socket, [socket network])
AC_SEARCH_LIBS(gethostbyname, [nsl])
AC_SEARCH_LIBS(dlopen, [dl])
AC_SEARCH_LIBS(inet_aton, [resolv])
AC_SEARCH_LIBS([clock_gettime], [rt], [have_rt=yes])
saved_LIBS="$LIBS"
AC_SEARCH_LIBS([clock_gettime], [rt])
if test "$LIBS" != "$saved_LIBS"; then
# Looks like we need -lrt for clock_gettime().
have_rt=yes
fi
if test "$enable_threads" = "yes"; then
AC_SEARCH_LIBS(pthread_create, [pthread])
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment