Yep, sorry for the missing info. By the way I'm on Windows major 19044, and I generate the cmake with cmake command from VS 2022 v17.3.6, I don't know if that's the info about the generator.
Anyway, I've managed to get the 32bit of my dll by specifying -A Win32 on the command line while using cmake to generate the project files.
All of this because I'm trying to instrument an application that is 32-bit and, in the first place, I thought that my x64-built dll was the problem but even now with my x86-built dll I'm getting the error "Target process <my\exe\path> is for the wrong architecture>". I've tried both x64 and x86 dll build but still I'm not able to spawn the instrumented process. Any hints?