00001 /* 00002 oscpack -- Open Sound Control packet manipulation library 00003 http://www.audiomulch.com/~rossb/oscpack 00004 00005 Copyright (c) 2004-2005 Ross Bencina <rossb@audiomulch.com> 00006 00007 Permission is hereby granted, free of charge, to any person obtaining 00008 a copy of this software and associated documentation files 00009 (the "Software"), to deal in the Software without restriction, 00010 including without limitation the rights to use, copy, modify, merge, 00011 publish, distribute, sublicense, and/or sell copies of the Software, 00012 and to permit persons to whom the Software is furnished to do so, 00013 subject to the following conditions: 00014 00015 The above copyright notice and this permission notice shall be 00016 included in all copies or substantial portions of the Software. 00017 00018 Any person wishing to distribute modifications to the Software is 00019 requested to send the modifications to the original developer so that 00020 they can be incorporated into the canonical version. 00021 00022 THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 00023 EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF 00024 MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 00025 IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR 00026 ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF 00027 CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION 00028 WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 00029 */ 00030 #ifndef OSC_HOSTENDIANNESS_H 00031 #define OSC_HOSTENDIANNESS_H 00032 00033 /* 00034 Make sure either OSC_HOST_LITTLE_ENDIAN or OSC_HOST_BIG_ENDIAN is defined 00035 00036 If you know a way to enhance the detection below for Linux and/or MacOSX 00037 please let me know! I've tried a few things which don't work. 00038 */ 00039 00040 #if defined(OSC_HOST_LITTLE_ENDIAN) || defined(OSC_HOST_BIG_ENDIAN) 00041 00042 // you can define one of the above symbols from the command line 00043 // then you don't have to edit this file. 00044 00045 #elif defined(__WIN32__) || defined(WIN32) 00046 00047 // assume that __WIN32__ is only defined on little endian systems 00048 00049 #define OSC_HOST_LITTLE_ENDIAN 1 00050 #undef OSC_HOST_BIG_ENDIAN 00051 00052 #elif defined(__APPLE__) 00053 00054 #if defined(__LITTLE_ENDIAN__) 00055 #define OSC_HOST_LITTLE_ENDIAN 1 00056 #undef OSC_HOST_BIG_ENDIAN 00057 #else 00058 #define OSC_HOST_BIG_ENDIAN 1 00059 #undef OSC_HOST_LITTLE_ENDIAN 00060 #endif 00061 00062 #else 00063 00064 #error please edit OSCHostEndianness.h to configure endianness 00065 00066 #endif 00067 00068 #endif /* OSC_HOSTENDIANNESS_H */ 00069