Typical cmake produre here was:
cmake .. -DCMAKE_TOOLCHAIN_FILE=/path/to/vcpkg.cmake
cmake --build .
That worked on both Windows and macOS. But then I noticed it was building in debug mode.
To choose build mode on Windows I did
cmake .. -DCMAKE_TOOLCHAIN_FILE=/path/to/vcpkg.cmake
cmake --build . --config=THEMODE
While on macOS I need to do
cmake .. -DCMAKE_TOOLCHAIN_FILE=/path/to/vcpkg.cmake -DCMAKE_BUILD_TYPE=THEMODE
cmake --build .
Where THEMODE is either Debug/Release.
I bet I'm missing something, isn't? The Cmake is all about Multiplatform, why it works differently to choose build mode on Windows/macOS?