You dont need to have two installations. This might be overkill if youre only building once every so often, but you can set up build tasks (simple shell script on mac) to launch parallels, wait for it to load, then launch win11, wait for it to load, then map a temporary network drive to your current folder (this is just because msbuild has problems with building from network locations) and then launch the project.
Or, if you want to just make a local style ci/cd you can just run cmake instead from that folder and wait for it to finish and close parallels and build the mac version after or before.