1
/*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*\
5
Copyright (c) 2001-2006 Octasic Inc.
9
This file is included to set target-specific constants.
11
This file is part of the Octasic OCT6100 GPL API . The OCT6100 GPL API is
12
free software; you can redistribute it and/or modify it under the terms of
13
the GNU General Public License as published by the Free Software Foundation;
14
either version 2 of the License, or (at your option) any later version.
16
The OCT6100 GPL API is distributed in the hope that it will be useful, but
17
WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
18
or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
21
You should have received a copy of the GNU General Public License
22
along with the OCT6100 GPL API; if not, write to the Free Software
23
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
25
$Octasic_Release: OCT612xAPI-01.00-PR43 $
27
$Octasic_Revision: 16 $
29
\*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*/
31
#ifndef __OCTOSDEPENDANT_H__
32
#define __OCTOSDEPENDANT_H__
35
/*--------------------------------------------------------------------------
37
----------------------------------------------------------------------------*/
45
/*****************************************************************************
50
WIN32 == WINDOWS 32 bit app
51
__WIN32__ == WINDOWS 32 bit app
52
_Windows == WINDOWS 16 bit app
54
_WINDOWS == Windows application .. not console
55
_DLL == Dll Application
56
_CONSOLE == Console Application .. no windows
59
__TURBOC__ == Turbo Compiler
60
__BORLANDC__ == Borland compiler
61
__OS2__ == Borland OS2 compiler
62
_Windows == Windows 16 bit app
65
__GNUC__ == GCC Compiler
66
__unix__ == Unix system
67
__vax__ == Unix system
80
*****************************************************************************/
82
/* Machine endian type */
84
#define OCT_MACH_LITTLE_ENDIAN 1
85
#define OCT_MACH_BIG_ENDIAN 2
87
/* Try to find current OCT_MACH_ENDIAN from compiler define values */
88
#if !defined( MACH_TYPE_BIG_ENDIAN ) && !defined( MACH_TYPE_LITTLE_ENDIAN )
91
#if defined( _M_IX86 )
92
#define OCT_MACH_ENDIAN OCT_MACH_LITTLE_ENDIAN
93
/* Look for PowerPC */
94
#elif defined( _M_MPPC ) || defined( _M_PPC )
95
#define OCT_MACH_ENDIAN OCT_MACH_BIG_ENDIAN
97
#if CPU==PPC860 || CPU==SIMNT
98
#define OCT_MACH_ENDIAN OCT_MACH_BIG_ENDIAN
100
#define OCT_MACH_ENDIAN OCT_MACH_LITTLE_ENDIAN
102
/* Default is little endian */
104
#define OCT_MACH_ENDIAN OCT_MACH_LITTLE_ENDIAN
107
#if defined( MACH_TYPE_BIG_ENDIAN )
108
#define OCT_MACH_ENDIAN OCT_MACH_BIG_ENDIAN
110
#define OCT_MACH_ENDIAN OCT_MACH_LITTLE_ENDIAN
114
/* Find system type if not already defined */
115
#if !defined( OCT_NTDRVENV ) && !defined( OCT_VXENV ) && !defined( OCT_WINENV )
117
#if defined( WIN32 ) || defined( __WIN32__ ) || defined( _WIN32_ ) || defined( WIN32S )
118
/* Verif if building a win32 driver */
119
#if ( defined( WIN32 ) && WIN32==100 )
124
#elif defined( _VXWORKS_ )
126
#elif defined( _ECOS_ )
128
#elif defined( _SOLARIS_ )
129
#define OCT_SOLARISENV
130
#elif defined( _LINUX_ )
133
/* Unknown environment */
134
#define OCT_UNKNOWNENV
137
#endif /* Already defined */
139
#if defined( __KERNEL__ ) && defined( OCT_LINUXENV )
140
#define OCT_LINUXDRVENV
144
#define OCT_OPT_USER_DEBUG
147
/*--------------------------------------------------------------------------
149
----------------------------------------------------------------------------*/
155
#endif /* __OCTOSDEPENDANT_H__ */