No description
8b467844e1
gentpl.py is python2/3-agnostic, but there's no way to cause it to be run with any interpreter other than 'python', it's just hard-coded into Makefile.common that way. Adjust that to use AM_PATH_PYTHON (provided by automake) to find an interpreter and run gentpl.py with that instead. This makes grub buildable when `python` does not exist (but rather `python3` or `python2` or `python2.7`, etc.) Minimum version is set to 2.6 as this is the first version with `__future__.print_function` available. Note, AM_PATH_PYTHON respects the PYTHON environment variable and will treat its value as the *only* candidate for a valid interpreter if it is set - when PYTHON is set, AM_PATH_PYTHON will not try to find any alternative interpreter, it will only check whether the interpreter set as the value of PYTHON meets the requirements and use it if so or fail if not. This means that when using grub's `autogen.sh`, as it too uses the value of the PYTHON environment variable (and if it is not set, just sets it to 'python') you cannot rely on AM_PATH_PYTHON interpreter discovery. If your desired Python interpreter is not just 'python', you must set the PYTHON environment variable, e.g. 'PYTHON=/usr/local/bin/python3 ./autogen.sh'. The specified interpreter will then be used both by autogen.sh itself and by the autotools-driven build scripts. Signed-off-by: Adam Williamson <awilliam@redhat.com> Reviewed-by: Daniel Kiper <daniel.kiper@oracle.com> |
||
---|---|---|
asm-tests | ||
build-aux | ||
conf | ||
docs | ||
grub-core | ||
include | ||
m4 | ||
po | ||
tests | ||
themes/starfield | ||
unicode | ||
util | ||
.gitignore | ||
ABOUT-NLS | ||
acinclude.m4 | ||
AUTHORS | ||
autogen.sh | ||
BUGS | ||
ChangeLog-2015 | ||
config.h.in | ||
configure.ac | ||
COPYING | ||
coreboot.cfg | ||
geninit.sh | ||
gentpl.py | ||
INSTALL | ||
linguas.sh | ||
Makefile.am | ||
Makefile.util.def | ||
NEWS | ||
README | ||
THANKS | ||
TODO |
This is GRUB 2, the second version of the GRand Unified Bootloader. GRUB 2 is rewritten from scratch to make GNU GRUB cleaner, safer, more robust, more powerful, and more portable. See the file NEWS for a description of recent changes to GRUB 2. See the file INSTALL for instructions on how to build and install the GRUB 2 data and program files. Please visit the official web page of GRUB 2, for more information. The URL is <http://www.gnu.org/software/grub/grub.html>. More extensive documentation is available in the Info manual, accessible using 'info grub' after building and installing GRUB 2. There are a number of important user-visible differences from the first version of GRUB, now known as GRUB Legacy. For a summary, please see: info grub Introduction 'Changes from GRUB Legacy'