diff options
author | Javier Jardón <javier.jardon@codethink.co.uk> | 2015-04-22 19:29:56 +0100 |
---|---|---|
committer | Javier Jardón <jjardon@gnome.org> | 2015-04-28 14:09:07 +0100 |
commit | 154a760fb884cee14c2604b8bfbe52b0e7c0d4b1 (patch) | |
tree | 46e97e44614352f90139db557432a8fcc76b43c7 /morphlib/buildcommand.py | |
parent | fa5c470ad5dd3a3416217363983eb3795ef53c79 (diff) | |
download | morph-154a760fb884cee14c2604b8bfbe52b0e7c0d4b1.tar.gz |
Add armv5l to list of valid architectures
Also add support to allow building compatible architectures on armv7
machines, as per the rationale in the comment in
_validate_architecture().
Change-Id: Ie0fe4002523f1f92f576bac8b654d4ea6fad5cf2
Diffstat (limited to 'morphlib/buildcommand.py')
-rw-r--r-- | morphlib/buildcommand.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/morphlib/buildcommand.py b/morphlib/buildcommand.py index fd5acdf5..37dccf82 100644 --- a/morphlib/buildcommand.py +++ b/morphlib/buildcommand.py @@ -141,6 +141,12 @@ class BuildCommand(object): if host_arch == 'armv8b' and root_arch in ('armv7b', 'armv7bhf'): return + # Since the armv7 instruction set is nearly entirely armv5 compatible, + # and since the incompatibilities are appropriately trapped in the + # kernel, we can safely run any armv5 toolchain natively on armv7. + if host_arch in ('armv7l', 'armv7lhf') and root_arch in 'armv5l': + return + raise morphlib.Error( 'Are you trying to cross-build? Host architecture is %s but ' 'target is %s' % (host_arch, root_arch)) |