Skip to content

Commit

Permalink
cuda.eclass: fix 'gcc-bindir -f' output to not use '=' in opt
Browse files Browse the repository at this point in the history
The '=' with the "" around the bindir are causing a "not a valid
directory" error while compiling with cuda support.

It now works as expected: with gcc-5.4.0 and cuda 7.5 NVCCFLAGS are set
properly to gcc-4.9.x

Closes: gentoo#3013
  • Loading branch information
Syderitic authored and mgorny committed Dec 20, 2016
1 parent d090017 commit 64263f4
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions eclass/cuda.eclass
Original file line number Diff line number Diff line change
Expand Up @@ -31,15 +31,15 @@ if [[ -z ${_CUDA_ECLASS} ]]; then

# @FUNCTION: cuda_gccdir
# @USAGE: [-f]
# @RETURN: gcc bindir compatible with current cuda, optionally (-f) prefixed with "--compiler-bindir="
# @RETURN: gcc bindir compatible with current cuda, optionally (-f) prefixed with "--compiler-bindir "
# @DESCRIPTION:
# Helper for determination of the latest gcc bindir supported by
# then current nvidia cuda toolkit.
#
# Example:
# @CODE
# cuda_gccdir -f
# -> --compiler-bindir="/usr/x86_64-pc-linux-gnu/gcc-bin/4.6.3"
# -> --compiler-bindir "/usr/x86_64-pc-linux-gnu/gcc-bin/4.6.3"
# @CODE
cuda_gccdir() {
debug-print-function ${FUNCNAME} "$@"
Expand All @@ -55,7 +55,7 @@ cuda_gccdir() {
while [ "$1" ]; do
case $1 in
-f)
flag="--compiler-bindir="
flag="--compiler-bindir "
;;
*)
;;
Expand Down

0 comments on commit 64263f4

Please sign in to comment.