mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2025-01-31 12:41:49 +01:00
[cmake] pass GO_EXECUTABLE to llgo-go
Summary: When calling llgo-go from the llvm_add_go_executable cmake function, specify $GO_EXECUTABLE as the go command to call. Without this, llgo-go searches $PATH which may be inconsistent with $GO_EXECUTABLE. Reviewers: pcc Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D11290 llvm-svn: 242749
This commit is contained in:
parent
f446b9894e
commit
d655ae71f1
@ -825,7 +825,7 @@ function(llvm_add_go_executable binary pkgpath)
|
|||||||
endforeach(d)
|
endforeach(d)
|
||||||
set(ldflags "${CMAKE_EXE_LINKER_FLAGS}")
|
set(ldflags "${CMAKE_EXE_LINKER_FLAGS}")
|
||||||
add_custom_command(OUTPUT ${binpath}
|
add_custom_command(OUTPUT ${binpath}
|
||||||
COMMAND ${CMAKE_BINARY_DIR}/bin/llvm-go "cc=${cc}" "cxx=${cxx}" "cppflags=${cppflags}" "ldflags=${ldflags}"
|
COMMAND ${CMAKE_BINARY_DIR}/bin/llvm-go "go=${GO_EXECUTABLE}" "cc=${cc}" "cxx=${cxx}" "cppflags=${cppflags}" "ldflags=${ldflags}"
|
||||||
${ARG_GOFLAGS} build -o ${binpath} ${pkgpath}
|
${ARG_GOFLAGS} build -o ${binpath} ${pkgpath}
|
||||||
DEPENDS llvm-config ${CMAKE_BINARY_DIR}/bin/llvm-go${CMAKE_EXECUTABLE_SUFFIX}
|
DEPENDS llvm-config ${CMAKE_BINARY_DIR}/bin/llvm-go${CMAKE_EXECUTABLE_SUFFIX}
|
||||||
${llvmlibs} ${ARG_DEPENDS}
|
${llvmlibs} ${ARG_DEPENDS}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user