blob: 651d6930726d296589f024386707280f4d61f5cc [file] [log] [blame]
Owen Taylor3473f882001-02-23 17:55:21 +00001/*
2 * xmlversion.h : compile-time version informations for the XML parser.
3 *
4 * See Copyright for the status of this software.
5 *
Daniel Veillardc5d64342001-06-24 12:13:24 +00006 * daniel@veillard.com
Owen Taylor3473f882001-02-23 17:55:21 +00007 */
8
9#ifndef __XML_VERSION_H__
10#define __XML_VERSION_H__
11
12#ifdef __cplusplus
13extern "C" {
14#endif
15
16/*
17 * use those to be sure nothing nasty will happen if
18 * your library and includes mismatch
19 */
Daniel Veillard2d90de42001-04-16 17:46:18 +000020#ifndef LIBXML2_COMPILING_MSCCDEF
Owen Taylor3473f882001-02-23 17:55:21 +000021extern void xmlCheckVersion(int version);
Daniel Veillard2d90de42001-04-16 17:46:18 +000022#endif /* LIBXML2_COMPILING_MSCCDEF */
Daniel Veillard5e2dace2001-07-18 19:30:27 +000023
24/**
25 * LIBXML_DOTTED_VERSION:
26 *
27 * the version string like "1.2.3"
28 */
Owen Taylor3473f882001-02-23 17:55:21 +000029#define LIBXML_DOTTED_VERSION "@VERSION@"
Daniel Veillard5e2dace2001-07-18 19:30:27 +000030
31/**
32 * LIBXML_VERSION:
33 *
34 * the version number: 1.2.3 value is 1002003
35 */
Owen Taylor3473f882001-02-23 17:55:21 +000036#define LIBXML_VERSION @LIBXML_VERSION_NUMBER@
Daniel Veillard5e2dace2001-07-18 19:30:27 +000037
38/**
39 * LIBXML_VERSION_STRING:
40 *
41 * the version number string, 1.2.3 value is "1002003"
42 */
Owen Taylor3473f882001-02-23 17:55:21 +000043#define LIBXML_VERSION_STRING "@LIBXML_VERSION_NUMBER@"
Daniel Veillard5e2dace2001-07-18 19:30:27 +000044
45/**
46 * LIBXML_TEST_VERSION:
47 *
48 * Macro to check that the libxml version in use is compatible with
49 * the version the software has been compiled against
50 */
Owen Taylor3473f882001-02-23 17:55:21 +000051#define LIBXML_TEST_VERSION xmlCheckVersion(@LIBXML_VERSION_NUMBER@);
52
Daniel Veillardacf7ff02001-10-29 20:21:47 +000053#ifndef VMS
Daniel Veillard7cf5e442001-09-10 20:16:32 +000054#if @WITH_TRIO@
Daniel Veillardbed7b052001-05-19 14:59:49 +000055/**
56 * WITH_TRIO:
57 *
Daniel Veillard7cf5e442001-09-10 20:16:32 +000058 * defined if the trio support need to be configured in
Daniel Veillard92ad2102001-03-27 12:47:33 +000059 */
Daniel Veillard92ad2102001-03-27 12:47:33 +000060#define WITH_TRIO
Daniel Veillard7cf5e442001-09-10 20:16:32 +000061#else
62/**
63 * WITHOUT_TRIO:
64 *
65 * defined if the trio support should not be configured in
66 */
67#define WITHOUT_TRIO
Daniel Veillard92ad2102001-03-27 12:47:33 +000068#endif
Daniel Veillardacf7ff02001-10-29 20:21:47 +000069#else /* VMS */
70#define WITH_TRIO 1
71#endif /* VMS */
Daniel Veillard92ad2102001-03-27 12:47:33 +000072
Daniel Veillardbed7b052001-05-19 14:59:49 +000073/**
Daniel Veillardb8478642001-10-12 17:29:10 +000074 * LIBXML_THREADS_ENABLED:
75 *
76 * Whether the thread support is configured in
77 */
78#if @WITH_THREADS@
79#if defined(_REENTRANT) || (_POSIX_C_SOURCE - 0 >= 199506L)
80#define LIBXML_THREAD_ENABLED
81#endif
82#endif
83
84/**
Daniel Veillardbed7b052001-05-19 14:59:49 +000085 * LIBXML_FTP_ENABLED:
86 *
Owen Taylor3473f882001-02-23 17:55:21 +000087 * Whether the FTP support is configured in
88 */
89#if @WITH_FTP@
90#define LIBXML_FTP_ENABLED
Owen Taylor3473f882001-02-23 17:55:21 +000091#endif
92
Daniel Veillardbed7b052001-05-19 14:59:49 +000093/**
94 * LIBXML_HTTP_ENABLED:
95 *
Owen Taylor3473f882001-02-23 17:55:21 +000096 * Whether the HTTP support is configured in
97 */
98#if @WITH_HTTP@
99#define LIBXML_HTTP_ENABLED
Owen Taylor3473f882001-02-23 17:55:21 +0000100#endif
101
Daniel Veillardbed7b052001-05-19 14:59:49 +0000102/**
103 * LIBXML_HTML_ENABLED:
104 *
Owen Taylor3473f882001-02-23 17:55:21 +0000105 * Whether the HTML support is configured in
106 */
107#if @WITH_HTML@
108#define LIBXML_HTML_ENABLED
Owen Taylor3473f882001-02-23 17:55:21 +0000109#endif
110
Daniel Veillardbed7b052001-05-19 14:59:49 +0000111/**
112 * LIBXML_CATALOG_ENABLED:
113 *
Daniel Veillarda7374592001-05-10 14:17:55 +0000114 * Whether the Catalog support is configured in
115 */
116#if @WITH_CATALOG@
117#define LIBXML_CATALOG_ENABLED
Daniel Veillarda7374592001-05-10 14:17:55 +0000118#endif
119
Daniel Veillardbed7b052001-05-19 14:59:49 +0000120/**
121 * LIBXML_DOCB_ENABLED:
122 *
Daniel Veillardeae522a2001-04-23 13:41:34 +0000123 * Whether the SGML Docbook support is configured in
Owen Taylor3473f882001-02-23 17:55:21 +0000124 */
Daniel Veillardeae522a2001-04-23 13:41:34 +0000125#if @WITH_DOCB@
126#define LIBXML_DOCB_ENABLED
Daniel Veillardeae522a2001-04-23 13:41:34 +0000127#endif
Owen Taylor3473f882001-02-23 17:55:21 +0000128
Daniel Veillardbed7b052001-05-19 14:59:49 +0000129/**
130 * LIBXML_XPATH_ENABLED:
131 *
Owen Taylor3473f882001-02-23 17:55:21 +0000132 * Whether XPath is configured in
133 */
134#if @WITH_XPATH@
135#define LIBXML_XPATH_ENABLED
Owen Taylor3473f882001-02-23 17:55:21 +0000136#endif
137
Daniel Veillardbed7b052001-05-19 14:59:49 +0000138/**
139 * LIBXML_XPTR_ENABLED:
140 *
Owen Taylor3473f882001-02-23 17:55:21 +0000141 * Whether XPointer is configured in
142 */
143#if @WITH_XPTR@
144#define LIBXML_XPTR_ENABLED
Owen Taylor3473f882001-02-23 17:55:21 +0000145#endif
146
Daniel Veillardbed7b052001-05-19 14:59:49 +0000147/**
148 * LIBXML_XINCLUDE_ENABLED:
149 *
Owen Taylor3473f882001-02-23 17:55:21 +0000150 * Whether XInclude is configured in
151 */
152#if @WITH_XINCLUDE@
153#define LIBXML_XINCLUDE_ENABLED
Owen Taylor3473f882001-02-23 17:55:21 +0000154#endif
155
Daniel Veillardbed7b052001-05-19 14:59:49 +0000156/**
157 * LIBXML_ICONV_ENABLED:
158 *
Owen Taylor3473f882001-02-23 17:55:21 +0000159 * Whether iconv support is available
160 */
Daniel Veillard9cc6dc62001-06-11 08:09:20 +0000161#if !defined(WIN32) || defined(__CYGWIN__)
Owen Taylor3473f882001-02-23 17:55:21 +0000162#if @WITH_ICONV@
163#define LIBXML_ICONV_ENABLED
Owen Taylor3473f882001-02-23 17:55:21 +0000164#endif
165#endif
166
Daniel Veillardbed7b052001-05-19 14:59:49 +0000167/**
168 * LIBXML_DEBUG_ENABLED:
169 *
Owen Taylor3473f882001-02-23 17:55:21 +0000170 * Whether Debugging module is configured in
171 */
172#if @WITH_DEBUG@
173#define LIBXML_DEBUG_ENABLED
Owen Taylor3473f882001-02-23 17:55:21 +0000174#endif
175
Daniel Veillardbed7b052001-05-19 14:59:49 +0000176/**
177 * DEBUG_MEMORY_LOCATION:
178 *
Owen Taylor3473f882001-02-23 17:55:21 +0000179 * Whether the memory debugging is configured in
180 */
181#if @WITH_MEM_DEBUG@
182#define DEBUG_MEMORY_LOCATION
183#endif
184
Daniel Veillard5e2dace2001-07-18 19:30:27 +0000185/**
186 * LIBXML_DLL_IMPORT:
187 *
Daniel Veillard50f34372001-08-03 12:06:36 +0000188 * Used on Windows (MS C compiler only) to declare a variable as
189 * imported from the library. This macro should be empty when compiling
190 * libxml itself. It should expand to __declspec(dllimport)
191 * when the client code includes this header, and that only if the client
192 * links dynamically against libxml.
193 * For this to work, we need three macros. One tells us which compiler is
194 * being used and luckily the compiler defines such a thing: _MSC_VER. The
195 * second macro tells us if we are compiling libxml or the client code and
196 * we define the macro IN_LIBXML on the compiler's command line for this
197 * purpose. The third macro, LIBXML_STATIC, must be defined by any client
198 * code which links against libxml statically.
Daniel Veillard5e2dace2001-07-18 19:30:27 +0000199 */
Owen Taylor3473f882001-02-23 17:55:21 +0000200#ifndef LIBXML_DLL_IMPORT
Daniel Veillard50f34372001-08-03 12:06:36 +0000201#if defined(_MSC_VER) && !defined(IN_LIBXML) && !defined(LIBXML_STATIC)
Owen Taylor3473f882001-02-23 17:55:21 +0000202#define LIBXML_DLL_IMPORT __declspec(dllimport)
203#else
204#define LIBXML_DLL_IMPORT
205#endif
206#endif
207
Daniel Veillardbed7b052001-05-19 14:59:49 +0000208/**
209 * ATTRIBUTE_UNUSED:
210 *
211 * Macro used to signal to GCC unused function parameters
212 */
Daniel Veillardc86a4fa2001-03-26 16:28:29 +0000213#ifdef __GNUC__
Daniel Veillard27b55282001-04-11 12:22:25 +0000214#ifdef HAVE_ANSIDECL_H
Daniel Veillardc86a4fa2001-03-26 16:28:29 +0000215#include <ansidecl.h>
Daniel Veillard27b55282001-04-11 12:22:25 +0000216#endif
Daniel Veillardc86a4fa2001-03-26 16:28:29 +0000217#ifndef ATTRIBUTE_UNUSED
218#define ATTRIBUTE_UNUSED
219#endif
220#else
221#define ATTRIBUTE_UNUSED
222#endif
223
Owen Taylor3473f882001-02-23 17:55:21 +0000224#ifdef __cplusplus
225}
226#endif /* __cplusplus */
227#endif
228
229