| 1 |
# |
|---|
| 2 |
# Copyright 2001,2002,2003,2004,2005,2006 Free Software Foundation, Inc. |
|---|
| 3 |
# |
|---|
| 4 |
# This file is part of GNU Radio |
|---|
| 5 |
# |
|---|
| 6 |
# GNU Radio is free software; you can redistribute it and/or modify |
|---|
| 7 |
# it under the terms of the GNU General Public License as published by |
|---|
| 8 |
# the Free Software Foundation; either version 3, or (at your option) |
|---|
| 9 |
# any later version. |
|---|
| 10 |
# |
|---|
| 11 |
# GNU Radio is distributed in the hope that it will be useful, |
|---|
| 12 |
# but WITHOUT ANY WARRANTY; without even the implied warranty of |
|---|
| 13 |
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|---|
| 14 |
# GNU General Public License for more details. |
|---|
| 15 |
# |
|---|
| 16 |
# You should have received a copy of the GNU General Public License |
|---|
| 17 |
# along with GNU Radio; see the file COPYING. If not, write to |
|---|
| 18 |
# the Free Software Foundation, Inc., 51 Franklin Street, |
|---|
| 19 |
# Boston, MA 02110-1301, USA. |
|---|
| 20 |
# |
|---|
| 21 |
|
|---|
| 22 |
Welcome to GNU Radio! |
|---|
| 23 |
|
|---|
| 24 |
|
|---|
| 25 |
As of August 3, 2006 we have restructured the GNU Radio build process |
|---|
| 26 |
and moved the source code repository from CVS to subversion. |
|---|
| 27 |
|
|---|
| 28 |
Please see http://gnuradio.org/trac for the wiki, bug tracking, |
|---|
| 29 |
and source code viewer. |
|---|
| 30 |
|
|---|
| 31 |
The bleeding edge code can be found in our subversion repository at |
|---|
| 32 |
http://gnuradio.org/svn. To checkout the latest, use this |
|---|
| 33 |
command: |
|---|
| 34 |
|
|---|
| 35 |
$ svn co http://gnuradio.org/svn/gnuradio/trunk gnuradio |
|---|
| 36 |
|
|---|
| 37 |
For information about subversion, please see: |
|---|
| 38 |
http://subversion.tigris.org/ |
|---|
| 39 |
|
|---|
| 40 |
|
|---|
| 41 |
|
|---|
| 42 |
GNU Radio is now distributed as one giant blob, instead of N smaller |
|---|
| 43 |
blobs. We believe that this will reduce some of the build problems |
|---|
| 44 |
people were seeing. Now you'll always get all of the code, and the |
|---|
| 45 |
configure step will determine which components can be built on your |
|---|
| 46 |
system. |
|---|
| 47 |
|
|---|
| 48 |
|
|---|
| 49 |
How to Build GNU Radio: |
|---|
| 50 |
|
|---|
| 51 |
(1) Ensure that you've satisfied the external dependencies listed |
|---|
| 52 |
below. The word "system" is used to mean "operating system |
|---|
| 53 |
and/or distribution", and means a full operating system, |
|---|
| 54 |
including kernel, user-space utilties, and a packaging system |
|---|
| 55 |
for additional software. On Linux, this means what |
|---|
| 56 |
"distribution" means. |
|---|
| 57 |
|
|---|
| 58 |
With the exception of SDCC, the following GNU/Linux |
|---|
| 59 |
distributions are known to come with all required dependencies |
|---|
| 60 |
pre-packaged: Ubuntu 6.06, SuSE 10.0 (the pay version, not the |
|---|
| 61 |
free download), Fedora Core 5. Other distribution may work too. |
|---|
| 62 |
We know these three are easy. The required packages may be |
|---|
| 63 |
contained on your installation CD/DVD, or may be loaded over the |
|---|
| 64 |
net. The specifics vary depending on your GNU/Linux |
|---|
| 65 |
distribution. |
|---|
| 66 |
|
|---|
| 67 |
On systems using pkgsrc (e.g. NetBSD and Dragonfly), build |
|---|
| 68 |
meta-packages/gnuradio, which will build a previous release and |
|---|
| 69 |
force installation of the dependencies. Then pkg_delete the |
|---|
| 70 |
gnuradio and usrp packages, which will leave the dependencies. |
|---|
| 71 |
(This should also work on OSX.) |
|---|
| 72 |
|
|---|
| 73 |
See the wiki at http://gnuradio.org/trac/wiki for details. |
|---|
| 74 |
|
|---|
| 75 |
FIXME: update the wiki; talk about OS/X, NetBSD and MinGW too. |
|---|
| 76 |
|
|---|
| 77 |
(2) do the "usual dance" |
|---|
| 78 |
|
|---|
| 79 |
$ ./bootstrap # not reqd when building from the tarball |
|---|
| 80 |
$ ./configure |
|---|
| 81 |
$ make && make check |
|---|
| 82 |
$ sudo make install |
|---|
| 83 |
|
|---|
| 84 |
|
|---|
| 85 |
That's it! |
|---|
| 86 |
|
|---|
| 87 |
|
|---|
| 88 |
------------------------------------------------------------------------------- |
|---|
| 89 |
|
|---|
| 90 |
KNOWN INCOMPATIBILITIES |
|---|
| 91 |
|
|---|
| 92 |
|
|---|
| 93 |
GNU Radio triggers bugs in g++ 3.3 for X86. DO NOT USE GCC 3.3 on |
|---|
| 94 |
the X86 platform. g++ 3.2, 3.4, and the 4.* series are known to work well. |
|---|
| 95 |
|
|---|
| 96 |
------------------------------------------------------------------------------- |
|---|
| 97 |
|
|---|
| 98 |
------------------------------------------------------------------------------- |
|---|
| 99 |
|
|---|
| 100 |
External dependencies |
|---|
| 101 |
|
|---|
| 102 |
------------------------------------------------------------------------------- |
|---|
| 103 |
|
|---|
| 104 |
Prerequisites: Before trying to build these from source, please try |
|---|
| 105 |
your system's installation tool (apt-get, pkg_install, YaST, yum, |
|---|
| 106 |
urpmi, etc.) first. Most recent systems have these packages |
|---|
| 107 |
available. |
|---|
| 108 |
|
|---|
| 109 |
You'll need to do a bit of sleuthing to figure out what your OS and |
|---|
| 110 |
packaging system calls these. If your system uses the convention of |
|---|
| 111 |
splitting files needed to run programs compiled with foo and files |
|---|
| 112 |
needed to do the compilation into packages named foo and foo-devel, |
|---|
| 113 |
install both packages. (Most GNU/Linux systems are like this, but |
|---|
| 114 |
pkgsrc is not and instead uses -devel to indicate a package of a |
|---|
| 115 |
not-yet-released or unstable version.) |
|---|
| 116 |
|
|---|
| 117 |
|
|---|
| 118 |
(1) The "autotools" |
|---|
| 119 |
|
|---|
| 120 |
autoconf 2.57 or later |
|---|
| 121 |
automake 1.7.4 or later |
|---|
| 122 |
libtool 1.5 or later |
|---|
| 123 |
|
|---|
| 124 |
If your system has automake-1.4, there's a good chance it also has |
|---|
| 125 |
automake-1.7 or later. Check your install disk and/or (on GNU/Linux) |
|---|
| 126 |
try: |
|---|
| 127 |
|
|---|
| 128 |
$ man update-alternatives |
|---|
| 129 |
|
|---|
| 130 |
for info on how some distributions support multiple versions. |
|---|
| 131 |
|
|---|
| 132 |
|
|---|
| 133 |
(2) pkgconfig 0.15.0 or later http://www.freedesktop.org/Software/pkgconfig |
|---|
| 134 |
|
|---|
| 135 |
From the web site: |
|---|
| 136 |
|
|---|
| 137 |
pkgconfig is a system for managing library compile/link flags that |
|---|
| 138 |
works with automake and autoconf. It replaces the ubiquitous *-config |
|---|
| 139 |
scripts you may have seen with a single tool. |
|---|
| 140 |
|
|---|
| 141 |
|
|---|
| 142 |
(3) FFTW 3.0 or later http://www.fftw.org |
|---|
| 143 |
|
|---|
| 144 |
IMPORTANT!!! When building FFTW, you MUST use the --enable-single and |
|---|
| 145 |
--enable-shared configure options. This builds the single precision |
|---|
| 146 |
floating point version which we use. You should also use either the |
|---|
| 147 |
--enable-3dnow or --enable-sse options if you're on an Athlon or Pentium |
|---|
| 148 |
respectively. |
|---|
| 149 |
|
|---|
| 150 |
[FIXME: GNU/Linux packages of single-precision fftw are typically called ??] |
|---|
| 151 |
In systems using pkgsrc, install math/fftwf. |
|---|
| 152 |
|
|---|
| 153 |
|
|---|
| 154 |
(4) Python 2.3 or later http://www.python.org |
|---|
| 155 |
|
|---|
| 156 |
Python 2.3 or later is now required. If your system splits |
|---|
| 157 |
python into a bunch of separate packages including python-devel or |
|---|
| 158 |
libpython you'll most likely need those too. |
|---|
| 159 |
|
|---|
| 160 |
|
|---|
| 161 |
(5) Numeric python library http://numeric.scipy.org |
|---|
| 162 |
|
|---|
| 163 |
Provides a high performance array type for Python. |
|---|
| 164 |
http://sourceforge.net/project/showfiles.php?group_id=1369&package_id=1351 |
|---|
| 165 |
|
|---|
| 166 |
|
|---|
| 167 |
(6) The Boost C++ Libraries http://www.boost.org |
|---|
| 168 |
|
|---|
| 169 |
We use the Smart Pointer library. Most systems already have the boost |
|---|
| 170 |
libraries available. In the unlikely event that yours doesn't, |
|---|
| 171 |
download the source and follow the build instructions. They're |
|---|
| 172 |
different from the normal ./configure && make |
|---|
| 173 |
|
|---|
| 174 |
|
|---|
| 175 |
(7) cppunit 1.9.14 or later. http://cppunit.sourceforge.net |
|---|
| 176 |
|
|---|
| 177 |
Unit testing framework for C++. |
|---|
| 178 |
|
|---|
| 179 |
|
|---|
| 180 |
(8) Simple Wrapper Interface Generator. http://www.swig.org |
|---|
| 181 |
|
|---|
| 182 |
These versions are known to work: |
|---|
| 183 |
1.3.23, 1.3.24, 1.3.25, 1.3.27, 1.3.28, 1.3.29 |
|---|
| 184 |
|
|---|
| 185 |
|
|---|
| 186 |
(9) SDCC: Small Device C Compiler. http://sdcc.sourceforge.net/ |
|---|
| 187 |
|
|---|
| 188 |
Use version 2.4.0 or later. |
|---|
| 189 |
|
|---|
| 190 |
This includes a C compiler and linker for the 8051. It's required to |
|---|
| 191 |
build the firmware for the USRP. If you don't have a USRP, don't |
|---|
| 192 |
worry about it. |
|---|
| 193 |
|
|---|
| 194 |
|
|---|
| 195 |
Optional, but nice to have: |
|---|
| 196 |
|
|---|
| 197 |
(10) wxPython. Python binding for the wxWidgets GUI framework. Use |
|---|
| 198 |
version 2.5.2.7 or later. Again, almost all systems have this |
|---|
| 199 |
available. |
|---|
| 200 |
|
|---|
| 201 |
As a last resort, build it from source (not recommended!) |
|---|
| 202 |
http://www.wxpython.org |
|---|
| 203 |
|
|---|
| 204 |
(11) xmlto version ? or later. http://cyberelk.net/tim/xmlto/index.html |
|---|
| 205 |
|
|---|
| 206 |
Wrapper for XML conversion tools to ease e.g. making html from docbook. |
|---|
| 207 |
|
|---|
| 208 |
|
|---|
| 209 |
---------------------------------------------------------------- |
|---|
| 210 |
|
|---|
| 211 |
If you've got doxygen installed and provide the --enable-doxygen |
|---|
| 212 |
configure option, the build process creates documentation for the |
|---|
| 213 |
class hierarchy etc. Point your browser at |
|---|
| 214 |
gnuradio/gnuradio-core/doc/html/index.html |
|---|
| 215 |
|
|---|
| 216 |
|
|---|
| 217 |
To run the examples you'll need to set PYTHONPATH. Note that the |
|---|
| 218 |
prefix and python version number in the path needs to match your |
|---|
| 219 |
installed version of python. |
|---|
| 220 |
|
|---|
| 221 |
$ export PYTHONPATH=/usr/local/lib/python2.4/site-packages |
|---|
| 222 |
|
|---|
| 223 |
You may want to add this to your shell init file (~/.bash_profile if |
|---|
| 224 |
you use bash). |
|---|
| 225 |
|
|---|
| 226 |
Note that on Fedora Core 4 and 5 when running on X86_64 machines, |
|---|
| 227 |
python is shippped with a strange (wrong) configuration that requires |
|---|
| 228 |
you to add both the lib64 and lib paths to your PYTHONPATH. |
|---|
| 229 |
E.g., |
|---|
| 230 |
|
|---|
| 231 |
$ export PYTHONPATH=/usr/local/lib64/python2.4/site-packages:/usr/local/lib/python2.4/site-packages |
|---|
| 232 |
|
|---|
| 233 |
[Don't complain to us, complain to the Fedora Core packagers.] |
|---|
| 234 |
|
|---|
| 235 |
|
|---|
| 236 |
Another handy trick if for example your fftw includes and libs are |
|---|
| 237 |
installed in, say ~/local/include and ~/local/lib, instead of |
|---|
| 238 |
/usr/local is this: |
|---|
| 239 |
|
|---|
| 240 |
$ export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$HOME/local/lib |
|---|
| 241 |
$ make CPPFLAGS="-I$HOME/local/include" |
|---|
| 242 |
|
|---|
| 243 |
|
|---|
| 244 |
Sometimes the prerequisites are installed in a location which is not |
|---|
| 245 |
included in the default compiler and linker search paths. This |
|---|
| 246 |
happens with pkgsrc and NetBSD. To build, tell configure to use these |
|---|
| 247 |
locations: |
|---|
| 248 |
|
|---|
| 249 |
LDFLAGS="-L/usr/pkg/lib -R/usr/pkg/lib" CPPFLAGS="-I/usr/pkg/include" ./configure --prefix=/usr/gnuradio |
|---|