06247b405a2464afdb45a467468dffe514d4206c
[anna.git] / README.md
1 # ANNA
2
3 Multi-purpose C++ development suite, focused on Telco resources (communications, protocols and tools).
4 ANNA is acronym for "Anna is not nothingness anymore", that is to say: "Anna is something to take into
5 account" (like a SONaTINA).
6
7 ANNA is a complete suite of tools and resources to build proffesional applications with minimum cost.
8
9 ## Revision control
10
11 Based on GIT, hosted on http://redmine.teslayout.com
12
13 You could use my pre-commit specific template if you want to do some basic checkings (i.e.
14  astyle code processing): Execute './scripts/git/use-pre-commit.sh'
15
16
17 ## Build project
18
19 This is a CMake based building suite.
20 Install cmake:
21
22      > sudo apt-get install cmake
23
24 And then generate the makefiles from project root directory:
25
26      > cmake .
27
28 You could specify type of build, 'Debug' or 'Release', for example:
29
30      > cmake -DCMAKE_BUILD_TYPE=Debug .
31      > cmake -DCMAKE_BUILD_TYPE=Release .
32
33 ## Clean project
34
35      > make clean
36
37 ## Change the compiler to Clang++
38
39      > cmake -DCMAKE_CXX_COMPILER=/usr/bin/clang++ 
40
41 ## Some basic ubuntu requirements
42
43 ### OpenSSL:
44      > sudo apt-get install libssl-dev
45  
46 ### Gnome XML:
47      > sudo apt-get install libxml2-dev
48
49 ### OpenLDAP:
50      > sudo apt-get install libldap2-dev
51
52 ### Pcap:
53      > sudo apt-get install libpcap-dev
54
55 ### MySql:
56      > sudo apt-get install libmysqlclient-dev
57
58 ### Oracle:
59      https://help.ubuntu.com/community/Oracle%20Instant%20Client
60      Set 'ORACLE_HOME' environment variable in your profile, i.e.:
61         export ORACLE_HOME=/usr/lib/oracle/12.1/client64/
62
63      Be sure to create in that directory, a link to oracle includes,
64      for example:
65
66         > /usr/lib/oracle/12.1/client64$ ls -lrt
67         total 8
68         drwxr-xr-x 2 root root 4096 Feb 28 15:59 bin
69         drwxr-xr-x 2 root root 4096 Feb 28 15:59 lib
70         lrwxrwxrwx 1 root root   33 Feb 28 16:07 include -> /usr/include/oracle/12.1/client64
71
72      The alternative is to edit SConstruct file directly to set
73      oracle includes directory.
74
75 ### Oracle-OpenLDAP conflict:
76      as usual, Oracle is doing things very bad. Move the ldap.h from oracle includes, i.e.:
77
78         > cd /usr/include/oracle/12.1/client64
79         > sudo mv ldap.h ldap.h.orig
80
81 ### Google Test Framework:
82
83      > sudo apt-get install libgtest-dev
84
85      Note that this package only install source files. You have to compile the
86      code yourself to create the necessary library files. These source files
87      should be located at /usr/src/gtest. Browse to this folder and use cmake
88      to compile the library:
89
90      > cd /usr/src/gtest
91      > sudo cmake CMakeLists.txt
92      > sudo make
93  
94      Copy or symlink libgtest.a and libgtest_main.a to your /usr/lib folder:
95      > sudo cp *.a /usr/lib
96
97 ## Documentation
98
99 Execute 'make doc'
100
101      > cd docs/doxygen
102      > tree -L 1
103
104      .
105      ├── Doxyfile
106      ├── html
107      ├── latex
108      └── man
109
110
111 ## Unit tests
112
113 Execute 'make test'
114
115 ## Install
116
117 To install headers, libraries, and examples, execute:
118
119      > make install
120
121 Optionally you could specify another prefix for installation:
122
123      > cmake -DCMAKE_INSTALL_PREFIX=$HOME/anna_deploy .
124
125 ## Uninstall
126
127      > cat install_manifest.txt | sudo xargs rm
128
129