drop AGW fixs from library-branch into master2014

This should make reviewing changes easy for Andrea