diff options
| -rw-r--r-- | meta/classes-global/insane.bbclass | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/meta/classes-global/insane.bbclass b/meta/classes-global/insane.bbclass index 3f26e1e065..b9d11d4910 100644 --- a/meta/classes-global/insane.bbclass +++ b/meta/classes-global/insane.bbclass | |||
| @@ -334,12 +334,12 @@ def package_qa_check_arch(path,name,d, elf, messages): | |||
| 334 | if not elf: | 334 | if not elf: |
| 335 | return | 335 | return |
| 336 | 336 | ||
| 337 | target_os = d.getVar('HOST_OS') | 337 | host_os = d.getVar('HOST_OS') |
| 338 | target_arch = d.getVar('HOST_ARCH') | 338 | host_arch = d.getVar('HOST_ARCH') |
| 339 | provides = d.getVar('PROVIDES') | 339 | provides = d.getVar('PROVIDES') |
| 340 | bpn = d.getVar('BPN') | 340 | bpn = d.getVar('BPN') |
| 341 | 341 | ||
| 342 | if target_arch == "allarch": | 342 | if host_arch == "allarch": |
| 343 | pn = d.getVar('PN') | 343 | pn = d.getVar('PN') |
| 344 | oe.qa.add_message(messages, "arch", pn + ": Recipe inherits the allarch class, but has packaged architecture-specific binaries") | 344 | oe.qa.add_message(messages, "arch", pn + ": Recipe inherits the allarch class, but has packaged architecture-specific binaries") |
| 345 | return | 345 | return |
| @@ -351,12 +351,12 @@ def package_qa_check_arch(path,name,d, elf, messages): | |||
| 351 | 351 | ||
| 352 | #if this will throw an exception, then fix the dict above | 352 | #if this will throw an exception, then fix the dict above |
| 353 | (machine, osabi, abiversion, littleendian, bits) \ | 353 | (machine, osabi, abiversion, littleendian, bits) \ |
| 354 | = oe.elf.machine_dict(d)[target_os][target_arch] | 354 | = oe.elf.machine_dict(d)[host_os][host_arch] |
| 355 | 355 | ||
| 356 | # Check the architecture and endiannes of the binary | 356 | # Check the architecture and endiannes of the binary |
| 357 | is_32 = (("virtual/kernel" in provides) or bb.data.inherits_class("module", d)) and \ | 357 | is_32 = (("virtual/kernel" in provides) or bb.data.inherits_class("module", d)) and \ |
| 358 | (target_os == "linux-gnux32" or target_os == "linux-muslx32" or \ | 358 | (host_os == "linux-gnux32" or host_os == "linux-muslx32" or \ |
| 359 | target_os == "linux-gnu_ilp32" or re.match(r'mips64.*32', d.getVar('DEFAULTTUNE'))) | 359 | host_os == "linux-gnu_ilp32" or re.match(r'mips64.*32', d.getVar('DEFAULTTUNE'))) |
| 360 | is_bpf = (oe.qa.elf_machine_to_string(elf.machine()) == "BPF") | 360 | is_bpf = (oe.qa.elf_machine_to_string(elf.machine()) == "BPF") |
| 361 | if not ((machine == elf.machine()) or is_32 or is_bpf): | 361 | if not ((machine == elf.machine()) or is_32 or is_bpf): |
| 362 | oe.qa.add_message(messages, "arch", "Architecture did not match (%s, expected %s) in %s" % \ | 362 | oe.qa.add_message(messages, "arch", "Architecture did not match (%s, expected %s) in %s" % \ |
