1 | /*
|
---|
2 | * libxml.h: internal header only used during the compilation of libxml
|
---|
3 | *
|
---|
4 | * See COPYRIGHT for the status of this software
|
---|
5 | *
|
---|
6 | * Author: [email protected]
|
---|
7 | */
|
---|
8 |
|
---|
9 | #ifndef __XML_LIBXML_H__
|
---|
10 | #define __XML_LIBXML_H__
|
---|
11 |
|
---|
12 | #ifndef NO_LARGEFILE_SOURCE
|
---|
13 | #ifndef _LARGEFILE_SOURCE
|
---|
14 | #define _LARGEFILE_SOURCE
|
---|
15 | #endif
|
---|
16 | #ifndef _FILE_OFFSET_BITS
|
---|
17 | #define _FILE_OFFSET_BITS 64
|
---|
18 | #endif
|
---|
19 | #endif
|
---|
20 |
|
---|
21 | #if defined(macintosh)
|
---|
22 | #include "config-mac.h"
|
---|
23 | #elif defined(_WIN32)
|
---|
24 | #include <win32config.h>
|
---|
25 | #include <libxml/xmlversion.h>
|
---|
26 | #elif defined(_WIN32_WCE)
|
---|
27 | /*
|
---|
28 | * Windows CE compatibility definitions and functions
|
---|
29 | * This is needed to compile libxml2 for Windows CE.
|
---|
30 | * At least I tested it with WinCE 5.0 for Emulator and WinCE 4.2/SH4 target
|
---|
31 | */
|
---|
32 | #include <win32config.h>
|
---|
33 | #include <libxml/xmlversion.h>
|
---|
34 | #elif defined(VBOX)
|
---|
35 | #include <vboxconfig.h>
|
---|
36 | #include <libxml/xmlversion.h>
|
---|
37 | #else
|
---|
38 | /*
|
---|
39 | * Currently supported platforms use either autoconf or
|
---|
40 | * copy to config.h own "preset" configuration file.
|
---|
41 | * As result ifdef HAVE_CONFIG_H is omited here.
|
---|
42 | */
|
---|
43 | #include "config.h"
|
---|
44 | #include <libxml/xmlversion.h>
|
---|
45 | #endif
|
---|
46 |
|
---|
47 | #if defined(__Lynx__)
|
---|
48 | #include <stdio.h> /* pull definition of size_t */
|
---|
49 | #include <varargs.h>
|
---|
50 | int snprintf(char *, size_t, const char *, ...);
|
---|
51 | int vfprintf(FILE *, const char *, va_list);
|
---|
52 | #endif
|
---|
53 |
|
---|
54 | #ifndef WITH_TRIO
|
---|
55 | #include <stdio.h>
|
---|
56 | #else
|
---|
57 | /**
|
---|
58 | * TRIO_REPLACE_STDIO:
|
---|
59 | *
|
---|
60 | * This macro is defined if teh trio string formatting functions are to
|
---|
61 | * be used instead of the default stdio ones.
|
---|
62 | */
|
---|
63 | #define TRIO_REPLACE_STDIO
|
---|
64 | #include "trio.h"
|
---|
65 | #endif
|
---|
66 |
|
---|
67 | /*
|
---|
68 | * Internal variable indicating if a callback has been registered for
|
---|
69 | * node creation/destruction. It avoids spending a lot of time in locking
|
---|
70 | * function while checking if the callback exists.
|
---|
71 | */
|
---|
72 | extern int __xmlRegisterCallbacks;
|
---|
73 | /*
|
---|
74 | * internal error reporting routines, shared but not partof the API.
|
---|
75 | */
|
---|
76 | void __xmlIOErr(int domain, int code, const char *extra);
|
---|
77 | void __xmlLoaderErr(void *ctx, const char *msg, const char *filename);
|
---|
78 | #ifdef LIBXML_HTML_ENABLED
|
---|
79 | /*
|
---|
80 | * internal function of HTML parser needed for xmlParseInNodeContext
|
---|
81 | * but not part of the API
|
---|
82 | */
|
---|
83 | void __htmlParseContent(void *ctx);
|
---|
84 | #endif
|
---|
85 |
|
---|
86 | /*
|
---|
87 | * internal global initialization critical section routines.
|
---|
88 | */
|
---|
89 | void __xmlGlobalInitMutexLock(void);
|
---|
90 | void __xmlGlobalInitMutexUnlock(void);
|
---|
91 | void __xmlGlobalInitMutexDestroy(void);
|
---|
92 |
|
---|
93 | int __xmlInitializeDict(void);
|
---|
94 |
|
---|
95 | #if defined(HAVE_RAND) && defined(HAVE_SRAND) && defined(HAVE_TIME)
|
---|
96 | /*
|
---|
97 | * internal thread safe random function
|
---|
98 | */
|
---|
99 | int __xmlRandom(void);
|
---|
100 | #endif
|
---|
101 |
|
---|
102 | int xmlNop(void);
|
---|
103 |
|
---|
104 | #ifdef IN_LIBXML
|
---|
105 | #ifdef __GNUC__
|
---|
106 | #ifdef PIC
|
---|
107 | #ifdef linux
|
---|
108 | #if (__GNUC__ == 3 && __GNUC_MINOR__ >= 3) || (__GNUC__ > 3)
|
---|
109 | #include "elfgcchack.h"
|
---|
110 | #endif
|
---|
111 | #endif
|
---|
112 | #endif
|
---|
113 | #endif
|
---|
114 | #endif
|
---|
115 | #if !defined(PIC) && !defined(NOLIBTOOL)
|
---|
116 | # define LIBXML_STATIC
|
---|
117 | #endif
|
---|
118 | #endif /* ! __XML_LIBXML_H__ */
|
---|