安装编译环境及transmission依赖:
apt-get install ca-certificates libcurl4-openssl-dev libssl-dev pkg-config build-essential checkinstall libevent-dev intltool libtool zlib1g-dev
下载编译transmission:
wget http://archive.ubuntu.com/ubuntu/pool/main/t/transmission/transmission_2.92.orig.tar.gz
tar zxvf transmission_2.92.orig.tar.gz
cd transmission-2.92
wget http://archive.ubuntu.com/ubuntu/pool/main/t/transmission/transmission_2.92-3ubuntu2.debian.tar.xz
tar Jxvf transmission_2.92-3ubuntu2.debian.tar.xz
#打openssl补丁,不然编译失败
patch -p 1 < debian/patches/f91cf5ad8c677b61ceb0bf5877b87f9e93256dd7.patch
#patch -p 1 < debian/patches/8c8386a7f3f482a9c917f51d28e0042e55f56b3e.patch
#patch -p 1 < debian/patches/transmission-fix-dns-rebinding-vuln.patch
#transmission跳过校验patch
wget https://github.com/superlukia/transmission-2.92_skiphashcheck/commit/56e327d1dacb5b3453954b76a6d0edd30edb7a34.patch
patch -p 1 < 56e327d1dacb5b3453954b76a6d0edd30edb7a34.patch
./configure
make
#替换已安装的transmission-daemon
mv /usr/bin/transmission-daemon /usr/bin/transmission-daemon.bak
cp daemon/transmission-daemon /usr/bin/transmission-daemon
2.94:
apt-get source transmission-daemon
#tar zxf transmission_2.94.orig.tar.gz transmission-2.94/
cd transmission-2.94/
wget https://github.com/blackyau/Transmission_SkipHashChek/commit/0a18e4dffc7002eb80abe39ae8c8c8aec1205967.patch
git apply 0a18e4dffc7002eb80abe39ae8c8c8aec1205967.patch
./autogen.sh
make
3.0:
apt install git ca-certificates libcurl4-openssl-dev libssl-dev pkg-config build-essential checkinstall libevent-dev intltool libtool zlib1g-dev libglib2.0-dev libsystemd-dev
git clone https://github.com/transmission/transmission
cd transmission/
git checkout 3.00
git submodule update --init
git clone https://github.com/TonyRL/docker-transmission-skip-hash-check.git
patch -p0 < docker-transmission-skip-hash-check/patches/001-skip-hash-checking.patch
patch -p0 < docker-transmission-skip-hash-check/patches/002-fdlimit.patch
patch -p0 < docker-transmission-skip-hash-check/patches/003-random-announce.patch
./autogen.sh --prefix=/usr/local/transmission --with-systemd
make && make install
如果编译时没安装libsystemd依赖,需修改下systemd服务,不然通过systemctl启动transmission会卡住。
cat /etc/systemd/system/multi-user.target.wants/transmission-daemon.service
[Unit]
Description=Transmission BitTorrent Daemon
After=network.target
[Service]
User=debian-transmission
#Type=notify
Type=simple
ExecStart=/usr/bin/transmission-daemon -f --log-error -g /var/lib/transmission-daemon/.config/transmission-daemon/
ExecStop=/bin/kill -s STOP $MAINPID
ExecReload=/bin/kill -s HUP $MAINPID
[Install]
WantedBy=multi-user.target
在WEB界面添加种子后校验时右键点击种子Ask tracker for more peers即可跳过校验。
另类方法:
https://www.jianshu.com/p/ab2df4282e59
参考:
https://github.com/superlukia/transmission-2.92_skiphashcheck
https://blog.csdn.net/Sardkit/article/details/79911925
标签:pt, transmission