Skip to content

HTTPS clone URL

Subversion checkout URL

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