True, I did it before with the specialized gcc. But clang should work also, and I have no clue why it does not. I already crosscompiled countless projects using it.
Well, i checked Source/Checks/cm_cxx_features.cmake and the answer for failing lies there. Configuration steps fails cause there are just a couple of warnings that match if(check_output MATCHES "(^|[ :])[Ww][Aa][Rr][Nn][Ii][Nn][Gg]") and that’s the reason…
I’ve added -Wno-unused-command-line-argument to my C/CXXFLAGS as a temporary hack and it works and builds the CMake. I understand that the problem comes from the fact that linking is using both CXXFLAGS and LDFLAGS but the flags controling standard include paths are ignored during linking, emitting a warning. But I need them badly in CXXFLAGS to properly set up my cross-toolchain.