aboutsummaryrefslogtreecommitdiff
path: root/acinclude.m4
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2007-03-10 07:38:42 +0000
committerNick Mathewson <nickm@torproject.org>2007-03-10 07:38:42 +0000
commit97b61b9889b3b201a32345bcf69c31f9ae472b74 (patch)
treed80350f9a5e703da32574d9c830c05005407cb82 /acinclude.m4
parent4ca75ecc496989027006dc981083b94bac0cf4a1 (diff)
downloadtor-97b61b9889b3b201a32345bcf69c31f9ae472b74.tar
tor-97b61b9889b3b201a32345bcf69c31f9ae472b74.tar.gz
r12519@Kushana: nickm | 2007-03-10 00:57:01 -0500
Remove a redundant check for event.h; add some comments, and reformat. svn:r9790
Diffstat (limited to 'acinclude.m4')
-rw-r--r--acinclude.m422
1 files changed, 6 insertions, 16 deletions
diff --git a/acinclude.m4 b/acinclude.m4
index 281af84f9..31814c029 100644
--- a/acinclude.m4
+++ b/acinclude.m4
@@ -4,16 +4,6 @@ dnl Copyright (c) 2001-2004, Roger Dingledine
dnl Copyright (c) 2004-2007, Roger Dingledine, Nick Mathewson
dnl See LICENSE for licensing information
-dnl TODO
-dnl - Stop requiring gethostbyname_r entirely when we're building with
-dnl eventdns?
-dnl - Remove redundant event.h check.
-dnl - Make the "no longe strictly accurate" message accurate.
-dnl - Tell the user what -dev package to install based on OS.
-dnl - Detect correct version of library.
-dnl - After merge:
-dnl Run autoupdate
-
AC_DEFUN([TOR_EXTEND_CODEPATH],
[
if test -d "$1/lib"; then
@@ -30,8 +20,8 @@ AC_DEFUN([TOR_EXTEND_CODEPATH],
dnl Look for a library, and its associated includes, and how to link
dnl against it.
-dnl
-dnl TOR_SEARCH_LIBRARY(1:libname, 2:withlocation, 3:linkargs, 4:headers,
+dnl
+dnl TOR_SEARCH_LIBRARY(1:libname, 2:withlocation, 3:linkargs, 4:headers,
dnl 5:prototype,
dnl 6:code, 7:optionname, 8:searchextra)
@@ -42,7 +32,7 @@ tor_saved_CPPFLAGS="$CPPFLAGS"
AC_CACHE_CHECK([for $1 directory], tor_cv_library_$1_dir, [
tor_$1_dir_found=no
tor_$1_any_linkable=no
-
+
for tor_trydir in "$2" "(system)" "$prefix" /usr/local /usr/pkg $8; do
LDFLAGS="$tor_saved_LDFLAGS"
LIBS="$tor_saved_LIBS $3"
@@ -63,12 +53,14 @@ AC_CACHE_CHECK([for $1 directory], tor_cv_library_$1_dir, [
TOR_EXTEND_CODEPATH($tor_trydir)
fi
- # Can we link against (but not necessarily compile) the binary?
+ # Can we link against (but not necessarily run, or find the headers for)
+ # the binary?
AC_LINK_IFELSE(AC_LANG_PROGRAM([$5], [$6]),
[linkable=yes], [linkable=no])
if test $linkable = yes; then
tor_$1_any_linkable=yes
+ # Okay, we can link against it. Can we find the headers?
AC_COMPILE_IFELSE(AC_LANG_PROGRAM([$4], [$6]),
[buildable=yes], [buildable=no])
if test $buildable = yes; then
@@ -132,5 +124,3 @@ fi # cross-compile
]) dnl end defun
-#XXXX Check for right version
-#XXXX accept list of search paths as options