blob: c5ffc883b2d91efe9a03c3c1bd4f33376bd1956e [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 Veillard7cf5e442001-09-10 20:16:32 +000053#if @WITH_TRIO@
Daniel Veillardbed7b052001-05-19 14:59:49 +000054/**
55 * WITH_TRIO:
56 *
Daniel Veillard7cf5e442001-09-10 20:16:32 +000057 * defined if the trio support need to be configured in
Daniel Veillard92ad2102001-03-27 12:47:33 +000058 */
Daniel Veillard92ad2102001-03-27 12:47:33 +000059#define WITH_TRIO
Daniel Veillard7cf5e442001-09-10 20:16:32 +000060#else
61/**
62 * WITHOUT_TRIO:
63 *
64 * defined if the trio support should not be configured in
65 */
66#define WITHOUT_TRIO
Daniel Veillard92ad2102001-03-27 12:47:33 +000067#endif
68
Daniel Veillardbed7b052001-05-19 14:59:49 +000069/**
Daniel Veillardb8478642001-10-12 17:29:10 +000070 * LIBXML_THREADS_ENABLED:
71 *
72 * Whether the thread support is configured in
73 */
74#if @WITH_THREADS@
75#if defined(_REENTRANT) || (_POSIX_C_SOURCE - 0 >= 199506L)
76#define LIBXML_THREAD_ENABLED
77#endif
78#endif
79
80/**
Daniel Veillardbed7b052001-05-19 14:59:49 +000081 * LIBXML_FTP_ENABLED:
82 *
Owen Taylor3473f882001-02-23 17:55:21 +000083 * Whether the FTP support is configured in
84 */
85#if @WITH_FTP@
86#define LIBXML_FTP_ENABLED
Owen Taylor3473f882001-02-23 17:55:21 +000087#endif
88
Daniel Veillardbed7b052001-05-19 14:59:49 +000089/**
90 * LIBXML_HTTP_ENABLED:
91 *
Owen Taylor3473f882001-02-23 17:55:21 +000092 * Whether the HTTP support is configured in
93 */
94#if @WITH_HTTP@
95#define LIBXML_HTTP_ENABLED
Owen Taylor3473f882001-02-23 17:55:21 +000096#endif
97
Daniel Veillardbed7b052001-05-19 14:59:49 +000098/**
99 * LIBXML_HTML_ENABLED:
100 *
Owen Taylor3473f882001-02-23 17:55:21 +0000101 * Whether the HTML support is configured in
102 */
103#if @WITH_HTML@
104#define LIBXML_HTML_ENABLED
Owen Taylor3473f882001-02-23 17:55:21 +0000105#endif
106
Daniel Veillardbed7b052001-05-19 14:59:49 +0000107/**
108 * LIBXML_CATALOG_ENABLED:
109 *
Daniel Veillarda7374592001-05-10 14:17:55 +0000110 * Whether the Catalog support is configured in
111 */
112#if @WITH_CATALOG@
113#define LIBXML_CATALOG_ENABLED
Daniel Veillarda7374592001-05-10 14:17:55 +0000114#endif
115
Daniel Veillardbed7b052001-05-19 14:59:49 +0000116/**
117 * LIBXML_DOCB_ENABLED:
118 *
Daniel Veillardeae522a2001-04-23 13:41:34 +0000119 * Whether the SGML Docbook support is configured in
Owen Taylor3473f882001-02-23 17:55:21 +0000120 */
Daniel Veillardeae522a2001-04-23 13:41:34 +0000121#if @WITH_DOCB@
122#define LIBXML_DOCB_ENABLED
Daniel Veillardeae522a2001-04-23 13:41:34 +0000123#endif
Owen Taylor3473f882001-02-23 17:55:21 +0000124
Daniel Veillardbed7b052001-05-19 14:59:49 +0000125/**
126 * LIBXML_XPATH_ENABLED:
127 *
Owen Taylor3473f882001-02-23 17:55:21 +0000128 * Whether XPath is configured in
129 */
130#if @WITH_XPATH@
131#define LIBXML_XPATH_ENABLED
Owen Taylor3473f882001-02-23 17:55:21 +0000132#endif
133
Daniel Veillardbed7b052001-05-19 14:59:49 +0000134/**
135 * LIBXML_XPTR_ENABLED:
136 *
Owen Taylor3473f882001-02-23 17:55:21 +0000137 * Whether XPointer is configured in
138 */
139#if @WITH_XPTR@
140#define LIBXML_XPTR_ENABLED
Owen Taylor3473f882001-02-23 17:55:21 +0000141#endif
142
Daniel Veillardbed7b052001-05-19 14:59:49 +0000143/**
144 * LIBXML_XINCLUDE_ENABLED:
145 *
Owen Taylor3473f882001-02-23 17:55:21 +0000146 * Whether XInclude is configured in
147 */
148#if @WITH_XINCLUDE@
149#define LIBXML_XINCLUDE_ENABLED
Owen Taylor3473f882001-02-23 17:55:21 +0000150#endif
151
Daniel Veillardbed7b052001-05-19 14:59:49 +0000152/**
153 * LIBXML_ICONV_ENABLED:
154 *
Owen Taylor3473f882001-02-23 17:55:21 +0000155 * Whether iconv support is available
156 */
Daniel Veillard9cc6dc62001-06-11 08:09:20 +0000157#if !defined(WIN32) || defined(__CYGWIN__)
Owen Taylor3473f882001-02-23 17:55:21 +0000158#if @WITH_ICONV@
159#define LIBXML_ICONV_ENABLED
Owen Taylor3473f882001-02-23 17:55:21 +0000160#endif
161#endif
162
Daniel Veillardbed7b052001-05-19 14:59:49 +0000163/**
164 * LIBXML_DEBUG_ENABLED:
165 *
Owen Taylor3473f882001-02-23 17:55:21 +0000166 * Whether Debugging module is configured in
167 */
168#if @WITH_DEBUG@
169#define LIBXML_DEBUG_ENABLED
Owen Taylor3473f882001-02-23 17:55:21 +0000170#endif
171
Daniel Veillardbed7b052001-05-19 14:59:49 +0000172/**
173 * DEBUG_MEMORY_LOCATION:
174 *
Owen Taylor3473f882001-02-23 17:55:21 +0000175 * Whether the memory debugging is configured in
176 */
177#if @WITH_MEM_DEBUG@
178#define DEBUG_MEMORY_LOCATION
179#endif
180
Daniel Veillard5e2dace2001-07-18 19:30:27 +0000181/**
182 * LIBXML_DLL_IMPORT:
183 *
Daniel Veillard50f34372001-08-03 12:06:36 +0000184 * Used on Windows (MS C compiler only) to declare a variable as
185 * imported from the library. This macro should be empty when compiling
186 * libxml itself. It should expand to __declspec(dllimport)
187 * when the client code includes this header, and that only if the client
188 * links dynamically against libxml.
189 * For this to work, we need three macros. One tells us which compiler is
190 * being used and luckily the compiler defines such a thing: _MSC_VER. The
191 * second macro tells us if we are compiling libxml or the client code and
192 * we define the macro IN_LIBXML on the compiler's command line for this
193 * purpose. The third macro, LIBXML_STATIC, must be defined by any client
194 * code which links against libxml statically.
Daniel Veillard5e2dace2001-07-18 19:30:27 +0000195 */
Owen Taylor3473f882001-02-23 17:55:21 +0000196#ifndef LIBXML_DLL_IMPORT
Daniel Veillard50f34372001-08-03 12:06:36 +0000197#if defined(_MSC_VER) && !defined(IN_LIBXML) && !defined(LIBXML_STATIC)
Owen Taylor3473f882001-02-23 17:55:21 +0000198#define LIBXML_DLL_IMPORT __declspec(dllimport)
199#else
200#define LIBXML_DLL_IMPORT
201#endif
202#endif
203
Daniel Veillardbed7b052001-05-19 14:59:49 +0000204/**
205 * ATTRIBUTE_UNUSED:
206 *
207 * Macro used to signal to GCC unused function parameters
208 */
Daniel Veillardc86a4fa2001-03-26 16:28:29 +0000209#ifdef __GNUC__
Daniel Veillard27b55282001-04-11 12:22:25 +0000210#ifdef HAVE_ANSIDECL_H
Daniel Veillardc86a4fa2001-03-26 16:28:29 +0000211#include <ansidecl.h>
Daniel Veillard27b55282001-04-11 12:22:25 +0000212#endif
Daniel Veillardc86a4fa2001-03-26 16:28:29 +0000213#ifndef ATTRIBUTE_UNUSED
214#define ATTRIBUTE_UNUSED
215#endif
216#else
217#define ATTRIBUTE_UNUSED
218#endif
219
Owen Taylor3473f882001-02-23 17:55:21 +0000220#ifdef __cplusplus
221}
222#endif /* __cplusplus */
223#endif
224
225