I would like to decompile a 32-bit Linux executable to C, modify some parts of it, and then compile it back. I do not care if the C code is not pretty and really hard to maintain. The only thing I care is to be able to compile it back to a 32-bit executable.

The program was written in C++ around 2006, but the source code was lost since then. It is not a small program, and it uses some dynamically linked libraries as well.

I tried Boomerang and Avast RetDec. None of them is able to provide a compilable result, but the one RetDec provides, is sometimes surprisingly readable. Unfortunately, I can not use this output to rewrite the project, because the code is really long. That is why I am looking for a way to produce compilable C code in the first place.

  • 3
    How complex are the changes you need to make? It might be more practical to identify the parts you need to change and patch the existing binary rather than try and recompile everything.
    – Rup
    Mar 11, 2019 at 11:02

1 Answer 1


Unfortunately no, there is no such decompiler publicly available. All decompilers have to guess the missing information and just one wrong answer is enough to spoil the result. Second, re-compilability is often not the goal.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.