Modify Makefile. Misc config+adv. Fix warnings.