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

Universal examples ignore picotool_DIR setting #531

Open
lurch opened this issue Aug 26, 2024 · 0 comments
Open

Universal examples ignore picotool_DIR setting #531

lurch opened this issue Aug 26, 2024 · 0 comments
Assignees

Comments

@lurch
Copy link
Contributor

lurch commented Aug 26, 2024

If I try and build all of pico-examples with something like this:

cd pico-examples
mkdir build
cd build
cmake .. -DPICO_SDK_PATH=../../pico-sdk -DPICO_RISCV_TOOLCHAIN_PATH=$(realpath ../../corev-openhw-gcc-ubuntu2204-20240530) -DPICO_ARM_TOOLCHAIN_PATH=/usr -Dpicotool_DIR=$(realpath ../../picotool.install/picotool)

(where ../../picotool.install is the location that I've done a "flat install" of picotool into), then when it gets as far as building the universal examples, it says "No installed picotool with version 2.0.0 found - building from source", and then downloads and builds a fresh copy of picotool! 🤦
By looking at https://github.com/raspberrypi/pico-examples/blob/develop/universal/CMakeLists.txt#L55 I was able to get this working with:

cmake .. -DPICO_SDK_PATH=../../pico-sdk -DPICO_RISCV_TOOLCHAIN_PATH=$(realpath ../../corev-openhw-gcc-ubuntu2204-20240530) -DPICO_ARM_TOOLCHAIN_PATH=/usr -Dpicotool_DIR=$(realpath ../../picotool.install/picotool) -Dpicotool_INSTALL_DIR=$(realpath ../../picotool.install)

i.e. by supplying both -Dpicotool_DIR=$(realpath ../../picotool.install/picotool) and -Dpicotool_INSTALL_DIR=$(realpath ../../picotool.install), but that's obviously a bit awkward / unexpected.

(And as an aside, I have to use realpath in a few places, because some parts of the build don't work properly with relative paths?)

will-v-pi added a commit to will-v-pi/pico-examples that referenced this issue Aug 27, 2024
will-v-pi added a commit that referenced this issue Sep 5, 2024
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

No branches or pull requests

3 participants
@lurch @will-v-pi and others