Quuxplusone / LLVMBugzillaTest

0 stars 0 forks source link

cross-compile configure does not propagate flags to configures run from Makefile #16872

Open Quuxplusone opened 11 years ago

Quuxplusone commented 11 years ago
Bugzilla Link PR16873
Status NEW
Importance P normal
Reported by feep (default_357-line@yahoo.de)
Reported on 2013-08-13 12:18:12 -0700
Last modified on 2013-08-22 20:46:30 -0700
Version 3.2
Hardware PC Linux
CC compnerd@compnerd.org, echristo@gmail.com, geek4civic@gmail.com, llvm-bugs@lists.llvm.org
Fixed by commit(s)
Attachments
Blocks
Blocked by
See also
When configuring LLVM 3.2 for cross compilation, additional flags may be
required (such as --with-python=/usr/bin/python2.7). The generated Makefile
contains a further configure call in cross-compile-build-tools, but this
configure is not aware of the --with-python specified on the command line and
fails.

Reproduce:

1. have an unsupported /usr/bin/python, such as 3.2, and a working version in
/usr/bin/python2.7 or such
2. configure llvm 3.2 for crosscompilation (configure --host=i686-mingw32 --
with-python=/usr/bin/python2.7)
3. make

Make will run further configures, which will be unable to find a working python
and fail.
Quuxplusone commented 11 years ago
I have confirmed on trunk that --with-python is not propagated to
BuildToos/Makefile.config.

I think configure--with-python may be aware of $PYTHON, rather than propagating
--with-python to BuildTools/configure.

To detect python,

1) use --with-python, if specified.
2) consider and honor $PYTHON.
3) detect appropriate version of python in configure.

FYI, I suppose Daniel is working for python scripts to make compatible to py3.