I’m trying to reduce the build time, hence, I’m experimenting with ccache.
It works fine on ubuntu and decreases build time from about 40 min to less than 10 min.
However, on Windows (MinGW), it says: ccache: error: execv of /C/tools/msys64/mingw64/bin/g++.exe failed: No such file or directory.
The problem is, it takes forever until a new build starts, hence, the commit-build-analyse-cycle is super slow.
I’m currently investigating if the file /C/tools/msys64/mingw64/bin/g++.exe exists, expecting results in a few hours (that’s kind of frustrating…)
No idea what the nexts steps would be. Is ccache supposed to work?
You can check Windows builder snapshot 1809 to see what is preinstalled (as well as environment and registry) in a Windows image without having to run a build every time.
okay, fair enough, I’ve asked that question.
The more interesting question is, however: how can I make it work?
I’ve installed ccache, and cmake finds it. Still i get this error and i have no idea where it comes from, how to debug or how to resolve it. No related issues in the internet.
Now I’m asking kindly for help, since the docs are quite sparse and they literaly say: ask for help in the forum.
Per my questions at Install ccache on Windows there should also be a chocolatey package available. And if your project is not tightly married to ccache, someone there suggested a Mozilla sccache which seems decent from the project README.
I have now abandoned ccache entirely and build my project with multiple cores to meet the 50-minute time limit.
I had to switch from make to ninja, because make does not support parallel build on MinGW, apparently.
So my solution is not to use ccache.
That’s sad, but maybe there is better support for it in the future.
As of today, using ccache in my project is not worth the trouble.
I’m sorry, but I can’t do your job for you (or rather, I can, but not for free) and it’s your job to diagnose problems in 3rd-party software.
I would start from checking that all files exist, and what kind of files they are (e.g. Cygwin emulates symlinks as files with special content), then using Process Monitor to find out what’s happening when the error occurs.
It looks like either your Ccache is a native Windows app and somehow gets fed a MinGW path (that it doesn’t understand) or a simulated symlink (which it doesn’t know how to deal with, either), or that g++ fails to invoke some of its underlying executables or is itself a broken symlink.
No one asked you personally to help me or to do my job.
The docs advised me to ask my question in the forum, hence, if you’re paid by travis, I think it actually is your and your colleagues’ job to help me out.
If you’re a volunteer, I’d kindly thank you very much for your time and help .
I have strong evidence that this is not a 3rd-party software issue, but rather directly linked to the travis build environment because I cannot reproduce the issue on my local system.
Thank you for the debug suggestions, I think this would be a good approach to continue (and, to be clear, I expected no more ).
It is my job to get my project running, I spent the last weekends on that job, now it’s done .
I hope you understand that I have little motivation to solve that ccache issue.
To turn the tables, it’s not my job to debug this very common setup, as the actual problem (i. e., the builds timed out) was solved in a different way (that does not imply it’s your job, though ).