1
0
mirror of https://github.com/gnss-sdr/gnss-sdr synced 2025-01-12 02:10:34 +00:00

adding CMake instructions and some other information. Updating Armadillo version and Mac OS X information. Fixing a non-sense sentence. Added 'ldconfig' in order to make sure that libraries are found.

git-svn-id: https://svn.code.sf.net/p/gnss-sdr/code/trunk@320 64b25241-fba3-4117-9849-534c7e92360d
This commit is contained in:
Carles Fernandez 2013-01-18 19:53:14 +00:00
parent 5ce8689209
commit fec4dde45c

110
README
View File

@ -21,15 +21,15 @@ This can take a while (up to two hours to complete, depending on your system), a
export PYTHONPATH=/usr/local/lib/python2.7/dist-packages
export LD_LIBRARY_PATH=/usr/local/lib
where /path/to/gnuradio is the folder in which you invoked build-gnuradio. In order to avoid defining these variables each time you enter a session, you may want to add these three lines to your $HOME/.bashrc file.
In order to avoid defining these variables each time you enter a session, you may want to add these three lines to your $HOME/.bashrc file.
* Install other libraries used by GNSS-SDR:
- Download, compile, and install the Armadillo linear algebra library
$ wget http://sourceforge.net/projects/arma/files/armadillo-3.4.3.tar.gz
$ tar xvfz armadillo-3.4.3.tar.gz
$ cd armadillo-3.4.3
$ wget http://sourceforge.net/projects/arma/files/armadillo-3.6.1.tar.gz
$ tar xvfz armadillo-3.6.1.tar.gz
$ cd armadillo-3.6.1
$ cmake .
$ make
$ sudo make install
@ -60,8 +60,7 @@ Please DO NOT install gtest (do not do "sudo make install"). Every user needs to
export GTEST_DIR=/home/username/gtest-1.6.0
changing /home/username/gtest-1.6.0 by the actual directory where you downloaded gtest.
changing /home/username/gtest-1.6.0 by the actual directory where you downloaded gtest. Again, it is recommended to add this line to your $HOME/.bashrc file.
- Download, unzip, configure, build and install Google's gflags package, a commandline flags processing module for C++:
@ -72,15 +71,17 @@ $ cd gflags-2.0
$ ./configure
$ make
$ sudo make install
$ sudo ldconfig
- Download, unzip, configure, build and install glog, a Google's library that implements application-level logging:
$ wget http://google-glog.googlecode.com/files/glog-0.3.2.tar.gz
$ tar xvfz glog-0.3.2.tar.gz
$ cd glog-0.3.2
$ cd glog-0.3.2
$ ./configure
$ make
$ sudo make install
$ sudo ldconfig
- Install Subversion
@ -90,6 +91,25 @@ $ sudo apt-get install subversion
$ svn co http://svn.code.sf.net/p/gnss-sdr/code/trunk gnss-sdr
Checking out GNSS-SDR as in the line above will create a folder named gnss-sdr with the following structure:
|-gnss-sdr
|---build <- where gnss-sdr is built
|---cmake <- CMake-related files
|---conf <- Configuration files. Each file represents one receiver.
|---data <- Populate this folder with your captured data.
|---docs <- Contains documentation-related files
|---drivers <- Drivers for some RF front-ends
|---firmware <- Firmware for some front-ends
|---install <- Executables
|---src <- Source code folder
|-----algorithms
|-----core
|-----main
|-----tests
|-----utils <- some utilities (e.g. Matlab scripts)
* Build GN3S V2 Custom firmware and driver (OPTIONAL)
@ -152,17 +172,86 @@ The default will be OSMOSDR_ROOT=/usr/local
* Build GNSS-SDR
You can choose either Bjam or CMake as a building tool. We are progressively moving to CMake, but Bjam is still available.
Using CMake
------------
- Go to GNSS-SDR's build directory:
$ cd gnss-sdr/build
- Configure and build the program:
$ cmake ../
$ make
- Move the executables to the install folder
$ make install
If everything goes well, two new executables will be created at gnss-sdr/install, namely gnss-sdr and run_tests.
You can create the documentation by doing:
$ make doc
from the gnss-sdr/build folder. This will generate HTML documentation that can be retrieved pointing your browser of preference to gnss-sdr/docs/html/index.html.
If a LaTeX installation is detected in your system,
$ make pdfmanual
will create a PDF manual at gnss-sdr/docs/GNSS-SDR_manual.pdf. Please note that the PDF generation requires some fonts to be installed on the host system. In Ubuntu 12.10, those fonts do not come by default. You can install them by doing:
$ sudo apt-get install texlive-fonts-recommended
and then run cmake ../ and make pdfmanual again. Finally,
$ make doc-clean
will remove the content of previously-generated documentation.
By default, CMake will build the Release version, meaning that the compiler will generate a faster, optimized executable. This is the recommended build type when using a RF front-end and you need to attain real time. Ifyou are working with a file (and thus without real-time constraints), you may want to obtain more information about the internals of the receiver, as well as more fine-grained logging. This can be done by building the Debug version, by doing:
$ cd gnss-sdr/build
$ cmake -DCMAKE_BUILD_TYPE=Debug ../
$ make
$ make install
Using Bjam
----------
- Go to GNSS-SDR's root directory and compile the program:
$ cd gnss-sdr
$ bjam
If everything went fine, a executable will be found at gnss-sdr/install/gnss-sdr
If everything went fine, two new executables will be created at gnss-sdr/install, namely gnss-sdr and run_tests.
- You can also build the release version (an optimized, faster executable) by typing:
$ bjam release
You can create the documentation by doing:
$ doxygen
from the gnss-sdr/build folder. This will generate HTML documentation that can be retrieved pointing your browser of preference to gnss-sdr/docs/html/index.html.
Updating GNSS-SDR
-----------------
If you checked out GNSS-SDR some days ago, it is possible that some developer has updated files at the Subversion repository. You can update your working copy by doing:
$ cd gnss-sdr
$ svn up
Before rebuiling the source code, it is safe (and recommended) to remove the remainders of old builds:
$ rm -rf gnss-sdr/build/*
@ -176,6 +265,9 @@ In order to take advantage of VOLK, compile it with the (rather old) GCC 4.2:
$ sudo port install gnuradio-devel +grc +python27 +uhd +orc +swig +qtgui +wxgui configure.compiler=llvm-gcc-4.2
However, GNSS-SDR cannot be compiled by GCC 4.2. It has been succesfully built with GCC 4.6, and (could) work in 4.5. If you compile GNU Radio with clang, apart from neglecting the benefits of VOLK, then the problem for building GNSS-SDR is Armadillo.
Check out http://llvm.org/bugs/show_bug.cgi?id=14768 in order to see the status of this bottleneck.
GETTING STARTED
---------------
@ -183,7 +275,7 @@ GETTING STARTED
1. After building the code, you will find the gnss-sdr executable file at gnss-sdr/install
2. At this moment, the real-time connection with the RF front-ends (USRPs or USB GNSS dongles) is not implemented yet. You need to work in post-processing mode. This means that you have to provide a captured GNSS signal file.
2. In post-processing mode, you have to provide a captured GNSS signal file.
2.1. The signal file can be easily recorded using the GNU Radio file sink in gr_complex<float> mode.