-
Notifications
You must be signed in to change notification settings - Fork 27
Fixes build issues and adds mypy stubs #22
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
Open
bnlerner
wants to merge
6
commits into
2b-t:main
Choose a base branch
from
bnlerner:brian/build-issues
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from 4 commits
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
e366d50
adds script and adds changes to enable multiple version of ubuntu to …
bnlerner 5894c20
adds mypy stubs
bnlerner f43e4e7
fixed implementation of .len vs can_dlc
bnlerner 865d90f
updates some comments
bnlerner 9c62d9f
Update include/myactuator_rmd/can/utilities.hpp
bnlerner f645aa5
Delete install_myactuator_rmd.sh
bnlerner 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 hidden or 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 |
|---|---|---|
| @@ -1,4 +1,4 @@ | ||
| *.pyc | ||
| build/ | ||
| myactuator_rmd_py.egg-info/ | ||
|
|
||
| dist/ |
This file contains hidden or 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 hidden or 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 @@ | ||
| include myactuator_rmd_py.pyi |
This file contains hidden or 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 hidden or 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,67 @@ | ||
| #!/bin/bash | ||
|
|
||
| # install_myactuator_rmd.sh | ||
| # Installs the myactuator_rmd_py package from the current directory. | ||
| # Assumes prerequisites like Python 3, pip, a C++ compiler, and CMake are installed. | ||
|
|
||
| # Exit immediately if a command exits with a non-zero status. | ||
| set -e | ||
|
|
||
| # --- Configuration --- | ||
| # Specify the path to your CMake executable if it's not in the default PATH | ||
| # or if you need a specific version (like the one from snap). | ||
| # Leave empty to use the default 'cmake' found in PATH. | ||
| CMAKE_EXECUTABLE="/snap/bin/cmake" | ||
| # Project directory (assumes the script is run from the project root) | ||
| PROJECT_DIR="$(pwd)" | ||
|
|
||
| # --- Prerequisite Checks --- | ||
| echo "Checking prerequisites..." | ||
|
|
||
| # Check for Python 3 & pip | ||
| if ! command -v python3 &> /dev/null; then | ||
| echo "Error: python3 not found." | ||
| exit 1 | ||
| fi | ||
| if ! python3 -m pip --version &> /dev/null; then | ||
| echo "Error: pip not found for python3." | ||
| exit 1 | ||
| fi | ||
| echo "Python 3 and pip found." | ||
|
|
||
| # Determine CMake command | ||
| if [ -n "$CMAKE_EXECUTABLE" ]; then | ||
| if ! command -v "$CMAKE_EXECUTABLE" &> /dev/null; then | ||
| echo "Error: Specified CMAKE_EXECUTABLE '$CMAKE_EXECUTABLE' not found." | ||
| exit 1 | ||
| fi | ||
| CMAKE_CMD="$CMAKE_EXECUTABLE" | ||
| echo "Using specified CMake: $CMAKE_CMD" | ||
| else | ||
| if ! command -v cmake &> /dev/null; then | ||
| echo "Error: cmake not found in PATH. Install CMake or set CMAKE_EXECUTABLE." | ||
| exit 1 | ||
| fi | ||
| CMAKE_CMD="cmake" | ||
| echo "Using CMake from PATH: $(command -v cmake)" | ||
| fi | ||
|
|
||
| # --- Installation Steps --- | ||
| echo "Starting installation of myactuator_rmd_py..." | ||
|
|
||
| # 1. Install/Upgrade required packages (using --user to match previous successful install) | ||
| echo "Installing/upgrading required packages..." | ||
| python3 -m pip install --upgrade pip wheel build pybind11 setuptools --user | ||
|
|
||
| # 2. Build the wheel | ||
| echo "Building wheel for myactuator_rmd_py from $PROJECT_DIR..." | ||
| export CMAKE_COMMAND="$CMAKE_CMD" | ||
| python3 -m pip wheel . --no-deps -w dist/ | ||
|
|
||
| # 3. Install the wheel | ||
| echo "Installing the wheel..." | ||
| python3 -m pip install --user --force-reinstall dist/myactuator_rmd_py*.whl | ||
|
|
||
| echo "" | ||
| echo "Installation of myactuator_rmd_py completed successfully!" | ||
| exit 0 |
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.
Uh oh!
There was an error while loading. Please reload this page.