Code Monkey home page Code Monkey logo

Comments (11)

kilograham avatar kilograham commented on June 30, 2024 4

you need to run it from a visual studio developer command prompt (or whatever it is called)

from pico-sdk.

lurch avatar lurch commented on June 30, 2024 2

Just for the sake of completeness (not that it really matters, because our instructions say to use nmake), but it turns out that the problem with ninja is that GCC outputs dependency-information in a slightly-incorrect format that ninja can't understand.
https://gitlab.kitware.com/cmake/cmake/-/issues/21997#note_929924

EDIT: ...which in turn has been fixed in the master version of ninja, ninja-build/ninja#1774 but seems like it isn't yet included in a released-version of ninja.

from pico-sdk.

eriklundh avatar eriklundh commented on June 30, 2024 2

The fix for ninja-build/ninja#1774 are included in ninja release 1.10.1 and later

from pico-sdk.

Bazz-Man avatar Bazz-Man commented on June 30, 2024 1

I think there is a problem with the ninja CMake generator and pico-examples, can you try setting "NMake Makefiles" as the preferred/default build generator in CMake plugin settings?

Excellent, that fixed it, many thanks kilograham :). So for everyone else, you need to add the "NMake Makefiles" to the Settings tab of the extension under the entry labelled:
Cmake: Generator
The CMake generator to use

Should look like this
image

from pico-sdk.

kilograham avatar kilograham commented on June 30, 2024 1

Also if you are using VS Code on something other than Windows you likely need to change this to "Unix Makefiles"

from pico-sdk.

aallan avatar aallan commented on June 30, 2024 1

I've now updated the documentation to reflect this, will be available in the next docs release expected today.

from pico-sdk.

kilograham avatar kilograham commented on June 30, 2024

I think there is a problem with the ninja CMake generator and pico-examples, can you try setting "NMake Makefiles" as the preferred/default build generator in CMake plugin settings?

from pico-sdk.

realjanek avatar realjanek commented on June 30, 2024

'nmake' is not recognized as an internal or external command,
operable program or batch file.

I follow the instructions in pdf running on Windows. All good until trying to run nmake.

D:\2021\RpiPico\pico-examples\build>cmake -G "NMake Makefiles" ..
Using PICO_SDK_PATH from environment ('....\pico-sdk')
Pico SDK is located at D:/2021/RpiPico/pico-sdk
Defaulting PICO_PLATFORM to rp2040 since not specified.
Defaulting PICO platform compiler to pico_arm_gcc since not specified.
-- Defaulting build type to 'Release' since not specified.
PICO compiler is pico_arm_gcc
PICO_GCC_TRIPLE defaulted to arm-none-eabi
-- The C compiler identification is GNU 10.2.1
-- The CXX compiler identification is GNU 10.2.1
-- The ASM compiler identification is GNU
-- Found assembler: C:/Program Files (x86)/GNU Arm Embedded Toolchain/10 2020-q4-major/bin/arm-none-eabi-gcc.exe
Defaulting PICO target board to pico since not specified.
Using board configuration from D:/2021/RpiPico/pico-sdk/src/boards/include/boards/pico.h
-- Found Python3: C:/Python38/python.exe (found version "3.8.7") found components: Interpreter
TinyUSB available at D:/2021/RpiPico/pico-sdk/lib/tinyusb/src/portable/raspberrypi/rp2040; adding USB support.
-- Could NOT find Doxygen (missing: DOXYGEN_EXECUTABLE)
ELF2UF2 will need to be built
PIOASM will need to be built
-- Configuring done
-- Generating done
-- Build files have been written to: D:/2021/RpiPico/pico-examples/build

D:\2021\RpiPico\pico-examples\build>nmake
'nmake' is not recognized as an internal or external command,
operable program or batch file.

from pico-sdk.

realjanek avatar realjanek commented on June 30, 2024

you need to run it from a visual studio developer command prompt (or whatever it is called)

Thanks a lot. It works. You save me a lot of time and headaches. I still have to figure out how to use VSCode. Is it possible to use J-Link for debugging on Windows?

from pico-sdk.

vishnumaiea avatar vishnumaiea commented on June 30, 2024

I've now updated the documentation to reflect this, will be available in the next docs release expected today.

You may also have to specify not to skip installing the Windows 10 SDK from VS build tool installation step. Because not installing the SDK will cause NMAKE to fail. Installing the Windows 10 SDK solved an error I encountered later.

from pico-sdk.

aallan avatar aallan commented on June 30, 2024

I'll add a note to the Getting Started book to this effect.

from pico-sdk.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.