Changeset 123 for cpp/common/nonstd.h


Ignore:
Timestamp:
02/10/14 17:08:23 (9 years ago)
Author:
sz
Message:

Cygwin compatibility

File:
1 edited

Legend:

Unmodified
Added
Removed
  • cpp/common/nonstd.h

    r109 r123  
     1// This file is a part of the Framsticks GDK.
     2// Copyright (C) 2002-2014  Maciej Komosinski and Szymon Ulatowski.  See LICENSE.txt for details.
     3// Refer to http://www.framsticks.com/ for further information.
     4
    15#ifndef _NONSTD_H_
    26#define _NONSTD_H_
     
    1822// ms visual c++
    1923#ifdef _MSC_VER
    20  #include <stdio.h> //musi byc najpierw ten include zeby robic definy ponizej (albo bedzie '_vsnprintf': attributes inconsistent with previous declaration, stdio.h:358)
     24 #include <stdio.h> //this #include must be present before two #defines below can be used, otherwise one will see: '_vsnprintf': attributes inconsistent with previous declaration, stdio.h:358
    2125 #define vsnprintf _vsnprintf
    2226 #define snprintf _snprintf
     
    4852#ifdef LINUX
    4953 #include <strings.h>
    50  #define stricmp(a,b) strcasecmp(a,b)
    51  #define _isnan(a) isnan(a) //do nonstd_math.h?
     54 #ifndef __CYGWIN__
     55  #define stricmp(a,b) strcasecmp(a,b)
     56 #endif
    5257#ifdef INITIAL_DIR_IS_HOME
    5358 #include "cwd.h"
     
    7075#ifdef IPHONE
    7176 #include <string>
    72  #define _isnan(a) isnan(a) //do nonstd_math.h?
    7377 std::string getAppHome();
    7478 std::string getAppResources();
     
    7882
    7983#ifdef SHP
    80  //#define __assert_func(a,b,c,d) 0 //Currently, we are sorry to inform you that assert() is not yet supported. We have considered your request for internal discussion. No ale na szczêœcie w³asna (byle by by³a, bo i tak zak³adamy ze assert ktore przeciez dziala tylko w trybie debug nie jest potrzebne na bada) implementacja w "bada-assert.cpp"
    8184 #define GET_APP_HOME "/Home/"
    8285 #define GET_APP_RESOURCES "/Res/"
     
    100103
    101104
    102 #ifdef MAIN_FRAMSTICKS
    103  #define SCRIPTS_DIR GET_APP_RESOURCES "scripts" //katalogi sa na iphone std::string a gdzie indziej "const char*" i to sie wszedzie kompiluje?
    104 #endif
    105 
    106 
    107105
    108106//typedef unsigned char boolean; //niestety nie mozna uzyc 'bool' bo VC w rpcndr.h wlasnie tak definiuje booleana, jako unsigned char
Note: See TracChangeset for help on using the changeset viewer.