- Import FullFAT and add it to build.
[reactos.git] / reactos / include / reactos / libs / fullfat / ff_types.h
1 /*****************************************************************************
2 * FullFAT - High Performance, Thread-Safe Embedded FAT File-System *
3 * Copyright (C) 2009 James Walmsley (james@worm.me.uk) *
4 * *
5 * This program is free software: you can redistribute it and/or modify *
6 * it under the terms of the GNU General Public License as published by *
7 * the Free Software Foundation, either version 3 of the License, or *
8 * (at your option) any later version. *
9 * *
10 * This program is distributed in the hope that it will be useful, *
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of *
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
13 * GNU General Public License for more details. *
14 * *
15 * You should have received a copy of the GNU General Public License *
16 * along with this program. If not, see <http://www.gnu.org/licenses/>. *
17 * *
18 * IMPORTANT NOTICE: *
19 * ================= *
20 * Alternative Licensing is available directly from the Copyright holder, *
21 * (James Walmsley). For more information consult LICENSING.TXT to obtain *
22 * a Commercial license. *
23 * *
24 * See RESTRICTIONS.TXT for extra restrictions on the use of FullFAT. *
25 * *
26 * Removing the above notice is illegal and will invalidate this license. *
27 *****************************************************************************
28 * See http://worm.me.uk/fullfat for more information. *
29 * Or http://fullfat.googlecode.com/ for latest releases and the wiki. *
30 *****************************************************************************/
31
32 /**
33 * This file defines some portable types.
34 * You should change these as appropriate for your platform, as necessary.
35 *
36 **/
37
38 #ifndef _FF_TYPES_H_
39 #define _FF_TYPES_H_
40
41 #include "ff_config.h"
42
43 //---------------- BOOLEAN TYPES
44 typedef char FF_T_BOOL; ///< This can be a char if your compiler isn't C99.
45
46 #define FF_TRUE 1 ///< 1 if bool not supported.
47 #define FF_FALSE 0 ///< 0 if bool not supported.
48
49 //---------------- 8 BIT INTEGERS
50 typedef char FF_T_INT8; ///< 8 bit default integer.
51 typedef unsigned char FF_T_UINT8; ///< 8 bit unsigned integer.
52 typedef signed char FF_T_SINT8; ///< 8 bit signed integer.
53
54 //---------------- 16 BIT INTEGERS
55 typedef short FF_T_INT16; ///< 16 bit default integer.
56 typedef unsigned short FF_T_UINT16; ///< 16 bit unsigned integer.
57 typedef signed short FF_T_SINT16; ///< 16 bit signed integer.
58
59 //---------------- 32 BIT INTEGERS
60 typedef long FF_T_INT32; ///< 32 bit default integer.
61 typedef unsigned long FF_T_UINT32; ///< 32 bit unsigned integer.
62 typedef signed long FF_T_SINT32; ///< 32 bit signed integer.
63
64 #ifdef FF_64_NUM_SUPPORT
65 //---------------- 64 BIT INTEGERS // If you cannot define these, then make sure you see ff_config.h
66 typedef long long FF_T_INT64; // about 64-bit number support.
67 typedef unsigned long long FF_T_UINT64; // It means that FF_GetVolumeSize() cannot return a size
68 typedef signed long long FF_T_SINT64; // > 4GB in bytes if you cannot support 64-bits integers.
69 // No other function makes use of 64-bit numbers.
70 #endif
71
72 typedef FF_T_SINT32 FF_ERROR; ///< A special error code type to ease some inconsistencies in Error reporting.
73
74 #endif // end of include guard