Skip to content

Commit

Permalink
find lib helper
Browse files Browse the repository at this point in the history
  • Loading branch information
atticusrussell committed Jun 20, 2023
1 parent bd2057b commit 15d443f
Show file tree
Hide file tree
Showing 2 changed files with 37 additions and 19 deletions.
34 changes: 17 additions & 17 deletions .github/workflows/ci-industrial.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,21 +43,21 @@ jobs:
- name: Go back to current directory
run: cd $CURRENT_DIR
- uses: actions/checkout@v3 # clone target repository
- name: Verify pigpio library install
run: sudo pigpiod -v
# - name: Verify pigpio library install
# run: sudo pigpiod -v

# - uses: actions/cache@v2 # fetch/store the directory used by ccache before/after the ci run
# with:
# path: ${{ env.CCACHE_DIR }}
# # This configuration will always create a new ccache cache starting off from the previous one (if any).
# # In this simple version it will be shared between all builds of the same ROS_REPO and ROS_REPO
# # and might need some fine-tuning to match the use case
# key: ccache-${{ matrix.ROS_DISTRO }}-${{ matrix.ROS_REPO }}-${{github.run_id}}
# restore-keys: |
# ccache-${{ matrix.ROS_DISTRO }}-${{ matrix.ROS_REPO }}-
# - uses: 'ros-industrial/industrial_ci@master' # run industrial_ci
# env: # either pass all entries explicitly
# ROS_DISTRO: ${{ matrix.ROS_DISTRO }}
# ROS_REPO: ${{ matrix.ROS_REPO }}
# # with: # or pass the full matrix as config
# # config: ${{toJSON(matrix)}}
- uses: actions/cache@v2 # fetch/store the directory used by ccache before/after the ci run
with:
path: ${{ env.CCACHE_DIR }}
# This configuration will always create a new ccache cache starting off from the previous one (if any).
# In this simple version it will be shared between all builds of the same ROS_REPO and ROS_REPO
# and might need some fine-tuning to match the use case
key: ccache-${{ matrix.ROS_DISTRO }}-${{ matrix.ROS_REPO }}-${{github.run_id}}
restore-keys: |
ccache-${{ matrix.ROS_DISTRO }}-${{ matrix.ROS_REPO }}-
- uses: 'ros-industrial/industrial_ci@master' # run industrial_ci
env: # either pass all entries explicitly
ROS_DISTRO: ${{ matrix.ROS_DISTRO }}
ROS_REPO: ${{ matrix.ROS_REPO }}
# with: # or pass the full matrix as config
# config: ${{toJSON(matrix)}}
22 changes: 20 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,26 @@ find_package(pluginlib REQUIRED)
find_package(rclcpp REQUIRED)
find_package(rclcpp_lifecycle REQUIRED)

find_library(PIGPIO_IF2_LIB pigpiod_if2 REQUIRED)
find_library(PIGPIO_LIB pigpio REQUIRED)
################################################################################
### Find the pigpio shared libraries.
################################################################################

# Find the pigpio libraries.
find_library(PIGPIO_LIB
NAMES libpigpio.so
HINTS /usr/local/lib
REQUIRED)

find_library(PIGPIO_IF2_LIB
NAMES libpigpiod_if2.so
HINTS /usr/local/lib
REQUIRED)

################################################################################
################################################################################

# find_library(PIGPIO_IF2_LIB pigpiod_if2 REQUIRED)
# find_library(PIGPIO_LIB pigpio REQUIRED)

add_library(
rpi_pwm_hardware_interface
Expand Down

0 comments on commit 15d443f

Please sign in to comment.