Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
W
wolf_scripts
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
mobile_robotics
wolf_projects
wolf_scripts
Commits
bd7dac06
Commit
bd7dac06
authored
1 year ago
by
Joan Vallvé Navarro
Browse files
Options
Downloads
Patches
Plain Diff
improved install_wolf
parent
7a21fdb8
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
install_wolf.sh
+171
-29
171 additions, 29 deletions
install_wolf.sh
with
171 additions
and
29 deletions
install_wolf.sh
+
171
−
29
View file @
bd7dac06
...
@@ -83,8 +83,9 @@ INSTALL_FALKO="undefined"
...
@@ -83,8 +83,9 @@ INSTALL_FALKO="undefined"
INSTALL_CSM
=
"undefined"
INSTALL_CSM
=
"undefined"
DEPS_PATH
=
"undefined"
DEPS_PATH
=
"undefined"
WOLF_PATH
=
"undefined"
WOLF_PATH
=
"undefined"
WOLF_BRANCH
=
"main"
while
getopts
"ap:d:w:hf:c:"
opt
;
do
while
getopts
"ap:d:w:hf:c:
b:
"
opt
;
do
case
${
opt
}
in
case
${
opt
}
in
a
)
# install all plugins
a
)
# install all plugins
if
[
"
$INSTALL_PLUGINS
"
!=
""
]
;
then
if
[
"
$INSTALL_PLUGINS
"
!=
""
]
;
then
...
@@ -151,6 +152,10 @@ while getopts "ap:d:w:hf:c:" opt; do
...
@@ -151,6 +152,10 @@ while getopts "ap:d:w:hf:c:" opt; do
exit
1
exit
1
fi
fi
;;
;;
b
)
# branch to clone
WOLF_BRANCH
=
$OPTARG
func_echo
"Set wolf branch:
${
WOLF_BRANCH
}
"
;;
h
)
# help
h
)
# help
usage
usage
exit
0
exit
0
...
@@ -215,8 +220,19 @@ fi
...
@@ -215,8 +220,19 @@ fi
# ceres
# ceres
func_echo
"Installing ceres 2.0 via source..."
func_echo
"Installing ceres 2.0 via source..."
cd
$DEPS_PATH
cd
$DEPS_PATH
git clone
--depth
1
-b
2.0.0 https://ceres-solver.googlesource.com/ceres-solver
cd
ceres-solver
FOLDER_NAME
=
"ceres-solver"
if
[
!
-d
$FOLDER_NAME
]
;
then
git clone
--depth
1
-b
2.0.0 https://ceres-solver.googlesource.com/ceres-solver
cd
$FOLDER_NAME
else
cd
$FOLDER_NAME
git fetch
--all
git checkout 2.0.0
git pull
fi
mkdir
-p
build
&&
cd
build
mkdir
-p
build
&&
cd
build
cmake
-DCMAKE_BUILD_TYPE
=
Release ..
cmake
-DCMAKE_BUILD_TYPE
=
Release ..
make
-j
$CORES
make
-j
$CORES
...
@@ -226,8 +242,19 @@ func_make_install
...
@@ -226,8 +242,19 @@ func_make_install
# spdlog
# spdlog
func_echo
"Installing spdlog 0.17 via source..."
func_echo
"Installing spdlog 0.17 via source..."
cd
$DEPS_PATH
cd
$DEPS_PATH
git clone
--depth
1
-b
v0.17.0 https://github.com/gabime/spdlog.git
cd
spdlog
FOLDER_NAME
=
"spdlog"
if
[
!
-d
$FOLDER_NAME
]
;
then
git clone
--depth
1
-b
v0.17.0 https://github.com/gabime/spdlog.git
cd
$FOLDER_NAME
else
cd
$FOLDER_NAME
git fetch
--all
git checkout v0.17.0
git pull
fi
mkdir
-p
build
&&
cd
build
mkdir
-p
build
&&
cd
build
cmake
-DCMAKE_BUILD_TYPE
=
Release
-DCMAKE_CXX_FLAGS
=
"
${
CMAKE_CXX_FLAGS
}
-fPIC"
..
cmake
-DCMAKE_BUILD_TYPE
=
Release
-DCMAKE_CXX_FLAGS
=
"
${
CMAKE_CXX_FLAGS
}
-fPIC"
..
make
-j
$CORES
make
-j
$CORES
...
@@ -255,8 +282,18 @@ func_echo "wolf folder path: $WOLF_PATH"
...
@@ -255,8 +282,18 @@ func_echo "wolf folder path: $WOLF_PATH"
# CORE -----------------------------------------------------
# CORE -----------------------------------------------------
func_echo
"Cloning wolf core..."
func_echo
"Cloning wolf core..."
cd
$WOLF_PATH
cd
$WOLF_PATH
git clone
-b
main https://gitlab.iri.upc.edu/mobile_robotics/wolf_projects/wolf_lib/wolf.git
cd
wolf
FOLDER_NAME
=
"wolf"
if
[
!
-d
$FOLDER_NAME
]
;
then
git clone
-b
$WOLF_BRANCH
https://gitlab.iri.upc.edu/mobile_robotics/wolf_projects/wolf_lib/wolf.git
cd
$FOLDER_NAME
else
cd
$FOLDER_NAME
git fetch
--all
git checkout
$WOLF_BRANCH
git pull
fi
func_echo
"Compiling wolf core..."
func_echo
"Compiling wolf core..."
mkdir
-p
build
&&
cd
build
mkdir
-p
build
&&
cd
build
...
@@ -284,8 +321,18 @@ if [ $INSTALL_IMU == "y" ]; then
...
@@ -284,8 +321,18 @@ if [ $INSTALL_IMU == "y" ]; then
func_echo
"Cloning plugin imu..."
func_echo
"Cloning plugin imu..."
cd
$WOLF_PATH
cd
$WOLF_PATH
git clone
-b
main https://gitlab.iri.upc.edu/mobile_robotics/wolf_projects/wolf_lib/plugins/imu.git
cd
imu
FOLDER_NAME
=
"imu"
if
[
!
-d
$FOLDER_NAME
]
;
then
git clone
-b
$WOLF_BRANCH
https://gitlab.iri.upc.edu/mobile_robotics/wolf_projects/wolf_lib/plugins/imu.git
cd
$FOLDER_NAME
else
cd
$FOLDER_NAME
git fetch
--all
git checkout
$WOLF_BRANCH
git pull
fi
func_echo
"Compiling plugin imu..."
func_echo
"Compiling plugin imu..."
mkdir
-p
build
&&
cd
build
mkdir
-p
build
&&
cd
build
...
@@ -315,8 +362,17 @@ if [ $INSTALL_GNSS == "y" ]; then
...
@@ -315,8 +362,17 @@ if [ $INSTALL_GNSS == "y" ]; then
func_echo
"Installing plugin gnss dependencies..."
func_echo
"Installing plugin gnss dependencies..."
cd
$DEPS_PATH
cd
$DEPS_PATH
git clone https://gitlab.iri.upc.edu/mobile_robotics/gauss_project/gnss_utils.git
cd
gnss_utils
FOLDER_NAME
=
"gnss_utils"
if
[
!
-d
$FOLDER_NAME
]
;
then
git clone https://gitlab.iri.upc.edu/mobile_robotics/gauss_project/gnss_utils.git
cd
$FOLDER_NAME
else
cd
$FOLDER_NAME
git pull
fi
git submodule update
--init
git submodule update
--init
mkdir
-p
build
&&
cd
build
mkdir
-p
build
&&
cd
build
cmake
-DCMAKE_BUILD_TYPE
=
Release
-DBUILD_DEMOS
=
ON
-DBUILD_TESTS
=
ON ..
cmake
-DCMAKE_BUILD_TYPE
=
Release
-DBUILD_DEMOS
=
ON
-DBUILD_TESTS
=
ON ..
...
@@ -326,8 +382,18 @@ if [ $INSTALL_GNSS == "y" ]; then
...
@@ -326,8 +382,18 @@ if [ $INSTALL_GNSS == "y" ]; then
func_echo
"Cloning plugin gnss..."
func_echo
"Cloning plugin gnss..."
cd
$WOLF_PATH
cd
$WOLF_PATH
git clone
-b
main https://gitlab.iri.upc.edu/mobile_robotics/wolf_projects/wolf_lib/plugins/gnss.git
cd
gnss
FOLDER_NAME
=
"gnss"
if
[
!
-d
$FOLDER_NAME
]
;
then
git clone
-b
$WOLF_BRANCH
https://gitlab.iri.upc.edu/mobile_robotics/wolf_projects/wolf_lib/plugins/gnss.git
cd
$FOLDER_NAME
else
cd
$FOLDER_NAME
git fetch
--all
git checkout
$WOLF_BRANCH
git pull
fi
func_echo
"Compiling plugin gnss..."
func_echo
"Compiling plugin gnss..."
mkdir
-p
build
&&
cd
build
mkdir
-p
build
&&
cd
build
...
@@ -376,8 +442,17 @@ if [ $INSTALL_LASER == "y" ]; then
...
@@ -376,8 +442,17 @@ if [ $INSTALL_LASER == "y" ]; then
sudo
apt
install
-y
libgsl-dev
sudo
apt
install
-y
libgsl-dev
fi
fi
cd
$DEPS_PATH
cd
$DEPS_PATH
git clone https://gitlab.iri.upc.edu/labrobotica/algorithms/csm.git
cd
csm
FOLDER_NAME
=
"csm"
if
[
!
-d
$FOLDER_NAME
]
;
then
git clone https://gitlab.iri.upc.edu/labrobotica/algorithms/csm.git
cd
$FOLDER_NAME
else
cd
$FOLDER_NAME
git pull
fi
mkdir
-p
build
&&
cd
build
mkdir
-p
build
&&
cd
build
cmake
-DCMAKE_BUILD_TYPE
=
Release ..
cmake
-DCMAKE_BUILD_TYPE
=
Release ..
make
-j
$CORES
make
-j
$CORES
...
@@ -398,8 +473,17 @@ if [ $INSTALL_LASER == "y" ]; then
...
@@ -398,8 +473,17 @@ if [ $INSTALL_LASER == "y" ]; then
fi
fi
if
[
$INSTALL_FALKO
==
"y"
]
;
then
if
[
$INSTALL_FALKO
==
"y"
]
;
then
cd
$DEPS_PATH
cd
$DEPS_PATH
git clone https://gitlab.iri.upc.edu/labrobotica/algorithms/falkolib.git
cd
falkolib
FOLDER_NAME
=
"falkolib"
if
[
!
-d
$FOLDER_NAME
]
;
then
git clone https://gitlab.iri.upc.edu/labrobotica/algorithms/falkolib.git
cd
$FOLDER_NAME
else
cd
$FOLDER_NAME
git pull
fi
mkdir
-p
build
&&
cd
build
mkdir
-p
build
&&
cd
build
cmake
-DCMAKE_BUILD_TYPE
=
Release ..
cmake
-DCMAKE_BUILD_TYPE
=
Release ..
make
-j
$CORES
make
-j
$CORES
...
@@ -411,8 +495,17 @@ if [ $INSTALL_LASER == "y" ]; then
...
@@ -411,8 +495,17 @@ if [ $INSTALL_LASER == "y" ]; then
# LASER_SCAN_UTILS
# LASER_SCAN_UTILS
func_echo
"Installing laser_scan_utils (required)..."
func_echo
"Installing laser_scan_utils (required)..."
cd
$DEPS_PATH
cd
$DEPS_PATH
git clone https://gitlab.iri.upc.edu/labrobotica/algorithms/laser_scan_utils.git
cd
laser_scan_utils
FOLDER_NAME
=
"laser_scan_utils"
if
[
!
-d
$FOLDER_NAME
]
;
then
git clone https://gitlab.iri.upc.edu/labrobotica/algorithms/laser_scan_utils.git
cd
$FOLDER_NAME
else
cd
$FOLDER_NAME
git pull
fi
mkdir
-p
build
&&
cd
build
mkdir
-p
build
&&
cd
build
cmake
-DCMAKE_BUILD_TYPE
=
Release ..
cmake
-DCMAKE_BUILD_TYPE
=
Release ..
make
-j
$CORES
make
-j
$CORES
...
@@ -423,8 +516,18 @@ if [ $INSTALL_LASER == "y" ]; then
...
@@ -423,8 +516,18 @@ if [ $INSTALL_LASER == "y" ]; then
# PLUGIN
# PLUGIN
func_echo
"Cloning plugin laser..."
func_echo
"Cloning plugin laser..."
cd
$WOLF_PATH
cd
$WOLF_PATH
git clone
-b
main https://gitlab.iri.upc.edu/mobile_robotics/wolf_projects/wolf_lib/plugins/laser.git
cd
laser
FOLDER_NAME
=
"laser"
if
[
!
-d
$FOLDER_NAME
]
;
then
git clone
-b
$WOLF_BRANCH
https://gitlab.iri.upc.edu/mobile_robotics/wolf_projects/wolf_lib/plugins/laser.git
cd
$FOLDER_NAME
else
cd
$FOLDER_NAME
git fetch
--all
git checkout
$WOLF_BRANCH
git pull
fi
func_echo
"Compiling plugin laser..."
func_echo
"Compiling plugin laser..."
mkdir
-p
build
&&
cd
build
mkdir
-p
build
&&
cd
build
...
@@ -464,8 +567,18 @@ if [ $INSTALL_VISION == "y" ]; then
...
@@ -464,8 +567,18 @@ if [ $INSTALL_VISION == "y" ]; then
func_echo
"Cloning plugin vision..."
func_echo
"Cloning plugin vision..."
cd
$WOLF_PATH
cd
$WOLF_PATH
git clone
-b
main https://gitlab.iri.upc.edu/mobile_robotics/wolf_projects/wolf_lib/plugins/vision.git
cd
vision
FOLDER_NAME
=
"vision"
if
[
!
-d
$FOLDER_NAME
]
;
then
git clone
-b
$WOLF_BRANCH
https://gitlab.iri.upc.edu/mobile_robotics/wolf_projects/wolf_lib/plugins/vision.git
cd
$FOLDER_NAME
else
cd
$FOLDER_NAME
git fetch
--all
git checkout
$WOLF_BRANCH
git pull
fi
func_echo
"Compiling plugin vision..."
func_echo
"Compiling plugin vision..."
mkdir
-p
build
&&
cd
build
mkdir
-p
build
&&
cd
build
...
@@ -497,8 +610,17 @@ if [ $INSTALL_VISION == "y" ]; then
...
@@ -497,8 +610,17 @@ if [ $INSTALL_VISION == "y" ]; then
func_echo
"Installing plugin apriltag dependencies..."
func_echo
"Installing plugin apriltag dependencies..."
cd
$DEPS_PATH
cd
$DEPS_PATH
git clone https://github.com/AprilRobotics/apriltag apriltaglib
cd
apriltaglib
FOLDER_NAME
=
"apriltaglib"
if
[
!
-d
$FOLDER_NAME
]
;
then
git clone https://github.com/AprilRobotics/apriltag apriltaglib
cd
$FOLDER_NAME
else
cd
$FOLDER_NAME
git pull
fi
mkdir
-p
build
&&
cd
build
mkdir
-p
build
&&
cd
build
cmake
-DCMAKE_BUILD_TYPE
=
Release ..
cmake
-DCMAKE_BUILD_TYPE
=
Release ..
make
-j
$CORES
make
-j
$CORES
...
@@ -507,8 +629,18 @@ if [ $INSTALL_VISION == "y" ]; then
...
@@ -507,8 +629,18 @@ if [ $INSTALL_VISION == "y" ]; then
func_echo
"Cloning plugin apriltag..."
func_echo
"Cloning plugin apriltag..."
cd
$WOLF_PATH
cd
$WOLF_PATH
git clone
-b
main https://gitlab.iri.upc.edu/mobile_robotics/wolf_projects/wolf_lib/plugins/apriltag.git
cd
apriltag
FOLDER_NAME
=
"apriltag"
if
[
!
-d
$FOLDER_NAME
]
;
then
git clone
-b
$WOLF_BRANCH
https://gitlab.iri.upc.edu/mobile_robotics/wolf_projects/wolf_lib/plugins/apriltag.git
cd
$FOLDER_NAME
else
cd
$FOLDER_NAME
git fetch
--all
git checkout
$WOLF_BRANCH
git pull
fi
func_echo
"Compiling plugin apriltag..."
func_echo
"Compiling plugin apriltag..."
mkdir
-p
build
&&
cd
build
mkdir
-p
build
&&
cd
build
...
@@ -543,8 +675,18 @@ if [ $INSTALL_IMU == "y" ]; then
...
@@ -543,8 +675,18 @@ if [ $INSTALL_IMU == "y" ]; then
func_echo
"Cloning plugin bodydynamics..."
func_echo
"Cloning plugin bodydynamics..."
cd
$WOLF_PATH
cd
$WOLF_PATH
git clone
-b
main https://gitlab.iri.upc.edu/mobile_robotics/wolf_projects/wolf_lib/plugins/bodydynamics.git
cd
bodydynamics
FOLDER_NAME
=
"bodydynamics"
if
[
!
-d
$FOLDER_NAME
]
;
then
git clone
-b
$WOLF_BRANCH
https://gitlab.iri.upc.edu/mobile_robotics/wolf_projects/wolf_lib/plugins/bodydynamics.git
cd
$FOLDER_NAME
else
cd
$FOLDER_NAME
git fetch
--all
git checkout
$WOLF_BRANCH
git pull
fi
func_echo
"Compiling plugin bodydynamics..."
func_echo
"Compiling plugin bodydynamics..."
mkdir
-p
build
&&
cd
build
mkdir
-p
build
&&
cd
build
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment