首先 OPKG命令 是openwrt插件安装特有命令 类似Ubuntu上的apt-get或者centos上的yum
好多openwrt系统固件都把opkg裁剪掉了,如果拿到一个openwrt系统又想用opkg安装网络上下载到的ipk包,应该怎么办呢?
First of all, the OPKG command is a special command for openwrt plug-in installation, similar to apt-get on Ubuntu or yum on centos
Many openwrt system firmwares have cut off the opkg. If you get an openwrt system and want to use opkg to install the ipk package downloaded from the network, what should I do?
Effective commands found on the network that can be directly executed
Download opkg release (latest when this was written was 0.3.1):
wget http://downloads.yoctoproject.org/releases/opkg/opkg-0.3.1.tar.gz
tar -zxvf opkg-0.3.1.tar.gz
install compilation dependencies: apt-get update && apt-get install -y gcc libtool autoconf pkg-config libarchive13 libarchive-dev libcurl3 libcurl4-gnutls-dev libssl-dev libgpgme11-dev libtool-bin
compile(compile with gpg support for signature verification, and curl to support basic auth-leave the enable-curl flag out to use it with the default wget): * (pre-compilation) if there's no configure script (a file called configure) you need to call ./autogen.sh first * ./configure --with-static-libopkg --disable-shared --enable-gpg --enable-curl --prefix=/usr && make && sudo make install
After make install is done you will have opkg installed-remember to add opkg.conf (example here) under /etc/opkg
After my test, it couldn’t be executed. In addition, all the compilations found in China were all nonsense and couldn’t run.
I searched in domestic and foreign search engines for 10 minutes and found more than 10 articles, most of which could not be solved.
Finally, a very simple way to solve the urgent need
It is to use the file management function that comes with openwrt, generally in System>>File Management
We open the root folder (recommended) You can also open a folder at will
Then click upload to upload the downloaded plug-in *.ipk file to openwrt
Then click Install to install the required plug-in
Please indicate the source for the original reprint of this article https://www.31du.cn/blog/openwrt-opkg-command-not-found.html
网络上面找到的能直接执行的有效命令 Download opkg release (latest when this was written was 0.3.1): wget http://downloads.yoctoproject.org/releases/opkg/opkg-0.3.1.tar.gz tar -zxvf opkg-0.3.1.tar.gz install compilation dependencies: apt-get update && apt-get install -y gcc libtool autoconf pkg-config libarchive13 libarchive-dev libcurl3 libcurl4-gnutls-dev libssl-dev libgpgme11-dev libtool-bin compile(compile with gpg support for signature verification, and curl to support basic auth - leave the enable-curl flag out to use it with the default wget): * (pre-compilation) if there's no configure script (a file called configure) you need to call ./autogen.sh first * ./configure --with-static-libopkg --disable-shared --enable-gpg --enable-curl --prefix=/usr && make && sudo make install After make install is done you will have opkg installed - remember to add opkg.conf (example here) under /etc/opkg
经过我的测试最终无法执行 另外国内找到的什么编译 全部都是扯淡无法运行
在国内外搜索引擎搜寻了10分钟 找了10几篇文章 大都无法解决
最后 一个非常简单的方法 解决燃眉之急
就是利用openwrt自带的文件管理功能 一般在 系统>>文件管理里面
我们打开root文件夹 (推荐) 也可随便打开一个文件夹
然后点击上传 把下载好的插件 *.ipk文件上传到openwrt里面
然后点击安装即可安装上所需插件
本文原创 转载请注明出处 https://www.31du.cn/blog/openwrt-opkg-command-not-found.html