2 # Copyright (C) 2008-2016 OpenWrt.org
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
8 include $(TOPDIR
)/rules.mk
14 PKG_SOURCE
:=$(PKG_NAME
)-$(PKG_VERSION
).
tar.gz
15 PKG_SOURCE_URL
:=https
://dist.torproject.org
/ \
16 https
://archive.torproject.org
/tor-package-archive
17 PKG_MD5SUM
:=763ae964e916c2a7a4c5015d351fcf8b
18 PKG_HASH
:=c1959bebff9a546a54cbedb58c8289a42441991af417d2d16f7b336be8903221
19 PKG_MAINTAINER
:=Hauke Mehrtens
<hauke@hauke-m.de
>
20 PKG_LICENSE_FILES
:=LICENSE
24 include $(INCLUDE_DIR
)/package.mk
26 define Package
/tor
/Default
29 URL
:=https
://www.torproject.org
/
33 define Package
/tor
/Default
/description
34 Tor is a toolset for a wide range of organizations and people that want to
35 improve their safety and security on the Internet. Using Tor can help you
36 anonymize web browsing and publishing
, instant messaging
, IRC
, SSH
, and
37 more. Tor also provides a platform on which software developers can build
38 new applications with built-in anonymity
, safety
, and privacy features.
42 $(call Package
/tor
/Default
)
43 TITLE
:=An anonymous Internet communication system
44 DEPENDS
:=+libevent2
+libopenssl
+libpthread
+librt
+zlib
+libcap
47 define Package
/tor
/description
48 $(call Package
/tor
/Default
/description
)
49 This package contains the tor daemon.
52 define Package
/tor-gencert
53 $(call Package
/tor
/Default
)
54 TITLE
:=Tor certificate generation
58 define Package
/tor-gencert
/description
59 $(call Package
/tor
/Default
/description
)
60 Generate certs and keys for Tor directory authorities
63 define Package
/tor-resolve
64 $(call Package
/tor
/Default
)
65 TITLE
:=tor hostname resolve
69 define Package
/tor-resolve
/description
70 $(call Package
/tor
/Default
/description
)
71 Resolve a hostname to an IP address via tor
74 define Package
/tor-geoip
75 $(call Package
/tor
/Default
)
76 TITLE
:=GeoIP db for tor
80 define Package
/tor-geoip
/description
81 $(call Package
/tor
/Default
/description
)
82 This package contains a GeoIP database mapping IP addresses to countries.
85 define Package
/tor
/conffiles
87 /var
/lib
/tor
/fingerprint
92 --with-libevent-dir
="$(STAGING_DIR)/usr" \
93 --with-ssl-dir
="$(STAGING_DIR)/usr" \
94 --with-openssl-dir
="$(STAGING_DIR)/usr" \
95 --with-zlib-dir
="$(STAGING_DIR)/usr" \
100 --disable-largefile \
101 --with-tor-user
=tor \
104 EXTRA_CFLAGS
+= -std
=gnu99
106 ifneq ($(CONFIG_SSP_SUPPORT
),y
)
108 --disable-gcc-hardening
110 EXTRA_CFLAGS
+= -fPIC
116 define Package
/tor
/install
117 $(INSTALL_DIR
) $(1)/usr
/sbin
118 $(INSTALL_BIN
) $(PKG_INSTALL_DIR
)/usr
/bin
/tor
$(1)/usr
/sbin
/
119 $(INSTALL_BIN
) $(PKG_INSTALL_DIR
)/usr
/bin
/torify
$(1)/usr
/sbin
/
120 $(INSTALL_DIR
) $(1)/etc
/init.d
121 $(INSTALL_BIN
) .
/files
/tor.init
$(1)/etc
/init.d
/tor
122 $(INSTALL_DIR
) $(1)/etc
/tor
123 $(INSTALL_CONF
) $(PKG_INSTALL_DIR
)/etc
/tor
/torrc.sample
$(1)/etc
/tor
/torrc
126 define Package
/tor-gencert
/install
127 $(INSTALL_DIR
) $(1)/usr
/sbin
128 $(INSTALL_BIN
) $(PKG_INSTALL_DIR
)/usr
/bin
/tor-gencert
$(1)/usr
/sbin
/
131 define Package
/tor-resolve
/install
132 $(INSTALL_DIR
) $(1)/usr
/sbin
133 $(INSTALL_BIN
) $(PKG_INSTALL_DIR
)/usr
/bin
/tor-resolve
$(1)/usr
/sbin
/
136 define Package
/tor-geoip
/install
137 $(INSTALL_DIR
) $(1)/usr
/share
/tor
138 $(CP
) $(PKG_INSTALL_DIR
)/usr
/share
/tor
/geoip
$(1)/usr
/share
/tor
/
139 $(CP
) $(PKG_INSTALL_DIR
)/usr
/share
/tor
/geoip6
$(1)/usr
/share
/tor
/
142 $(eval
$(call BuildPackage
,tor
))
143 $(eval
$(call BuildPackage
,tor-gencert
))
144 $(eval
$(call BuildPackage
,tor-resolve
))
145 $(eval
$(call BuildPackage
,tor-geoip
))