mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-02 15:41:48 +00:00
nixpkgs: tor depends on torsocks
This may seem strange, but tor distributes its 'torify' wrapper which in turn attempts to use torsocks to bridge a connection, meaning 'tor' users out the box may want it to work. Signed-off-by: Austin Seipp <aseipp@pobox.com>
This commit is contained in:
parent
d92d0eca92
commit
c206c728a8
@ -1,4 +1,4 @@
|
||||
{ stdenv, fetchurl, libevent, openssl, zlib }:
|
||||
{ stdenv, fetchurl, libevent, openssl, zlib, torsocks }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "tor-0.2.5.10";
|
||||
@ -8,10 +8,20 @@ stdenv.mkDerivation rec {
|
||||
sha256 = "0fx8qnwh2f8ykfx0np4hyznjfi4xfy96z59pk96y3zyjvjjh5pdk";
|
||||
};
|
||||
|
||||
buildInputs = [ libevent openssl zlib ];
|
||||
# Note: torsocks is specified as a dependency, as the distributed
|
||||
# 'torify' wrapper attempts to use it; although there is no
|
||||
# ./configure time check for any of this.
|
||||
buildInputs = [ libevent openssl zlib torsocks ];
|
||||
|
||||
CFLAGS = "-lgcc_s";
|
||||
|
||||
# Patch 'torify' to point directly to torsocks.
|
||||
patchPhase = ''
|
||||
substituteInPlace contrib/client-tools/torify \
|
||||
--replace 'pathfind torsocks' true \
|
||||
--replace 'exec torsocks' 'exec ${torsocks}/bin/torsocks'
|
||||
'';
|
||||
|
||||
doCheck = true;
|
||||
|
||||
meta = {
|
||||
|
Loading…
Reference in New Issue
Block a user