BR2_TOOLCHAIN_EXTERNAL_CXX depends on BR2_TOOLCHAIN_EXTERNAL_CUSTOM. BR2_TOOLCHAIN_BUILDROOT_CXX depends on BR2_TOOLCHAIN_BUILDROOT, which is not enabled when BR2_TOOLCHAIN_EXTERNAL_BOOTLIN is enabled. So it seems the config doesn't allow to enable C++ support together with selecting bootlin toolchain. Is there anything that can be done with that?
stsp, All, > So it seems the config doesn't allow to > enable C++ support together with selecting > bootlin toolchain. Have you actually tried to enable a package written in C++? The symbols you reference are just intermediate symbols, that ultimately select BR2_INSTALL_LIBSTDCPP, which is the one symbol that represents whether C++ is available in the toolchain. All Bootlin toolchains with C++ support do select that symbol. > Is there anything that can be done with that? No, because it is already working as expected. Regards, Yann E. MORIN.
> Have you actually tried to enable a package written in C++? Of course! Even if BR2_INSTALL_LIBSTDCPP is enabled, with bootlin tool-chain there is still no host g++ so the compilation fails. > No, because it is already working as expected. I think this is a premature judgement.
stsp, All, > with bootlin tool-chain there is still no > host g++ The Bootlin tolchains are cross toolchains; they compile for the target, not for the host. The host C++ compiler is not provided by the cross toolchain. The host toolchain (of which g++ is part) is to be provided by the distribution you use on your host system; Buildroot does not handle it at all: it is expected to be present. Install the C++ part of the toolchain from your distribution; if that does not exist, ask your distribution to package it. > so the compilation fails. What exactly fails? Please provide a log of the failing build. > I think this is a premature judgement. Maybe... Does not look like it, though: the Bootlin toolchains are widely used, and I know for a fact that they do support C++ for the target, for using that daily. Regards, Yann E. MORIN.
OK, I am sorry, "make clean" have fixed the problem. The problem was the missing output/host/bin/x86_64-linux-g++ (host g++), but its now there. So not sure what happened. :(
stsp, All, > "make clean" have fixed the problem. If you change the toolchain settings in menuconfig, then you have to rebuild from scratch; see the manual: https://buildroot.org/downloads/manual/manual.html#full-rebuild > output/host/bin/x86_64-linux-g++ (host g++) This is not the host C++ compiler. This is the cross-compiler. It looks like you just happen to have an x86-64 target, like you have an x86-64 host. Regards, Yann E. MORIN.
> If you change the toolchain settings in menuconfig, then you have to rebuild > from scratch; see the manual: Treating such things anyhow but bugs, is quite unhelpful. :) If you know "make clean" is now needed, then please tell me so on exit from menuconfig. Either by printing such a message, or, better yet, asking to run "make clean" (ok/cancel) before exiting TUI. > It looks like you just happen to have an x86-64 target, like you have > an x86-64 host. I see, thanks. So "host" in a dir name, doesn't make it a host compiler. Just a cross-compiler that runs on host.
stsp, All,0 > Treating such things anyhow but > bugs, is quite unhelpful. :) > If you know "make clean" is now needed, > then please tell me so on exit from > menuconfig. Either by printing such a > message, or, better yet, asking to run > "make clean" (ok/cancel) before exiting > TUI. Rebuilding from scratch after menuconfig is not always required; if one just adds a new package which has no dependency and is not the dependency of another, then this is usually OK, and running "make" again is often just enough. So no, this is not a bug, and this is expected behaviour. It has limitations, and those are thoroughly explained in the manual. Regards, Yann E. MORIN.
> Rebuilding from scratch after menuconfig is not always required; I am not saying about "always". Likewise, you pop up the "save settings?" TUI dialog only if the settings changed. You can do the same here by alerting the user when needed, or even offering to do the "make clean" from TUI.