Improve handling of wrapper with undefined reference.