Refactored, configured Makefile, added server crash handling.