/[svn]/linuxsampler/trunk/src/common/global.h
ViewVC logotype

Contents of /linuxsampler/trunk/src/common/global.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1792 - (show annotations) (download) (as text)
Sun Nov 16 19:19:26 2008 UTC (15 years, 4 months ago) by persson
File MIME type: text/x-c++hdr
File size: 2352 byte(s)
* fixes for building on OS X

1 /***************************************************************************
2 * *
3 * LinuxSampler - modular, streaming capable sampler *
4 * *
5 * Copyright (C) 2003, 2004 by Benno Senoner and Christian Schoenebeck *
6 * Copyright (C) 2005 - 2007 Christian Schoenebeck *
7 * *
8 * This program is free software; you can redistribute it and/or modify *
9 * it under the terms of the GNU General Public License as published by *
10 * the Free Software Foundation; either version 2 of the License, or *
11 * (at your option) any later version. *
12 * *
13 * This program is distributed in the hope that it will be useful, *
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of *
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
16 * GNU General Public License for more details. *
17 * *
18 * You should have received a copy of the GNU General Public License *
19 * along with this program; if not, write to the Free Software *
20 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, *
21 * MA 02111-1307 USA *
22 ***************************************************************************/
23
24 // All application global declarations that HAVE to be exposed to the C++
25 // API are defined here.
26
27 #ifndef __LS_GLOBAL_H__
28 #define __LS_GLOBAL_H__
29
30 #include <stdlib.h>
31 #include <stdint.h>
32 #include <stdio.h>
33
34 #include <string>
35
36 typedef std::string String;
37
38 #if defined(WIN32)
39 #include <windows.h>
40 #define usleep(a) Sleep(a/1000)
41 #define sleep(a) Sleep(a*1000)
42 typedef unsigned int uint;
43 // FIXME: define proper functions which do proper alignement under Win32
44 #define alignedMalloc(a,b) malloc(b)
45 #define alignedFree(a) free(a)
46 #else
47 // needed for usleep under POSIX
48 #include <stdio.h>
49 // for uint
50 #include <sys/types.h>
51 #endif
52
53
54 #endif // __LS_GLOBAL_H__

  ViewVC Help
Powered by ViewVC