app-editors/hteditor: use ${CHOST}-ar, not ar, gug #722040

AC_PATH_PROG needs absolute path and does not add ${CHOST}
prefix. AC_CHECK_TOOL does the opposite. Use that.

Reported-by: Agostino Sarubbo
Closes: https://bugs.gentoo.org/722040
Package-Manager: Portage-2.3.99, Repoman-2.3.22
Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org>
This commit is contained in:
Sergei Trofimovich
2020-05-10 10:27:12 +01:00
parent c7c59239ba
commit ccdcdc3dcf
2 changed files with 18 additions and 3 deletions
@@ -0,0 +1,14 @@
https://bugs.gentoo.org/722040
--- a/configure.ac
+++ b/configure.ac
@@ -104,8 +104,8 @@ AC_PROG_CPP
AC_PROG_CXX
AC_PROG_YACC
AM_PROG_LEX
-AC_PATH_PROG(AR, ar)
-AC_PATH_PROG(AR, gar)
+AC_CHECK_TOOL(AR, ar)
+AC_CHECK_TOOL(AR, gar)
if test "x$AR" = "x"; then
AC_MSG_ERROR([*** 'ar' and 'gar' missing, please install one of them or fix your \$PATH ***])
@@ -33,6 +33,7 @@ PATCHES=(
"${FILESDIR}"/${P}-gcc-6-uchar.patch
"${FILESDIR}"/${P}-format-security.patch
"${FILESDIR}"/${P}-gcc-10.patch
"${FILESDIR}"/${P}-AR.patch
)
src_prepare() {
@@ -46,9 +47,9 @@ src_configure() {
--enable-maintainermode
}
src_compile() {
emake AR="$(tc-getAR)" CFLAGS="${CFLAGS}" CXXFLAGS="${CXXFLAGS}"
}
#src_compile() {
# emake AR="$(tc-getAR)" CFLAGS="${CFLAGS}" CXXFLAGS="${CXXFLAGS}"
#}
src_install() {
#For prefix