sofia-sip/su_types.h

Go to the documentation of this file.
00001 /*
00002  * This file is part of the Sofia-SIP package
00003  *
00004  * Copyright (C) 2005 Nokia Corporation.
00005  *
00006  * Contact: Pekka Pessi <pekka.pessi@nokia-email.address.hidden>
00007  *
00008  * This library is free software; you can redistribute it and/or
00009  * modify it under the terms of the GNU Lesser General Public License
00010  * as published by the Free Software Foundation; either version 2.1 of
00011  * the License, or (at your option) any later version.
00012  *
00013  * This library is distributed in the hope that it will be useful, but
00014  * WITHOUT ANY WARRANTY; without even the implied warranty of
00015  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
00016  * Lesser General Public License for more details.
00017  *
00018  * You should have received a copy of the GNU Lesser General Public
00019  * License along with this library; if not, write to the Free Software
00020  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
00021  * 02110-1301 USA
00022  *
00023  */
00024 
00025 #ifndef SU_TYPES_H
00026 
00027 #define SU_TYPES_H
00028 
00036 #ifndef SU_CONFIG_H
00037 #include "sofia-sip/su_config.h"
00038 #endif
00039 
00040 #if SU_HAVE_STDINT
00041 #include <stdint.h>
00042 #elif SU_HAVE_INTTYPES
00043 #include <inttypes.h>
00044 #endif
00045 
00046 #if SU_HAVE_SYS_TYPES
00047 #include <sys/types.h>
00048 #endif
00049 
00050 #include <stddef.h>
00051 
00052 SOFIA_BEGIN_DECLS
00053 
00054 #if SU_HAVE_STDINT || SU_HAVE_INTTYPES
00055 #define SU_S64_T int64_t
00056 #define SU_U64_T uint64_t
00057 #define SU_S32_T int32_t
00058 #define SU_U32_T uint32_t
00059 #define SU_S16_T int16_t
00060 #define SU_U16_T uint16_t
00061 #define SU_S8_T  int8_t
00062 #define SU_U8_T  uint8_t
00063 #define SU_LEAST64_T int_least64_t
00064 #define SU_LEAST32_T int_least32_t
00065 #define SU_LEAST16_T int_least16_t
00066 #define SU_LEAST8_T int_least8_t
00067 #elif SU_HAVE_WIN32 || DOCUMENTATION_ONLY
00068 /* Use macros defined in <su_configure_win32.h> */
00069 
00071 typedef SU_INTPTR_T intptr_t;
00073 typedef SU_U64_T uint64_t;
00075 typedef SU_S64_T int64_t;
00077 typedef SU_U32_T uint32_t;
00079 typedef SU_S32_T int32_t;
00081 typedef SU_U16_T uint16_t;
00083 typedef SU_S16_T int16_t;
00085 typedef SU_U8_T  uint8_t;
00087 typedef SU_S8_T  int8_t;
00088 
00090 typedef SU_LEAST64_T int_least64_t;
00092 typedef SU_LEAST32_T int_least32_t;
00094 typedef SU_LEAST16_T int_least16_t;
00096 typedef SU_LEAST8_T int_least8_t;
00097 #else
00098 #error "no integer types available."
00099 #endif
00100 
00101 SOFIA_END_DECLS
00102 
00103 #endif /* SU_TYPES_H */

Sofia-SIP 1.12.1 - Copyright (C) 2006 Nokia Corporation. All rights reserved. Licensed under the terms of the GNU Lesser General Public License.