Sunday, September 25, 2011

Include into assembler files .h files with definitions

This very general question how to incorporate C and Assembler. Bcoz sometimes you have many C sources and headers and you need rewrite something on assembler. Everybody knows about inline assembler in gcc. But not many knows that you can write into assembler and include some of required .h files. Linux kernel has some examples, but they not easy to look. I found some good explanation on ARM site [1] and adopt it for gcc