Request for explanation regarding cmake invocation in windows
Closed this issue · 3 comments
I'm building qtprotobuf
for the first time for Windows10.
When (following the instructions in the README) I called cmake --build
, it complained The syntax of the command is incorrect
until I removed the trailing -- /m:<N>
. Perhaps a one-line explanation of why that switch is included would be useful to help me and others understand its significance.
Hi @gmabey , /m:<N>
is the jom analog of the gmake/ninja generator -j<N>
option, so it might not work if you use a different CMake generator than VS's jom. Also, please make sure you replaced the <N>
expression with the desired amount of the building threads. Aaaaand you may simply use the --parallel CMake option to set the number of building threads to the estimated maximum for your system. Hope this helps :)
Thank you for that explanation. I think I would suggest that (even if you use that switch for internal builds) you remove it from the README so that there's no need to make that explanation. Like, it's an optimization, and probably (when used by others) will lead to more confusion than benefit.
Agree, some points are for me as well, it's quite hard to remember some steps/options after not touching the project for a while.