Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Doxygen and Assembly Language

I'd like to use Doxygen to document legacy code that's a mix of C and x86 assembly language. The assembly language is not inline, but in separate assembly-only files. How can I document the assembly language portion?

like image 857
bitFlipper Avatar asked Jan 25 '23 00:01

bitFlipper


2 Answers

Question 12 of the Doxygen FAQ eventually led me to a Perl filter that looks promising. It converts the assembly code into something C-like that Doxygen can parse. Thanks!

The original link appears to be dead. However back in 2008, I had pulled down a copy of asm4doxy.pl and squirreled it away. I've put it up on Pastebin if anyone is still interested. As I recall, I tried it, but it didn't really work for me at the time, but YMMV.

like image 84
bitFlipper Avatar answered Feb 01 '23 22:02

bitFlipper


See question 12 of the Doxygen FAQ. Are you dealing with pure assembly files, or inline assembly inside C sources? Assuming the former, you'll have to either write an input filter to transform the assembly code into something C-like (easier), or write a new parser (much harder).

like image 29
Adam Rosenfield Avatar answered Feb 01 '23 22:02

Adam Rosenfield