Azure-Samples / iot-middleware-freertos-samples

This repo has samples for dev kits using the Azure IoT middleware for FreeRTOS
MIT License
76 stars 46 forks source link

CMake configuration/build error for PC Simulation (windows) #353

Closed engemil closed 1 year ago

engemil commented 1 year ago

This issue is for a: (mark with an x)

- [x] bug report -> please search issues before submitting
- [ ] feature request
- [ ] documentation issue or request
- [ ] regression (a behavior that used to work and stopped in a new release)

Minimal steps to reproduce

Installed CMake 3.26.0-rc5 (newest version)

Next in the terminal (VS Code terminal):

git clone <repo>
cd iot-middleware-freertos-samples
git submodule update --init --recursive
cmake -DVENDOR=PC -DCMAKE_GENERATOR_PLATFORM=Win32 -DBOARD=windows -Bbuild_windows . 

(Update: 14.03.2023):

Have tried to install newest Visual Studio with C++ compiler. Doesn't seem to with the "nmake"-problem.

Any log messages given by the failure

CMake Error at CMakeLists.txt:9 (project):
  Generator

    NMake Makefiles

  does not support platform specification, but platform

    Win32

  was specified.

CMake Error: CMAKE_C_COMPILER not set, after EnableLanguage
CMake Error: CMAKE_ASM_COMPILER not set, after EnableLanguage
-- Configuring incomplete, errors occurred!

Expected/desired behavior

To run configuration complete without errors.

OS and Version?

Windows 11

Mention any other details that might be useful

(No)

engemil commented 1 year ago

Problem seem to relate to VS 2022 with the "Desktop Development with C++ workload" option. As it worked fine with VS 2019.