Main Page   Modules   Data Structures   File List   Data Fields   Globals  

cross_platform.h

Go to the documentation of this file.
00001 /*
00002  * cross_platform.h
00003  * Created on 14 Mar 2005
00004  * Authors:
00005  *    Wesley Leggette <wleggette@kaylix.net>
00006  * 
00007  * 
00008  * 
00009  * libdarc
00010  * 
00011  * 
00012  * This program is free software; you can redistribute it and/or modify
00013  * it under the terms of the GNU General Public License as published by
00014  * the Free Software Foundation; either version 2 of the License, or
00015  * (at your option) any later version.
00016  *
00017  * This program is distributed in the hope that it will be useful,
00018  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00019  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00020  * GNU General Public License for more details.
00021  *
00022  * You should have received a copy of the GNU General Public License
00023  * along with this program; if not, write to the Free Software
00024  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00025  * 
00026  * $Id: cross__platform_8h-source.html 708 2005-03-21 12:30:37Z leggwes $
00027  */
00028 
00034 #if defined __CYGWIN32__ && !defined __CYGWIN__
00035 #  define __CYGWIN__ __CYGWIN32__
00036 #endif
00037 
00038 #if defined _WIN32 && !defined __CYGWIN__
00039     /* Use Windows seperators on all _WIN32 defining
00040        environments, except Cygwin. */
00041 #  define DIR_SEPARATOR_CHAR        '\\'
00042 #  define DIR_SEPARATOR_STR         "\\"
00043 #  define PATH_SEPARATOR_CHAR       ';'
00044 #  define PATH_SEPARATOR_STR        ";"
00045 #endif
00046 #ifndef DIR_SEPARATOR_CHAR
00047     /* Assume that not having this indicator is an indicator that all
00048        are missing. */
00049 #  define DIR_SEPARATOR_CHAR        '/'
00050 #  define DIR_SEPARATOR_STR         "/"
00051 #  define PATH_SEPARATOR_CHAR       ':'
00052 #  define PATH_SEPARATOR_STR        ":"
00053 #endif /* !DIR_SEPARATOR_CHAR */
00054 
00055 #if defined _WIN32 && !defined __CYGWIN__
00056 #  define WIN32_PLATFORM 1
00057 #  define UNIX_PLATFORM 0
00058 #else
00059 #  define WIN32_PLATFORM 0
00060 #  define UNIX_PLATFORM 1
00061 #endif
00062 
00063 
00064 #ifdef _WIN32
00065 #  ifdef DLL_EXPORT
00066 #    define DLLIMPORT extern __declspec (dllexport)
00067 #  else
00068 #    ifdef LIBDARC_DLL_IMPORT
00069 #      define DLLIMPORT extern __declspec (dllimport)
00070 #    endif
00071 #  endif
00072 #endif
00073 #ifndef DLLIMPORT
00074 #  define DLLIMPORT extern
00075 #endif
00076 
00077 
00078