Main  /  Edit version 8  /  Edit version 9  /   /  Users Area

Difference "Installation of CppCMS Framework" ver. 8 versus ver. 9

Content:

<!--toc-->
## Requirements
We should divide the requirements into three categories:
- **Mandatory** -- you _must_ follow them
- **Recommended** -- you generally _should_ have them unless you have good reasons.
- **Suggested** -- you _may_ have them, they provide some useful functionality.
You can find list of packages for Debian and Ubuntu [there](/wikipp/en/page/install_debain_deps).
### Mandatory
- POSIX<sup><a href="#m1">1</a></sup> Compatible Platforms: Linux, FreeBSD, OpenSolaris and Cygwin<sup><a href="#m2">2</a></sup> are tested.
- Reasonable, standard complaint, C and C++ compilers that works smoothly with autotools.
GCC 3.4, 4.1, 4.2 and 4.3 (not recently) are tested. More compilers are planned to be tested.
- [CgiCC](http://www.gnu.org/software/cgicc/) library. Version 3.2.8 and above recommended.
- [Boost](http://www.boost.org/) libraries 1.33.1 or higher. 1.35 and above recommended.
- Python 2.x. It is used for compilation of templates to C++ code.
### Recommended
- [FastCGI](http://www.fastcgi.com/) Library including C++ bindings.
FastCGI is the most popular communication protocol that
is supported by vast majority of web servers.
- One of the following web servers:
- [Lighttpd](http://www.lighttpd.net/)
- [Nginx](http://nginx.net/)
- [Apache2](http://httpd.apache.org/) with `mod_fastcgi`.
They are supported by CppCMS scripts that allow debug your applications easily.
### Suggested
- [OSSP mm](http://www.ossp.org/pkg/lib/mm/) shared memory allocation library. Provides process shared cache backend for mod prefork.
- [Asio](http://tenermerx.com/Asio/) 1.0.0 and above or [Boost](http://www.boost.org/) 1.35.0 and above that includes Asio. Provides distributed cache and sessions backends.
- [libgcrypt](http://directory.fsf.org/project/libgcrypt/) cryptography library. Provides encrypted cookies session backend.
- [Sqlite3](http://www.sqlite.org/). It provides fast and simple DB for storage of sessions data.
- [GNU gettext](http://www.gnu.org/software/gettext/) -- it provides internationalization support.
It is not required for build, but it is required if you want to localize for your applications. It provides tools like xgettext. msgget and so on. CppCMS does not use its internationalization library.
## Build
### Getting sources
#### From Tarboll
You may download latest version from [SF Download Page](http://sourceforge.net/project/showfiles.php?group_id=209965). For example cppcms-X.Y.Z.tar.gz
Untar them
tar -xzvf cppcms-X.Y.Z.tar.gz
cd cppcms-X.Y.Z
#### From subversion
In addition to normal requirements you need subversion client and full autotools chain
svn co http://cppcms.svn.sourceforge.net/svnroot/cppcms/framework/trunk cppcms
Then run:
cd cppcms
./autogen.sh
./autogen.sh
### Configuration
Usually, configure script would recognize persistence of all libraries, and disable non mandatory parts if some of libraries are missing. However, you may disable them manually using following flags:
--disable-forkcache Disable shared memory cache
--disable-fastcgi Disable fastcgi interface
--disable-tcpcache Disable distributed cache system
--disable-crypt Disable encrypted sessions backend
--disable-sqlite Disable Sqlite sessions backend
--enable-boostsuffix Specify custom suffix for boost libraries
So you run:
./configure
make
If all finished without errors, run as "root":
make install
### Building with Custom Boost Libraries
Generally, boost libraries are provided by your operating system, however, in some cases you may want to use special version of Boost that was build from the source.
Default Boost build does not create symbolic links to specific libraries so, you may find files like this:
/opt/include/boost-1_35/boost/regex.hpp
/opt/lib/libboost_regex-gcc41-mt.so
Instead of
/usr/include/boost/regex.hpp
/usr/lib/libboost_regex.so
In this case, you should specify `--enable-boostsuffix` option in order to complete configuration and link correctly. In the above case it would be:
./configure CXXFLAGS=-I/opt/include/boost-1_35 \
LDFLAGS=-L/opt/lib --enable-boostsuffix=gcc41-mt
Don't forget to make sure that /opt/lib is in your `LD_LIBRARY_PATH`.
## Notes on binary packages
At this point CppCMS project does not provide binary packages for several reasons:
1. This software works with wide range of different libraries and their different versions. Linux distribution packagers should decide how to build this framework and against which libraries.
2. Some of libraries are not available from official repositories of all popular distributions.
3. CppCMS project provided for developers that probably should deploy their application to different environment
where, in most of cases, that library would be build
for their own need with modules they need.
---------
1. <span id="m1"></span> Some of POSIX/UNIX Features that are used:
- bash
- Berkeley and UNIX Sockets stack including poll(2)
- mmap, fork, sigaction
- Process shared pthread mutex/rwlock (optional, recommended)
- `/dev/urandom`
- fcntl for file locking
2. <span id="m2"></span> Cygwin has many performance drawbacks, thus it is not recommended for production environment (as Windows at all `;-)`)

About

CppCMS is a web development framework for performance demanding applications.

Support This Project

SourceForge.net Logo

Поддержать проект

CppCMS needs You


Navigation

Main Page


Valid CSS | Valid XHTML 1.0