Port the fixes for the Makefile.ams to 4.2.0. Unit tests are now linking correctly for 4.2.0.