Apply Makefile and GCC fixes to 'less-memory' version