VirtualBox

source: vbox/trunk/src/libs/libxml2-2.9.14/libxml.h@ 98879

Last change on this file since 98879 was 95312, checked in by vboxsync, 2 years ago

libs/{curl,libxml2}: OSE export fixes, bugref:8515

  • Property svn:eol-style set to native
File size: 3.6 KB
Line 
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: breese@users.sourceforge.net
7 */
8
9#ifndef __XML_LIBXML_H__
10#define __XML_LIBXML_H__
11
12/*
13 * These macros must be defined before including system headers.
14 * Do not add any #include directives above this block.
15 */
16#ifndef NO_LARGEFILE_SOURCE
17#ifndef _LARGEFILE_SOURCE
18#define _LARGEFILE_SOURCE
19#endif
20#ifndef _FILE_OFFSET_BITS
21#define _FILE_OFFSET_BITS 64
22#endif
23#endif
24
25#if defined(macintosh)
26#include "config-mac.h"
27#elif defined(_WIN32)
28#include <win32config.h>
29#include <libxml/xmlversion.h>
30#elif defined(_WIN32_WCE)
31/*
32 * Windows CE compatibility definitions and functions
33 * This is needed to compile libxml2 for Windows CE.
34 * At least I tested it with WinCE 5.0 for Emulator and WinCE 4.2/SH4 target
35 */
36#include <win32config.h>
37#include <libxml/xmlversion.h>
38#elif defined(VBOX)
39#include <vboxconfig.h>
40#include <libxml/xmlversion.h>
41#else
42/*
43 * Currently supported platforms use either autoconf or
44 * copy to config.h own "preset" configuration file.
45 * As result ifdef HAVE_CONFIG_H is omitted here.
46 */
47#include "config.h"
48#include <libxml/xmlversion.h>
49#endif
50#include <libxml/xmlstring.h>
51
52#if defined(__Lynx__)
53#include <stdio.h> /* pull definition of size_t */
54#include <varargs.h>
55int snprintf(char *, size_t, const char *, ...);
56int vfprintf(FILE *, const char *, va_list);
57#endif
58
59#ifndef WITH_TRIO
60#include <stdio.h>
61#else
62/**
63 * TRIO_REPLACE_STDIO:
64 *
65 * This macro is defined if the trio string formatting functions are to
66 * be used instead of the default stdio ones.
67 */
68#define TRIO_REPLACE_STDIO
69#include "trio.h"
70#endif
71
72#if defined(__clang__) || \
73 (defined(__GNUC__) && (__GNUC__ * 100 + __GNUC_MINOR__ >= 406))
74#define XML_IGNORE_PEDANTIC_WARNINGS \
75 _Pragma("GCC diagnostic push") \
76 _Pragma("GCC diagnostic ignored \"-Wpedantic\"")
77#define XML_POP_WARNINGS \
78 _Pragma("GCC diagnostic pop")
79#else
80#define XML_IGNORE_PEDANTIC_WARNINGS
81#define XML_POP_WARNINGS
82#endif
83
84#if defined(__clang__) || \
85 (defined(__GNUC__) && (__GNUC__ >= 8))
86#define ATTRIBUTE_NO_SANITIZE(arg) __attribute__((no_sanitize(arg)))
87#else
88#define ATTRIBUTE_NO_SANITIZE(arg)
89#endif
90
91/*
92 * Internal variable indicating if a callback has been registered for
93 * node creation/destruction. It avoids spending a lot of time in locking
94 * function while checking if the callback exists.
95 */
96extern int __xmlRegisterCallbacks;
97/*
98 * internal error reporting routines, shared but not part of the API.
99 */
100void __xmlIOErr(int domain, int code, const char *extra);
101void __xmlLoaderErr(void *ctx, const char *msg, const char *filename) LIBXML_ATTR_FORMAT(2,0);
102#ifdef LIBXML_HTML_ENABLED
103/*
104 * internal function of HTML parser needed for xmlParseInNodeContext
105 * but not part of the API
106 */
107void __htmlParseContent(void *ctx);
108#endif
109
110/*
111 * internal global initialization critical section routines.
112 */
113void __xmlGlobalInitMutexLock(void);
114void __xmlGlobalInitMutexUnlock(void);
115void __xmlGlobalInitMutexDestroy(void);
116
117int __xmlInitializeDict(void);
118
119#if defined(HAVE_RAND) && defined(HAVE_SRAND) && defined(HAVE_TIME)
120/*
121 * internal thread safe random function
122 */
123int __xmlRandom(void);
124#endif
125
126XMLPUBFUN xmlChar * XMLCALL xmlEscapeFormatString(xmlChar **msg);
127int xmlInputReadCallbackNop(void *context, char *buffer, int len);
128
129#ifdef IN_LIBXML
130#ifdef __GNUC__
131#ifdef PIC
132#ifdef __linux__
133#if (__GNUC__ == 3 && __GNUC_MINOR__ >= 3) || (__GNUC__ > 3)
134#include "elfgcchack.h"
135#endif
136#endif
137#endif
138#endif
139#endif
140#if !defined(PIC) && !defined(NOLIBTOOL) && !defined(LIBXML_STATIC)
141# define LIBXML_STATIC
142#endif
143#endif /* ! __XML_LIBXML_H__ */
Note: See TracBrowser for help on using the repository browser.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette