More info about change compiler
[anna.git] / README.md
index 840e9ac..0ed188a 100644 (file)
--- a/README.md
+++ b/README.md
@@ -1,56 +1,63 @@
-ANNA
-====
-ANNA is the acronym for "ANNA is not 'N' anymore", a complete suite of tools and resources
- to build proffesional applications with minimum cost.
+# ANNA
 
-Revision control
-================
-Based on GIT, hosted on www.bitbucket.org.
+Multi-purpose C++ development suite, focused on Telco resources (communications, protocols and tools).
+ANNA is acronym for "Anna is not nothingness anymore", that is to say: "Anna is something to take into
+account" (like a SONaTINA).
+
+ANNA is a complete suite of tools and resources to build proffesional applications with minimum cost.
+
+## Revision control
+
+Based on GIT, hosted on http://redmine.teslayout.com
 
 You could use my pre-commit specific template if you want to do some basic checkings (i.e.
- astyle code processing): Execute './scr/git/use-pre-commit.sh'
+ astyle code processing): Execute './scripts/git/use-pre-commit.sh'
+
+
+## Build project
+
+This is a CMake based building suite.
+Install cmake:
 
-Documentation
-=============
-Execute 'scons doc'
+     > sudo apt-get install cmake
 
-Unit tests
-==========
-Execute 'scons test'
+And then generate the makefiles from project root directory:
 
-Examples
-========
-Execute 'scons examples' to generate example binaries
+     > cmake .
 
-Install
-=======
-Execute 'scons install'
-(install-include-and-lib and install-example, are another aliases for selective installation)
+You could specify type of build, 'Debug' or 'Release', for example:
 
-Uninstall
-=========
-Execute 'scons uninstall'
+     > cmake -DCMAKE_BUILD_TYPE=Debug .
+     > cmake -DCMAKE_BUILD_TYPE=Release .
 
+## Clean project
 
+     > make clean
 
-Some basic ubuntu requirements
-==============================
-* Scons python-based building suite:
-     sudo apt-get install scons
+## Change the compilers
 
-* OpenSSL:
-     sudo apt-get install libssl-dev
+     > cmake -DCMAKE_CXX_COMPILER=/usr/bin/g++     -DCMAKE_C_COMPILER=/usr/bin/gcc
+     or
+     > cmake -DCMAKE_CXX_COMPILER=/usr/bin/clang++ -DCMAKE_C_COMPILER=/usr/bin/clang
+
+## Some basic ubuntu requirements
+
+### OpenSSL:
+     > sudo apt-get install libssl-dev
  
-* Gnome XML:
-     sudo apt-get install libxml2-dev
+### Gnome XML:
+     > sudo apt-get install libxml2-dev
+
+### OpenLDAP:
+     > sudo apt-get install libldap2-dev
 
-* OpenLDAP:
-     sudo apt-get install libldap2-dev
+### Pcap:
+     > sudo apt-get install libpcap-dev
 
-* MySql:
-     sudo apt-get install libmysqlclient-dev
+### MySql:
+     sudo apt-get install libmysqlclient-dev
 
-* Oracle:
+### Oracle:
      https://help.ubuntu.com/community/Oracle%20Instant%20Client
      Set 'ORACLE_HOME' environment variable in your profile, i.e.:
         export ORACLE_HOME=/usr/lib/oracle/12.1/client64/
@@ -58,7 +65,7 @@ Some basic ubuntu requirements
      Be sure to create in that directory, a link to oracle includes,
      for example:
 
-       <user>@<host>:/usr/lib/oracle/12.1/client64$ ls -lrt
+       /usr/lib/oracle/12.1/client64$ ls -lrt
        total 8
        drwxr-xr-x 2 root root 4096 Feb 28 15:59 bin
        drwxr-xr-x 2 root root 4096 Feb 28 15:59 lib
@@ -67,19 +74,58 @@ Some basic ubuntu requirements
      The alternative is to edit SConstruct file directly to set
      oracle includes directory.
 
-* Oracle-OpenLDAP conflict:
+### Oracle-OpenLDAP conflict:
      as usual, Oracle is doing things very bad. Move the ldap.h from oracle includes, i.e.:
 
-        cd /usr/include/oracle/12.1/client64
-        sudo mv ldap.h ldap.h.orig
+        cd /usr/include/oracle/12.1/client64
+        sudo mv ldap.h ldap.h.orig
 
-* Boost:
-     Although the more i use, the more i dislike, this suite is included (ambition to learn
-     new things...):
+### Google Test Framework:
 
-        sudo apt-get install libboost-dev
-        sudo apt-get install libboost-test-dev
+     > sudo apt-get install libgtest-dev
 
+     Note that this package only install source files. You have to compile the
+     code yourself to create the necessary library files. These source files
+     should be located at /usr/src/gtest. Browse to this folder and use cmake
+     to compile the library:
+
+     > cd /usr/src/gtest
+     > sudo cmake CMakeLists.txt
+     > sudo make
  
+     Copy or symlink libgtest.a and libgtest_main.a to your /usr/lib folder:
+     > sudo cp *.a /usr/lib
+
+## Documentation
+
+Execute 'make doc'
+
+     > cd docs/doxygen
+     > tree -L 1
+
+     .
+     ├── Doxyfile
+     ├── html
+     ├── latex
+     └── man
+
+
+## Unit tests
+
+Execute 'make test'
+
+## Install
+
+To install headers, libraries, and examples, execute:
+
+     > make install
+
+Optionally you could specify another prefix for installation:
+
+     > cmake -DCMAKE_INSTALL_PREFIX=$HOME/anna_deploy .
+
+## Uninstall
+
+     > cat install_manifest.txt | sudo xargs rm