This adds functionality to default CROSS_COMPILE to a sensible value when cross-building (so one doesn't always have to specify this on the make command line), as well as storing ARCH and SUBARCH in the Makefile generated when building outside of the source directory (so that subsequent make invocations don't have to always repeat these). From: Jan Beulich (actual patch attached)