How to configure Makefile build targets in subdirectories
I'm running CLion 2023.2.2 on a Macbook Pro, and using the remote development facility to copy and build the code on a Linux box. My team's main C++ project is set up roughly like this:
root
Makefile
component1
Makefile
[source files]
unittest
Makefile
[unit tests]
component2
[more of the same]
[more components like that]
When I run a build via the all target, everything builds fine. The top-level makefile also has a check target which builds and runs the unit tests, and I have that also set up as a build configuration and it works too. However, it takes a long time so what I want is to have build configurations for the individual unittest directories, either for the check targets in the makefiles or the individual test targets. I cannot for the life of me figure out a way to do this with CLion.
The other problem I'm having, undoubtedly related, is that when I'm working on the unit tests, I get the banner across the top that says “This file does not belong to any project target; code insight features might not work properly” and indeed they don't.
Please sign in to leave a comment.