ThrowTheSwitch / Ceedling

Ruby-based unit testing and build system for C projects
http://throwtheswitch.org
Other
579 stars 243 forks source link

ceedling utils:gcov fails #649

Open prabodini opened 2 years ago

prabodini commented 2 years ago

Im trying to create an html report for the test coverage using gcov.

I can successfully run

  1. ceedling clean
  2. ceedling test:all
  3. ceedling gcov:all

But ceedling utils:gcov fail with the following error message.

_rake aborted!
Errno::ENOENT: No such file or directory - gcovr --version
C:/Ruby30-x64/bin/ceedling:25:in `load'
C:/Ruby30-x64/bin/ceedling:25:in `<main>'
Tasks: TOP => utils:gcov
(See full trace by running task with --trace)
ERROR: Ceedling Failed_

The ceedling version I have, Ceedling:: 0.31.1 Unity:: 2.5.4 CMock:: 2.5.4 CException:: 1.3.3

dpostorivo commented 2 years ago

Do you have gcovr installed? Double check the readme here for install instructions if you need them: https://github.com/ThrowTheSwitch/Ceedling/tree/master/plugins/gcov

prabodini commented 2 years ago

Do you have gcovr installed? Double check the readme here for install instructions if you need them: https://github.com/ThrowTheSwitch/Ceedling/tree/master/plugins/gcov

I have gcovr installed. (using pip install gcovr)

sudamj commented 2 years ago

Do you have gcovr installed? Double check the readme here for install instructions if you need them: https://github.com/ThrowTheSwitch/Ceedling/tree/master/plugins/gcov

I have gcovr installed. (using pip install gcovr)

I have exactly the same issue. My environment is cygwin

lukzeg commented 1 year ago

Hi @prabodini ,

Do I ask you for maybe giving me more information on what your setup looks like on a Windows machine? I'm trying to reproduce your issue on a Windows machine.

I have installed python3 with gcovr. As well I'm using mingw64 with installed gcc and gdb. Unfortunately, I'm not able to produce your issue.

@sudamj : Did you installed gcovr under pure Windows or under Cygwin?

prabodini commented 1 year ago

Hi @lukzeg It's been a while and I don't think I had gdb installed. I will try it again

TinyTed58 commented 1 year ago

Did anyone find a fix for this?

pjensen-addco commented 4 months ago

Raising this post up from the dead for those who might run across this issue: You might have different python interpreters that are installed on your machine, and thus pip install gcovr is installing it in the wrong Python interpreter.

I had several python interpreters installed. I am unsure of how to tell which python interpreter GCOV is attempting to call, but for me:

py -m pip install gcovr

worked.

danmcb commented 2 weeks ago

for me this issue was solved by installing gcovr with apt, not with pip ("which gcovr" should find gcovr)