jaffer
jaffer

Reputation: 1

esp32 compiles helloworld example on windows with powershell and reports ninja error

esp32 compiles helloworld example on windows and reports ninja error

I just configured the esp32 compilation environment on windows with powershell, and then tested it;

My compilation environment configuration is as follows:

  1. git clone esp-idf project
  2. git checkout v5.0.1
  3. Open powershell and run ./install.bat
  4. Run ./export.ps1 to import environment variables
  5. Enter the helloworld example directory, the relative path is "esp-idf\examples\get-started\hello_world"
  6. After running idf.py build, ninja reports an error, and the error message is as follows:
Executing action: all (aliases: build)
Running ninja in directory e:\esp-idf\esp-idf\examples\get-started\hello_world\build
Executing "ninja all"...
ninja: error: 'E:/esp-idf/esp-idf/components/esp_wifi/lib/esp32/libcoexist.a', needed by 'hello_world.elf', missing and no known rule to make it
ninja failed with exit code 1, output of the command is in the e:\esp-idf\esp-idf\examples\get-started\hello_world\build\log\idf_py_stderr_output_7424 and e:\esp-idf\esp-idf\examples\get-started\hello_world\build\log\idf_py_stdout_output_7424
PS E:\esp-idf\esp-idf\examples\get-started\hello_world> idf.py build
Executing action: all (aliases: build)
Running ninja in directory e:\esp-idf\esp-idf\examples\get-started\hello_world\build
Executing "ninja all"...
ninja: error: 'E:/esp-idf/esp-idf/components/esp_wifi/lib/esp32/libcoexist.a', needed by 'hello_world.elf', missing and no known rule to make it
ninja failed with exit code 1, output of the command is in the e:\esp-idf\esp-idf\examples\get-started\hello_world\build\log\idf_py_stderr_output_25140 and e:\esp-idf\esp-idf\examples\get-started\hello_world\build\log\idf_py_stdout_output_25140

Is it possible to configure the environment through the powershell command on windows, and then it will be compiled and not supported? it shouldn't be

Upvotes: 0

Views: 127

Answers (1)

jaffer
jaffer

Reputation: 1

I solved thid problem by doing the following:

After switching to the v5.1 branch, you need to use git pull to update the branch content. and then run ./install.bat to install environment.

Upvotes: 0

Related Questions