How to find the coverage of a library opened using dlopen()?
问题 I have a C++ library (.so) which is opened using dlopen() by another application. But I need to find the code coverage of this library while run within the application using gcov. Is it possible? If yes, how can it be done? If not, how can the issue be resolved? 回答1: Firstly have your compiled your C++ library with the --coverage flag? I've never actually used a '.so' library with gcov before, so I'm not sure it would work anyway. Secondly could you arrange a test version of your application