Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Check if pico-vscode.cmake file exists #65

Merged
merged 2 commits into from
Sep 9, 2024

Conversation

Mr-Bossman
Copy link
Contributor

Check if pico-vscode.cmake file exists to allow sharing vscode based projects with others that do not have the extension installed.

f"include({cmakeIncPath()})\n"
f"set(picoVscode {cmakeIncPath()})\n"
"if (EXISTS ${picoVscode})\n"
" include(${picoVscode})\n"
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@will-v-pi it would be nice to set the PICO_PLATFORM in the main CMakeLists.txt too as it allows projects that use riscv to be shared with others that do not have the extension installed.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think I'd prefer to stick to defaulting the pico platform based off the board (as the SDK does), and only changing it to Risc-V when using a Risc-V toolchain. For projects that require Risc-V and may have users not using the extension, they can add this to their CMakeLists.txt file to set the platform

if (NOT DEFINED PICO_PLATFORM)
    set(PICO_PLATFORM rp2350-riscv CACHE STRING "Pico Platform")
endif()

Copy link
Collaborator

@will-v-pi will-v-pi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you also update the cmakeUpdateSDK function in src/utils/cmakeUtil.mts to match this change? Other than that I'm happy to merge this

Check if pico-vscode.cmake file exists to allow sharing vscode based
projects with others that do not have the extension installed.

Signed-off-by: Jesse Taube <[email protected]>
Copy link
Collaborator

@will-v-pi will-v-pi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks - I'll merge this now

@will-v-pi will-v-pi merged commit adf88ba into raspberrypi:main Sep 9, 2024
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants