-
Notifications
You must be signed in to change notification settings - Fork 43
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
Patch cargo toolchain for noble #136
Merged
+71
−4
Merged
Changes from all commits
Commits
Show all changes
11 commits
Select commit
Hold shift + click to select a range
dce7bb8
Patch cargo toolchain for noble
Yadunund b421813
Add tmp build for noble job
Yadunund 0f568c8
Try to fix iron
Yadunund af91402
Patch even for iron builds
Yadunund 3edb8e6
Force build with 1.75.0 on jammy
Yadunund 783803a
Update zenoh_c_vendor/CMakeLists.txt
Yadunund a48a0e5
Update zenoh_c_vendor/CMakeLists.txt
Yadunund 5b98e67
Update zenoh_c_vendor/CMakeLists.txt
Yadunund f2be32c
Patch zenoh-c based on cargo toolchain availability
Yadunund 6e70d51
Merge branch 'rolling' into yadu/noble
Yadunund 3f84748
Make patch from zenoh-c PR #301
Yadunund File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
name: build_noble | ||
on: | ||
pull_request: | ||
push: | ||
branches: [ rolling ] | ||
workflow_dispatch: | ||
defaults: | ||
run: | ||
shell: bash | ||
jobs: | ||
test: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
docker_image: ['ubuntu:noble-20240225'] | ||
container: | ||
image: ${{ matrix.docker_image }} | ||
timeout-minutes: 30 | ||
steps: | ||
- name: Setup rolling | ||
run: | | ||
apt update && apt install curl -y | ||
curl -sSL https://raw.githubusercontent.com/ros/rosdistro/master/ros.key -o /usr/share/keyrings/ros-archive-keyring.gpg | ||
echo "deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/ros-archive-keyring.gpg] http://packages.ros.org/ros2/ubuntu $(. /etc/os-release && echo $UBUNTU_CODENAME) main" | tee /etc/apt/sources.list.d/ros2.list > /dev/null | ||
apt update && apt install ros-dev-tools -y | ||
apt install ros-rolling-ros-base -y | ||
- uses: actions/checkout@v2 | ||
- name: rosdep | ||
run: | | ||
rosdep init | ||
rosdep update | ||
rosdep install --from-paths . --rosdistro rolling -yir | ||
- name: build | ||
run: | | ||
source /opt/ros/rolling/setup.bash | ||
colcon build |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
diff --git a/CMakeLists.txt b/CMakeLists.txt | ||
index 00aa5ca..d236e99 100644 | ||
--- a/CMakeLists.txt | ||
+++ b/CMakeLists.txt | ||
@@ -27,7 +27,7 @@ declare_cache_var_true_if_vscode(ZENOHC_BUILD_IN_SOURCE_TREE "Do build inside so | ||
declare_cache_var(ZENOHC_BUILD_WITH_LOGGER_AUTOINIT TRUE BOOL "Enable logger-autoinit zenoh-c feature") | ||
declare_cache_var(ZENOHC_BUILD_WITH_SHARED_MEMORY TRUE BOOL "Enable shared-memory zenoh-c feature") | ||
declare_cache_var(ZENOHC_CUSTOM_TARGET "" STRING "Rust target for cross compilation, 'aarch64-unknown-linux-gnu' for example") | ||
-declare_cache_var(ZENOHC_CARGO_CHANNEL "stable" STRING "Cargo channel selected: stable or nightly") | ||
+declare_cache_var(ZENOHC_CARGO_CHANNEL "" STRING "Cargo channel parameter. Should be '+stable', '+nightly' or empty value") | ||
declare_cache_var(ZENOHC_CARGO_FLAGS "" STRING "Additional cargo flags") | ||
declare_cache_var(ZENOHC_LIB_STATIC FALSE BOOL "Alias zenohc::lib target to zenohc::static if TRUE, to zenohc::shared if FALSE") | ||
|
||
@@ -198,8 +198,8 @@ file(GLOB_RECURSE rust_sources "Cargo.toml.in" "src/*.rs" "build.rs" "splitguide | ||
add_custom_command( | ||
OUTPUT ${libs} | ||
COMMAND ${CMAKE_COMMAND} -E echo \"RUSTFLAGS = $$RUSTFLAGS\" | ||
- COMMAND ${CMAKE_COMMAND} -E echo \"cargo +${ZENOHC_CARGO_CHANNEL} build ${cargo_flags}\" | ||
- COMMAND cargo +${ZENOHC_CARGO_CHANNEL} build ${cargo_flags} | ||
+ COMMAND ${CMAKE_COMMAND} -E echo \"cargo ${ZENOHC_CARGO_CHANNEL} build ${cargo_flags}\" | ||
+ COMMAND cargo ${ZENOHC_CARGO_CHANNEL} build ${cargo_flags} | ||
VERBATIM | ||
COMMAND_EXPAND_LISTS | ||
DEPENDS "${rust_sources}" |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is cool! When/how did that happen with rosdep? Or does Noble ship debs for rust build tools?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The debs are available in Jammy too but the versions are very dated so we install them via
rustup
to compile zenoh. Noble ships with cargo/rustc1.75.0
which works out of the box for our use case.