| 1 | = Build Preparation = |
| 2 | [[TracNav(Getting-Started/TOC)]] |
| 3 | |
| 4 | == Create config_site.h file == |
| 5 | |
| 6 | Before source files can be built, the pjlib/include/pj/config_site.h file must be created (it can just be an empty file). |
| 7 | |
| 8 | Note: When the Makefile based build system is used, this process is taken care by the Makefiles. But when non-Makefile based build system (such as Visual Studio) is used, the config_site.h file must be created manually. |
| 9 | |
| 10 | |
| 11 | == What is config_site.h File == |
| 12 | |
| 13 | The pjlib/include/pj/config_site.h contains local customizations to the libraries. |
| 14 | |
| 15 | All customizations should be put in this file instead of modifying PJ's files, because if PJ's files get modified, then those modified files will not be updated the next time the source is synchronized. Or in other case, the local modification may be overwritten with the fresh copy from the SVN. |
| 16 | |
| 17 | Putting the local customization to the config_site.h solves this problem, because this file is not included in the version control, so it will never be overwritten by "svn update" command. |
| 18 | |
| 19 | Please find list of configuration macros that can be overriden from these files: |
| 20 | |
| 21 | * PJLIB Configuration (the pjlib/config.h file) |
| 22 | * PJLIB-UTIL Configuration (the pjlib-util/config.h file) |
| 23 | * PJNATH Configuration (the pjnath/config.h file) |
| 24 | * PJMEDIA Configuration (the pjmedia/config.h file) |
| 25 | * PJSIP Configuration (the pjsip/sip_config.h file) |
| 26 | |
| 27 | A sample config_site.h file is also available in pjlib/include/config_site_sample.h. |
| 28 | |
| 29 | |
| 30 | == Creating config_site.h file == |
| 31 | |
| 32 | The simplest way is just to create an empty file, to use whetever default values set by the libraries. |
| 33 | |
| 34 | Another way to create the config_site.h file is to write something like the following: |
| 35 | |
| 36 | {{{ |
| 37 | // Uncomment to get minimum footprint (suitable for 1-2 concurrent calls only) |
| 38 | //#define PJ_CONFIG_MINIMAL_SIZE |
| 39 | |
| 40 | // Uncomment to get maximum performance |
| 41 | //#define PJ_CONFIG_MAXIMUM_SPEED |
| 42 | |
| 43 | #include <pj/config_site_sample.h> |
| 44 | }}} |