From 2e511ab1b1ff3d78c695874e3b28ff4ce7680cc8 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Thu, 2 Apr 2015 17:28:07 +0000 Subject: kyotocabinet based db driver first version that compiles DO NOT USE IT, dragons live there git-svn-id: http://svn.miranda-ng.org/main/trunk@12580 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- plugins/Dbx_kyoto/src/kyotocabinet/myconf.h | 242 ++++++++++++++++++++++++++++ 1 file changed, 242 insertions(+) create mode 100644 plugins/Dbx_kyoto/src/kyotocabinet/myconf.h (limited to 'plugins/Dbx_kyoto/src/kyotocabinet/myconf.h') diff --git a/plugins/Dbx_kyoto/src/kyotocabinet/myconf.h b/plugins/Dbx_kyoto/src/kyotocabinet/myconf.h new file mode 100644 index 0000000000..3bb8dd2f3b --- /dev/null +++ b/plugins/Dbx_kyoto/src/kyotocabinet/myconf.h @@ -0,0 +1,242 @@ +/************************************************************************************************* + * System-dependent configurations + * Copyright (C) 2009-2012 FAL Labs + * This file is part of Kyoto Cabinet. + * This program is free software: you can redistribute it and/or modify it under the terms of + * the GNU General Public License as published by the Free Software Foundation, either version + * 3 of the License, or any later version. + * This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; + * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * See the GNU General Public License for more details. + * You should have received a copy of the GNU General Public License along with this program. + * If not, see . + *************************************************************************************************/ + + +#ifndef _MYCONF_H // duplication check +#define _MYCONF_H + + + +/************************************************************************************************* + * system discrimination + *************************************************************************************************/ + + +#if defined(__linux__) + +#define _SYS_LINUX_ +#define _KC_OSNAME "Linux" + +#elif defined(__FreeBSD__) + +#define _SYS_FREEBSD_ +#define _KC_OSNAME "FreeBSD" + +#elif defined(__NetBSD__) + +#define _SYS_NETBSD_ +#define _KC_OSNAME "NetBSD" + +#elif defined(__OpenBSD__) + +#define _SYS_OPENBSD_ +#define _KC_OSNAME "OpenBSD" + +#elif defined(__sun__) || defined(__sun) + +#define _SYS_SUNOS_ +#define _KC_OSNAME "SunOS" + +#elif defined(__hpux) + +#define _SYS_HPUX_ +#define _KC_OSNAME "HP-UX" + +#elif defined(__osf) + +#define _SYS_TRU64_ +#define _KC_OSNAME "Tru64" + +#elif defined(_AIX) + +#define _SYS_AIX_ +#define _KC_OSNAME "AIX" + +#elif defined(__APPLE__) && defined(__MACH__) + +#define _SYS_MACOSX_ +#define _KC_OSNAME "Mac OS X" + +#elif defined(_MSC_VER) + +#define _SYS_MSVC_ +#define _KC_OSNAME "Windows (VC++)" + +#elif defined(_WIN32) + +#define _SYS_MINGW_ +#define _KC_OSNAME "Windows (MinGW)" + +#elif defined(__CYGWIN__) + +#define _SYS_CYGWIN_ +#define _KC_OSNAME "Windows (Cygwin)" + +#else + +#define _SYS_GENERIC_ +#define _KC_OSNAME "Generic" + +#endif + +#define _KC_VERSION "1.2.76" +#define _KC_LIBVER 16 +#define _KC_LIBREV 13 +#define _KC_FMTVER 5 + +#if defined(_MYBIGEND) +#define _KC_BIGEND 1 +#else +#define _KC_BIGEND 0 +#endif + +#if defined(_MYGCCATOMIC) +#define _KC_GCCATOMIC 1 +#else +#define _KC_GCCATOMIC 0 +#endif + +#if defined(_MYZLIB) +#define _KC_ZLIB 1 +#else +#define _KC_ZLIB 0 +#endif + +#if defined(_MYLZO) +#define _KC_LZO 1 +#else +#define _KC_LZO 0 +#endif + +#if defined(_MYLZMA) +#define _KC_LZMA 1 +#else +#define _KC_LZMA 0 +#endif + +#if defined(_SYS_MSVC_) +#define _KC_PXREGEX 0 +#else +#define _KC_PXREGEX 1 +#endif + + + +/************************************************************************************************* + * notation of the file system + *************************************************************************************************/ + + +#if defined(_SYS_MSVC_) || defined(_SYS_MINGW_) + +#define MYPATHCHR '\\' +#define MYPATHSTR "\\" +#define MYEXTCHR '.' +#define MYEXTSTR "." +#define MYCDIRSTR "." +#define MYPDIRSTR ".." + +#else + +#define MYPATHCHR '/' +#define MYPATHSTR "/" +#define MYEXTCHR '.' +#define MYEXTSTR "." +#define MYCDIRSTR "." +#define MYPDIRSTR ".." + +#endif + + + +/************************************************************************************************* + * general headers + *************************************************************************************************/ + + +extern "C" { +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +} + +extern "C" { +#include +} + +#if defined(_SYS_MSVC_) || defined(_SYS_MINGW_) + +#include +#include +#include +#include +#include +#include +#include + +#else + +extern "C" { +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +} + +extern "C" { +#include +#include +} + +#endif + +#if defined(_SYS_FREEBSD_) || defined(_SYS_OPENBSD_) || defined(_SYS_NETBSD_) || \ + defined(_SYS_MACOSX_) +#define pthread_spinlock_t pthread_mutex_t +#define pthread_spin_init(KC_a, KC_b) \ + pthread_mutex_init(KC_a, NULL) +#define pthread_spin_destroy(KC_a) \ + pthread_mutex_destroy(KC_a) +#define pthread_spin_lock(KC_a) \ + pthread_mutex_lock(KC_a) +#define pthread_spin_trylock(KC_a) \ + pthread_mutex_trylock(KC_a) +#define pthread_spin_unlock(KC_a) \ + pthread_mutex_unlock(KC_a) +#endif + + +#endif // duplication check + + +// END OF FILE -- cgit v1.2.3