modfied to support xenial and mutiple architecture.