Skip to content

Commit

Permalink
Merge pull request #258 from k-okada/fix_22.04
Browse files Browse the repository at this point in the history
[ros-o] euscollada: qhull 0.29.2 from Ubuntu 22.04 uses /usr/include/libqhull/qhull_a.h instead of /usr/include/qhull/qhull_a.h
  • Loading branch information
k-okada authored Jan 7, 2025
2 parents 1f1a342 + d1b80cd commit 5db2df7
Show file tree
Hide file tree
Showing 6 changed files with 203 additions and 2 deletions.
155 changes: 155 additions & 0 deletions .github/workflows/config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,155 @@
on:
push:
branches:
- master
pull_request:

env:
DISPLAY: ':0.0'

jobs:
ros:
runs-on: ubuntu-latest
continue-on-error: false
strategy:
fail-fast: false
matrix:
include:
- ROS_DISTRO: indigo
CONTAINER: jskrobotics/ros-ubuntu:14.04
BEFORE_SCRIPT : "sudo pip install virtualenv==15.1.0"
NOT_TEST_INSTALL: true
- ROS_DISTRO: kinetic
CONTAINER: ubuntu:16.04
BEFORE_SCRIPT: "pip install --user matplotlib==2.2.5"
- ROS_DISTRO: melodic
CONTAINER: ubuntu:18.04
- ROS_DISTRO: noetic
CONTAINER: ubuntu:20.04

container:
image: ${{ matrix.CONTAINER }}
volumes:
- /tmp/node20:/__e/node20

steps:
- name: Install latest git ( use sudo for ros-ubuntu )
run: |
[ -e /etc/apt/sources.list.d/ubuntu-esm-infra-$(lsb_release -cs).list ] && sudo rm /etc/apt/sources.list.d/ubuntu-esm-infra-$(lsb_release -cs).list ## fix Err https://esm.ubuntu.com trusty-infra-security/main amd64 Packages, gnutls_handshake() failed: Handshake failed
(apt-get update && apt-get install -y sudo) || echo "OK"
sudo apt-get update
sudo apt-get install -y software-properties-common
sudo apt-get update
sudo -E add-apt-repository -y ppa:git-core/ppa
sudo apt-get update
sudo apt-get install -y git
- name: work around permission issue # https://github.com/actions/checkout/issues/760#issuecomment-1097501613
run: |
set -x
export USER=$(whoami)
if [ "${{ matrix.CONTAINER }}" = "jskrobotics/ros-ubuntu:14.04" ]; then
git config --global --add safe.directory $GITHUB_WORKSPACE || echo "OK" # Show 'could not lock config file /github/home/.gitconfig: Permission denied', but it is ok
sudo mkdir -p /__w/
sudo chmod 777 -R /__w/
sudo chown -R $USER $HOME
sudo mkdir -p /__w/_temp/_runner_file_commands/
sudo chown -R $USER /__w/_temp/_runner_file_commands/
# sudo mkdir -p /home/runner/work/_temp/_github_workflow/
# sudo chown -R $USER $HOME /home/runner/work/_temp/_github_workflow/
# ls -al /home/runner/work/_temp/_github_workflow/
else
git config --global --add safe.directory $GITHUB_WORKSPACE
fi
- name: Try to replace `node` with an glibc 2.17
shell: bash
run: |
if [ "${{ matrix.CONTAINER }}" = "jskrobotics/ros-ubuntu:14.04" ]; then
export USER=$(whoami)
sudo chmod 777 -R /__e/node20
sudo chown -R $USER /__e/node20
fi
ls -lar /__e/node20 &&
sudo apt-get install -y curl &&
curl -Lo /tmp/node.tar.gz https://unofficial-builds.nodejs.org/download/release/v20.17.0/node-v20.17.0-linux-x64-glibc-217.tar.gz &&
cd /__e/node20 &&
tar -x --strip-components=1 -f /tmp/node.tar.gz &&
ls -lar /__e/node20/bin/
- name: Chcekout
uses: actions/[email protected]
with:
submodules: true

- name: Run jsk_travis
uses: jsk-ros-pkg/jsk_travis@master
with:
ROS_PARALLEL_JOBS : "-j8"
CATKIN_PARALLEL_JOBS : "-p8"
ROS_PARALLEL_TEST_JOBS : "-j8"
CATKIN_PARALLEL_TEST_JOBS : "-p8"
BEFORE_SCRIPT : ${{ matrix.BEFORE_SCRIPT }}
ROS_DISTRO : ${{ matrix.ROS_DISTRO }}
USE_DEB : ${{ matrix.USE_DEB }}
NOT_TEST_INSTALL : ${{ matrix.NOT_TEST_INSTALL }}
TEST_PKGS : ${{ matrix.TEST_PKGS }}
EXTRA_DEB : ${{ matrix.EXTRA_DEB }}

# ROS-O setup https://github.com/v4hn/ros-o-builder/blob/jammy-one/README.md#install-instructions
ros-o:
runs-on: ubuntu-latest

strategy:
fail-fast: false
matrix:
include:
- DISTRO: ubuntu:22.04
ROS_REPOSITORY_URL: https://raw.githubusercontent.com/v4hn/ros-o-builder/jammy-one/repository

container: ${{ matrix.DISTRO }}

env:
DEBIAN_FRONTEND : noninteractive

steps:
- name: Chcekout Source
uses: actions/[email protected]

- name: Setup ROS-O deb repository
run: |
set -x
apt update && apt install -qq -y ca-certificates
echo "deb [trusted=yes] ${{ matrix.ROS_REPOSITORY_URL }}/ ./" | tee /etc/apt/sources.list.d/ros-o-builder.list
apt update
apt install -qq -y python3-rosdep2
echo "yaml ${{ matrix.ROS_REPOSITORY_URL }}/local.yaml debian" | tee /etc/ros/rosdep/sources.list.d/1-ros-o-builder.list
rosdep update
- name: Setup catkin-tools
run: |
set -x
# setup catkin tools
apt install -qq -y python3-pip
pip3 install catkin-tools
# setup build tools
apt install -qq -y cmake build-essential catkin ros-one-rosbash
- name: Setup Workspace
run: |
source /opt/ros/one/setup.bash
set -x
# setup workspace
mkdir -p ~/ws/src
cd ~/ws/src
ln -sf $GITHUB_WORKSPACE .
rosdep install -qq -r -y --from-path . --ignore-src || echo "OK"
shell: bash

- name: Compile Packages
run: |
source /opt/ros/one/setup.bash
set -x
cd ~/ws/
catkin build --no-status -sv ${{ matrix.CATKIN_OPTIONS }} --cmake-args -DCATKIN_ENABLE_TESTING=OFF -DCMAKE_VERBOSE_MAKEFILE:BOOL=ON ${{ matrix.CMAKE_OPTIONS }}
shell: bash
18 changes: 18 additions & 0 deletions .github/workflows/python2.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# generated by `./generate_action_config.py noetic`
# jsk_travis
on: [push, pull_request]

jobs:
test:
runs-on: ubuntu-latest
name: check_python2

container: ubuntu:20.04

steps:
- name: Chcekout
uses: actions/checkout@v2
- name: Check Python2
run: |
apt update -q && apt install -y -q python2
python2 -m compileall .
22 changes: 22 additions & 0 deletions .github/workflows/python3.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# generated by `./generate_action_config.py noetic`
# jsk_travis
on: [push, pull_request]

jobs:
test:
runs-on: ubuntu-latest
name: check_python3

container: ubuntu:20.04

steps:
- name: Install latest git to download .git directory in actions/checkout@v2 ( use sudo for ros-ubuntu )
run: apt-get update && apt-get install -y software-properties-common && apt-get update && add-apt-repository -y ppa:git-core/ppa && apt-get update && apt-get install -y git
- name: work around permission issue # https://github.com/actions/checkout/issues/760#issuecomment-1097501613
run: git config --global --add safe.directory $GITHUB_WORKSPACE
- name: Chcekout
uses: actions/checkout@v2
- name: Check Python3
run: |
apt update -q && apt install -y -q python3 git 2to3
bash -c "ret=0; trap 'ret=1' ERR; python3 -m compileall .; 2to3 -w -f except -f execfile -f has_key -f import -f raw_input -f zip .; git diff --exit-code . > /dev/null; echo Exitting with \$ret; exit \$ret"
6 changes: 6 additions & 0 deletions euscollada/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,12 @@ IF(${yaml_cpp_VERSION} VERSION_GREATER "0.5.0")
add_definitions("-DUSE_CURRENT_YAML")
ENDIF()
pkg_check_modules(assimpdevel assimp_devel REQUIRED)
## qhull >= 0.29.2 uses /usr/include/libqhull instead of /usr/linclude/qhull
pkg_check_modules(qhull qhull)
if("${qhull_FOUND}" AND "${qhull_VERSION}" VERSION_GREATER "0.29.1")
add_definitions("-DQHULL_INCLUDE_LIBQHULL")
endif()


pkg_check_modules(URDFDOM REQUIRED urdfdom)
message(STATUS "Find URDFDOM ${URDFDOM_VERSION}")
Expand Down
2 changes: 1 addition & 1 deletion euscollada/src/collada2eus.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ using namespace ColladaDOM150;
#include <boost/filesystem/path.hpp>

extern "C" {
#ifdef __APPLE__
#if (defined __APPLE__) || (defined QHULL_INCLUDE_LIBQHULL)
#include <libqhull/qhull_a.h>
#else
#include <qhull/qhull_a.h>
Expand Down
2 changes: 1 addition & 1 deletion euscollada/src/collada2eus_urdfmodel.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
#include "yaml-cpp/yaml.h"

extern "C" {
#ifdef __APPLE__
#if (defined __APPLE__) || (defined QHULL_INCLUDE_LIBQHULL)
#include <libqhull/qhull_a.h>
#else
#include <qhull/qhull_a.h>
Expand Down

0 comments on commit 5db2df7

Please sign in to comment.