libgcrypt: Respect portage host cc variable
Pass CC_FOR_BUILD to econf. Otherwise it invokes gcc instead of portage
specified HOST/BUILD CC.
Gentoo PR: https://github.com/gentoo/gentoo/pull/16151
BUG=chromium:979916, chromium:991812
TEST=CQ
Change-Id: Icf21aab2c3dccd6f17be14e3803d953fd6bacaaf
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/overlays/portage-stable/+/2240123
Tested-by: Manoj Gupta <manojgupta@chromium.org>
Reviewed-by: George Burgess <gbiv@chromium.org>
diff --git a/dev-libs/libgcrypt/libgcrypt-1.8.5.ebuild b/dev-libs/libgcrypt/libgcrypt-1.8.5-r1.ebuild
similarity index 94%
rename from dev-libs/libgcrypt/libgcrypt-1.8.5.ebuild
rename to dev-libs/libgcrypt/libgcrypt-1.8.5-r1.ebuild
index 8dbdb77..183d7c3 100644
--- a/dev-libs/libgcrypt/libgcrypt-1.8.5.ebuild
+++ b/dev-libs/libgcrypt/libgcrypt-1.8.5-r1.ebuild
@@ -3,7 +3,7 @@
EAPI=7
-inherit autotools flag-o-matic multilib-minimal
+inherit autotools flag-o-matic multilib-minimal toolchain-funcs
DESCRIPTION="General purpose crypto library based on the code used in GnuPG"
HOMEPAGE="http://www.gnupg.org/"
@@ -40,6 +40,7 @@
append-cflags -Wa,--divide
fi
local myeconfargs=(
+ CC_FOR_BUILD="$(tc-getBUILD_CC)"
--enable-noexecstack
$(use_enable o-flag-munging O-flag-munging)
$(use_enable static-libs static)