Changeset 26697 in webkit for trunk/JavaScriptCore/pcre/pcre-config.h
- Timestamp:
- Oct 16, 2007, 10:38:39 PM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/JavaScriptCore/pcre/pcre-config.h
r24453 r26697 1 /* On Unix systems config.in is converted by configure into config.h. PCRE is2 written in Standard C, but there are a few non-standard things it can cope3 with, allowing it to run on SunOS4 and other "close to standard" systems.4 1 5 On a non-Unix system you should just copy this file into config.h, and set up 6 the macros the way you need them. You should normally change the definitions of 7 HAVE_STRERROR and HAVE_MEMMOVE to 1. Unfortunately, because of the way autoconf 8 works, these cannot be made the defaults. If your system has bcopy() and not 9 memmove(), change the definition of HAVE_BCOPY instead of HAVE_MEMMOVE. If your 10 system has neither bcopy() nor memmove(), leave them both as 0; an emulation 11 function will be used. */ 2 /* On Unix-like systems config.in is converted by "configure" into config.h. 3 Some other environments also support the use of "configure". PCRE is written in 4 Standard C, but there are a few non-standard things it can cope with, allowing 5 it to run on SunOS4 and other "close to standard" systems. 6 7 On a non-Unix-like system you should just copy this file into config.h, and set 8 up the macros the way you need them. You should normally change the definitions 9 of HAVE_STRERROR and HAVE_MEMMOVE to 1. Unfortunately, because of the way 10 autoconf works, these cannot be made the defaults. If your system has bcopy() 11 and not memmove(), change the definition of HAVE_BCOPY instead of HAVE_MEMMOVE. 12 If your system has neither bcopy() nor memmove(), leave them both as 0; an 13 emulation function will be used. */ 12 14 13 15 /* If you are compiling for a system that uses EBCDIC instead of ASCII … … 15 17 this can be done via --enable-ebcdic. */ 16 18 19 #ifndef EBCDIC 17 20 #define EBCDIC 0 21 #endif 18 22 19 /* If you are compiling for a system that needs some magic to be inserted 20 before the definition of an exported function, define this macro to contain the 21 relevant magic. It apears at the start of every exported function. */ 23 /* If you are compiling for a system other than a Unix-like system or Win32, 24 and it needs some magic to be inserted before the definition of a function that 25 is exported by the library, define this macro to contain the relevant magic. If 26 you do not define this macro, it defaults to "extern" for a C compiler and 27 "extern C" for a C++ compiler on non-Win32 systems. This macro apears at the 28 start of every exported function that is part of the external API. It does not 29 appear on functions that are "external" in the C sense, but which are internal 30 to the library. */ 22 31 23 #define PCRE_ EXPORT32 #define PCRE_DATA_SCOPE extern 24 33 25 /* Define t o empty if the "const" keyword does not work. */34 /* Define the following macro to empty if the "const" keyword does not work. */ 26 35 27 36 #undef const 28 37 29 /* Define to "unsigned" if <stddef.h> doesn't define size_t. */ 38 /* Define the following macro to "unsigned" if <stddef.h> does not define 39 size_t. */ 30 40 31 41 #undef size_t 32 42 33 43 /* The following two definitions are mainly for the benefit of SunOS4, which 34 does n't have the strerror() or memmove() functions that should be present in44 does not have the strerror() or memmove() functions that should be present in 35 45 all Standard C libraries. The macros HAVE_STRERROR and HAVE_MEMMOVE should 36 46 normally be defined with the value 1 for other systems, but unfortunately we 37 can 't make this the default because "configure" files generated by autoconf47 cannot make this the default because "configure" files generated by autoconf 38 48 will only change 0 to 1; they won't change 1 to 0 if the functions are not 39 49 found. */ … … 42 52 #define HAVE_MEMMOVE 1 43 53 44 /* There are some non-Unix systems that don't even have bcopy(). If this macro45 is false, an emulation is used. If HAVE_MEMMOVE is set to 1, the value of54 /* There are some non-Unix-like systems that don't even have bcopy(). If this 55 macro is false, an emulation is used. If HAVE_MEMMOVE is set to 1, the value of 46 56 HAVE_BCOPY is not relevant. */ 47 57 48 #define HAVE_BCOPY 158 #define HAVE_BCOPY 0 49 59 50 60 /* The value of NEWLINE determines the newline character. The default is to 51 61 leave it up to the compiler, but some sites want to force a particular value. 52 On Unix systems, "configure" can be used to override this default. */62 On Unix-like systems, "configure" can be used to override this default. */ 53 63 64 #ifndef NEWLINE 54 65 #define NEWLINE '\n' 66 #endif 55 67 56 /* The value of LINK_SIZE determines the number of bytes used to store 57 links as offsets within the compiled regex. The default is 2, which allows for 58 compiled patterns up to 64K long. This covers the vast majority of cases. 59 However, PCRE can also be compiled to use 3 or 4 bytes instead. This allows for60 longer patterns in extreme cases. On Unix systems, "configure" can be used to 61 override this default. */68 /* The value of LINK_SIZE determines the number of bytes used to store links as 69 offsets within the compiled regex. The default is 2, which allows for compiled 70 patterns up to 64K long. This covers the vast majority of cases. However, PCRE 71 can also be compiled to use 3 or 4 bytes instead. This allows for longer 72 patterns in extreme cases. On systems that support it, "configure" can be used 73 to override this default. */ 62 74 75 #ifndef LINK_SIZE 63 76 #define LINK_SIZE 2 64 65 /* The value of MATCH_LIMIT determines the default number of times the match() 66 function can be called during a single execution of pcre_exec(). (There is a 67 runtime method of setting a different limit.) The limit exists in order to 68 catch runaway regular expressions that take for ever to determine that they do 69 not match. The default is set very large so that it does not accidentally catch 70 legitimate cases. On Unix systems, "configure" can be used to override this 71 default default. */ 72 73 #define MATCH_LIMIT 10000000 77 #endif 74 78 75 79 /* When calling PCRE via the POSIX interface, additional working storage is … … 78 82 the number of expected substrings is small, the wrapper function uses space on 79 83 the stack, because this is faster than using malloc() for each call. The 80 threshold above which the stack is no longer use is defined by POSIX_MALLOC_81 THRESHOLD. On Unix systems, "configure" can be used to override this default.82 */84 threshold above which the stack is no longer used is defined by POSIX_MALLOC_ 85 THRESHOLD. On systems that support it, "configure" can be used to override this 86 default. */ 83 87 88 #ifndef POSIX_MALLOC_THRESHOLD 84 89 #define POSIX_MALLOC_THRESHOLD 10 90 #endif 85 91 86 92 /* PCRE uses recursive function calls to handle backtracking while matching. 87 93 This can sometimes be a problem on systems that have stacks of limited size. 88 94 Define NO_RECURSE to get a version that doesn't use recursion in the match() 89 function; instead it creates its own stack by steam using pcre_recurse_malloc 90 to get memory. For more detail, see comments and other stuff just above the91 match() function. On Unix systems, "configure" can be used to set this in the 92 Makefile (use --disable-stack-for-recursion). */95 function; instead it creates its own stack by steam using pcre_recurse_malloc() 96 to obtain memory from the heap. For more detail, see the comments and other 97 stuff just above the match() function. On systems that support it, "configure" 98 can be used to set this in the Makefile (use --disable-stack-for-recursion). */ 93 99 94 100 #define NO_RECURSE 95 101 96 /* End */ 102 /* The value of MATCH_LIMIT determines the default number of times the internal 103 match() function can be called during a single execution of pcre_exec(). There 104 is a runtime interface for setting a different limit. The limit exists in order 105 to catch runaway regular expressions that take for ever to determine that they 106 do not match. The default is set very large so that it does not accidentally 107 catch legitimate cases. On systems that support it, "configure" can be used to 108 override this default default. */ 109 110 #ifndef MATCH_LIMIT 111 #define MATCH_LIMIT 10000000 112 #endif 113 114 /* The above limit applies to all calls of match(), whether or not they 115 increase the recursion depth. In some environments it is desirable to limit the 116 depth of recursive calls of match() more strictly, in order to restrict the 117 maximum amount of stack (or heap, if NO_RECURSE is defined) that is used. The 118 value of MATCH_LIMIT_RECURSION applies only to recursive calls of match(). To 119 have any useful effect, it must be less than the value of MATCH_LIMIT. There is 120 a runtime method for setting a different limit. On systems that support it, 121 "configure" can be used to override this default default. */ 122 123 #ifndef MATCH_LIMIT_RECURSION 124 #define MATCH_LIMIT_RECURSION MATCH_LIMIT 125 #endif 97 126 98 127 #define SUPPORT_UCP 1 … … 100 129 101 130 #define JAVASCRIPT 1 131 132 /* End */
Note:
See TracChangeset
for help on using the changeset viewer.