Skip to contentSkip to conversation

package/tor: new package

PATCH New Bernd Kuhls 2 participants 2 messages Apr 20, 2015 – Apr 25, 2015

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 package/tor: new package

---
v2: bump to version 0.2.5.12

 package/Config.in                   |    1 +
 package/tor/0001-openssl-libz.patch |   89 +++++++++++++++++++++++++++++++++++
 package/tor/Config.in               |   13 +++++
 package/tor/tor.hash                |    2 +
 package/tor/tor.mk                  |   36 ++++++++++++++
 5 files changed, 141 insertions(+)
 create mode 100644 package/tor/0001-openssl-libz.patch
 create mode 100644 package/tor/Config.in
 create mode 100644 package/tor/tor.hash
 create mode 100644 package/tor/tor.mk
package/Config.in +1 -0
index 468f75d..8e0de39 100644
@@ -1290,6 +1290,7 @@ endif
 	source "package/tinc/Config.in"
 	source "package/tinyhttpd/Config.in"
 	source "package/tn5250/Config.in"
+	source "package/tor/Config.in"
 	source "package/transmission/Config.in"
 	source "package/tvheadend/Config.in"
 	source "package/udpcast/Config.in"
package/tor/0001-openssl-libz.patch new file +89 -0

89 lines not on this page · raw message

package/tor/Config.in new file +13 -0
new file mode 100644
index 0000000..0f48d36
@@ -0,0 +1,13 @@
+config BR2_PACKAGE_TOR
+	bool "tor"
+	depends on BR2_USE_MMU # fork()
+	select BR2_PACKAGE_LIBEVENT
+	select BR2_PACKAGE_OPENSSL
+	select BR2_PACKAGE_ZLIB
+	help
+	  Tor is free software and an open network that helps you defend against
+	  traffic analysis, a form of network surveillance that threatens
+	  personal freedom and privacy, confidential business activities and
+	  relationships, and state security.
+
+	  https://www.torproject.org
package/tor/tor.hash new file +2 -0
new file mode 100644
index 0000000..5cd523f
@@ -0,0 +1,2 @@
+# Locally computed
+sha256	550fdafffeb4c1e3035bb8cc42e6e49d5af17ad79563bd118af22c1107f72b49	tor-0.2.5.12.tar.gz
package/tor/tor.mk new file +36 -0
new file mode 100644
index 0000000..82c0f6c
@@ -0,0 +1,36 @@
+################################################################################
+#
+# tor
+#
+################################################################################
+
+TOR_VERSION = 0.2.5.12
+TOR_SITE = https://dist.torproject.org
+TOR_LICENSE = BSD-3c
+TOR_LICENSE_FILES = LICENSE
+TOR_DEPENDENCIES = libevent openssl zlib
+TOR_AUTORECONF = YES
+
+TOR_CONF_OPTS = \
+	--disable-gcc-hardening \
+	--with-libevent-dir=$(STAGING_DIR)/usr \
+	--with-openssl-dir=$(STAGING_DIR)/usr \
+	--with-zlib-dir=$(STAGING_DIR)/usr
+
+ifeq ($(BR2_STATIC_LIBS),y)
+TOR_CONF_OPTS += \
+	--enable-static-libevent \
+	--enable-static-openssl \
+	--enable-static-tor \
+	--enable-static-zlib
+endif
+
+# libseccomp support depends on largefile, see src/common/sandbox.c, line 16
+ifeq ($(BR2_PACKAGE_LIBSECCOMP)$(BR2_LARGEFILE),yy)
+TOR_CONF_OPTS += --enable-seccomp
+TOR_DEPENDENCIES += libseccomp
+else
+TOR_CONF_OPTS += --disable-seccomp
+endif
+
+$(eval $(autotools-package))
Signature · 1 line
1.7.10.4
#1 lore raw

PATCH v2 1/1 package/tor: new package

Dear Bernd Kuhls,

Quoted 4 lines · Bernd Kuhls

---
v2: bump to version 0.2.5.12

Applied after doing some small changes:

[Thomas:
- remove reference to BR2_LARGEFILE, this option has been removed. Largefile support is now guaranteed to be present.
- rewrap Config.in help text to the appropriate length.]

Also, if you have some time, could you:

* Send your tor patch upstream

* Adjust tor.mk to install the tor systemd service file that is available in contrib/dist/tor.service

* Add a sysv startup script to start tor

Thanks a lot!

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com