[OpenWrt-Devel] Did CONFIG_NATIVE_TOOLCHAIN ever work?

Zefir Kurtisi zefir.kurtisi at neratec.com
Tue Oct 13 06:03:39 EDT 2015

Hi all,

could someone confirm that building packages with the native toolchain ever worked?

At my side (x86_64 / gcc (Ubuntu 5.2.1-21ubuntu2) 5.2.1 20151003) I observe an
error and upon reading the scripts to me it looks it can't work as is.

To reproduce in git HEAD:
1. configure
  * target: x86
  * subtarget: x86_64
  * Advanced configuration options (for developers)
    -> Use external toolchain
       -> Use host's toolchain *
2. prepare toolchain
  * run: make toolchain/prepare V=s
  * observe error:
> make[2]: Entering directory './openwrt.git/toolchain/wrapper'
> Testing external toolchain for ipv6 support ... Toolchain directory '--cflags' does not exist.
> failed
> ERROR: CONFIG_IPV6 is enabled but the external toolchain does not support it
> Makefile:62: recipe for target './openwrt.git/build_dir/toolchain-x86_64-linux-gnu/wrapper-1/.prepared' failed
> make[2]: *** [./openwrt.git/build_dir/toolchain-x86_64-linux-gnu/wrapper-1/.prepared] Error 1
> make[2]: Leaving directory './openwrt.git/toolchain/wrapper'

Trying to dig into the problem, the issue is
1) toolchain/wrapper/Makefile calls
   $(SCRIPT_DIR)/ext-toolchain.sh --toolchain $(CONFIG_TOOLCHAIN_ROOT)
2) --toolchain is a mandatory parameter
3) but CONFIG_TOOLCHAIN_ROOT is never set

If I append 'CONFIG_TOOLCHAIN_ROOT="/usr"' to the .config file, the
toolchain/wrapper build succeeds, but the build breaks in later stages. Therefore
I assume I must be missing something.

Could somebody confirm that the native toolchain build is working?

openwrt-devel mailing list
openwrt-devel at lists.openwrt.org

More information about the openwrt-devel mailing list