
Without extra flags, we would try to use LLVM 13 for cgo and LLVM 14 for
other things since 873412b43a
. That isn't
great. So fix this by only using LLVM 14 in the cgo package.
16 строки
581 Б
Go
16 строки
581 Б
Go
//go:build !byollvm && !llvm13
|
|
// +build !byollvm,!llvm13
|
|
|
|
package cgo
|
|
|
|
/*
|
|
#cgo linux CFLAGS: -I/usr/lib/llvm-14/include
|
|
#cgo darwin,amd64 CFLAGS: -I/usr/local/opt/llvm@14/include
|
|
#cgo darwin,arm64 CFLAGS: -I/opt/homebrew/opt/llvm@14/include
|
|
#cgo freebsd CFLAGS: -I/usr/local/llvm14/include
|
|
#cgo linux LDFLAGS: -L/usr/lib/llvm-14/lib -lclang
|
|
#cgo darwin,amd64 LDFLAGS: -L/usr/local/opt/llvm@14/lib -lclang -lffi
|
|
#cgo darwin,arm64 LDFLAGS: -L/opt/homebrew/opt/llvm@14/lib -lclang -lffi
|
|
#cgo freebsd LDFLAGS: -L/usr/local/llvm14/lib -lclang
|
|
*/
|
|
import "C"
|