openwrt

openwrt 编译错误

夙愿已清 提交于 2019-11-29 04:33:49
Collected errors: * check_data_file_clashes: Package luci-mod-admin-full wants to install file /opt/svnworking/A1905_Openwrt_4G/source/master/build_dir/target-mipsel_24kc_musl/root-ramips/usr/lib/lua/luci/controller/admin/index.lua But that file is already provided by package * luci-base * check_data_file_clashes: Package luci-mod-admin-full wants to install file /opt/svnworking/A1905_Openwrt_4G/source/master/build_dir/target-mipsel_24kc_musl/root-ramips/usr/lib/lua/luci/controller/admin/network.lua But that file is already provided by package * luci-mod-network * check_data_file_clashes:

How to find out if the eth0 mode is static or dhcp?

China☆狼群 提交于 2019-11-28 07:57:34
问题 I want to use a C program to get if the ip of the network interface is set manually or via dhcp. I've tried to use the following code and it has worked in Debian, but it hasn't worked in OpenWrt. I want to know how to write a C program doing this in OpenWrt. I have tried to use this: #include <stdio.h> int main(void) { FILE *fp; char buffer[80]; fp=popen("cat /etc/network/interfaces |grep ^iface\\ br-lan | awk -F ' ' '{print $4}'","r"); fgets(buffer, sizeof(buffer), fp); printf("%s", buffer);

Openwrt开发之wifi sta设置

末鹿安然 提交于 2019-11-27 21:54:52
场景: openwrtWIFI当做sta,连接上级AP,其他外设比如手机、pc设备连接到openwrt的局域网,通过openwrt访问外网。 dhcp配置: config dnsmasq option domainneeded 1 option boguspriv 1 option filterwin2k 0 # enable for dial on demand option localise_queries 1 option rebind_protection 1 # disable if upstream must serve RFC1918 addresses option rebind_localhost 1 # enable for RBL checking and similar services #list rebind_domain example.lan # whitelist RFC1918 responses for domains option local '/lan/' option domain 'lan' option expandhosts 1 option nonegcache 0 option authoritative 1 option readethers 1 option leasefile '/tmp/dhcp.leases'

Openwrt

空扰寡人 提交于 2019-11-27 06:24:02
ubuntu环境    点击 openwrt 查询自己系统需要安装的那些 比如我的系统是ubuntu 18.04,选择的就是18.04 查询设备CPU信息    点击 openwrt 查询自己路由器对应的CPU信息 准备OpenWrt环境 下载openwrt源码 这个过程可能会有点漫长,可以将github上的资源搬到码云,然后从码云下载,据说速度很快,详细的教程百度搜一下就有 git clone https://git.openwrt.org/openwrt/openwrt.git 选择自己需要的分支 cd openwrt/ # lede git checkout lede-17.01 # openwrt git checkout openwrt-18.06 编译检查 在安装Ubuntu环境的时候,我们已经安装了一部分需要的库,在这个地方如果报错,只需要根据报错的信息安装对应库就好了 make defconfig && make prereq 配置编译信息 在第二部我们已经查到自己路由信息,在这个地方只需要按照查询的信息选择就好 make menuconfig 关于一些选项的说明,来自于《OpenWrt智能路由系统开发 跟hoowa学智能路由》 如果只是生成SDK开发环境,勾选比较少,我所勾选的是 Target System (Atheros AR7xxx/AR9xxx)

openwrt: Makefile 框架分析

若如初见. 提交于 2019-11-26 23:39:41
/*--> */ /*--> */ 主 Makefile 分析 注: 1 ) make -n 可打印 makefile 执行的命令,而不执行。 2 )可以在规则的命令中增加 echo 跟踪执行进度。 顶层目录的 Makefile 是 openert 的总 Makefile ,第一个编译目标 world 是 make 的默认编译目标。 world: include $(TOPDIR)/include/host.mk ifneq ($(OPENWRT_BUILD),1) _SINGLE=export MAKEFLAGS=$(space); override OPENWRT_BUILD=1 export OPENWRT_BUILD GREP_OPTIONS= export GREP_OPTIONS include $(TOPDIR)/include/debug.mk include $(TOPDIR)/include/depends.mk include $(TOPDIR)/include/toplevel.mk else include rules.mk include $(INCLUDE_DIR)/depends.mk include $(INCLUDE_DIR)/subdir.mk include target/Makefile include package/Makefile

openwrt编译环境搭建

对着背影说爱祢 提交于 2019-11-26 23:39:24
1,首先安装ubuntu系统,这里安装的是虚拟机 2,安装openwrt编译所需环境 apt-get install build-essential libncures5-dev gawk libssl-dev subversion git uzip 在安装之前运行了下 apt-get update 在安装时出现了“/var/lib/dpkg/local”的错误 rm了这个文件 3,在home目录下mkdir openwrt了一个文件目录,然后运行 git clone git://git.openwrt.org/15.05/openwrt.git获取openwrt源码 4,进入openwrt源码 scripts目录下 运行 ./feeds update -a 更新所以 然后 ./feeds install -a 出现了很多警告... 5,make menuconfig 成功出现蓝色的openwrt配置界面 来源: http://www.cnblogs.com/b422/p/5585740.html

OpenWRT交叉编译

人盡茶涼 提交于 2019-11-26 23:39:14
对于当前不在OpenWRT repository中的软件,如果是用源码形式发布的,那么可以用OpenWRT Buildroot进行交叉编译。 首先编译好Buildroot(一般编译过一次固件,就已经编译好了) 找到目录staging_dir/toolchain-architecture_gcc-complierver_uClibc-libcver/bin/ 把它加入到环境变量PATH: PATH=$PATH(上面提到的目录) export PATH 把环境变量STAGING_DIR设置为上面提到的toolchain目录: STAGING_DIR=toolchain目录 export STAGING_DIR 设置编译设置中的一些参数,我这里用到的是修改makefile: make CC=architecture-openwrt-linux-uclibc-gcc LD=architecture-openwrt-linux-uclibc-ld 如果缺一些头文件或者库文件,那么需要修改CFLAGS和LDFLAGS,让它们指向staging_dir/target-architecture_uClibc-libcver/usr/include和.../usr/lib目录 编译单独的安装包 首先make menuconfig,在里面选择好需编译的软件包和它依赖的库。 然后make tools