elf2hex
elf2hex copied to clipboard
objcopy verilog output
objcopy can produce verilog output directly from ELF files with "objcopy -O verilog inputfile outputfile".
It's not quite the same sort of output, though:
- We need it all in one blob, objcopy's verilog backend is sparse.
- It only supports one bit width (or at least did last time I checked).
IIRC I actually own the bug to fix these on sourceware.org :)
On my side I fixed the issue by generating an intelhex output from objcopy and then converting it to "readmemh" compatible file with a Python script.