mirror of
https://git.in.rschanz.org/ryan77627/guix.git
synced 2024-11-07 23:46:13 -05:00
gnu: clang-from-llvm: Fix building on riscv64-linux.
* gnu/packages/llvm.scm (clang-from-llvm)[arguments]: When building for riscv64-linux add configure-flags and make-flags to ensure linking with '-latomic'.
This commit is contained in:
parent
a5f4c03df1
commit
926fcb488b
1 changed files with 9 additions and 1 deletions
|
@ -216,7 +216,15 @@ (define* (clang-from-llvm llvm clang-runtime
|
|||
;; Use a sane default include directory.
|
||||
(string-append "-DC_INCLUDE_DIRS="
|
||||
(assoc-ref %build-inputs "libc")
|
||||
"/include"))
|
||||
"/include")
|
||||
,@(if (target-riscv64?)
|
||||
(list "-DLIBOMP_LIBFLAGS=-latomic"
|
||||
"-DCMAKE_SHARED_LINKER_FLAGS=-latomic")
|
||||
`()))
|
||||
|
||||
,@(if (target-riscv64?)
|
||||
`(#:make-flags '("LDFLAGS=-latomic"))
|
||||
'())
|
||||
|
||||
;; Don't use '-g' during the build to save space.
|
||||
#:build-type "Release"
|
||||
|
|
Loading…
Reference in a new issue