[Bug 44311] Boomerang 0.3.x decompiler fails to load ARM binaries, reports 'GetMachine: Unsupported machine type: 40 (0x28)'

wine-bugs at winehq.org wine-bugs at winehq.org
Sat Jan 6 19:27:20 CST 2018


https://bugs.winehq.org/show_bug.cgi?id=44311

Anastasius Focht <focht at gmx.net> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |download, source
             Status|NEEDINFO                    |RESOLVED
         Resolution|---                         |INVALID
                 CC|                            |focht at gmx.net
                URL|                            |http://boomerang.sourceforg
                   |                            |e.net/download.php
            Summary|Boomerang decompiler issue  |Boomerang 0.3.x decompiler
                   |                            |fails to load ARM binaries,
                   |                            |reports 'GetMachine:
                   |                            |Unsupported machine type:
                   |                            |40 (0x28)'

--- Comment #4 from Anastasius Focht <focht at gmx.net> ---
Hello Mega,

the app works as expected.

It seems you don't understand the limitations of the app.

--- snip ---
Error: ElfBinaryFile :: GetMachine: Unsupported machine type: 40 (0x28)
--- snip ---

This is output from the app, not Wine.

You are trying to decompile binaries for the ARM architecture which the app
doesn't support. Look at the source code of the app if in doubt.

$ svn checkout https://svn.code.sf.net/p/boomerang/code/trunk boomerang-code

boomerang-code/boomerang/loader/ElfBinaryFile.cpp:852

--- snip ---
...
MACHINE ElfBinaryFile::GetMachine() const
{
    int machine = elfRead2(&((Elf32_Ehdr*) m_pImage)->e_machine);
    if ((machine == EM_SPARC) || (machine == EM_SPARC32PLUS)) return
MACHINE_SPARC;
    else if (machine == EM_386) return MACHINE_PENTIUM;
    else if (machine == EM_PA_RISC) return MACHINE_HPRISC;
    else if (machine == EM_68K) return MACHINE_PALM; // Unlikely
    else if (machine == EM_PPC) return MACHINE_PPC;
    else if (machine == EM_ST20) return MACHINE_ST20;
    else if (machine == EM_MIPS) return MACHINE_MIPS;
    else if (machine == EM_X86_64)
        {
            std::cerr << "Error: ElfBinaryFile::GetMachine: The AMD x86-64
architecture is not supported yet\n";
            return (MACHINE) - 1;
        }
    // An unknown machine type
    std::cerr << "Error: ElfBinaryFile::GetMachine: Unsupported machine type: "
              << machine << " (0x" << std::hex << machine << ")\n";
    std::cerr << "(Please add a description for this type, thanks!)\n";
    return (MACHINE) - 1;
}
...
--- snip ---

There is nothing to fix here. Decompiling x86 ELF/PE works fine.

$ sha1sum boomerang-win32-alpha-0.3.1.zip 
b9936d0bfbbe4dba884f89257149e3829f7c8b7a  boomerang-win32-alpha-0.3.1.zip

$ du -sh boomerang-win32-alpha-0.3.1.zip 
4.2M    boomerang-win32-alpha-0.3.1.zip

$ wine --version
wine-3.0-rc5

Regards

-- 
Do not reply to this email, post in Bugzilla using the
above URL to reply.
You are receiving this mail because:
You are watching all bug changes.



More information about the wine-bugs mailing list