blob: 04d7c3bad7067a7344be764beb30233f08960b70 [file] [log] [blame] [view]
Alexander Afanasyev2a8e6272014-03-17 19:36:50 -07001ndn-cpp-dev: A dev version of Named Data Networking client library for C++
Alexander Afanasyev553d0c82014-01-28 19:19:39 -08002===========================================================================
3
4Prerequisites
5-------------
6
Alexander Afanasyev2a8e6272014-03-17 19:36:50 -07007(These are prerequisites to build ndn-cpp-dev. To do development of ndn-cpp-dev code and update the build system,
Alexander Afanasyev553d0c82014-01-28 19:19:39 -08008 see Development Prerequisites.)
9
Alexander Afanasyev2a8e6272014-03-17 19:36:50 -070010Required:
Alexander Afanasyev553d0c82014-01-28 19:19:39 -080011
12* libcrypto
Alexander Afanasyev2a8e6272014-03-17 19:36:50 -070013* libsqlite3
Alexander Afanasyev553d0c82014-01-28 19:19:39 -080014* libcrypto++
Alexander Afanasyevdafdc372014-03-03 15:58:44 +000015* boost libraries (>= 1.48)
Alexander Afanasyev553d0c82014-01-28 19:19:39 -080016* OSX Security framework (on OSX platform only)
17
18Following are the detailed steps for each platform to install the prerequisites.
19
20* Mac OS X 10.7.3, Mac OS X 10.8.4
21
22 Install Xcode.
23 In Xcode Preferences > Downloads, install "Command Line Tools".
24
25* Mac OS X 10.9
26
27 Install Xcode. (Xcode on OS X 10.9 seems to already have the Command Line Tools.)
28
29 If using macports, dependencies can be installed using the following commands:
30
31 sudo port install boost sqlite3 libcryptopp
32
Alexander Afanasyevdafdc372014-03-03 15:58:44 +000033* Ubuntu 12.04, Ubuntu 13.10
Alexander Afanasyev553d0c82014-01-28 19:19:39 -080034
35 In a terminal, enter:
36
37 sudo apt-get install build-essential
Alexander Afanasyevdafdc372014-03-03 15:58:44 +000038 # For Ubuntu 12.04
39 sudo apt-get install libboost1.48-all-dev
40 # For Ubuntu 13.10
41 sudo apt-get install libboost-all-dev
42 sudo apt-get install libssl-dev libsqlite3-dev libcrypto++-dev
Alexander Afanasyev553d0c82014-01-28 19:19:39 -080043
44* Windows Cygwin
45
46 Cygwin is tested on Windows 7 64-bit with the "Devel" packages selected to install at the top level of the
47 cygwin installer. This includes libcrypto and libsqlite3.
48
49Build
50-----
51
Alexander Afanasyev2a8e6272014-03-17 19:36:50 -070052(These are instructions to build ndn-cpp-dev. To do development of ndn-cpp-dev
53code and update the build system, see Development.)
Alexander Afanasyev553d0c82014-01-28 19:19:39 -080054
Alexander Afanasyev2a8e6272014-03-17 19:36:50 -070055To build in a terminal, change directory to the ndn-cpp-dev root. Enter:
Alexander Afanasyev553d0c82014-01-28 19:19:39 -080056
57 ./waf configure
58 ./waf
59 sudo ./waf install
60
61This makes and installs the following items:
62
63* ``<LIBPATH>/libndn-cpp-dev.*``: static and dynamic NDN C++ libraries
64* ``<LIBPATH>/pkgconfig/libndn-cpp-dev.pc``: pkgconfig file storing all neccessary flags
65 to build against the library. For example, if pkgconfig or pkgconf package is
66 installed and PKG_CONFIG_PATH is configured properly (or ``<LIBPATH>/pkgconfig`` is a
67 default path), ``pkgconfig --libs --clflags libndn-cpp-dev`` will return all necessary
68 compile and link flags for the library.
69* ``<BINPATH>/tlvdump``: a simple tool to dump contents of TLV-formatted data
70* ``<BINPATH>/ndncatchunks3``: a simplified equivalent to ndncatchunks2 in NDNx package
71* ``<BINPATH>/ndnputchunks3``: a simplified equivalent to ndnputchunks2 in NDNx package
72
73If configured with tests: ``./waf configure --with-tests``), the above commands will
74also produce:
75
76* ``build/tests/unit-tests``: A tool to run unit tests for the library
77
78Documentation
79-------------
80
81To make documentation, enter:
82
83 ./waf doxygen
84
85This will produce doxygen API code documentation in:
86
87* build/doc/html
88
89Supported platforms
90-------------------
91
92(to be confirmed)
93
Alexander Afanasyev2a8e6272014-03-17 19:36:50 -070094ndn-cpp-dev is tested on the following platforms:
Alexander Afanasyevdafdc372014-03-03 15:58:44 +000095
96* Ubuntu 12.04 (64 bit and 32 bit)
97* Ubuntu 13.10 (64 bit and 32 bit)
98* Mac OS X 10.8
99* Mac OS X 10.9
Alexander Afanasyev553d0c82014-01-28 19:19:39 -0800100
101Development Prerequisites
102-------------------------
103
Alexander Afanasyev2a8e6272014-03-17 19:36:50 -0700104These steps are only needed to do development of ndn-cpp-dev code and update the build system.
Alexander Afanasyev553d0c82014-01-28 19:19:39 -0800105First follow the Prerequisites above for your platforms.
106
107* Mac OS X 10.7.3, Mac OS X 10.8.4, Mac OS X 10.9
108
109 Install MacPorts from http://www.macports.org/install.php
110 In a terminal, enter:
111
112 sudo port install doxygen
113
114* Ubuntu 12.04 (64 bit and 32 bit), Ubuntu 13.04 (64 bit)
115
116 In a terminal, enter:
117
118 sudo apt-get install doxygen
119
120Development
121-----------
122
123Follow Development Prerequisites above for your platform.