Giter VIP home page Giter VIP logo

Comments (2)

Guillaumebeuzeboc avatar Guillaumebeuzeboc commented on May 23, 2024

Hello,
it seems that a part is missing.
Previously there was a part call fastdds-no-shared-memory:

  fastdds-no-shared-memory:
    plugin: dump
    source: snap/local/
    organize:
      'fastdds_no_shared_memory.xml': usr/share/
      'launcher-plotjuggler*': usr/bin/

This part was indeed importing a configuration to disable the shared memory, but also importing a local launcher script.

By adding the following to the snapcraft.yaml file in parts should solve the issue:

  local-file:
    plugin: dump
    source: snap/local/
    organize:
      'launcher-plotjuggler*': usr/bin/

The complete snapcraft.yaml should then be:

name: plotjuggler
adopt-info: plotjuggler # parse metadata from the plotjuggler part
summary: The timeseries visualization tool that you deserve
description: |
  QT5 based application to display time series in plots,
  using an intuitive "drag and drop" interface.

  The snap comes with only ROS 2 plugins.
  You can launch it with

    $ plotjuggler

issues: https://github.com/facontidavide/plotjuggler/issues
source-code: https://github.com/facontidavide/plotjuggler
license: MPL-2.0

confinement: strict
base: core20

package-repositories:
  # ROS
  - components: [main]
    formats: [deb]
    key-id: C1CF6E31E6BADE8868B172B4F42ED6FBAB17C654
    key-server: keyserver.ubuntu.com
    suites: [focal]
    type: apt
    url: http://packages.ros.org/ros/ubuntu

apps:
  plotjuggler:
    command: usr/bin/launcher-plotjuggler-ros
    plugs: [network, network-bind, home, removable-media]
    extensions: [kde-neon]

parts:
  plotjuggler:
    plugin: cmake
    source: .
    cmake-parameters:
      - -DCMAKE_BUILD_TYPE=Release
    build-packages:
      - distro-info-data
      - libpulse0
      - libdw-dev
      - libbfd-dev
      - libdwarf-dev
      - libprotoc-dev
      - libgl-dev
      - libmosquitto-dev
      - libzmq3-dev
      - libzstd-dev
    stage-packages:
      - libdw1
      - libmosquitto1
      - libprotobuf17
      - libprotobuf-dev
      - libzmq5
      - libzstd1
      - libpsm-infinipath1
    override-pull: |
        snapcraftctl pull

        version="$(git describe --always --tags| sed -e 's/^v//;s/-/+git/;y/-/./')"
        [ -n "$(echo $version | grep "+git")" ] && grade=devel || grade=stable
        snapcraftctl set-version "$version"
        snapcraftctl set-grade "$grade"

        # Necessary to bypass XDG desktop portals because ROS 2 bags metadata.yaml are refering db3 files relatively
        sed -i '/QApplication app(new_argc, new_argv.data());/a QCoreApplication::setAttribute(Qt::AA_DontUseNativeDialogs);' plotjuggler_app/main.cpp

  plotjuggler-ros:
    after: [plotjuggler]
    plugin: catkin
    source: .
    build-environment:
    - ROS_VERSION: '1'
    - ROS_DISTRO: noetic
    catkin-cmake-args:
      - -DCMAKE_BUILD_TYPE=Release
      # point to previously build plotjuggler
      - -Dplotjuggler_DIR:PATH=$SNAPCRAFT_STAGE/usr/local/lib/cmake/plotjuggler
      # necessary to point to kde-neon snap Qt libraries
      - ${SNAPCRAFT_CMAKE_ARGS}
    build-packages:
      - git
      - python3-vcstool
      - ros-noetic-ros-environment
      - ros-noetic-catkin
    override-pull: |
      if [ ! -d plotjuggler-ros-plugins ]; then

        vcs import < /root/parts/plotjuggler/src/snap/local/plotjuggler.rosinstall

        # prevent rosdep from installing plotjuggler
        sed -i "s|<depend>plotjuggler</depend>||" plotjuggler-ros-plugins/package.xml

        # Replace find_package(catkin components plotjuggler)
        # with    find_package(plotjuggler)
        sed -i "s|plotjuggler )|)|" plotjuggler-ros-plugins/CMakeLists.txt
        sed -i "/find_package(catkin/a find_package(plotjuggler REQUIRED)" plotjuggler-ros-plugins/CMakeLists.txt

        # Qt dependencies are managed by the kde neon-extension
        sed -i '/qt/d' plotjuggler-ros-plugins/package.xml
      fi
  local-file:
    plugin: dump
    source: snap/local/
    organize:
      'launcher-plotjuggler*': usr/bin/

I can prepare a PR on the ros_refactored branch if needed.

from plotjuggler.

facontidavide avatar facontidavide commented on May 23, 2024

thanks,

from plotjuggler.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.