Skip to content

Commit

Permalink
Debug CI (#1)
Browse files Browse the repository at this point in the history
* Update ci.yml to use ROS Industrial CI
  • Loading branch information
Tuebel authored Aug 29, 2024
1 parent 0464a35 commit 40bfcf1
Show file tree
Hide file tree
Showing 4 changed files with 26 additions and 37 deletions.
25 changes: 8 additions & 17 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,23 +13,14 @@ on:
- main

jobs:
CI:
industrial_ci:
name: ROS Industrial CI
runs-on: ubuntu-latest
container:
# avoid long installation times
image: ros:noetic-robot
steps:
- uses: actions/checkout@v4
- uses: ros-tooling/setup-ros@v0.7
with:
required-ros-distributions: noetic
- uses: ros-tooling/action-ros-ci@v0.3
with:
package-name: lbrmed_bringup lbrmed_control lbrmed_description lbrmed_hw_fri lbrmed_moveit_config lbrmed_msgs
target-ros1-distro: noetic
vcs-repo-file-url: .rosinstall
id: ros_ci
- name: catkin lint
run: |
. ${{ steps.ros_ci.outputs.ros-workspace-directory-name }}/devel/setup.sh
catkin_lint -W2 --pkg lbrmed_bringup —pkg lbrmed_control —pkg lbrmed_description —pkg lbrmed_hw_fri —pkg lbrmed_moveit_config —pkg lbrmed_msgs
- uses: "ros-industrial/industrial_ci@master"
env:
ROS_DISTRO: noetic
CATKIN_LINT: true
CATKIN_LINT_ARGS: -W2
UPSTREAM_WORKSPACE: .rosinstall
16 changes: 8 additions & 8 deletions fri/fri/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
cmake_minimum_required(VERSION 2.8.3)
cmake_minimum_required(VERSION 3.0.2)
project(fri)

find_package(catkin REQUIRED COMPONENTS nanopb)

catkin_package(
INCLUDE_DIRS include
LIBRARIES fri_lib
LIBRARIES ${PROJECT_NAME}_lib
CATKIN_DEPENDS nanopb
)
include_directories(${catkin_INCLUDE_DIRS} include ${CMAKE_CURRENT_SOURCE_DIR}/include)

# Define target
add_library(fri_lib
add_library(${PROJECT_NAME}_lib
src/friClientApplication.cpp
src/friCommandMessageEncoder.cpp
src/friLBRClient.cpp
Expand All @@ -26,15 +26,15 @@ add_library(fri_lib

# Add compile options
if(MSVC)
target_compile_options(fri_lib
target_compile_options(${PROJECT_NAME}_lib
PRIVATE -DPB_SYSTEM_HEADER=<nanopb/pb_syshdr_win.h>
-DPB_FIELD_16BIT
-DWIN32
-DHAVE_STDINT_H
-DHAVE_STDBOOL_H
)
else()
target_compile_options(fri_lib
target_compile_options(${PROJECT_NAME}_lib
PRIVATE
-O2
-Wall
Expand All @@ -49,15 +49,15 @@ else()
endif()

# Add include directories for target
target_include_directories(fri_lib PUBLIC include PRIVATE src)
target_include_directories(${PROJECT_NAME}_lib PUBLIC include PRIVATE src)

# Link against dependencies
target_link_libraries(fri_lib
target_link_libraries(${PROJECT_NAME}_lib
${catkin_LIBRARIES}
)

# Install
install(TARGETS fri_lib
install(TARGETS ${PROJECT_NAME}_lib
ARCHIVE DESTINATION ${CATKIN_PACKAGE_LIB_DESTINATION}
LIBRARY DESTINATION ${CATKIN_PACKAGE_LIB_DESTINATION}
RUNTIME DESTINATION ${CATKIN_PACKAGE_BIN_DESTINATION}
Expand Down
22 changes: 10 additions & 12 deletions fri/nanopb/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,38 +1,36 @@
cmake_minimum_required(VERSION 2.8.3)
cmake_minimum_required(VERSION 3.0.2)
project(nanopb)

find_package(catkin REQUIRED)

catkin_package(
INCLUDE_DIRS include
LIBRARIES nanopb
LIBRARIES ${PROJECT_NAME}
)

include_directories(${catkin_INCLUDE_DIRS} include ${CMAKE_CURRENT_SOURCE_DIR}/include)
# Define target
add_library(nanopb
add_library(${PROJECT_NAME}
src/pb_decode.c
src/pb_encode.c
)



if(MSVC)
target_compile_options(nanopb
target_compile_options(${PROJECT_NAME}
PRIVATE
-DPB_SYSTEM_HEADER=<nanopb/pb_syshdr_win.h>
-DPB_SYSTEM_HEADER=<${PROJECT_NAME}/pb_syshdr_win.h>
-DPB_FIELD_16BIT
-DWIN32
-DHAVE_STDINT_H
-DHAVE_STDBOOL_H
)
else()
target_compile_options(nanopb
target_compile_options(${PROJECT_NAME}
PRIVATE
-O2
-Wall
-DHAVE_SOCKLEN_T
-DPB_SYSTEM_HEADER=<nanopb/pb_syshdr.h>
-DPB_SYSTEM_HEADER=<${PROJECT_NAME}/pb_syshdr.h>
-DPB_FIELD_16BIT
-DHAVE_STDINT_H
-DHAVE_STDDEF_H
Expand All @@ -43,12 +41,12 @@ else()
endif()

# Add include directories for target
target_include_directories(nanopb PUBLIC include PRIVATE src
target_include_directories(${PROJECT_NAME} PUBLIC include PRIVATE src
)
target_link_libraries(nanopb ${catkin_LIBRARIES})
target_link_libraries(${PROJECT_NAME} ${catkin_LIBRARIES})
# Install
install(
TARGETS nanopb
TARGETS ${PROJECT_NAME}
ARCHIVE DESTINATION ${CATKIN_PACKAGE_LIB_DESTINATION}
LIBRARY DESTINATION ${CATKIN_PACKAGE_LIB_DESTINATION}
RUNTIME DESTINATION ${CATKIN_GLOBAL_BIN_DESTINATION}
Expand Down
Empty file modified lbrmed_msgs/config/lbrmed_impedance_fri.cfg
100644 → 100755
Empty file.

0 comments on commit 40bfcf1

Please sign in to comment.