主页 > 路由器 > centos 6 64位系统下交叉编译openwrt ipk

centos 6 64位系统下交叉编译openwrt ipk

2018年11月17日 centos 6 64位系统下交叉编译openwrt ipk有3条评论 阅读: 20,610 次

以编译openwrt-ssr for openwrt 18.06.1为例

1、安装依赖库
yum install -y subversion binutils bzip2 gcc gcc-c++ gawk gettext flex xz time
yum install -y ncurses-devel zlib-devel make patch unzip perl-ExtUtils-MakeMaker
yum install -y glibc glibc-devel glibc-static quilt ncurses-lib sed sdcc intltool sharutils bison wget

2、下载SDK,以K2P MTK的SDK为例
wget http://downloads.openwrt.org/releases/18.06.1/targets/ramips/mt7621/openwrt-sdk-18.06.1-ramips-mt7621_gcc-7.3.0_musl.Linux-x86_64.tar.xz

xz -d openwrt-sdk-18.06.1-ramips-mt7621_gcc-7.3.0_musl.Linux-x86_64.tar.xz

tar xf openwrt-sdk-18.06.1-ramips-mt7621_gcc-7.3.0_musl.Linux-x86_64.tar

3、下载ipk源码
cd openwrt-sdk-18.06.1-ramips-mt7621_gcc-7.3.0_musl.Linux-x86_64
./scripts/feeds update packages
./scripts/feeds install libpcre
./scripts/feeds update
./scripts/feeds install zlib
./scripts/feeds install libopenssl

git clone https://github.com/ywb94/openwrt-ssr.git package/openwrt-ssr

4、编译
make menuconfig
# 选择要编译的包
#luci ->3. Applications-> luci-app-shadowsocksR 原始版本
#luci ->3. Applications-> luci-app-shadowsocksR-GFW GFWList版本
选择为“M”后保存退出

# 开始编译
make package/openwrt-ssr/compile V=99

编译完成:

ipk目录如上图所示

ipk安装时如果提示dnsmasq错误,需先卸载dnsmasq,重新安装
opkg remove dnsmasq
安装后需重启一次路由器,否则无法启动

评论:3

  1. xi gou 回复
    2018年11月19日 于 上午12:03

    您好,想请问一下您这个openwrt-ssr安装后能否正常使用ipv6的地址ssr服务器呢

  2. 不止倾慕 回复
    2018年11月20日 于 上午8:24

    如果要编译的ipk存在依赖包怎么办呢?

    • ywb 回复
      2018年11月20日 于 上午10:59

      会自己安装

发表评论

新用户的评论需审核后才会显示;

电子邮件地址不会被公开;
必填项已用*标注