HOWTO_Install_Gazebo/Player/Stage
| Installation • Kernel & Hardware • Networks • Portage • Software • System • X Server • Gaming • Non-x86 • Emulators • Misc |
Contents |
Introduction
Player/Stage/Gazebo is a set of robotics control and simulation software that is not currently in Portage..
An excellent how-to can already be found at: vlab.pjwstk.edu.pl
Portage overlay
Because Player/Stage/Gazebo don't exist as official Gentoo ebuilds (yet), before we can install Player/Stage/Gazebo, we need to create a portage overlay (if you don't have one already...).
mkdir /usr/local/portage -p
Now we obtain the necessary ebuilds
cd /usr/local && wget http://projects.ict.usc.edu/gazebo/psg-portage-current.tar.bz2
(the tar.bz2 is a mini portage tree)
tar xjvf psg-portage-current.tar.bz2 && rm psg-portage-current.tar.bz2
Note: don't forget to set PORTDIR_OVERLAY="/usr/local/portage" (in /etc/make.conf)!
echo "PORTDIR_OVERLAY=/usr/local/portage" >> /etc/make.conf
Installation
Compilation Note:
I was only able to get wxgazebo working properly with nVidia's GLX libraries, YMMV. Also, unless the nVidia GLX libraries are installed before the compile, it seems that even though it compiles cleanly, wxgazebo bombs out with GLX errors. However, if you switch to nVidia's GLX libraries before the compile (over xorg-x11's GLX), you might get linking errors against /usr/lib/opengl/nvidia/lib/libGLcore.so.1.
Assuming you're planning on installing wxgazebo:
echo "x11-drivers/nvidia-drivers ~x86 >> /etc/portage/package.keywords" emerge -av x11-drivers/nvidia-drivers eselect opengl set xorg-x11
Setting USE Flags:
Probably you want the USE flags to persists in case of rebuilds or upgrades:
echo "sci-misc/player gazebo" >> /etc/portage/package.use echo "sci-misc/gazebo 3ds" >> /etc/portage/package.use
Emerge:
Now for the long part, lets emerge this puppy:
emerge -av gazebo player stage
which should result in something like this:
bookoo ~ # emerge -av gazebo player stage These are the packages that I would merge, in order: Calculating dependencies ...done! [ebuild N ] sci-misc/gazebo-0.6.0 USE="3ds" 0 kB [1] [ebuild N ] sci-misc/player-2.0.2 USE="gazebo ieee1394 python ssl -doc -fixedtones -howl -opencv-cvs -sphinx2 -v4l -wifi" 0 kB [1] [ebuild N ] sci-misc/stage-2.0.2 USE="-doc" 0 kB [1] Total size of downloads: 0 kB Portage overlays: [1] /usr/local/portage Do you want me to merge these packages? [Yes/No] yes
Post-Emerge
If you are using a nVidia card, you should switch back to nVidia's GLX libraries
eselect opengl set nvidia
Testing
To see if things worked...
Player
player /usr/share/stage/worlds/simple.cfg # or as of the latest version (adjust for actual path on your machine) PLAYERPATH=/usr/lib player /usr/share/stage/worlds/simple.cfg
You should get a windows with a top view of some terrain over a grid and a robot in red in the lower left corner.
Gazebo
gazebo /usr/share/gazebo/worlds/example.world
You should get the Gazebo init messages along with some updated time info.
wxGazebo
wxgazebo /usr/share/gazebo/worlds/example.world
You should see a window with some terrain, a ball, and a robot; all in 3D.
Troubleshooting
Xorg has probably changed since this ebuild was created (I have Modular Xorg 7.0) so I had to create a symlink for rgb.txt (you might not need to).
ln -s /usr/share/X11/rgb.txt /usr/X11R6/lib/X11/rgb.txt
Otherwise, you might get
... err: unable to open color database /usr/X11R6/lib/X11/rgb.txt : No such file or directory (stage.c stg_lookup_color) Segmentation fault
You might also see:
scotty ~ # player /usr/share/player/config/gazebo.cfg * Part of the Player/Stage/Gazebo Project [http://playerstage.sourceforge.net]. * Copyright (C) 2000 - 2006 Brian Gerkey, Richard Vaughan, Andrew Howard, * Nate Koenig, and contributors. Released under the GNU General Public License. * Player comes with ABSOLUTELY NO WARRANTY. This is free software, and you * are welcome to redistribute it under certain conditions; see COPYING * for details. error : Couldn't find driver "gz_sim" error : failed to parse config file /usr/share/player/config/gazebo.cfg
See http://www.nabble.com/Couldn%27t-find-driver-%22gz_sim%22-tf1850022.html
Miscellany
Like it says in the documentation, depending on what is already installed on your system, Player/Stage/Gazebo may have quite a few dependencies, so emerging may take a while...
Also, using the GUI features of gazebo will require emerging it with wxPython. A detailed HowTo is available at http://playerstage.sourceforge.net/doc/Gazebo-manual-0.5-html/install.html
Created by NickStallman.net, Luxury Homes Australia
Real estate agents should be using interactive floor plans and list their apartments, townhouses and units.
