Created attachment 385050 [details] build.log make -j4 -l5 cuda-install=/opt/cuda CUDA_PATH=/opt/cuda/ MPI_GCC=10 verbose=1 make[1]: Entering directory '/var/tmp/portage/dev-util/nvidia-cuda-sdk-6.5.14/work/cuda-samples/0_Simple/simpleTextureDrv' make[1]: Entering directory '/var/tmp/portage/dev-util/nvidia-cuda-sdk-6.5.14/work/cuda-samples/0_Simple/inlinePTX' make[1]: Entering directory '/var/tmp/portage/dev-util/nvidia-cuda-sdk-6.5.14/work/cuda-samples/0_Simple/simpleLayeredTexture' make[1]: Entering directory '/var/tmp/portage/dev-util/nvidia-cuda-sdk-6.5.14/work/cuda-samples/0_Simple/simpleAtomicIntrinsics' /opt/cuda//bin/nvcc -ccbin x86_64-pc-linux-gnu-g++ -I../../common/inc -O2 -v --compiler-bindir="/usr/x86_64-pc-linux-gnu/gcc-bin/4.8.3" --compiler-options="-O2 -march=native -fno-stack-protector -U_FORTIFY_SOURCE" --linker-options="-O1,--as-needed" -m64 -gencode arch=compute_11,code=sm_11 -gencode arch=compute_20,code=sm_20 -gencode arch=compute_30,code=sm_30 -gencode arch=compute_35,code=sm_35 -gencode arch=compute_37,code=sm_37 -gencode arch=compute_50,code=sm_50 -gencode arch=compute_50,code=compute_50 -o simpleAtomicIntrinsics.o -c simpleAtomicIntrinsics.cu /opt/cuda//bin/nvcc -ccbin x86_64-pc-linux-gnu-g++ -I../../common/inc -O2 -v --compiler-bindir="/usr/x86_64-pc-linux-gnu/gcc-bin/4.8.3" --compiler-options="-O2 -march=native -fno-stack-protector -U_FORTIFY_SOURCE" --linker-options="-O1,--as-needed" -m64 -gencode arch=compute_20,code=sm_20 -gencode arch=compute_30,code=sm_30 -gencode arch=compute_35,code=sm_35 -gencode arch=compute_37,code=sm_37 -gencode arch=compute_50,code=sm_50 -gencode arch=compute_50,code=compute_50 -o simpleLayeredTexture.o -c simpleLayeredTexture.cu /opt/cuda//bin/nvcc -ccbin x86_64-pc-linux-gnu-g++ -I../../common/inc -O2 -v --compiler-bindir="/usr/x86_64-pc-linux-gnu/gcc-bin/4.8.3" --compiler-options="-O2 -march=native -fno-stack-protector -U_FORTIFY_SOURCE" --linker-options="-O1,--as-needed" -m64 -gencode arch=compute_11,code=sm_11 -gencode arch=compute_20,code=sm_20 -gencode arch=compute_30,code=sm_30 -gencode arch=compute_35,code=sm_35 -gencode arch=compute_37,code=sm_37 -gencode arch=compute_50,code=sm_50 -gencode arch=compute_50,code=compute_50 -o inlinePTX.o -c inlinePTX.cu nvcc fatal : redefinition of argument 'compiler-bindir' Makefile:196: recipe for target 'simpleAtomicIntrinsics.o' failed make[1]: *** [simpleAtomicIntrinsics.o] Error 1
Created attachment 385052 [details] emerge --info
Apparently, -ccbin and --compiler-bindir can't both be set. The following patch solves the problem for me: --- nvidia-cuda-sdk-6.5.14.ebuild 2014-09-19 06:53:57.118470681 +0800 +++ nvidia-cuda-sdk-6.5.14.ebuild 2014-09-19 06:56:11.958603140 +0800 @@ -55,6 +55,7 @@ export RAWLDFLAGS="$(raw-ldflags)" # epatch "${FILESDIR}"/${P}-asneeded.patch + NVCCFLAGS="$(echo "$NVCCFLAGS" | sed -e 's:--compiler-bindir=[^ ]*::')" sed \ -e 's:-O2::g' \ -e 's:-O3::g' \
Thanks for the report. But I think we need to remove ccbin as it will break otherwise with gcc-4.9. But I will look into it.
+ 19 Sep 2014; Justin Lecher <jlec@gentoo.org> nvidia-cuda-sdk-6.5.14.ebuild: + Fix double definition of c++ compiler, #523142 +