How to compile a project from console

Is it possible to start compilation of a CLion cmake project from console?

My goal is to compile my project over ssh, where I have no GUI access, but I just want to compile the changes I have made to the project via git.

Thanks in advance

3 comments
Comment actions Permalink

I not fully understood the question, but maybe this:

cmake /path/to/project && make -j4
0
Comment actions Permalink

Oh ok, but will this compile to the same location where Clion compiles into?

0
Comment actions Permalink

No, to set build location set flag --build like this:

cmake /path/to/build --build /path/to/project && make

for example CLion execute command for build my project:

/home/dev/Soft/clion/bin/cmake/bin/cmake --build /home/dev/.CLion2016.2/system/cmake/generated/e2dit-db4f164d/db4f164d/Debug --target all -- -j 4

I think names e2dit-db4f164d and db4f164d are temporary

1

Please sign in to leave a comment.