In fact you could compile your code directly from Linux. Which image are you using? If you are using the uclibc image, you have to download the packagegroup-core-buildessential package from AlexT's repo as well as gcc, g++ or any other compiler you need, MRAA can also be downloaded from AlexT's repo.
If you are using the eglibc image, all the stuff needed to compile should already be there.
To compile a C code on Linux you will have to:
- Create a file with the code: vi test.c
- Compile the code with gcc: gcc test.c -o test -lmraa
- Run the code with: ./test
To update the packages on the eglibc image (including MRAA) you can follow this guide: IoT - Upgrading Intel® IoT Developer Kit libraries – Intel® Edison or Intel® Galileo board | Intel® Developer Zone