updated compile-instructions and improved aff detection process