Fix code for GCC.
Add Makefile.