User:Holgersson/work-in-progress/Arduino

Alternative: Write native C or C++ code
Instead of using the Arduino IDE or one of the plenty wrappers in form of makefiles, cmake files, IDE plugins etc. all using the same Arduino processing language you can directly program the AVR microcontroller inside your arduino.

Setup the toolchain
Just setup the toolchain as described above.

Install necessary packages
1. sys-devel/make 2. dev-embedded/avrdude

External references
https://balau82.wordpress.com/2011/03/29/programming-arduino-uno-in-pure-c/