Commit 0fa8f6cb authored by Michal Berger's avatar Michal Berger Committed by Tomasz Zawadzki
Browse files

scripts/detect_cc: Allow to use llvm linker under clang's LTO build



Change-Id: I542cf9526684a5b9447def7b207f381def275e2e
Signed-off-by: default avatarMichal Berger <michal.berger@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/21766


Tested-by: default avatarSPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: default avatarKonrad Sztyber <konrad.sztyber@intel.com>
Reviewed-by: default avatarJim Harris <jim.harris@samsung.com>
parent a79a8e3f
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -111,8 +111,8 @@ esac
CCAR="ar"
if [ "$LTO" = "y" ]; then
	if [ "$CC_TYPE" = "clang" ]; then
		if [ "$LD_TYPE" != "gold" ]; then
			err "Using LTO with clang requires the gold linker."
		if [[ "$LD_TYPE" != "gold" && "$LD_TYPE" != "lld" ]]; then
			err "Using LTO with clang requires the gold or lld linker."
			exit 1
		fi
		CCAR="llvm-ar"