diff options
author | Alyssa Ross <hi@alyssa.is> | 2021-04-09 18:28:16 +0000 |
---|---|---|
committer | Alyssa Ross <hi@alyssa.is> | 2021-04-12 18:46:15 +0000 |
commit | fd2e737e0678ee7d8081baef05b305146a2c0034 (patch) | |
tree | ac3e9b27576a0382335532d126f9a66d486bc638 /nixpkgs/pkgs/applications/networking/onionshare/fix-paths-gui.patch | |
parent | cc207d720b6aa836e256c1ee9842bc739e630a8a (diff) | |
parent | 9e377a6ce42dccd9b624ae4ce8f978dc892ba0e2 (diff) | |
download | nixlib-fd2e737e0678ee7d8081baef05b305146a2c0034.tar nixlib-fd2e737e0678ee7d8081baef05b305146a2c0034.tar.gz nixlib-fd2e737e0678ee7d8081baef05b305146a2c0034.tar.bz2 nixlib-fd2e737e0678ee7d8081baef05b305146a2c0034.tar.lz nixlib-fd2e737e0678ee7d8081baef05b305146a2c0034.tar.xz nixlib-fd2e737e0678ee7d8081baef05b305146a2c0034.tar.zst nixlib-fd2e737e0678ee7d8081baef05b305146a2c0034.zip |
Merge remote-tracking branch 'nixpkgs/nixos-unstable'
Diffstat (limited to 'nixpkgs/pkgs/applications/networking/onionshare/fix-paths-gui.patch')
-rw-r--r-- | nixpkgs/pkgs/applications/networking/onionshare/fix-paths-gui.patch | 37 |
1 files changed, 37 insertions, 0 deletions
diff --git a/nixpkgs/pkgs/applications/networking/onionshare/fix-paths-gui.patch b/nixpkgs/pkgs/applications/networking/onionshare/fix-paths-gui.patch new file mode 100644 index 000000000000..cdc2e3d47dd8 --- /dev/null +++ b/nixpkgs/pkgs/applications/networking/onionshare/fix-paths-gui.patch @@ -0,0 +1,37 @@ + +--- a/onionshare/gui_common.py ++++ b/onionshare/gui_common.py +@@ -376,29 +376,10 @@ class GuiCommon: + } + + def get_tor_paths(self): +- if self.common.platform == "Linux": +- tor_path = shutil.which("tor") +- obfs4proxy_file_path = shutil.which("obfs4proxy") +- prefix = os.path.dirname(os.path.dirname(tor_path)) +- tor_geo_ip_file_path = os.path.join(prefix, "share/tor/geoip") +- tor_geo_ipv6_file_path = os.path.join(prefix, "share/tor/geoip6") +- elif self.common.platform == "Windows": +- base_path = self.get_resource_path("tor") +- tor_path = os.path.join(base_path, "Tor", "tor.exe") +- obfs4proxy_file_path = os.path.join(base_path, "Tor", "obfs4proxy.exe") +- tor_geo_ip_file_path = os.path.join(base_path, "Data", "Tor", "geoip") +- tor_geo_ipv6_file_path = os.path.join(base_path, "Data", "Tor", "geoip6") +- elif self.common.platform == "Darwin": +- base_path = self.get_resource_path("tor") +- tor_path = os.path.join(base_path, "tor") +- obfs4proxy_file_path = os.path.join(base_path, "obfs4proxy.exe") +- tor_geo_ip_file_path = os.path.join(base_path, "geoip") +- tor_geo_ipv6_file_path = os.path.join(base_path, "geoip6") +- elif self.common.platform == "BSD": +- tor_path = "/usr/local/bin/tor" +- tor_geo_ip_file_path = "/usr/local/share/tor/geoip" +- tor_geo_ipv6_file_path = "/usr/local/share/tor/geoip6" +- obfs4proxy_file_path = "/usr/local/bin/obfs4proxy" ++ tor_path = "@tor@/bin/tor" ++ tor_geo_ip_file_path = "@geoip@/share/tor/geoip" ++ tor_geo_ipv6_file_path = "@geoip@/share/tor/geoip6" ++ obfs4proxy_file_path = "@obfs4@/bin/obfs4proxy" + + return ( + tor_path, |