[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
Re: [tor-bugs] #9869 [Tor]: configure runs tests with wrong tools for --host if suitable tools are not in $PATH
#9869: configure runs tests with wrong tools for --host if suitable tools are not
in $PATH
-------------------------+-------------------------------------------------
Reporter: sqrt2 | Owner:
Type: defect | Status: needs_review
Priority: normal | Milestone: Tor: 0.2.5.x-final
Component: Tor | Version: Tor: unspecified
Resolution: | Keywords: armv6 curve25519 build tor-relay
Actual Points: | 024-backport
Points: | Parent ID:
-------------------------+-------------------------------------------------
Changes (by sqrt2):
* status: reopened => needs_review
Comment:
The core of the issue is that autoconf is fairly bad at detecting whether
it's cross compiling and has some strange attitudes about when to warn and
when to error.
Unless the user explicitly specifies --host ''and'' --build, it will say
cross_compiling=maybe.
AC_CHECK_TOOL actually detects that it could not find a properly named
tool, and will print a warning, but only if cross_compiling==yes. We can
cleanly check for whether that warning has been issued and error with a
helpful error message instead.
If cross_compiling==maybe however, things get ugly. As soon as AC_PROG_CC
is run, autoconf will try to verify that it is cross-compiling by building
a program and AC_TRY_RUN it. Because it will find any compiler on the
system, however, it will also find the standard, non-cross, compiler, and
come to the wrong conclusion cross_compiling=no. Since we check for the
correct ar before running AC_PROG_CC, we can perform the same check that
it would normally lead it to printing a warning and error with a helpful
warning message instead. (I would argue that autoconf should at least warn
here by default.)
The patch I have posted above will implement this and give the user the
option to --disable-tool-name-check to skip this test and continue with
the tools found by AC_CHECK_TOOL.
--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/9869#comment:6>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online
_______________________________________________
tor-bugs mailing list
tor-bugs@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-bugs