Problem in compiling LEDE on Ubuntu 14.04.5 with Target=IPQ806X

Hi,

I have downloaded the latest LEDE from github and I am trying to compile it on Ubuntu 14.04 with Kernel 4.4.0-66-generic. I follow the steps mentioned in Quick Image Building Guide
I set the target to IPQ806x since this is the CPU architecture of my router. However, during the compilation process I get an error related to missing a file named term.m. I search for the file using the following command

dpkg-query --search term.h

I get the following output:

virtualbox-5.0: /usr/share/virtualbox/src/vboxhost/vboxdrv/include/iprt/initterm.h
virtualbox-5.0: /usr/share/virtualbox/src/vboxhost/vboxnetadp/include/iprt/initterm.h
libncurses5-dev:amd64: /usr/include/term.h
virtualbox-5.0: /usr/share/virtualbox/src/vboxhost/vboxpci/include/iprt/initterm.h
virtualbox-5.0: /usr/share/virtualbox/src/vboxhost/vboxnetflt/include/iprt/initterm.h
virtualbox-5.0: /usr/share/virtualbox/src/vboxhost/vboxdrv/include/internal/initterm.h

This means the file already exists in the system. So how can I solve this problem?

Here is the output of the compilation process with V=s

make[3]: Leaving directory /home/ha/OpenWrt/lede/package/system/ubox' make[3]: Entering directory /home/ha/OpenWrt/lede/package/utils/util-linux'
rm -f /home/ha/OpenWrt/lede/build_dir/target-arm_cortex-a15+neon-vfpv4_musl_eabi/util-linux-2.29.2/.built
touch /home/ha/OpenWrt/lede/build_dir/target-arm_cortex-a15+neon-vfpv4_musl_eabi/util-linux-2.29.2/.built_check
CFLAGS="-Os -pipe -mcpu=cortex-a15 -mfpu=neon-vfpv4 -fno-caller-saves -fno-plt -fhonour-copts -Wno-error=unused-but-set-variable -Wno-error=unused-result -mfloat-abi=hard -iremap/home/ha/OpenWrt/lede/build_dir/target-arm_cortex-a15+neon-vfpv4_musl_eabi/util-linux-2.29.2:util-linux-2.29.2 -Wformat -Werror=format-security -fstack-protector -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fpic -std=gnu99 -I/home/ha/OpenWrt/lede/staging_dir/target-arm_cortex-a15+neon-vfpv4_musl_eabi/usr/include -I/home/ha/OpenWrt/lede/staging_dir/target-arm_cortex-a15+neon-vfpv4_musl_eabi/include -I/home/ha/OpenWrt/lede/staging_dir/toolchain-arm_cortex-a15+neon-vfpv4_gcc-5.4.0_musl_eabi/usr/include -I/home/ha/OpenWrt/lede/staging_dir/toolchain-arm_cortex-a15+neon-vfpv4_gcc-5.4.0_musl_eabi/include/fortify -I/home/ha/OpenWrt/lede/staging_dir/toolchain-arm_cortex-a15+neon-vfpv4_gcc-5.4.0_musl_eabi/include " CXXFLAGS="-Os -pipe -mcpu=cortex-a15 -mfpu=neon-vfpv4 -fno-caller-saves -fno-plt -fhonour-copts -Wno-error=unused-but-set-variable -Wno-error=unused-result -mfloat-abi=hard -iremap/home/ha/OpenWrt/lede/build_dir/target-arm_cortex-a15+neon-vfpv4_musl_eabi/util-linux-2.29.2:util-linux-2.29.2 -Wformat -Werror=format-security -fstack-protector -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fpic -std=gnu99 -I/home/ha/OpenWrt/lede/staging_dir/target-arm_cortex-a15+neon-vfpv4_musl_eabi/usr/include -I/home/ha/OpenWrt/lede/staging_dir/target-arm_cortex-a15+neon-vfpv4_musl_eabi/include -I/home/ha/OpenWrt/lede/staging_dir/toolchain-arm_cortex-a15+neon-vfpv4_gcc-5.4.0_musl_eabi/usr/include -I/home/ha/OpenWrt/lede/staging_dir/toolchain-arm_cortex-a15+neon-vfpv4_gcc-5.4.0_musl_eabi/include/fortify -I/home/ha/OpenWrt/lede/staging_dir/toolchain-arm_cortex-a15+neon-vfpv4_gcc-5.4.0_musl_eabi/include " LDFLAGS="-L/home/ha/OpenWrt/lede/staging_dir/target-arm_cortex-a15+neon-vfpv4_musl_eabi/usr/lib -L/home/ha/OpenWrt/lede/staging_dir/target-arm_cortex-a15+neon-vfpv4_musl_eabi/lib -L/home/ha/OpenWrt/lede/staging_dir/toolchain-arm_cortex-a15+neon-vfpv4_gcc-5.4.0_musl_eabi/usr/lib -L/home/ha/OpenWrt/lede/staging_dir/toolchain-arm_cortex-a15+neon-vfpv4_gcc-5.4.0_musl_eabi/lib -znow -zrelro " make -j1 -C /home/ha/OpenWrt/lede/build_dir/target-arm_cortex-a15+neon-vfpv4_musl_eabi/util-linux-2.29.2/. AR="arm-openwrt-linux-muslgnueabi-gcc-ar" AS="arm-openwrt-linux-muslgnueabi-gcc -c -Os -pipe -mcpu=cortex-a15 -mfpu=neon-vfpv4 -fno-caller-saves -fno-plt -fhonour-copts -Wno-error=unused-but-set-variable -Wno-error=unused-result -mfloat-abi=hard -iremap/home/ha/OpenWrt/lede/build_dir/target-arm_cortex-a15+neon-vfpv4_musl_eabi/util-linux-2.29.2:util-linux-2.29.2 -Wformat -Werror=format-security -fstack-protector -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -fpic -std=gnu99" LD=arm-openwrt-linux-muslgnueabi-ld NM="arm-openwrt-linux-muslgnueabi-gcc-nm" CC="arm-openwrt-linux-muslgnueabi-gcc" GCC="arm-openwrt-linux-muslgnueabi-gcc" CXX="arm-openwrt-linux-muslgnueabi-g++" RANLIB="arm-openwrt-linux-muslgnueabi-gcc-ranlib" STRIP=arm-openwrt-linux-muslgnueabi-strip OBJCOPY=arm-openwrt-linux-muslgnueabi-objcopy OBJDUMP=arm-openwrt-linux-muslgnueabi-objdump SIZE=arm-openwrt-linux-muslgnueabi-size CROSS="arm-openwrt-linux-muslgnueabi-" ARCH="arm" ;
make[4]: Entering directory /home/ha/OpenWrt/lede/build_dir/target-arm_cortex-a15+neon-vfpv4_musl_eabi/util-linux-2.29.2' make all-recursive make[5]: Entering directory /home/ha/OpenWrt/lede/build_dir/target-arm_cortex-a15+neon-vfpv4_musl_eabi/util-linux-2.29.2'
Making all in po
make[6]: Entering directory /home/ha/OpenWrt/lede/build_dir/target-arm_cortex-a15+neon-vfpv4_musl_eabi/util-linux-2.29.2/po' make[6]: Nothing to be done for all'.
make[6]: Leaving directory /home/ha/OpenWrt/lede/build_dir/target-arm_cortex-a15+neon-vfpv4_musl_eabi/util-linux-2.29.2/po' make[6]: Entering directory /home/ha/OpenWrt/lede/build_dir/target-arm_cortex-a15+neon-vfpv4_musl_eabi/util-linux-2.29.2'
CC text-utils/more-more.o
text-utils/more.c:193:50: fatal error: term.h: No such file or directory
compilation terminated.
make[6]: *** [text-utils/more-more.o] Error 1
make[6]: Leaving directory /home/ha/OpenWrt/lede/build_dir/target-arm_cortex-a15+neon-vfpv4_musl_eabi/util-linux-2.29.2' make[5]: *** [all-recursive] Error 1 make[5]: Leaving directory /home/ha/OpenWrt/lede/build_dir/target-arm_cortex-a15+neon-vfpv4_musl_eabi/util-linux-2.29.2'
make[4]: *** [all] Error 2
make[4]: Leaving directory /home/ha/OpenWrt/lede/build_dir/target-arm_cortex-a15+neon-vfpv4_musl_eabi/util-linux-2.29.2' make[3]: *** [/home/ha/OpenWrt/lede/build_dir/target-arm_cortex-a15+neon-vfpv4_musl_eabi/util-linux-2.29.2/.built] Error 2 make[3]: Leaving directory /home/ha/OpenWrt/lede/package/utils/util-linux'
make[2]: *** [package/utils/util-linux/compile] Error 2
make[2]: Leaving directory /home/ha/OpenWrt/lede' make[1]: *** [/home/ha/OpenWrt/lede/staging_dir/target-arm_cortex-a15+neon-vfpv4_musl_eabi/stamp/.package_compile] Error 2 make[1]: Leaving directory /home/ha/OpenWrt/lede'
make: *** [world] Error 2

That util-linux upgrade to 2.29.2 has already been reverted. Git pull updated sources and rebuild. Possibly your error was from that failed update.

1 Like

Thanks. Git Pull fixed the problem and now I have the binary file.

We ran into some fun dependency issues, it's fixed now and committed. :slight_smile: