yse / easy_profiler

Lightweight profiler library for c++
MIT License
2.18k stars 189 forks source link

Profiler API common function names conflict with other libraries #215

Closed kevswims closed 1 month ago

kevswims commented 2 months ago

Since the core API in https://github.com/yse/easy_profiler/blob/develop/easy_profiler_core/include/easy/profiler.h is inside an extern "C" block, any functions declared that match the function names of another library will cause linking to fail.

In our particular case, the now and version functions are conflicting with the same functions in libsystemd.

There is a PR here https://github.com/yse/easy_profiler/pull/188 that covers some of these functions but not the now() function.

The posted PR looks like it would fix our issues if the now() function was also renamed. Is there anything blocking that PR or another approach that should be taken to fix this?

yse commented 1 month ago

Thank you for feedback. I've been merged the PR. Check latest develop version. Also merged PR with Qt6 migration