Skip to content
This repository
Newer
Older
100644 219 lines (147 sloc) 6.614 kb
090db653 »
2011-08-05 added notes on OS X 10.7 installation
1 Quick start: Build Stage from RTV's Github
2 ------------------------------------------
3
12bbec6f »
2011-08-05 added Ubuntu instructions after testing new build scripts on Ubuntu 1…
4 Tested 2011.8.5 on:
5
6 - OS X 10.7 Lion
7 - Ubuntu 11.04
090db653 »
2011-08-05 added notes on OS X 10.7 installation
8
9 1) Install Stage's dependencies:
10
11 FLTK >=1.1
12 git
13 cmake
14 pkg-config
12bbec6f »
2011-08-05 added Ubuntu instructions after testing new build scripts on Ubuntu 1…
15 libpng
16 jpeglib
17 OpenGLU
090db653 »
2011-08-05 added notes on OS X 10.7 installation
18
19 On the Mac I use Homebrew, since MacPorts installs way more than Stage needs (http://mxcl.github.com/homebrew/)
20
21 $ brew install --HEAD fltk cmake git pkg-config
22
23 If you want to use Player/Stage, install and test Player now.
24
25 2) Get and build Stage
26
27 $ mkdir stage4
28 $ cd stage4
29 $ git clone git://github.com/rtv/Stage.git
30 $ export STG=$HOME/stg
31 $ cmake -DCMAKE_INSTALL_PREFIX=$STG Stage
32 $ make
33
34 3) Install and set up environment
35
36 $ make install
12bbec6f »
2011-08-05 added Ubuntu instructions after testing new build scripts on Ubuntu 1…
37
38 On OS X:
39
090db653 »
2011-08-05 added notes on OS X 10.7 installation
40 $ export DYLD_LIBRARY_PATH=$STG/lib
41
12bbec6f »
2011-08-05 added Ubuntu instructions after testing new build scripts on Ubuntu 1…
42 On Linux:
43
44 $ export LD_LIBRARY_PATH=$STG/lib
45
090db653 »
2011-08-05 added notes on OS X 10.7 installation
46 4) Run Stage
47 $ stage Stage/worlds/simple.world
48
49 5) Please report build issues, bugs or other problems using the tracker at http://github.com/rtv/Stage/issues
50
51
52 --- Longer instructions ------------------------------------------
f48d622f » gerkey
2005-02-07 Modernized configure.in for autoconf 2.58 / automake 1.7.
53
3bd03c8e » jeremy_asher
2008-07-10 Documentation changed to source INSTALL file for instructions
54 Build system
55 ------------
72c8156c » rtv
2009-01-23 bugfixes
56 Stage is now built using the CMake build system (version 2.4.7 or
57 newer). This has two main advantages over the old GNU
58 autoconf/automake system: (i) it is much faster; (ii) CMake can create
59 native build files for Windows and Mac OS X, which will help Stage
60 become more portable.
9193b683 » gerkey
2002-08-21 new files needed for Autotools
61
18d767c2 » jeremy_asher
2008-07-11 Added dependencies section to install docs
62 Dependencies
63 ------------
996c2812 » rtv
2009-09-26 replaced some c-strings with std::strings
64 Building Stage requires the following tools and libraries:
18d767c2 » jeremy_asher
2008-07-11 Added dependencies section to install docs
65
996c2812 » rtv
2009-09-26 replaced some c-strings with std::strings
66 - pkg-config
18d767c2 » jeremy_asher
2008-07-11 Added dependencies section to install docs
67 - FLTK 1.1.x
68 - OpenGL
69 - libpng
70 - ltdl (Libtool)
9193b683 » gerkey
2002-08-21 new files needed for Autotools
71
552aa07c »
2010-11-25 preparing package for release 4.0.0
72 The optional Player plugin requires Player >= 2.1.
73
74 The optional Avonstage web-enabled binary requires Avon >= 0.1.
7f749cd2 » rtv
2009-07-22 preparing 3.1 rel
75
40d33186 » mani-monaj
2011-09-22 Added some information about dependencies and opengl for Linux to INS…
76 On a typical Debian based Linux distribution (like Ubuntu & Mint) you can install above dependencies using this command: (assuming that you have already installed build tools like cmake and build-essentials)
77
78 sudo apt-get install pkg-config libfltk1.1-dev libgl1-mesa-dev libglu1-mesa-dev libpng12-dev libtool
79
80 Please note that OpenGL libraries (gl1 & glu1) come with graphics card drivers and they are vendor based, therefore you need to inatall required drivers for your graphics card first.
81
3bd03c8e » jeremy_asher
2008-07-10 Documentation changed to source INSTALL file for instructions
82 Configuring the build
83 ---------------------
40d33186 » mani-monaj
2011-09-22 Added some information about dependencies and opengl for Linux to INS…
84 Unpack the distribution or check it out from Git. Change directory to
0304ea3d » rtv
2008-07-08 adding to config.h, removing dead files and moving some things around…
85 the top level of the Stage source tree.
f48d622f » gerkey
2005-02-07 Modernized configure.in for autoconf 2.58 / automake 1.7.
86
0304ea3d » rtv
2008-07-08 adding to config.h, removing dead files and moving some things around…
87 First, you may need to help CMake find your the libraries on which
88 Stage depends. For example, if you use MacPorts on OS X, packages are
4fbd8085 » jeremy_asher
2008-07-11 Fixed INSTALL formatting
89 usually installed in `/opt/local`, which is not in CMake's default
0304ea3d » rtv
2008-07-08 adding to config.h, removing dead files and moving some things around…
90 system search path. Add your non-standard software directories to
91 CMake's search paths by setting environment variables, e.g. in bash:
9193b683 » gerkey
2002-08-21 new files needed for Autotools
92
3bd03c8e » jeremy_asher
2008-07-10 Documentation changed to source INSTALL file for instructions
93 $ export CMAKE_INCLUDE_PATH=/opt/local/include
94 $ export CMAKE_LIBRARY_PATH=/opt/local/lib
f48d622f » gerkey
2005-02-07 Modernized configure.in for autoconf 2.58 / automake 1.7.
95
0304ea3d » rtv
2008-07-08 adding to config.h, removing dead files and moving some things around…
96 If you want to use Player with Stage, install Player first, then make
97 sure that pkg-config can find it. Test it like so:
f48d622f » gerkey
2005-02-07 Modernized configure.in for autoconf 2.58 / automake 1.7.
98
3bd03c8e » jeremy_asher
2008-07-10 Documentation changed to source INSTALL file for instructions
99 $ pkg-config --modversion playercore
f48d622f » gerkey
2005-02-07 Modernized configure.in for autoconf 2.58 / automake 1.7.
100
0304ea3d » rtv
2008-07-08 adding to config.h, removing dead files and moving some things around…
101 This should output the version number of the Player installation
102 (probably 2.2.0 or later). If not, add the location of Player's
7f749cd2 » rtv
2009-07-22 preparing 3.1 rel
103 pkg-config file to your `PKG_CONFIG_PATH`, eg. in bash, and replacing <Player installation prefix> with the correct directory, do:
9193b683 » gerkey
2002-08-21 new files needed for Autotools
104
3bd03c8e » jeremy_asher
2008-07-10 Documentation changed to source INSTALL file for instructions
105 $ export PKG_CONFIG_PATH+=<Player installation prefix>/lib/pkgconfig
9193b683 » gerkey
2002-08-21 new files needed for Autotools
106
0304ea3d » rtv
2008-07-08 adding to config.h, removing dead files and moving some things around…
107 Now that the supporting software is set up, you can decide where you
108 want to install Stage. The default installation directory varies by
4fbd8085 » jeremy_asher
2008-07-11 Fixed INSTALL formatting
109 system, but is often `/usr/local` on Unix variants. This is easy and is
0304ea3d » rtv
2008-07-08 adding to config.h, removing dead files and moving some things around…
110 often a good choice, but has the disadvantage that installation needs
111 root/sudo priviliges. To install in the default location, do:
112
3bd03c8e » jeremy_asher
2008-07-10 Documentation changed to source INSTALL file for instructions
113 $ cmake .
0304ea3d » rtv
2008-07-08 adding to config.h, removing dead files and moving some things around…
114
4fbd8085 » jeremy_asher
2008-07-11 Fixed INSTALL formatting
115 If you wish to install Stage elsewhere, define the `CMAKE_INSTALL_PATH`
0304ea3d » rtv
2008-07-08 adding to config.h, removing dead files and moving some things around…
116 path variable when invoking cmake. To do this, use this command,
4fbd8085 » jeremy_asher
2008-07-11 Fixed INSTALL formatting
117 substituting `<prefix>` with your chosen installation
0304ea3d » rtv
2008-07-08 adding to config.h, removing dead files and moving some things around…
118 directory.
119
3bd03c8e » jeremy_asher
2008-07-10 Documentation changed to source INSTALL file for instructions
120 $ cmake -DCMAKE_INSTALL_PREFIX=<prefix> .
0304ea3d » rtv
2008-07-08 adding to config.h, removing dead files and moving some things around…
121
4fbd8085 » jeremy_asher
2008-07-11 Fixed INSTALL formatting
122 For example to install in `$HOME/playerstage`, do:
0304ea3d » rtv
2008-07-08 adding to config.h, removing dead files and moving some things around…
123
3bd03c8e » jeremy_asher
2008-07-10 Documentation changed to source INSTALL file for instructions
124 $ cmake -DCMAKE_INSTALL_PREFIX=$HOME/playerstage .
0304ea3d » rtv
2008-07-08 adding to config.h, removing dead files and moving some things around…
125
b4caa835 » rtv
2008-07-08 successfully generated, built and installed source package
126 Cmake will generate makefiles specifically for your machine. When this
4fbd8085 » jeremy_asher
2008-07-11 Fixed INSTALL formatting
127 is done, you can inspect and edit the build settings by using ccmake:
128
129 $ ccmake .
130
131 or by editing the file CMakeCache.txt manually.
0304ea3d » rtv
2008-07-08 adding to config.h, removing dead files and moving some things around…
132
3bd03c8e » jeremy_asher
2008-07-10 Documentation changed to source INSTALL file for instructions
133 Building
134 --------
0304ea3d » rtv
2008-07-08 adding to config.h, removing dead files and moving some things around…
135 In the top level directory of the source tree, do:
136
3bd03c8e » jeremy_asher
2008-07-10 Documentation changed to source INSTALL file for instructions
137 $ make
0304ea3d » rtv
2008-07-08 adding to config.h, removing dead files and moving some things around…
138
3bd03c8e » jeremy_asher
2008-07-10 Documentation changed to source INSTALL file for instructions
139 Installing
140 ----------
0304ea3d » rtv
2008-07-08 adding to config.h, removing dead files and moving some things around…
141 In the top level directory of the source tree, do:
142
3bd03c8e » jeremy_asher
2008-07-10 Documentation changed to source INSTALL file for instructions
143 $ make install
0304ea3d » rtv
2008-07-08 adding to config.h, removing dead files and moving some things around…
144
145 (You may need to run this command as root or sudo, depending on the
146 install location).
147
148 Stage will install its components in various directories, for example:
149
4fbd8085 » jeremy_asher
2008-07-11 Fixed INSTALL formatting
150 <prefix>/bin (executables, including the 'stage' program)
151 <prefix>/lib (libraries, including libstage)
152 <prefix>/share (contains data resources, such as images)
0304ea3d » rtv
2008-07-08 adding to config.h, removing dead files and moving some things around…
153
3bd03c8e » jeremy_asher
2008-07-10 Documentation changed to source INSTALL file for instructions
154 Setup
155 -----
0304ea3d » rtv
2008-07-08 adding to config.h, removing dead files and moving some things around…
156 You must ensure that the dynamic library libstage.so (or
157 libstage.dylib, or libstage.dll, depending on your platform) can be
158 found by your system's library loader. The method for doing this
159 varies by platform.
160
4fbd8085 » jeremy_asher
2008-07-11 Fixed INSTALL formatting
161 On Linux, using bash:
0304ea3d » rtv
2008-07-08 adding to config.h, removing dead files and moving some things around…
162
3bd03c8e » jeremy_asher
2008-07-10 Documentation changed to source INSTALL file for instructions
163 $ export LD_LIBRARY_PATH=<prefix>/lib
0304ea3d » rtv
2008-07-08 adding to config.h, removing dead files and moving some things around…
164
4fbd8085 » jeremy_asher
2008-07-11 Fixed INSTALL formatting
165 On OS X, using bash:
0304ea3d » rtv
2008-07-08 adding to config.h, removing dead files and moving some things around…
166
3bd03c8e » jeremy_asher
2008-07-10 Documentation changed to source INSTALL file for instructions
167 $ export DYLD_LIBRARY_PATH=<prefix>/lib
0304ea3d » rtv
2008-07-08 adding to config.h, removing dead files and moving some things around…
168
4fbd8085 » jeremy_asher
2008-07-11 Fixed INSTALL formatting
169 If you plan to use Stage plugins, you also need to set the `STAGEPATH`
0304ea3d » rtv
2008-07-08 adding to config.h, removing dead files and moving some things around…
170 environment variable to include the directory that contains your
4fbd8085 » jeremy_asher
2008-07-11 Fixed INSTALL formatting
171 plugins. E.g. in bash, do:
0304ea3d » rtv
2008-07-08 adding to config.h, removing dead files and moving some things around…
172
3bd03c8e » jeremy_asher
2008-07-10 Documentation changed to source INSTALL file for instructions
173 $ export STAGEPATH=/usr/local/lib
0304ea3d » rtv
2008-07-08 adding to config.h, removing dead files and moving some things around…
174
4fbd8085 » jeremy_asher
2008-07-11 Fixed INSTALL formatting
175 If you installed Stage somewhere other than `/usr/local`, substitute
0304ea3d » rtv
2008-07-08 adding to config.h, removing dead files and moving some things around…
176 your install prefix:
177
3bd03c8e » jeremy_asher
2008-07-10 Documentation changed to source INSTALL file for instructions
178 $ export STAGEPATH=<stage install prefix>/lib
0304ea3d » rtv
2008-07-08 adding to config.h, removing dead files and moving some things around…
179
180 If you are using Stage with Player, you probably don't need to set the
4fbd8085 » jeremy_asher
2008-07-11 Fixed INSTALL formatting
181 `STAGEPATH`. However, you may need to set the `PLAYERPATH` to include
0304ea3d » rtv
2008-07-08 adding to config.h, removing dead files and moving some things around…
182 Stage's installed lib directory instead.
183
3bd03c8e » jeremy_asher
2008-07-10 Documentation changed to source INSTALL file for instructions
184 Testing
185 -------
0304ea3d » rtv
2008-07-08 adding to config.h, removing dead files and moving some things around…
186 To test your Stage installation, do:
187
3bd03c8e » jeremy_asher
2008-07-10 Documentation changed to source INSTALL file for instructions
188 $ <prefix>/bin/stage worlds/simple.world
0304ea3d » rtv
2008-07-08 adding to config.h, removing dead files and moving some things around…
189
190 You should see a window appear, showing some robots. You can change
191 the camera point of view by holding down the 'ctrl' key and moving the
192 mouse pointer. If this works, you are ready to write your own robot
193 simulations using libstage.
194
195 If you plan to use Stage plugins, you can test that plugins are
196 working:
197
3bd03c8e » jeremy_asher
2008-07-10 Documentation changed to source INSTALL file for instructions
198 $ <prefix>/bin/stage worlds/fasr.world
0304ea3d » rtv
2008-07-08 adding to config.h, removing dead files and moving some things around…
199
200 You should see a window appear, showing some robots. Try pressing the
201 'p' key to pause and un-pause the simulation, to check that the robots
202 are working. If this works, you are ready to write Stage plugins.
203
40d33186 » mani-monaj
2011-09-22 Added some information about dependencies and opengl for Linux to INS…
204 (If the stage window is flicking or some texts are not shown properly on Linux, try to disable compiz, if it is enabled)
205
3bd03c8e » jeremy_asher
2008-07-10 Documentation changed to source INSTALL file for instructions
206 Next steps
207 ----------
0304ea3d » rtv
2008-07-08 adding to config.h, removing dead files and moving some things around…
208 - read the Stage manual, available from the Player Project website
209 (also buildable from the docsrc directory in the source tree
210 (requires doxygen)).
211
212 - look at the examples provided in the worlds and examples
213 directories.
214
215
216 Enjoy using Stage -- rtv
217
4fbd8085 » jeremy_asher
2008-07-11 Fixed INSTALL formatting
218 "All the world's a stage, and all the men and women merely players"
0304ea3d » rtv
2008-07-08 adding to config.h, removing dead files and moving some things around…
219 Wm. Shakespeare - "As you like it"
Something went wrong with that request. Please try again.