Cleanup C compilation and copy user .[ch] files to compilation dir

This is in preparation for the support of different platforms, especially Android.

Copy all .[ch] files used by the legacy native interface and the gc_chooser.[ch] files to the compilation dir. Allows for local compilation, generated code portability and compatibility with difficult compilation tool chains. Only the output executable may link outside of the compilation dir.

Also cleans up the method in charge of compiling the C code and Makefile. It is now separated in three methods with a clearer use of variables and better readability. This will allow to customize the behavior of the final compilation according to the platform.