ubuntu16.04通过修改transmission源码编译安装transmission,使得其能够通过ipv6在六维下载
2016-11-12 14:55
1141 查看
1. 首先通过官网提供的github地址下载transmission-2.04.tar.xz
然后通过命令
进行解压
2:首先更改metainfo.c中的内容
static int
is_rfc2396_alnum( char ch )
{
return ( '0' <= ch & ch <= '9' )
|| ( 'A' <= ch & ch <= 'Z' )
|| ( 'a' <= ch & ch <= 'z' );
}
改为:
static int
is_rfc2396_alnum( char ch )
{
return ( '0' <= ch & ch <= '9' )
|| ( 'A' <= ch & ch <= 'Z' )
|| ( 'a' <= ch & ch <= 'z' )
|| ( ch == '.' )
|| ( ch == '-' )
|| ( ch == '_' )
|| ( ch == '~' );
}
3,将metainfo.c中static void escape( char * out, const uint8_t * in, size_t in_len )函数中的:
out += tr_snprintf( out, 4, "%%%02X", (unsigned int)*in++ );
改为
out += tr_snprintf( out, 4, "%%%02x", (unsigned int)*in++ );
4,注释掉web.c中这个内容,就可以连接六维。
if(( addr = tr_sessionGetPublicAddress( s, TR_AF_INET )))
curl_easy_setopt( e, CURLOPT_INTERFACE, tr_ntop_non_ts( addr ) );
5.为了得到一个图形界面一定要再加上
如果不安装libgtk2.0-dev,安装后没有图形界面,只有命令行
6. 编译安装
然后按照正常的流程
./configure
make
sudo make install
期间:可能会出现缺少一些组件,自己百度通过apt-get安装。
对于error: libevent 1.4.9 or higher not found!:
通过如下命令解决:
7.配置 仅使用ipv6流量,不使用ipv4流量
进入配置文件的目录(blocklists是过滤清单所在的文件夹)
新建并打开一个文件(名字随意)
在ip文件中添加如下的内容
打开配置文件
启用blocklists(默认不启用)
软件重启
参考:修改源码
解决libevent 1.49 or higher not found!错误
安装图形界面
配置仅使用ipv6流量
然后通过命令
xz -d transmission-2.04.tar.xz tar -xvf trans*.tar
进行解压
2:首先更改metainfo.c中的内容
static int
is_rfc2396_alnum( char ch )
{
return ( '0' <= ch & ch <= '9' )
|| ( 'A' <= ch & ch <= 'Z' )
|| ( 'a' <= ch & ch <= 'z' );
}
改为:
static int
is_rfc2396_alnum( char ch )
{
return ( '0' <= ch & ch <= '9' )
|| ( 'A' <= ch & ch <= 'Z' )
|| ( 'a' <= ch & ch <= 'z' )
|| ( ch == '.' )
|| ( ch == '-' )
|| ( ch == '_' )
|| ( ch == '~' );
}
3,将metainfo.c中static void escape( char * out, const uint8_t * in, size_t in_len )函数中的:
out += tr_snprintf( out, 4, "%%%02X", (unsigned int)*in++ );
改为
out += tr_snprintf( out, 4, "%%%02x", (unsigned int)*in++ );
4,注释掉web.c中这个内容,就可以连接六维。
if(( addr = tr_sessionGetPublicAddress( s, TR_AF_INET )))
curl_easy_setopt( e, CURLOPT_INTERFACE, tr_ntop_non_ts( addr ) );
5.为了得到一个图形界面一定要再加上
sudo apt-get install libgtk2.0-dev
如果不安装libgtk2.0-dev,安装后没有图形界面,只有命令行
6. 编译安装
然后按照正常的流程
./configure
make
sudo make install
期间:可能会出现缺少一些组件,自己百度通过apt-get安装。
对于error: libevent 1.4.9 or higher not found!:
通过如下命令解决:
wget http://monkey.org/~provos/libevent-1.4.9-stable.tar.gz tar -xzvf libevent-1.4.9-stable.tar.gz cd libevent-1.4.9-stable.tar ./configure make sudo make install
7.配置 仅使用ipv6流量,不使用ipv4流量
进入配置文件的目录(blocklists是过滤清单所在的文件夹)
cd ~/.config/transmission/blocklists/
新建并打开一个文件(名字随意)
touch ip
vim ip
在ip文件中添加如下的内容
Ipv4:0.0.0.0-255.255.255.255
打开配置文件
vim ../settings.json
启用blocklists(默认不启用)
将"blocklist-enabled"的值设为true
软件重启
在blocklists文件夹下生成ip.bin文件,说明成功
参考:修改源码
解决libevent 1.49 or higher not found!错误
安装图形界面
配置仅使用ipv6流量
相关文章推荐
- Ubuntu16.04 通过源码编译安装 MySQL 5.7.17
- win7下安装Ubuntu16.04及android源码下载,编译
- Ubuntu下android-4.0.3_r1源码下载,阅读工具安装配置,源码编译详解
- Ubuntu通过源码编译安装Octave 4.0
- ubuntu16.04源码编译安装Poco1.7.8
- Android 源码编译详解【二】:VMware12/Ubuntu16 下载、安装图解
- 进击的Geek(三):Ubuntu16.04中vim的源码编译安装
- Android4.2源码在UBUNTU上的下载,编译及安装
- Android内核源码 在Ubuntu上下载,编译,安装
- ubuntu 16.04通过源码方式安装nginx
- 在Ubuntu中通过源码安装编译安装软件(MySQL篇) 收藏
- Ubuntu 16.04源码编译安装PHP 5.6.29的教程
- zz在Ubuntu中通过源码安装编译安装软件(MySQL篇)
- ubuntu10.10,下载mysql源码,编译安装
- Ubuntu 16.04源码编译安装Apache 2.4.25教程
- 在Ubuntu上下载、编译和安装Android最新源代码(实践后修改)
- Linux(Ubuntu 12.04)源码编译安装gcc-4.9.1(方法一)——亲自测试通过
- Ubuntu下Ruby的下载和编译源码安装
- 在Ubuntu上下载、编译和安装Android源码
- Ubuntu 16.04 源码编译安装PHP7