Changes to attempt to silence bcc64x
[ACE_TAO.git] / ACE / ace / Default_Constants.h
blob26405b2bc2cec3e65248e7c49cdbc26c75dc17a5
1 // -*- C++ -*-
3 //=============================================================================
4 /**
5 * @file Default_Constants.h
7 * @author Douglas C. Schmidt <d.schmidt@vanderbilt.edu>
8 * @author Jesper S. M|ller<stophph@diku.dk>
9 * @author and a cast of thousands...
11 * This one is split from the famous OS.h
13 //=============================================================================
15 #ifndef ACE_DEFAULT_CONSTANTS_H
16 #define ACE_DEFAULT_CONSTANTS_H
17 #include /**/ "ace/pre.h"
19 // Included just keep compilers that see #pragma directive first
20 // happy.
21 #include /**/ "ace/config-all.h"
23 #if !defined (ACE_LACKS_PRAGMA_ONCE)
24 # pragma once
25 #endif /* ACE_LACKS_PRAGMA_ONCE */
27 // For _POSIX_TIMER_MAX
28 #include "ace/os_include/os_limits.h"
30 // Define the default constants for ACE. Many of these are used for
31 // the ACE tests and applications. You can change these values by
32 // defining the macros in your config.h file.
33 # if !defined (ACE_DEFAULT_CLOSE_ALL_HANDLES)
34 # define ACE_DEFAULT_CLOSE_ALL_HANDLES true
35 # endif /* ACE_DEFAULT_CLOSE_ALL_HANDLES */
37 // The maximum length for a fully qualified Internet name.
38 # if !defined(ACE_MAX_FULLY_QUALIFIED_NAME_LEN)
39 # define ACE_MAX_FULLY_QUALIFIED_NAME_LEN 256
40 # endif /* ACE_MAX_FULLY_QUALIFIED_NAME_LEN */
42 #if !defined (ACE_DEFAULT_PAGEFILE_POOL_BASE)
43 #define ACE_DEFAULT_PAGEFILE_POOL_BASE (void *) 0
44 #endif /* ACE_DEFAULT_PAGEFILE_POOL_BASE */
46 #if !defined (ACE_DEFAULT_PAGEFILE_POOL_SIZE)
47 #define ACE_DEFAULT_PAGEFILE_POOL_SIZE (size_t) 0x01000000
48 #endif /* ACE_DEFAULT_PAGEFILE_POOL_SIZE */
50 #if !defined (ACE_DEFAULT_PAGEFILE_POOL_CHUNK)
51 #define ACE_DEFAULT_PAGEFILE_POOL_CHUNK (size_t) 0x00010000
52 #endif /* ACE_DEFAULT_PAGEFILE_POOL_CHUNK */
54 #if !defined (ACE_DEFAULT_PAGEFILE_POOL_NAME)
55 #define ACE_DEFAULT_PAGEFILE_POOL_NAME ACE_TEXT ("Default_ACE_Pagefile_Memory_Pool")
56 #endif /* ACE_DEFAULT_PAGEFILE_POOL_NAME */
58 #if !defined (ACE_DEFAULT_MESSAGE_BLOCK_PRIORITY)
59 #define ACE_DEFAULT_MESSAGE_BLOCK_PRIORITY 0
60 #endif /* ACE_DEFAULT_MESSAGE_BLOCK_PRIORITY */
62 #if !defined (ACE_DEFAULT_SERVICE_REPOSITORY_SIZE)
63 #define ACE_DEFAULT_SERVICE_REPOSITORY_SIZE 1024
64 #endif /* ACE_DEFAULT_SERVICE_REPOSITORY_SIZE */
66 #if !defined (ACE_DEFAULT_SERVICE_GESTALT_SIZE)
67 #define ACE_DEFAULT_SERVICE_GESTALT_SIZE 1024
68 #endif /* ACE_DEFAULT_SERVICE_GESTALT_SIZE */
70 #if !defined (ACE_REACTOR_NOTIFICATION_ARRAY_SIZE)
71 #define ACE_REACTOR_NOTIFICATION_ARRAY_SIZE 1024
72 #endif /* ACE_REACTOR_NOTIFICATION_ARRAY_SIZE */
74 # if !defined (ACE_DEFAULT_TIMEOUT)
75 # define ACE_DEFAULT_TIMEOUT 5
76 # endif /* ACE_DEFAULT_TIMEOUT */
78 # if !defined (ACE_DEFAULT_BACKLOG)
79 # define ACE_DEFAULT_BACKLOG 5
80 # endif /* ACE_DEFAULT_BACKLOG */
82 # if !defined (ACE_DEFAULT_ASYNCH_BACKLOG)
83 # define ACE_DEFAULT_ASYNCH_BACKLOG 5
84 # endif /* ACE_DEFAULT_ASYNCH_BACKLOG */
86 # if !defined (ACE_DEFAULT_THREADS)
87 # define ACE_DEFAULT_THREADS 1
88 # endif /* ACE_DEFAULT_THREADS */
90 // The following 3 defines are used in the IP multicast and broadcast tests.
91 # if !defined (ACE_DEFAULT_BROADCAST_PORT)
92 # define ACE_DEFAULT_BROADCAST_PORT 20000
93 # endif /* ACE_DEFAULT_BROADCAST_PORT */
95 # if !defined (ACE_DEFAULT_MULTICAST_PORT)
96 # define ACE_DEFAULT_MULTICAST_PORT 20001
97 # endif /* ACE_DEFAULT_MULTICAST_PORT */
99 # if !defined (ACE_DEFAULT_MULTICAST_ADDR)
100 // This address MUST be within the range for host group addresses:
101 // 224.0.0.0 to 239.255.255.255.
102 # define ACE_DEFAULT_MULTICAST_ADDR "224.9.9.2"
103 # endif /* ACE_DEFAULT_MULTICAST_ADDR */
105 # if defined (ACE_HAS_IPV6)
106 # if !defined (ACE_DEFAULT_MULTICASTV6_ADDR)
107 // This address should be within the range for site-local addresses:
108 // ff05::0/16 .
109 # define ACE_DEFAULT_MULTICASTV6_ADDR "ff05:0::ff01:1"
110 # endif /* ACE_DEFAULT_MULTICASTV6_ADDR */
111 # endif
113 // Default port number for HTTP.
114 # if !defined (ACE_DEFAULT_HTTP_SERVER_PORT)
115 # define ACE_DEFAULT_HTTP_SERVER_PORT 80
116 # endif /* ACE_DEFAULT_HTTP_SERVER_PORT */
118 // Used in many IPC_SAP tests
119 # if !defined (ACE_DEFAULT_SERVER_PORT)
120 # define ACE_DEFAULT_SERVER_PORT 20002
121 # endif /* ACE_DEFAULT_SERVER_PORT */
123 # if !defined (ACE_DEFAULT_HTTP_PORT)
124 # define ACE_DEFAULT_HTTP_PORT 80
125 # endif /* ACE_DEFAULT_HTTP_PORT */
127 # if !defined (ACE_DEFAULT_MAX_SOCKET_BUFSIZ)
128 # define ACE_DEFAULT_MAX_SOCKET_BUFSIZ 65536
129 # endif /* ACE_DEFAULT_MAX_SOCKET_BUFSIZ */
131 # if !defined (ACE_DEFAULT_SERVER_PORT_STR)
132 # define ACE_DEFAULT_SERVER_PORT_STR ACE_TEXT("20002")
133 # endif /* ACE_DEFAULT_SERVER_PORT_STR */
135 // Used for the Service_Directory test
136 # if !defined (ACE_DEFAULT_SERVICE_PORT)
137 # define ACE_DEFAULT_SERVICE_PORT 20003
138 # endif /* ACE_DEFAULT_SERVICE_PORT */
140 // Used for the ACE_Thread_Spawn test
141 # if !defined (ACE_DEFAULT_THR_PORT )
142 # define ACE_DEFAULT_THR_PORT 20004
143 # endif /* ACE_DEFAULT_THR_PORT */
145 // Used for <SOCK_Connect::connect> tests
146 # if !defined (ACE_DEFAULT_LOCAL_PORT)
147 # define ACE_DEFAULT_LOCAL_PORT 20005
148 # endif /* ACE_DEFAULT_LOCAL_PORT */
150 // Used for Connector tests
151 # if !defined (ACE_DEFAULT_LOCAL_PORT_STR)
152 # define ACE_DEFAULT_LOCAL_PORT_STR "20005"
153 # endif /* ACE_DEFAULT_LOCAL_PORT_STR */
155 // Used for the name server.
156 # if !defined (ACE_DEFAULT_NAME_SERVER_PORT)
157 # define ACE_DEFAULT_NAME_SERVER_PORT 20006
158 # endif /* ACE_DEFAULT_NAME_SERVER_PORT */
160 # if !defined (ACE_DEFAULT_NAME_SERVER_PORT_STR)
161 # define ACE_DEFAULT_NAME_SERVER_PORT_STR "20006"
162 # endif /* ACE_DEFAULT_NAME_SERVER_PORT_STR */
164 // Used for the token server.
165 # if !defined (ACE_DEFAULT_TOKEN_SERVER_PORT)
166 # define ACE_DEFAULT_TOKEN_SERVER_PORT 20007
167 # endif /* ACE_DEFAULT_TOKEN_SERVER_PORT */
169 # if !defined (ACE_DEFAULT_TOKEN_SERVER_PORT_STR)
170 # define ACE_DEFAULT_TOKEN_SERVER_PORT_STR "20007"
171 # endif /* ACE_DEFAULT_TOKEN_SERVER_PORT_STR */
173 // Used for the logging server.
174 # if !defined (ACE_DEFAULT_LOGGING_SERVER_PORT)
175 # define ACE_DEFAULT_LOGGING_SERVER_PORT 20008
176 # endif /* ACE_DEFAULT_LOGGING_SERVER_PORT */
178 # if !defined (ACE_DEFAULT_LOGGING_SERVER_PORT_STR)
179 # define ACE_DEFAULT_LOGGING_SERVER_PORT_STR "20008"
180 # endif /* ACE_DEFAULT_LOGGING_SERVER_PORT_STR */
182 // Used for the logging server.
183 # if !defined (ACE_DEFAULT_THR_LOGGING_SERVER_PORT)
184 # define ACE_DEFAULT_THR_LOGGING_SERVER_PORT 20008
185 # endif /* ACE_DEFAULT_THR_LOGGING_SERVER_PORT */
187 # if !defined (ACE_DEFAULT_THR_LOGGING_SERVER_PORT_STR)
188 # define ACE_DEFAULT_THR_LOGGING_SERVER_PORT_STR "20008"
189 # endif /* ACE_DEFAULT_THR_LOGGING_SERVER_PORT_STR */
191 // Used for the time server.
192 # if !defined (ACE_DEFAULT_TIME_SERVER_PORT)
193 # define ACE_DEFAULT_TIME_SERVER_PORT 20009
194 # endif /* ACE_DEFAULT_TIME_SERVER_PORT */
196 # if !defined (ACE_DEFAULT_TIME_SERVER_PORT_STR)
197 # define ACE_DEFAULT_TIME_SERVER_PORT_STR "20009"
198 # endif /* ACE_DEFAULT_TIME_SERVER_PORT_STR */
200 # if !defined (ACE_DEFAULT_TIME_SERVER_STR)
201 # define ACE_DEFAULT_TIME_SERVER_STR "ACE_TS_TIME"
202 # endif /* ACE_DEFAULT_TIME_SERVER_STR */
204 // Used by the FIFO tests
205 # if !defined (ACE_DEFAULT_RENDEZVOUS)
206 # if defined (ACE_HAS_STREAM_PIPES)
207 # define ACE_DEFAULT_RENDEZVOUS ACE_TEXT("/tmp/fifo.ace")
208 # else
209 # define ACE_DEFAULT_RENDEZVOUS ACE_TEXT("localhost:20010")
210 # endif /* ACE_HAS_STREAM_PIPES */
211 # endif /* ACE_DEFAULT_RENDEZVOUS */
213 // Used for the UNIX syslog logging interface to ACE_Log_Msg.
214 # ifndef ACE_DEFAULT_SYSLOG_FACILITY
215 # define ACE_DEFAULT_SYSLOG_FACILITY LOG_USER
216 # endif /* ACE_DEFAULT_SYSLOG_FACILITY */
218 # if !defined (ACE_HAS_STREAM_LOG_MSG_IPC)
219 # if defined (ACE_HAS_STREAM_PIPES)
220 # define ACE_HAS_STREAM_LOG_MSG_IPC 1
221 # else
222 # define ACE_HAS_STREAM_LOG_MSG_IPC 0
223 # endif /* ACE_HAS_STREAM_PIPES */
224 # endif /* !ACE_HAS_STREAM_LOG_MSG_IPC */
226 # if !defined (ACE_DEFAULT_LOGGER_KEY)
227 # if (ACE_HAS_STREAM_LOG_MSG_IPC == 1)
228 # define ACE_DEFAULT_LOGGER_KEY ACE_TEXT ("/tmp/server_daemon")
229 # else
230 # define ACE_DEFAULT_LOGGER_KEY ACE_TEXT ("localhost:20012")
231 # endif /* ACE_HAS_STREAM_LOG_MSG_IPC==1 */
232 # endif /* ACE_DEFAULT_LOGGER_KEY */
234 // The way to specify the local host for loopback IP. This is usually
235 // "localhost" but it may need changing on some platforms.
236 # if !defined (ACE_LOCALHOST)
237 # define ACE_LOCALHOST ACE_TEXT ("localhost")
238 # endif
240 // This specification for an IPv6 localhost should work on all platforms
241 // supporting IPv6
242 # if defined (ACE_HAS_IPV6)
243 # if !defined (ACE_IPV6_LOCALHOST)
244 # define ACE_IPV6_LOCALHOST ACE_TEXT ("::1")
245 # endif /* ACE_IPV6_LOCALHOST*/
246 #endif /* ACE_HAS_IPV6 */
248 // This specification for an IPv6 ANY address should work on all platforms
249 // supporting IPv6
250 # if defined (ACE_HAS_IPV6)
251 # if !defined (ACE_IPV6_ANY)
252 # define ACE_IPV6_ANY ACE_TEXT ("::")
253 # endif /* ACE_IPV6_ANY*/
254 #endif /* ACE_HAS_IPV6 */
256 # if !defined (ACE_DEFAULT_SERVER_HOST)
257 # if defined (ACE_HAS_IPV6)
258 # define ACE_DEFAULT_SERVER_HOST ACE_IPV6_LOCALHOST
259 # else /*ACE_HAS_IPV6*/
260 # define ACE_DEFAULT_SERVER_HOST ACE_LOCALHOST
261 # endif /*ACE_HAS_IPV6*/
262 # endif /* ACE_DEFAULT_SERVER_HOST */
264 // Default shared memory key
265 # if !defined (ACE_DEFAULT_SHM_KEY)
266 # define ACE_DEFAULT_SHM_KEY 1234
267 # endif /* ACE_DEFAULT_SHM_KEY */
269 // Default address for shared memory mapped files and SYSV shared memory
270 // (defaults to 64 M).
271 # if !defined (ACE_DEFAULT_BASE_ADDR)
272 # define ACE_DEFAULT_BASE_ADDR ((char *) (64 * 1024 * 1024))
273 # endif /* ACE_DEFAULT_BASE_ADDR */
275 // Default segment size used by SYSV shared memory (128 K)
276 # if !defined (ACE_DEFAULT_SEGMENT_SIZE)
277 # define ACE_DEFAULT_SEGMENT_SIZE 1024 * 128
278 # endif /* ACE_DEFAULT_SEGMENT_SIZE */
280 // Maximum number of SYSV shared memory segments
281 // (does anyone know how to figure out the right values?!)
282 # if !defined (ACE_DEFAULT_MAX_SEGMENTS)
283 # define ACE_DEFAULT_MAX_SEGMENTS 6
284 # endif /* ACE_DEFAULT_MAX_SEGMENTS */
286 // Name of the map that's stored in shared memory.
287 # if !defined (ACE_NAME_SERVER_MAP)
288 # define ACE_NAME_SERVER_MAP "Name Server Map"
289 # endif /* ACE_NAME_SERVER_MAP */
291 // Default file permissions.
292 # if !defined (ACE_DEFAULT_FILE_PERMS)
293 # if defined (ACE_VXWORKS)
294 # define ACE_DEFAULT_FILE_PERMS (S_IRUSR | S_IWUSR| S_IRGRP| S_IROTH)
295 # else
296 # define ACE_DEFAULT_FILE_PERMS 0644
297 # endif /* ACE_VXWORKS */
298 # endif /* ACE_DEFAULT_FILE_PERMS */
300 // Default directory permissions.
301 # if !defined (ACE_DEFAULT_DIR_PERMS)
302 # define ACE_DEFAULT_DIR_PERMS 0755
303 # endif /* ACE_DEFAULT_DIR_PERMS */
305 # if !defined (ACE_DEFAULT_TIMEPROBE_TABLE_SIZE)
306 # define ACE_DEFAULT_TIMEPROBE_TABLE_SIZE 8 * 1024
307 # endif /* ACE_DEFAULT_TIMEPROBE_TABLE_SIZE */
309 // Default size of the ACE Map_Manager.
310 # if !defined (ACE_DEFAULT_MAP_SIZE)
311 # define ACE_DEFAULT_MAP_SIZE 1024
312 # endif /* ACE_DEFAULT_MAP_SIZE */
314 # if defined (ACE_DEFAULT_MAP_SIZE) && (ACE_DEFAULT_MAP_SIZE == 0)
315 # error ACE_DEFAULT_MAP_SIZE should not be zero
316 # endif /* ACE_DEFAULT_MAP_SIZE */
318 // Defaults for ACE Timer Wheel
319 # if !defined (ACE_DEFAULT_TIMER_WHEEL_SIZE)
320 # define ACE_DEFAULT_TIMER_WHEEL_SIZE 1024
321 # endif /* ACE_DEFAULT_TIMER_WHEEL_SIZE */
323 # if !defined (ACE_DEFAULT_TIMER_WHEEL_RESOLUTION)
324 # define ACE_DEFAULT_TIMER_WHEEL_RESOLUTION 100
325 # endif /* ACE_DEFAULT_TIMER_WHEEL_RESOLUTION */
327 // Default size for ACE Timer Hash table
328 # if !defined (ACE_DEFAULT_TIMER_HASH_TABLE_SIZE)
329 # define ACE_DEFAULT_TIMER_HASH_TABLE_SIZE 1024
330 # endif /* ACE_DEFAULT_TIMER_HASH_TABLE_SIZE */
332 // Defaults for the ACE Free List
333 # if !defined (ACE_DEFAULT_FREE_LIST_PREALLOC)
334 # define ACE_DEFAULT_FREE_LIST_PREALLOC 0
335 # endif /* ACE_DEFAULT_FREE_LIST_PREALLOC */
337 # if !defined (ACE_DEFAULT_FREE_LIST_LWM)
338 # define ACE_DEFAULT_FREE_LIST_LWM 0
339 # endif /* ACE_DEFAULT_FREE_LIST_LWM */
341 # if !defined (ACE_DEFAULT_FREE_LIST_HWM)
342 # define ACE_DEFAULT_FREE_LIST_HWM 25000
343 # endif /* ACE_DEFAULT_FREE_LIST_HWM */
345 # if !defined (ACE_DEFAULT_FREE_LIST_INC)
346 # define ACE_DEFAULT_FREE_LIST_INC 100
347 # endif /* ACE_DEFAULT_FREE_LIST_INC */
349 # if !defined (ACE_UNIQUE_NAME_LEN)
350 # define ACE_UNIQUE_NAME_LEN 100
351 # endif /* ACE_UNIQUE_NAME_LEN */
353 # if !defined (ACE_MAX_DGRAM_SIZE)
354 // This is just a guess. 8k is the normal limit on
355 // most machines because that's what NFS expects.
356 # define ACE_MAX_DGRAM_SIZE 8192
357 # endif /* ACE_MAX_DGRAM_SIZE */
359 # if !defined (ACE_DEFAULT_ARGV_BUFSIZ)
360 # define ACE_DEFAULT_ARGV_BUFSIZ 1024 * 4
361 # endif /* ACE_DEFAULT_ARGV_BUFSIZ */
363 // A free list which create more elements when there aren't enough
364 // elements.
365 # define ACE_FREE_LIST_WITH_POOL 1
367 // A simple free list which doesn't allocate/deallocate elements.
368 # define ACE_PURE_FREE_LIST 2
370 # if defined (ACE_WIN32)
372 // This is necessary to work around bugs with Win32 non-blocking
373 // connects...
374 # if !defined (ACE_NON_BLOCKING_BUG_DELAY)
375 # define ACE_NON_BLOCKING_BUG_DELAY 35000
376 # endif /* ACE_NON_BLOCKING_BUG_DELAY */
377 # endif /*ACE_WIN32*/
379 // Max size of an ACE Log Record data buffer. This can be reset in
380 // the config.h file if you'd like to increase or decrease the size.
381 # if !defined (ACE_MAXLOGMSGLEN)
382 # define ACE_MAXLOGMSGLEN 4 * 1024
383 # endif /* ACE_MAXLOGMSGLEN */
385 // Max size of an ACE Token.
386 # define ACE_MAXTOKENNAMELEN 40
388 // Max size of an ACE Token client ID.
389 # define ACE_MAXCLIENTIDLEN MAXHOSTNAMELEN + 20
391 /// Max udp packet size
392 #if !defined (ACE_MAX_UDP_PACKET_SIZE)
393 #define ACE_MAX_UDP_PACKET_SIZE 65507
394 #endif
397 * @name Default values to control CDR classes memory allocation strategies
399 //@{
400 /// Control the initial size of all CDR buffers, application
401 /// developers may want to optimize this value to fit their request
402 /// size
403 #if !defined (ACE_DEFAULT_CDR_BUFSIZE)
404 # define ACE_DEFAULT_CDR_BUFSIZE 512
405 #endif /* ACE_DEFAULT_CDR_BUFSIZE */
407 #if (ACE_DEFAULT_CDR_BUFSIZE == 0)
408 # error: ACE_DEFAULT_CDR_BUFSIZE should be bigger then 0
409 #endif
411 /// Stop exponential growth of CDR buffers to avoid overallocation
412 #if !defined (ACE_DEFAULT_CDR_EXP_GROWTH_MAX)
413 # define ACE_DEFAULT_CDR_EXP_GROWTH_MAX 65536
414 #endif /* ACE_DEFAULT_CDR_EXP_GROWTH_MAX */
416 /// Control CDR buffer growth after maximum exponential growth is
417 /// reached
418 #if !defined (ACE_DEFAULT_CDR_LINEAR_GROWTH_CHUNK)
419 # define ACE_DEFAULT_CDR_LINEAR_GROWTH_CHUNK 65536
420 #endif /* ACE_DEFAULT_CDR_LINEAR_GROWTH_CHUNK */
421 //@}
423 /// Control the zero-copy optimizations for octet sequences
425 * Large octet sequences can be sent without any copies by chaining
426 * them in the list of message blocks that represent a single CDR
427 * stream. However, if the octet sequence is too small the zero copy
428 * optimizations actually hurt performance. Octet sequences smaller
429 * than this value will be copied.
431 #if !defined (ACE_DEFAULT_CDR_MEMCPY_TRADEOFF)
432 #define ACE_DEFAULT_CDR_MEMCPY_TRADEOFF 256
433 #endif /* ACE_DEFAULT_CDR_MEMCPY_TRADEOFF */
435 #if defined (ACE_WIN32)
436 // Define the pathname separator characters for Win32 (ugh).
437 # define ACE_DIRECTORY_SEPARATOR_STR_A "\\"
438 # define ACE_DIRECTORY_SEPARATOR_CHAR_A '\\'
439 #else
440 // Define the pathname separator characters for UNIX.
441 # define ACE_DIRECTORY_SEPARATOR_STR_A "/"
442 # define ACE_DIRECTORY_SEPARATOR_CHAR_A '/'
443 #endif /* ACE_WIN32 */
445 // Define the Wide character and normal versions of some of the string macros
446 #if defined (ACE_HAS_WCHAR)
447 # define ACE_DIRECTORY_SEPARATOR_STR_W ACE_TEXT_WIDE(ACE_DIRECTORY_SEPARATOR_STR_A)
448 # define ACE_DIRECTORY_SEPARATOR_CHAR_W ACE_TEXT_WIDE(ACE_DIRECTORY_SEPARATOR_CHAR_A)
449 #endif /* ACE_HAS_WCHAR */
451 #define ACE_DIRECTORY_SEPARATOR_STR ACE_TEXT (ACE_DIRECTORY_SEPARATOR_STR_A)
452 #define ACE_DIRECTORY_SEPARATOR_CHAR ACE_TEXT (ACE_DIRECTORY_SEPARATOR_CHAR_A)
454 #if !defined (ACE_DEFAULT_THREAD_PRIORITY)
455 # define ACE_DEFAULT_THREAD_PRIORITY (-0x7fffffffL - 1L)
456 #endif /* ACE_DEFAULT_THREAD_PRIORITY */
458 #if !defined (ACE_DEFAULT_THREAD_STACKSIZE)
459 # define ACE_DEFAULT_THREAD_STACKSIZE 0
460 #endif /* ACE_DEFAULT_THREAD_STACKSIZE */
462 #if !defined (ACE_MAX_DEFAULT_PORT)
463 # define ACE_MAX_DEFAULT_PORT 65535
464 #endif /* ACE_MAX_DEFAULT_PORT */
466 // Default number of ACE_Event_Handlers supported by
467 // ACE_Timer_Heap.
468 #if !defined (ACE_DEFAULT_TIMERS) && defined (_POSIX_TIMER_MAX)
469 # define ACE_DEFAULT_TIMERS _POSIX_TIMER_MAX
470 #endif /* ACE_DEFAULT_TIMERS */
472 #if !defined (ACE_DEFAULT_TIMERS) || (defined (ACE_DEFAULT_TIMERS) && (ACE_DEFAULT_TIMERS == 0))
473 #error ACE_DEFAULT_TIMERS should be defined and not be zero
474 #endif /* ACE_DEFAULT_TIMERS */
476 #if defined (ACE_WIN32)
477 # define ACE_PLATFORM_A "Win32"
478 # define ACE_PLATFORM_EXE_SUFFIX_A ".exe"
479 #elif defined (ACE_VXWORKS)
480 # define ACE_PLATFORM_A "VxWorks"
481 # if defined (__RTP__)
482 # define ACE_PLATFORM_EXE_SUFFIX_A ".vxe"
483 # else
484 # define ACE_PLATFORM_EXE_SUFFIX_A ".out"
485 # endif
486 #else /* !ACE_WIN32 && !ACE_VXWORKS */
487 # define ACE_PLATFORM_A "UNIX"
488 # define ACE_PLATFORM_EXE_SUFFIX_A ""
489 #endif /* ACE_WIN32 */
491 // Define the Wide character and normal versions of some of the string macros
492 #if defined (ACE_HAS_WCHAR)
493 # define ACE_PLATFORM_W ACE_TEXT_WIDE(ACE_PLATFORM_A)
494 # define ACE_PLATFORM_EXE_SUFFIX_W ACE_TEXT_WIDE(ACE_PLATFORM_EXE_SUFFIX_A)
495 #endif /* ACE_HAS_WCHAR */
497 #define ACE_PLATFORM ACE_TEXT (ACE_PLATFORM_A)
498 #define ACE_PLATFORM_EXE_SUFFIX ACE_TEXT (ACE_PLATFORM_EXE_SUFFIX_A)
500 #if defined (ACE_WIN32)
501 # define ACE_LD_SEARCH_PATH ACE_TEXT ("PATH")
502 # define ACE_LD_SEARCH_PATH_SEPARATOR_STR ACE_TEXT (";")
503 # define ACE_DLL_SUFFIX ACE_TEXT (".dll")
504 # if !defined (ACE_DLL_PREFIX)
505 # define ACE_DLL_PREFIX ACE_TEXT ("")
506 # endif /* !ACE_DLL_PREFIX */
507 #else /* !ACE_WIN32 */
508 # if !defined (ACE_LD_SEARCH_PATH)
509 # define ACE_LD_SEARCH_PATH ACE_TEXT ("LD_LIBRARY_PATH")
510 # endif /* ACE_LD_SEARCH_PATH */
511 # if !defined (ACE_LD_SEARCH_PATH_SEPARATOR_STR)
512 # define ACE_LD_SEARCH_PATH_SEPARATOR_STR ACE_TEXT (":")
513 # endif /* ACE_LD_SEARCH_PATH_SEPARATOR_STR */
514 #endif /* ACE_WIN32 */
516 #if !defined (ACE_DLL_SUFFIX)
517 # define ACE_DLL_SUFFIX ACE_TEXT (".so")
518 #endif /* ACE_DLL_SUFFIX */
520 #if !defined (ACE_DLL_PREFIX)
521 # define ACE_DLL_PREFIX ACE_TEXT ("lib")
522 #endif /* ACE_DLL_PREFIX */
524 #if defined (ACE_WIN32)
525 // Used for dynamic linking
526 # if !defined (ACE_DEFAULT_SVC_CONF)
527 # if (ACE_USES_CLASSIC_SVC_CONF == 1)
528 # define ACE_DEFAULT_SVC_CONF ACE_TEXT (".\\svc.conf")
529 # else
530 # define ACE_DEFAULT_SVC_CONF ACE_TEXT (".\\svc.conf.xml")
531 # endif /* ACE_USES_CLASSIC_SVC_CONF ==1 */
532 # endif /* ACE_DEFAULT_SVC_CONF */
533 #endif /* ACE_WIN32 */
535 // Used for dynamic linking.
536 #if !defined (ACE_DEFAULT_SVC_CONF)
537 # if (ACE_USES_CLASSIC_SVC_CONF == 1)
538 # define ACE_DEFAULT_SVC_CONF ACE_TEXT ("./svc.conf")
539 # else
540 # define ACE_DEFAULT_SVC_CONF ACE_TEXT ("./svc.conf.xml")
541 # endif /* ACE_USES_CLASSIC_SVC_CONF ==1 */
542 #endif /* ACE_DEFAULT_SVC_CONF */
544 #if !defined (ACE_LOGGER_KEY)
545 # define ACE_LOGGER_KEY ACE_TEXT ("/tmp/server_daemon")
546 #endif /* ACE_LOGGER_KEY */
548 // Theses defines are used by the ACE Name Server.
549 #if !defined (ACE_DEFAULT_LOCALNAME_A)
550 # define ACE_DEFAULT_LOCALNAME_A "localnames"
551 #endif /* ACE_DEFAULT_LOCALNAME_A */
552 #if !defined (ACE_DEFAULT_GLOBALNAME_A)
553 # define ACE_DEFAULT_GLOBALNAME_A "globalnames"
554 #endif /* ACE_DEFAULT_GLOBALNAME_A */
556 #if defined (ACE_HAS_WCHAR)
557 # define ACE_DEFAULT_LOCALNAME_W ACE_TEXT_WIDE(ACE_DEFAULT_LOCALNAME_A)
558 # define ACE_DEFAULT_GLOBALNAME_W ACE_TEXT_WIDE(ACE_DEFAULT_GLOBALNAME_A)
559 #endif /* ACE_HAS_WCHAR */
561 #define ACE_DEFAULT_LOCALNAME ACE_TEXT (ACE_DEFAULT_LOCALNAME_A)
562 #define ACE_DEFAULT_GLOBALNAME ACE_TEXT (ACE_DEFAULT_GLOBALNAME_A)
564 #if !defined (ACE_DEFAULT_OPEN_PERMS)
565 # define ACE_DEFAULT_OPEN_PERMS ACE_DEFAULT_FILE_PERMS
566 #endif /* ACE_DEFAULT_OPEN_PERMS */
568 #if !defined (ACE_DEFAULT_RW_PROCESS_MUTEX_PERMS)
569 # if defined (ACE_WIN32)
570 # define ACE_DEFAULT_RW_PROCESS_MUTEX_PERMS ACE_DEFAULT_OPEN_PERMS
571 # else
572 # define ACE_DEFAULT_RW_PROCESS_MUTEX_PERMS (S_IRUSR | S_IWUSR)
573 # endif /* ACE_WIN32 */
574 #endif /* ACE_DEFAULT_RW_PROCESS_MUTEX_PERMS */
576 # if defined (ACE_WIN32)
577 // The "null" device on Win32.
578 # define ACE_DEV_NULL "nul"
579 # define ACE_SYSCALL_FAILED 0xFFFFFFFF
580 # else /* !ACE_WIN32 */
581 // The "null" device on UNIX.
582 # define ACE_DEV_NULL "/dev/null"
583 # define ACE_SYSCALL_FAILED -1
584 # endif /* ACE_WIN32 */
586 #if !defined (ACE_DEFAULT_ACCEPTOR_USE_SELECT)
587 # define ACE_DEFAULT_ACCEPTOR_USE_SELECT 1
588 #endif /* ACE_DEFAULT_ACCEPTOR_USE_SELECT */
590 #include /**/ "ace/post.h"
591 #endif /*ACE_DEFAULT_CONSTANTS_H*/