On 2016-02-26 14:40, Tomas Janousek wrote: > Hi, > > On Fri, Feb 26, 2016 at 01:59:07PM +0100, Andreas Beckmann wrote: >> The make.log from -3 (or -4 which I uploaded this morning) would be >> nice. It should contain the invocation of conftest.sh, which gets passed >> all the flags it will use later on. > > Okay, I'm attaching it. I think that the easiest solution would be to patch > conftest.sh:build_cflags to add -m64 if the arch is x86_64. The kernel build > does this in arch/x86/Makefile regardless of whether gcc defaults to 32/64, so > conftest could do that too.
In 355.11 the problem comes from Kbuild: NV_CONFTEST_CFLAGS := $(shell $(NV_CONFTEST_CMD) build_cflags) conftest.sh should not derive compile flags on its own, instead the KBUILD_CFLAGS from Kbuild should be used (which contains the -m64). Once we understood hwo this works in the new build system (355+), we can backport it to the older releases. There is also LINUXINCLUDE which could provide us with all the -I flags ... I tried a patch (in svn, but disabled) that adds KBUILD_CFLAGS to NV_CONFTEST_CFLAGS, but that already makes the build fail. (I didn't even think about testing 32/64 bit mixtures). Andreas PS: I just uploaded 355.11-3 to experimental, but primarily to get the new packages through NEW.

