Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
T
Tor
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Benjamin J. Thompson
Tor
Commits
79c056cb
Commit
79c056cb
authored
19 years ago
by
Nick Mathewson
Browse files
Options
Downloads
Patches
Plain Diff
Very experimental code to try to make libevent work from bad /usr/local/libs
svn:r4238
parent
c5b986ec
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
configure.in
+82
-1
82 additions, 1 deletion
configure.in
with
82 additions
and
1 deletion
configure.in
+
82
−
1
View file @
79c056cb
...
...
@@ -56,7 +56,88 @@ AC_SEARCH_LIBS(socket, [socket])
AC_SEARCH_LIBS(gethostbyname, [nsl])
AC_SEARCH_LIBS(pthread_create, [pthread])
AC_SEARCH_LIBS(pthread_detach, [pthread])
AC_SEARCH_LIBS(event_loop, [event], , AC_MSG_ERROR(Libevent library not found. Tor requires libevent to build. You can get the latest version of libevent at http://www.monkey.org/~provos/libevent/ ))
dnl ------------------------------------------------------
dnl Where do you live, libevent?
AC_SEARCH_LIBS(event_loop, [event], event_found=yes, event_found=no)
if test "$event_found" = no; then
echo FLOOIE
saved_LIBS="$LIBS"
saved_LDFLAGS="$LDFLAGS"
saved_CPPFLAGS="$CPPFLAGS"
AC_CACHE_CHECK([for libevent in /usr/local/lib], ac_cv_libevent_local, [
LIBS="$LIBS -levent"
LDFLAGS="$LDFLAGS -L/usr/local/lib"
CPPFLAGS="$CPPFLAGS -I/usr/local/include"
AC_TRY_COMPILE([
#include <event.h>
int main(void)
{
event_init();
return 0;
}], [ libevent_is_in_local=yes ], [ libevent_is_in_local=no ])
if test libevent_is_in_local = yes; then
AC_TRY_RUN([
#include <event.h>
int main(void)
{
event_init();
return 0;
}], , [ ac_cv_libevent_local=unlinked ])
else
ac_cv_libevent_local=no
fi
if test "$GCC" = yes -a $ac_vc_libevent_local = unlinked ; then
LDFLAGS="$LDFLAGS -Wl,-R/usr/local/lib"
AC_TRY_RUN([
#include <event.h>
int main(void)
{
event_init();
return 0;
}], [ ac_cv_libevent_local=unlinked_gcc_elf ])
fi
LIBS="$saved_LIBS"
CFLAGS="$saved_CFLAGS"
LDFLAGS="$saved_LDFLAGS" ])
if test $ac_cv_libevent_local != no; then
LIBS="$LIBS -levent"
LDFLAGS="$LDFLAGS -L/usr/local/lib"
CFLAGS="$CFLAGS -I/usr/local/include"
fi
if test $av_cv_libevent_local = unlinked_gcc_elf; then
LDFLAGS="$LDFLAGS -Wl,-R/usr/local/lib"
fi
if test $ac_cv_libevent_local = unlinked; then
echo <<EOF
=====================================================
HEY!!!!
Your libevent library is installed in /usr/local/lib,
but your dynamic linker isn't configured to look for
it there.
EOF
if test -f /etc/ld.so.conf; then
echo <<EOF
Maybe you need to add /usr/local/lib to /etc/ld.so.conf,
and then run ldconfig -v ?
EOF
fi
echo <<EOF
=====================================================
EOF
fi
fi
dnl ------------------------------------------------------
dnl Where do you live, OpenSSL?
saved_LIBS="$LIBS"
saved_LDFLAGS="$LDFLAGS"
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment