BLOG | DOCUMENTATION | TRAC

Home --> Documentations --> PJLIB Reference

config.h
Go to the documentation of this file.
1 /* $Id: config.h 5160 2015-08-12 02:39:26Z riza $ */
2 /*
3  * Copyright (C) 2008-2011 Teluu Inc. (http://www.teluu.com)
4  * Copyright (C) 2003-2008 Benny Prijono <benny@prijono.org>
5  *
6  * This program is free software; you can redistribute it and/or modify
7  * it under the terms of the GNU General Public License as published by
8  * the Free Software Foundation; either version 2 of the License, or
9  * (at your option) any later version.
10  *
11  * This program is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14  * GNU General Public License for more details.
15  *
16  * You should have received a copy of the GNU General Public License
17  * along with this program; if not, write to the Free Software
18  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
19  */
20 #ifndef __PJ_CONFIG_H__
21 #define __PJ_CONFIG_H__
22 
23 
29 /********************************************************************
30  * Include compiler specific configuration.
31  */
32 #if defined(_MSC_VER)
33 # include <pj/compat/cc_msvc.h>
34 #elif defined(__GNUC__)
35 # include <pj/compat/cc_gcc.h>
36 #elif defined(__CW32__)
37 # include <pj/compat/cc_mwcc.h>
38 #elif defined(__MWERKS__)
39 # include <pj/compat/cc_codew.h>
40 #elif defined(__GCCE__)
41 # include <pj/compat/cc_gcce.h>
42 #elif defined(__ARMCC__)
43 # include <pj/compat/cc_armcc.h>
44 #else
45 # error "Unknown compiler."
46 #endif
47 
48 /* PJ_ALIGN_DATA is compiler specific directive to align data address */
49 #ifndef PJ_ALIGN_DATA
50 # error "PJ_ALIGN_DATA is not defined!"
51 #endif
52 
53 /********************************************************************
54  * Include target OS specific configuration.
55  */
56 #if defined(PJ_AUTOCONF)
57  /*
58  * Autoconf
59  */
60 # include <pj/compat/os_auto.h>
61 
62 #elif defined(PJ_SYMBIAN) && PJ_SYMBIAN!=0
63  /*
64  * SymbianOS
65  */
66 # include <pj/compat/os_symbian.h>
67 
68 #elif defined(PJ_WIN32_WINCE) || defined(_WIN32_WCE) || defined(UNDER_CE)
69  /*
70  * Windows CE
71  */
72 # undef PJ_WIN32_WINCE
73 # define PJ_WIN32_WINCE 1
74 # include <pj/compat/os_win32_wince.h>
75 
76  /* Also define Win32 */
77 # define PJ_WIN32 1
78 
79 #elif defined(PJ_WIN32) || defined(_WIN32) || defined(__WIN32__) || \
80  defined(WIN32) || defined(PJ_WIN64) || defined(_WIN64) || \
81  defined(WIN64) || defined(__TOS_WIN__)
82 # if defined(PJ_WIN64) || defined(_WIN64) || defined(WIN64)
83  /*
84  * Win64
85  */
86 # undef PJ_WIN64
87 # define PJ_WIN64 1
88 # endif
89 # undef PJ_WIN32
90 # define PJ_WIN32 1
91 # include <pj/compat/os_win32.h>
92 
93 #elif defined(PJ_LINUX_KERNEL) && PJ_LINUX_KERNEL!=0
94  /*
95  * Linux kernel
96  */
97 # include <pj/compat/os_linux_kernel.h>
98 
99 #elif defined(PJ_LINUX) || defined(linux) || defined(__linux)
100  /*
101  * Linux
102  */
103 # undef PJ_LINUX
104 # define PJ_LINUX 1
105 # include <pj/compat/os_linux.h>
106 
107 #elif defined(PJ_PALMOS) && PJ_PALMOS!=0
108  /*
109  * Palm
110  */
111 # include <pj/compat/os_palmos.h>
112 
113 #elif defined(PJ_SUNOS) || defined(sun) || defined(__sun)
114  /*
115  * SunOS
116  */
117 # undef PJ_SUNOS
118 # define PJ_SUNOS 1
119 # include <pj/compat/os_sunos.h>
120 
121 #elif defined(PJ_DARWINOS) || defined(__MACOSX__) || \
122  defined (__APPLE__) || defined (__MACH__)
123  /*
124  * MacOS X
125  */
126 # undef PJ_DARWINOS
127 # define PJ_DARWINOS 1
128 # include <pj/compat/os_darwinos.h>
129 
130 #elif defined(PJ_RTEMS) && PJ_RTEMS!=0
131  /*
132  * RTEMS
133  */
134 # include <pj/compat/os_rtems.h>
135 #else
136 # error "Please specify target os."
137 #endif
138 
139 
140 /********************************************************************
141  * Target machine specific configuration.
142  */
143 #if defined(PJ_AUTOCONF)
144  /*
145  * Autoconf configured
146  */
147 #include <pj/compat/m_auto.h>
148 
149 #elif defined (PJ_M_I386) || defined(_i386_) || defined(i_386_) || \
150  defined(_X86_) || defined(x86) || defined(__i386__) || \
151  defined(__i386) || defined(_M_IX86) || defined(__I86__)
152  /*
153  * Generic i386 processor family, little-endian
154  */
155 # undef PJ_M_I386
156 # define PJ_M_I386 1
157 # define PJ_M_NAME "i386"
158 # define PJ_HAS_PENTIUM 1
159 # define PJ_IS_LITTLE_ENDIAN 1
160 # define PJ_IS_BIG_ENDIAN 0
161 
162 
163 #elif defined (PJ_M_X86_64) || defined(__amd64__) || defined(__amd64) || \
164  defined(__x86_64__) || defined(__x86_64) || \
165  defined(_M_X64) || defined(_M_AMD64)
166  /*
167  * AMD 64bit processor, little endian
168  */
169 # undef PJ_M_X86_64
170 # define PJ_M_X86_64 1
171 # define PJ_M_NAME "x86_64"
172 # define PJ_HAS_PENTIUM 1
173 # define PJ_IS_LITTLE_ENDIAN 1
174 # define PJ_IS_BIG_ENDIAN 0
175 
176 #elif defined(PJ_M_IA64) || defined(__ia64__) || defined(_IA64) || \
177  defined(__IA64__) || defined( _M_IA64)
178  /*
179  * Intel IA64 processor, default to little endian
180  */
181 # undef PJ_M_IA64
182 # define PJ_M_IA64 1
183 # define PJ_M_NAME "ia64"
184 # define PJ_HAS_PENTIUM 1
185 # define PJ_IS_LITTLE_ENDIAN 1
186 # define PJ_IS_BIG_ENDIAN 0
187 
188 #elif defined (PJ_M_M68K) && PJ_M_M68K != 0
189 
190  /*
191  * Motorola m68k processor, big endian
192  */
193 # undef PJ_M_M68K
194 # define PJ_M_M68K 1
195 # define PJ_M_NAME "m68k"
196 # define PJ_HAS_PENTIUM 0
197 # define PJ_IS_LITTLE_ENDIAN 0
198 # define PJ_IS_BIG_ENDIAN 1
199 
200 
201 #elif defined (PJ_M_ALPHA) || defined (__alpha__) || defined (__alpha) || \
202  defined (_M_ALPHA)
203  /*
204  * DEC Alpha processor, little endian
205  */
206 # undef PJ_M_ALPHA
207 # define PJ_M_ALPHA 1
208 # define PJ_M_NAME "alpha"
209 # define PJ_HAS_PENTIUM 0
210 # define PJ_IS_LITTLE_ENDIAN 1
211 # define PJ_IS_BIG_ENDIAN 0
212 
213 
214 #elif defined(PJ_M_MIPS) || defined(__mips__) || defined(__mips) || \
215  defined(__MIPS__) || defined(MIPS) || defined(_MIPS_)
216  /*
217  * MIPS, bi-endian, so raise error if endianness is not configured
218  */
219 # undef PJ_M_MIPS
220 # define PJ_M_MIPS 1
221 # define PJ_M_NAME "mips"
222 # define PJ_HAS_PENTIUM 0
223 # if !PJ_IS_LITTLE_ENDIAN && !PJ_IS_BIG_ENDIAN
224 # error Endianness must be declared for this processor
225 # endif
226 
227 
228 #elif defined (PJ_M_SPARC) || defined( __sparc__) || defined(__sparc)
229  /*
230  * Sun Sparc, big endian
231  */
232 # undef PJ_M_SPARC
233 # define PJ_M_SPARC 1
234 # define PJ_M_NAME "sparc"
235 # define PJ_HAS_PENTIUM 0
236 # define PJ_IS_LITTLE_ENDIAN 0
237 # define PJ_IS_BIG_ENDIAN 1
238 
239 #elif defined (PJ_M_ARMV4) || defined(ARM) || defined(_ARM_) || \
240  defined(ARMV4) || defined(__arm__)
241  /*
242  * ARM, bi-endian, so raise error if endianness is not configured
243  */
244 # undef PJ_M_ARMV4
245 # define PJ_M_ARMV4 1
246 # define PJ_M_NAME "armv4"
247 # define PJ_HAS_PENTIUM 0
248 # if !PJ_IS_LITTLE_ENDIAN && !PJ_IS_BIG_ENDIAN
249 # error Endianness must be declared for this processor
250 # endif
251 
252 #elif defined (PJ_M_POWERPC) || defined(__powerpc) || defined(__powerpc__) || \
253  defined(__POWERPC__) || defined(__ppc__) || defined(_M_PPC) || \
254  defined(_ARCH_PPC)
255  /*
256  * PowerPC, bi-endian, so raise error if endianness is not configured
257  */
258 # undef PJ_M_POWERPC
259 # define PJ_M_POWERPC 1
260 # define PJ_M_NAME "powerpc"
261 # define PJ_HAS_PENTIUM 0
262 # if !PJ_IS_LITTLE_ENDIAN && !PJ_IS_BIG_ENDIAN
263 # error Endianness must be declared for this processor
264 # endif
265 
266 #elif defined (PJ_M_NIOS2) || defined(__nios2) || defined(__nios2__) || \
267  defined(__NIOS2__) || defined(__M_NIOS2) || defined(_ARCH_NIOS2)
268  /*
269  * Nios2, little endian
270  */
271 # undef PJ_M_NIOS2
272 # define PJ_M_NIOS2 1
273 # define PJ_M_NAME "nios2"
274 # define PJ_HAS_PENTIUM 0
275 # define PJ_IS_LITTLE_ENDIAN 1
276 # define PJ_IS_BIG_ENDIAN 0
277 
278 #else
279 # error "Please specify target machine."
280 #endif
281 
282 /* Include size_t definition. */
283 #include <pj/compat/size_t.h>
284 
285 /* Include site/user specific configuration to control PJLIB features.
286  * YOU MUST CREATE THIS FILE YOURSELF!!
287  */
288 #include <pj/config_site.h>
289 
290 /********************************************************************
291  * PJLIB Features.
292  */
293 
294 /* Overrides for DOXYGEN */
295 #ifdef DOXYGEN
296 # undef PJ_FUNCTIONS_ARE_INLINED
297 # undef PJ_HAS_FLOATING_POINT
298 # undef PJ_LOG_MAX_LEVEL
299 # undef PJ_LOG_MAX_SIZE
300 # undef PJ_LOG_USE_STACK_BUFFER
301 # undef PJ_TERM_HAS_COLOR
302 # undef PJ_POOL_DEBUG
303 # undef PJ_HAS_TCP
304 # undef PJ_MAX_HOSTNAME
305 # undef PJ_IOQUEUE_MAX_HANDLES
306 # undef FD_SETSIZE
307 # undef PJ_HAS_SEMAPHORE
308 # undef PJ_HAS_EVENT_OBJ
309 # undef PJ_ENABLE_EXTRA_CHECK
310 # undef PJ_EXCEPTION_USE_WIN32_SEH
311 # undef PJ_HAS_ERROR_STRING
312 
313 # define PJ_HAS_IPV6 1
314 #endif
315 
333 #ifndef PJ_DEBUG
334 # ifndef NDEBUG
335 # define PJ_DEBUG 1
336 # else
337 # define PJ_DEBUG 0
338 # endif
339 #endif
340 
349 #ifndef PJ_DEBUG_MUTEX
350 # define PJ_DEBUG_MUTEX 0
351 #endif
352 
358 #ifndef PJ_FUNCTIONS_ARE_INLINED
359 # define PJ_FUNCTIONS_ARE_INLINED 0
360 #endif
361 
367 #ifndef PJ_HAS_FLOATING_POINT
368 # define PJ_HAS_FLOATING_POINT 1
369 #endif
370 
388 #ifndef PJ_LOG_MAX_LEVEL
389 # define PJ_LOG_MAX_LEVEL 5
390 #endif
391 
400 #ifndef PJ_LOG_MAX_SIZE
401 # define PJ_LOG_MAX_SIZE 4000
402 #endif
403 
412 #ifndef PJ_LOG_USE_STACK_BUFFER
413 # define PJ_LOG_USE_STACK_BUFFER 1
414 #endif
415 
421 #ifndef PJ_LOG_ENABLE_INDENT
422 # define PJ_LOG_ENABLE_INDENT 1
423 #endif
424 
431 #ifndef PJ_LOG_INDENT_SIZE
432 # define PJ_LOG_INDENT_SIZE 1
433 #endif
434 
440 #ifndef PJ_LOG_INDENT_CHAR
441 # define PJ_LOG_INDENT_CHAR '.'
442 #endif
443 
449 #ifndef PJ_TERM_HAS_COLOR
450 # define PJ_TERM_HAS_COLOR 1
451 #endif
452 
453 
465 #ifndef PJ_SAFE_POOL
466 # define PJ_SAFE_POOL 0
467 #endif
468 
469 
478 #ifndef PJ_POOL_DEBUG
479 # define PJ_POOL_DEBUG 0
480 #endif
481 
482 
491 #ifndef PJ_TIMER_DEBUG
492 # define PJ_TIMER_DEBUG 0
493 #endif
494 
495 
499 #ifndef PJ_GRP_LOCK_DEBUG
500 # define PJ_GRP_LOCK_DEBUG 0
501 #endif
502 
503 
510 #ifndef PJ_THREAD_DEFAULT_STACK_SIZE
511 # define PJ_THREAD_DEFAULT_STACK_SIZE 8192
512 #endif
513 
514 
522 #ifndef PJ_OS_HAS_CHECK_STACK
523 # define PJ_OS_HAS_CHECK_STACK 0
524 #endif
525 
531 #ifndef PJ_HAS_POOL_ALT_API
532 # define PJ_HAS_POOL_ALT_API PJ_POOL_DEBUG
533 #endif
534 
535 
542 #ifndef PJ_HAS_TCP
543 # define PJ_HAS_TCP 1
544 #endif
545 
552 #ifndef PJ_HAS_IPV6
553 # define PJ_HAS_IPV6 0
554 #endif
555 
563 #ifndef PJ_MAX_HOSTNAME
564 # define PJ_MAX_HOSTNAME (128)
565 #endif
566 
573 #ifndef PJ_ACTIVESOCK_MAX_CONSECUTIVE_ACCEPT_ERROR
574 # define PJ_ACTIVESOCK_MAX_CONSECUTIVE_ACCEPT_ERROR 50
575 #endif
576 
584 #ifndef PJ_IOQUEUE_MAX_HANDLES
585 # define PJ_IOQUEUE_MAX_HANDLES (64)
586 #endif
587 
588 
605 #ifndef PJ_IOQUEUE_HAS_SAFE_UNREG
606 # define PJ_IOQUEUE_HAS_SAFE_UNREG 1
607 #endif
608 
609 
621 #ifndef PJ_IOQUEUE_DEFAULT_ALLOW_CONCURRENCY
622 # define PJ_IOQUEUE_DEFAULT_ALLOW_CONCURRENCY 1
623 #endif
624 
625 
626 /* Sanity check:
627  * if ioqueue concurrency is disallowed, PJ_IOQUEUE_HAS_SAFE_UNREG
628  * must be enabled.
629  */
630 #if (PJ_IOQUEUE_DEFAULT_ALLOW_CONCURRENCY==0) && (PJ_IOQUEUE_HAS_SAFE_UNREG==0)
631 # error PJ_IOQUEUE_HAS_SAFE_UNREG must be enabled if ioqueue concurrency \
632  is disabled
633 #endif
634 
635 
645 #ifndef PJ_IOQUEUE_KEY_FREE_DELAY
646 # define PJ_IOQUEUE_KEY_FREE_DELAY 500
647 #endif
648 
649 
655 #ifndef PJ_FD_SETSIZE_SETABLE
656 # if (defined(PJ_HAS_WINSOCK_H) && PJ_HAS_WINSOCK_H!=0) || \
657  (defined(PJ_HAS_WINSOCK2_H) && PJ_HAS_WINSOCK2_H!=0)
658 # define PJ_FD_SETSIZE_SETABLE 1
659 # else
660 # define PJ_FD_SETSIZE_SETABLE 0
661 # endif
662 #endif
663 
670 #if PJ_FD_SETSIZE_SETABLE
671  /* Only override FD_SETSIZE if the value has not been set */
672 # ifndef FD_SETSIZE
673 # define FD_SETSIZE PJ_IOQUEUE_MAX_HANDLES
674 # endif
675 #else
676  /* When FD_SETSIZE is not changeable, check if PJ_IOQUEUE_MAX_HANDLES
677  * is lower than FD_SETSIZE value.
678  *
679  * Update: Not all ioqueue backends require this (such as epoll), so
680  * this check will be done on the ioqueue implementation itself, such as
681  * ioqueue select.
682  */
683 /*
684 # ifdef FD_SETSIZE
685 # if PJ_IOQUEUE_MAX_HANDLES > FD_SETSIZE
686 # error "PJ_IOQUEUE_MAX_HANDLES is greater than FD_SETSIZE"
687 # endif
688 # endif
689 */
690 #endif
691 
692 
699 #ifndef PJ_IP_HELPER_IGNORE_LOOPBACK_IF
700 # define PJ_IP_HELPER_IGNORE_LOOPBACK_IF 1
701 #endif
702 
703 
709 #ifndef PJ_HAS_SEMAPHORE
710 # define PJ_HAS_SEMAPHORE 1
711 #endif
712 
713 
719 #ifndef PJ_HAS_EVENT_OBJ
720 # define PJ_HAS_EVENT_OBJ 1
721 #endif
722 
723 
727 #ifndef PJ_MAXPATH
728 # define PJ_MAXPATH 260
729 #endif
730 
731 
743 #ifndef PJ_ENABLE_EXTRA_CHECK
744 # define PJ_ENABLE_EXTRA_CHECK 1
745 #endif
746 
747 
759 #ifndef PJ_HAS_EXCEPTION_NAMES
760 # define PJ_HAS_EXCEPTION_NAMES 1
761 #endif
762 
770 #ifndef PJ_MAX_EXCEPTION_ID
771 # define PJ_MAX_EXCEPTION_ID 16
772 #endif
773 
780 #ifndef PJ_EXCEPTION_USE_WIN32_SEH
781 # define PJ_EXCEPTION_USE_WIN32_SEH 0
782 #endif
783 
790 #ifndef PJ_TIMESTAMP_USE_RDTSC
791 # define PJ_TIMESTAMP_USE_RDTSC 0
792 #endif
793 
798 #ifndef PJ_NATIVE_ERR_POSITIVE
799 # define PJ_NATIVE_ERR_POSITIVE 1
800 #endif
801 
808 #ifndef PJ_HAS_ERROR_STRING
809 # define PJ_HAS_ERROR_STRING 1
810 #endif
811 
812 
821 #ifndef PJ_HAS_STRICMP_ALNUM
822 # define PJ_HAS_STRICMP_ALNUM 0
823 #endif
824 
825 
826 /*
827  * Types of QoS backend implementation.
828  */
829 
834 #define PJ_QOS_DUMMY 1
835 
837 #define PJ_QOS_BSD 2
838 
840 #define PJ_QOS_WM 3
841 
843 #define PJ_QOS_SYMBIAN 4
844 
848 #ifndef PJ_QOS_IMPLEMENTATION
849 # if defined(PJ_WIN32_WINCE) && PJ_WIN32_WINCE && _WIN32_WCE >= 0x502
850  /* Windows Mobile 6 or later */
851 # define PJ_QOS_IMPLEMENTATION PJ_QOS_WM
852 # endif
853 #endif
854 
855 
863 #ifndef PJ_HAS_SSL_SOCK
864 # define PJ_HAS_SSL_SOCK 0
865 #endif
866 
867 
873 #ifndef PJ_SSL_SOCK_MAX_CIPHERS
874 # define PJ_SSL_SOCK_MAX_CIPHERS 256
875 #endif
876 
877 
885 #ifndef PJ_SSL_SOCK_OSSL_CIPHERS
886 # define PJ_SSL_SOCK_OSSL_CIPHERS "HIGH:-COMPLEMENTOFDEFAULT"
887 #endif
888 
889 
896 #ifndef PJ_SOCK_DISABLE_WSAECONNRESET
897 # define PJ_SOCK_DISABLE_WSAECONNRESET 1
898 #endif
899 
900 
903 /********************************************************************
904  * General macros.
905  */
906 
989 #define PJ_INLINE(type) PJ_INLINE_SPECIFIER type
990 
999 #ifndef PJ_EXPORT_DECL_SPECIFIER
1000 # define PJ_EXPORT_DECL_SPECIFIER
1001 #endif
1002 
1003 
1012 #ifndef PJ_EXPORT_DEF_SPECIFIER
1013 # define PJ_EXPORT_DEF_SPECIFIER
1014 #endif
1015 
1016 
1024 #ifndef PJ_IMPORT_DECL_SPECIFIER
1025 # define PJ_IMPORT_DECL_SPECIFIER
1026 #endif
1027 
1028 
1032 #ifndef PJ_EXPORT_SYMBOL
1033 # define PJ_EXPORT_SYMBOL(x)
1034 #endif
1035 
1036 
1042 #if defined(PJ_DLL)
1043 # if defined(PJ_EXPORTING)
1044 # define PJ_DECL(type) PJ_EXPORT_DECL_SPECIFIER type
1045 # else
1046 # define PJ_DECL(type) PJ_IMPORT_DECL_SPECIFIER type
1047 # endif
1048 #elif !defined(PJ_DECL)
1049 # if defined(__cplusplus)
1050 # define PJ_DECL(type) type
1051 # else
1052 # define PJ_DECL(type) extern type
1053 # endif
1054 #endif
1055 
1056 
1062 #if defined(PJ_DLL) && defined(PJ_EXPORTING)
1063 # define PJ_DEF(type) PJ_EXPORT_DEF_SPECIFIER type
1064 #elif !defined(PJ_DEF)
1065 # define PJ_DEF(type) type
1066 #endif
1067 
1068 
1087 #ifdef __cplusplus
1088 # define PJ_DECL_NO_RETURN(type) PJ_DECL(type) PJ_NORETURN
1089 # define PJ_IDECL_NO_RETURN(type) PJ_INLINE(type) PJ_NORETURN
1090 # define PJ_BEGIN_DECL extern "C" {
1091 # define PJ_END_DECL }
1092 #else
1093 # define PJ_DECL_NO_RETURN(type) PJ_NORETURN PJ_DECL(type)
1094 # define PJ_IDECL_NO_RETURN(type) PJ_NORETURN PJ_INLINE(type)
1095 # define PJ_BEGIN_DECL
1096 # define PJ_END_DECL
1097 #endif
1098 
1099 
1100 
1106 #if defined(PJ_DLL)
1107 # if defined(PJ_EXPORTING)
1108 # define PJ_DECL_DATA(type) PJ_EXPORT_DECL_SPECIFIER extern type
1109 # else
1110 # define PJ_DECL_DATA(type) PJ_IMPORT_DECL_SPECIFIER extern type
1111 # endif
1112 #elif !defined(PJ_DECL_DATA)
1113 # define PJ_DECL_DATA(type) extern type
1114 #endif
1115 
1116 
1122 #if defined(PJ_DLL) && defined(PJ_EXPORTING)
1123 # define PJ_DEF_DATA(type) PJ_EXPORT_DEF_SPECIFIER type
1124 #elif !defined(PJ_DEF_DATA)
1125 # define PJ_DEF_DATA(type) type
1126 #endif
1127 
1128 
1140 #if PJ_FUNCTIONS_ARE_INLINED
1141 # define PJ_IDECL(type) PJ_INLINE(type)
1142 # define PJ_IDEF(type) PJ_INLINE(type)
1143 #else
1144 # define PJ_IDECL(type) PJ_DECL(type)
1145 # define PJ_IDEF(type) PJ_DEF(type)
1146 #endif
1147 
1148 
1154 #define PJ_UNUSED_ARG(arg) (void)arg
1155 
1162 #ifndef PJ_TODO
1163 # define PJ_TODO(id) TODO___##id:
1164 #endif
1165 
1170 #ifndef PJ_RACE_ME
1171 # define PJ_RACE_ME(x)
1172 #endif
1173 
1179 #define __pj_throw__(x)
1180 
1183 /********************************************************************
1184  * Sanity Checks
1185  */
1186 #ifndef PJ_HAS_HIGH_RES_TIMER
1187 # error "PJ_HAS_HIGH_RES_TIMER is not defined!"
1188 #endif
1189 
1190 #if !defined(PJ_HAS_PENTIUM)
1191 # error "PJ_HAS_PENTIUM is not defined!"
1192 #endif
1193 
1194 #if !defined(PJ_IS_LITTLE_ENDIAN)
1195 # error "PJ_IS_LITTLE_ENDIAN is not defined!"
1196 #endif
1197 
1198 #if !defined(PJ_IS_BIG_ENDIAN)
1199 # error "PJ_IS_BIG_ENDIAN is not defined!"
1200 #endif
1201 
1202 #if !defined(PJ_EMULATE_RWMUTEX)
1203 # error "PJ_EMULATE_RWMUTEX should be defined in compat/os_xx.h"
1204 #endif
1205 
1206 #if !defined(PJ_THREAD_SET_STACK_SIZE)
1207 # error "PJ_THREAD_SET_STACK_SIZE should be defined in compat/os_xx.h"
1208 #endif
1209 
1210 #if !defined(PJ_THREAD_ALLOCATE_STACK)
1211 # error "PJ_THREAD_ALLOCATE_STACK should be defined in compat/os_xx.h"
1212 #endif
1213 
1215 
1217 #define PJ_VERSION_NUM_MAJOR 2
1218 
1220 #define PJ_VERSION_NUM_MINOR 4
1221 
1223 #define PJ_VERSION_NUM_REV 5
1224 
1229 #define PJ_VERSION_NUM_EXTRA ""
1230 
1236 #define PJ_VERSION_NUM ((PJ_VERSION_NUM_MAJOR << 24) | \
1237  (PJ_VERSION_NUM_MINOR << 16) | \
1238  (PJ_VERSION_NUM_REV << 8))
1239 
1243 PJ_DECL_DATA(const char*) PJ_VERSION;
1244 
1250 PJ_DECL(const char*) pj_get_version(void);
1251 
1255 PJ_DECL(void) pj_dump_config(void);
1256 
1258 
1259 
1260 #endif /* __PJ_CONFIG_H__ */
1261 
void pj_dump_config(void)
const char * pj_get_version(void)
#define PJ_END_DECL
Definition: config.h:1096
#define PJ_BEGIN_DECL
Definition: config.h:1095
const char * PJ_VERSION
Definition: config.h:1243

 


PJLIB Open Source, high performance, small footprint, and very very portable framework
Copyright (C) 2006-2009 Teluu Inc.