hrvach/deskhop

Directory 'path/to/pico-sdk' not found error appears oddly.

Walkline80 opened this issue · 3 comments

Here is my operation steps:

The deskhop and esp32 folders are in sibling directories.

$ cd deskhop
$ PICO_SDK_PATH=/esp32/micropython/lib/pico-sdk/ cmake -S . -B build

Of cause the cmake give me an error message:

CMake Error at pico_sdk_import.cmake:52 (message):
  Directory '/esp32/micropython/lib/pico-sdk' not found

And then correct the wrong path:

$ PICO_SDK_PATH=~/esp32/micropython/lib/pico-sdk/ cmake -S . -B build

But, the cmake still give me an error message, exactly the same as the above, even the ~ not appears.

Then, I have to remove the build folder inside deskhop and execute the command again:

$ rm -rf build
$ PICO_SDK_PATH=~/esp32/micropython/lib/pico-sdk/ cmake -S . -B build

This time the cmake will success, I think it's a cmake script issue?

Providing the wrong path in the PICO_SDK_PATH will make CMakeCache.txt cache it, I think you can provide --fresh if you want it to update the variable.

pico sdk is now bundled and you no longer need to provide sdk path variable, so considering resolved.

Thanks for the update, this improves a lot of efficiency and also saves a lot of hard drive space.