00001
00002
00003 #include <config.h>
00004 const char * dummy = {
00005 "// version.h: Define preprocesor symbols for the library version.",
00006 "// If using GCC, also check the C++ ABI version is compatible with that used",
00007 "// to build the library.",
00008 "//",
00009 "// Copyright (C) 2002,2004,2005,2006,2007 Olly Betts",
00010 "//",
00011 "// This program is free software; you can redistribute it and/or",
00012 "// modify it under the terms of the GNU General Public License as",
00013 "// published by the Free Software Foundation; either version 2 of the",
00014 "// License, or (at your option) any later version.",
00015 "//",
00016 "// This program is distributed in the hope that it will be useful,",
00017 "// but WITHOUT ANY WARRANTY; without even the implied warranty of",
00018 "// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the",
00019 "// GNU General Public License for more details.",
00020 "//",
00021 "// You should have received a copy of the GNU General Public License",
00022 "// along with this program; if not, write to the Free Software",
00023 "// Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA",
00024 "",
00025 "#ifndef XAPIAN_INCLUDED_VERSION_H",
00026 "#define XAPIAN_INCLUDED_VERSION_H",
00027 #ifdef __GNUC__
00028
00029
00030
00031
00032
00033
00034
00035
00036
00037
00038
00039
00040
00041
00042
00043
00044
00045
00046
00047
00048 #define V2(A,B) J2(A,B)
00049 #define J2(A,B) g++ A##.##B
00050 #define V3(A,B,C) J3(A,B,C)
00051 #define J3(A,B,C) g++ A##.##B##.##C
00052 "",
00053 "#ifdef __GNUC__",
00054 #ifdef __GXX_ABI_VERSION
00055
00056
00057 #if __GNUC__ == 3 && __GNUC_MINOR__ == 0
00058 "#if !(__GNUC__ == 3 && __GNUC_MINOR__ == 0)",
00059 #elif __GNUC__ == 3 && __GNUC_MINOR__ == 1
00060 "#if !(__GNUC__ == 3 && __GNUC_MINOR__ == 1)",
00061 #else
00062 "#if !defined(__GXX_ABI_VERSION) || __GXX_ABI_VERSION != ",__GXX_ABI_VERSION,
00063 #endif
00064 #elif __GNUC__ == 2 && __GNUC_MINOR__ == 96
00065 "#if !(__GNUC__ == 2 && __GNUC_MINOR__ == 96)",
00066 #else
00067 "#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 96)",
00068 #endif
00069 "#error The C++ ABI version of compiler you are using does not match",
00070 "#error that of the compiler used to build the library. The versions",
00071 "#error must match or your program will not work correctly.",
00072 #ifdef __GNUC_PATCHLEVEL__
00073 "#error The Xapian library was built with ",V3(__GNUC__,__GNUC_MINOR__,__GNUC_PATCHLEVEL__),
00074 #else
00075 "#error The Xapian library was built with ",V2(__GNUC__,__GNUC_MINOR__),
00076 #endif
00077 "#endif",
00078 "",
00079
00080
00081 #if (__GNUC__ == 3 && __GNUC_MINOR__ >= 4) || __GNUC__ >= 4
00082 #ifdef _GLIBCXX_DEBUG
00083 "#ifndef _GLIBCXX_DEBUG",
00084 "#error This library was compiled with _GLIBCXX_DEBUG defined, but you",
00085 "#error have not specified this flag. The settings must match or your",
00086 "#error program will not work correctly.",
00087 "#endif",
00088 #else
00089 "#ifdef _GLIBCXX_DEBUG",
00090 "#error You are compiling with _GLIBCXX_DEBUG defined, but the library",
00091 "#error was not compiled with this flag. The settings must match or your",
00092 "#error program will not work correctly.",
00093 "#endif",
00094 #endif
00095 #endif
00096 "#endif",
00097 #endif
00098 "",
00099 "#define XAPIAN_VERSION ",STRING_VERSION,
00100 "#define XAPIAN_MAJOR_VERSION ",MAJOR_VERSION,
00101 "#define XAPIAN_MINOR_VERSION ",MINOR_VERSION,
00102 "#define XAPIAN_REVISION ",REVISION,
00103 "",
00104 #ifdef XAPIAN_HAS_FLINT_BACKEND
00105 "#define XAPIAN_HAS_FLINT_BACKEND 1",
00106 #else
00107 "/* #undef XAPIAN_HAS_FLINT_BACKEND */",
00108 #endif
00109 #ifdef XAPIAN_HAS_QUARTZ_BACKEND
00110 "#define XAPIAN_HAS_QUARTZ_BACKEND 1",
00111 #else
00112 "/* #undef XAPIAN_HAS_QUARTZ_BACKEND */",
00113 #endif
00114 #ifdef XAPIAN_HAS_INMEMORY_BACKEND
00115 "#define XAPIAN_HAS_INMEMORY_BACKEND 1",
00116 #else
00117 "/* #undef XAPIAN_HAS_INMEMORY_BACKEND */",
00118 #endif
00119 #ifdef XAPIAN_HAS_REMOTE_BACKEND
00120 "#define XAPIAN_HAS_REMOTE_BACKEND 1",
00121 #else
00122 "/* #undef XAPIAN_HAS_REMOTE_BACKEND */",
00123 #endif
00124 "",
00125 "#endif /* XAPIAN_INCLUDED_VERSION_H */"
00126 };