-
Notifications
You must be signed in to change notification settings - Fork 2
/
trifinger_base_pylon.def
79 lines (70 loc) · 3.52 KB
/
trifinger_base_pylon.def
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
# Add Pylon SDK to the image
# This is not included in the original image due to possible license issues.
Bootstrap: localimage
From: ./trifinger_base.sif
%post -c /bin/bash
set -e
export DEBIAN_FRONTEND=noninteractive
# The code below for downloading Pylon is taken from
# https://github.com/basler/pylon-ros-camera/blob/ed094fad02eed38af830a052c7420befc6483ef3/pylon_camera/rosdep/pylon_sdk.rdmanifest
# and is distributed with the following license:
#
# Copyright (C) 2018, Magazino GmbH. All rights reserved.
#
# Improved by drag and bot GmbH (www.dragandbot.com), 2019
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice,
# this list of conditions and the following disclaimer.
# 2. Redistributions in binary form must reproduce the above copyright
# notice, this list of conditions and the following disclaimer in the
# documentation and/or other materials provided with the distribution.
# 3. Neither the names of Magazino GmbH nor the names of its
# contributors may be used to endorse or promote products derived from
# this software without specific prior written permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
# ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
# LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
# CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
# SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
# INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
# CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
# ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
# POSSIBILITY OF SUCH DAMAGE.
arch="$(uname -m)"
if [ "$arch" == "armv7l" ]; then
pkgarch="armhf"
elif [ "$arch" == "aarch64" ]; then
pkgarch="arm64"
elif [ "$arch" == "arm64" ]; then
pkgarch="arm64"
elif [ "$arch" == "x86_64" ]; then
pkgarch="amd64"
else
pkgarch="i386"
fi
version="5.2.0.13457"
checksum=9d4f70aae93012d6ca21bb4aff706ce409da155a446e86b90d00f0dd0a26fd55
pkg=pylon_${version}-deb0_${pkgarch}.deb
url="https://dnb-public-downloads-misc.s3.eu-central-1.amazonaws.com/pylon/${pkg}"
download_path="/_cache/${pkg}"
# only download if not existing
if [ ! -e "${download_path}" ]; then
wget --no-check-certificate -O "${download_path}" $url
fi
# verify checksum (to make sure the package on the server wasn't modified)
echo "${checksum} ${download_path}" | sha256sum --check || exit 2
dpkg -i "${download_path}"
%help
Container for building the BLMC_EI/ROBOT_FINGER project.
Run it with `singularity shell` at the root of your workspace, set up the
environment by executing `source /setup.sh` and build with `colcon build`.
This version of the image contains the Pylon Camera Software Suite needed to
operate the Basler cameras. The license of this software can be found in
`/opt/pylon5/share/pylon/License.html` inside this image. You may only use
it if you accept its license.