On Mon, 23 Nov 2015 09:42:10 +0100, Daniel Jakots wrote:
> Hi,
> 
> Tor 0.2.7.5 is now released. You can see the changelog in the announce
> [1].
> 
> In "new system requirements":
>     - Tor no longer includes workarounds to support Libevent versions
>       before 1.3e. Libevent 2.0 or later is recommended. Closes
>       ticket 15248.
> 
> I didn't change anything with that, I let Pascal choose.
> 
> [1]: 
> https://lists.torproject.org/pipermail/tor-announce/2015-November/000103.html
> 
> Cheers,
> Daniel
> 

Yes, I think the port should switch to libevent2 per default.  It still
works with 1.4, but "2.0 is recommended" is pretty clear.


Index: Makefile
===================================================================
RCS file: /cvs/ports/net/tor/Makefile,v
retrieving revision 1.86
diff -u -p -r1.86 Makefile
--- Makefile    20 Jul 2015 19:55:58 -0000      1.86
+++ Makefile    23 Nov 2015 17:44:57 -0000
@@ -2,27 +2,29 @@
 
 COMMENT=       anonymity service using onion routing
 
-DISTNAME=      tor-0.2.6.10
+DISTNAME=      tor-0.2.7.5
 CATEGORIES=    net
 HOMEPAGE=      https://www.torproject.org/
-REVISION=      1
 
 MAINTAINER=    Pascal Stumpf <pascal.stu...@cubes.de>
 
 # BSD
 PERMIT_PACKAGE_CDROM=  Yes
 
-WANTLIB += c crypto event m pthread ssl z
+WANTLIB += c crypto event_core event_extra m pthread ssl z
 
 MASTER_SITES=  https://www.torproject.org/dist/
 
-CONFIGURE_STYLE=gnu
+CONFIGURE_STYLE=autoconf
 AUTOCONF_VERSION = 2.69
 # PIE is already taken care of on a per-arch basis, and we have stack 
protection
 # anyway on FRAME_GROWS_DOWN archs.
 CONFIGURE_ARGS=        --with-ssl-dir=/usr \
+               --with-libevent-dir="${LOCALBASE}" \
                --disable-gcc-hardening
 CONFIGURE_ENV+=ac_cv_member_struct_ssl_method_st_get_cipher_by_char=no
+
+LIB_DEPENDS=   devel/libevent2
 
 DB_DIR=                /var/tor
 SUBST_VARS+=   DB_DIR
Index: distinfo
===================================================================
RCS file: /cvs/ports/net/tor/distinfo,v
retrieving revision 1.70
diff -u -p -r1.70 distinfo
--- distinfo    14 Jul 2015 12:05:44 -0000      1.70
+++ distinfo    23 Nov 2015 17:44:57 -0000
@@ -1,2 +1,2 @@
-SHA256 (tor-0.2.6.10.tar.gz) = BULA7+Q7hmGTN4Yvp+sCx6dMsjp51YcJBiil8PEiS40=
-SIZE (tor-0.2.6.10.tar.gz) = 3587211
+SHA256 (tor-0.2.7.5.tar.gz) = fSqeTbG9md64OVYJtZysIXsMHun/LusPCIuRpdj2ql8=
+SIZE (tor-0.2.7.5.tar.gz) = 4838541
Index: patches/patch-Makefile_in
===================================================================
RCS file: patches/patch-Makefile_in
diff -N patches/patch-Makefile_in
--- /dev/null   1 Jan 1970 00:00:00 -0000
+++ patches/patch-Makefile_in   23 Nov 2015 17:44:57 -0000
@@ -0,0 +1,29 @@
+$OpenBSD$
+--- Makefile.in.orig   Fri Nov 20 19:46:55 2015
++++ Makefile.in        Fri Nov 20 19:47:27 2015
+@@ -6768,8 +6768,8 @@ uninstall-man: uninstall-man1
+ src/common/log.o: micro-revision.i
+ 
+ src/or/tor_main.o: micro-revision.i
+-@COVERAGE_ENABLED_TRUE@export 
TESTING_TOR_BINARY=$(top_builddir)/src/or/tor-cov
+-@COVERAGE_ENABLED_FALSE@export TESTING_TOR_BINARY=$(top_builddir)/src/or/tor
++@COVERAGE_ENABLED_TRUE@TESTING_TOR_BINARY=$(top_builddir)/src/or/tor-cov
++@COVERAGE_ENABLED_FALSE@TESTING_TOR_BINARY=$(top_builddir)/src/or/tor
+ 
+ micro-revision.i: FORCE
+       $(AM_V_at)rm -f micro-revision.tmp; \
+@@ -6791,10 +6791,10 @@ micro-revision.i: FORCE
+ 
+ FORCE:
+ 
+-export PYTHON=@PYTHON@
+-export SHELL=@SHELL@
+-export abs_top_srcdir=@abs_top_srcdir@
+-export builddir=@builddir@
++PYTHON=@PYTHON@
++SHELL=@SHELL@
++abs_top_srcdir=@abs_top_srcdir@
++builddir=@builddir@
+ # fallback_consensus
+ 
+ # If we don't have it, fake it.
Index: patches/patch-configure_ac
===================================================================
RCS file: patches/patch-configure_ac
diff -N patches/patch-configure_ac
--- /dev/null   1 Jan 1970 00:00:00 -0000
+++ patches/patch-configure_ac  23 Nov 2015 17:44:57 -0000
@@ -0,0 +1,44 @@
+$OpenBSD$
+
+Make this work w/ libevent2 on OpenBSD
+https://trac.torproject.org/projects/tor/attachment/ticket/16651/event2-b.patch
+
+--- configure.ac.orig  Fri Nov 13 14:41:42 2015
++++ configure.ac       Mon Nov 23 18:38:05 2015
+@@ -505,10 +505,7 @@ AC_CHECK_MEMBERS([struct event.min_heap_idx], , ,
+ AC_CHECK_HEADERS(event2/event.h event2/dns.h event2/bufferevent_ssl.h)
+ 
+ LIBS="$save_LIBS"
+-LDFLAGS="$save_LDFLAGS"
+-CPPFLAGS="$save_CPPFLAGS"
+ 
+-
+ AM_CONDITIONAL(USE_EXTERNAL_EVDNS, test x$ac_cv_header_event2_dns_h = xyes)
+ 
+ if test "$enable_static_libevent" = "yes"; then
+@@ -518,8 +515,24 @@ if test "$enable_static_libevent" = "yes"; then
+      TOR_LIBEVENT_LIBS="$TOR_LIBDIR_libevent/libevent.a 
$STATIC_LIBEVENT_FLAGS"
+    fi
+ else
+-     TOR_LIBEVENT_LIBS="-levent"
++     if test x$ac_cv_header_event2_event_h = "xyes"; then
++       AC_SEARCH_LIBS(event_new, [event event_core])
++       AC_SEARCH_LIBS(evdns_base_new, [event event_extra])
++
++       if test $ac_cv_search_event_new != "none required"; then
++         TOR_LIBEVENT_LIBS="$ac_cv_search_event_new"
++       fi
++       if test $ac_cv_search_evdns_base_new != "none required"; then
++         TOR_LIBEVENT_LIBS="$ac_cv_search_evdns_base_new $TOR_LIBEVENT_LIBS"
++       fi
++     else
++       TOR_LIBEVENT_LIBS="-levent"
++     fi
+ fi
++
++LIBS="$save_LIBS"
++LDFLAGS="$save_LDFLAGS"
++CPPFLAGS="$save_CPPFLAGS"
+ 
+ dnl This isn't the best test for Libevent 2.0.3-alpha.  Once it's released,
+ dnl we can do much better.
Index: patches/patch-src_config_torrc_sample_in
===================================================================
RCS file: /cvs/ports/net/tor/patches/patch-src_config_torrc_sample_in,v
retrieving revision 1.14
diff -u -p -r1.14 patch-src_config_torrc_sample_in
--- patches/patch-src_config_torrc_sample_in    26 Mar 2015 21:32:30 -0000      
1.14
+++ patches/patch-src_config_torrc_sample_in    23 Nov 2015 17:44:57 -0000
@@ -1,7 +1,7 @@
 $OpenBSD: patch-src_config_torrc_sample_in,v 1.14 2015/03/26 21:32:30 pascal 
Exp $
---- src/config/torrc.sample.in.orig    Tue Feb 24 16:33:30 2015
-+++ src/config/torrc.sample.in Wed Mar 25 11:33:26 2015
-@@ -38,18 +38,18 @@
+--- src/config/torrc.sample.in.orig    Fri Nov 13 14:41:38 2015
++++ src/config/torrc.sample.in Fri Nov 20 19:45:16 2015
+@@ -39,18 +39,18 @@
  ## Send every possible message to @LOCALSTATEDIR@/log/tor/debug.log
  #Log debug file @LOCALSTATEDIR@/log/tor/debug.log
  ## Use the system log instead of Tor's logfiles
@@ -23,12 +23,12 @@ $OpenBSD: patch-src_config_torrc_sample_
  
  ## The port on which Tor will listen for local connections from Tor
  ## controller applications, as documented in control-spec.txt.
-@@ -173,6 +173,8 @@
- ## For security, by default Tor rejects connections to private (local)
- ## networks, including to your public IP address. See the man page entry
- ## for ExitPolicyRejectPrivate if you want to allow "exit enclaving".
+@@ -182,6 +182,8 @@
+ ## and any public IPv4 and IPv6 addresses on any interface on the relay.
+ ## See the man page entry for ExitPolicyRejectPrivate if you want to allow
+ ## "exit enclaving".
 +## Revoke privileges
 +User _tor
  ##
- #ExitPolicy accept *:6660-6667,reject *:* # allow irc ports but no more
- #ExitPolicy accept *:119 # accept nntp as well as default exit policy
+ #ExitPolicy accept *:6660-6667,reject *:* # allow irc ports on IPv4 and IPv6 
but no more
+ #ExitPolicy accept *:119 # accept nntp ports on IPv4 and IPv6 as well as 
default exit policy

Reply via email to