Changeset 492


Ignore:
Timestamp:
03/31/16 00:34:37 (5 years ago)
Author:
Maciej Komosinski
Message:

emscripten compatibility

Location:
cpp
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • cpp/common/nonstd_math.cpp

    r471 r492  
    1414
    1515
    16 #if defined __BORLANDC__ || (_MSC_VER <= 1700)
     16#if (defined __BORLANDC__ || (_MSC_VER <= 1700)) & (!defined EMSCRIPTEN)
    1717double round(double val) //http://stackoverflow.com/questions/2170385/c-math-functions
    1818{   
  • cpp/common/nonstd_math.h

    r286 r492  
    1717#endif
    1818
    19 #if defined __BORLANDC__ || (_MSC_VER <= 1700)
    20 double round(double val);  //http://stackoverflow.com/questions/2170385/c-math-functions
     19#if (defined __BORLANDC__ || (_MSC_VER <= 1700)) & (!defined EMSCRIPTEN)
     20  double round(double val);  //http://stackoverflow.com/questions/2170385/c-math-functions
    2121#endif
    2222
  • cpp/frams/canvas/nn_smart_layout.cpp

    r319 r492  
    99 #include <alloc.h> //borland needs for alloc/free
    1010#endif
    11 #ifdef MACOS
     11#if (defined MACOS) | (defined EMSCRIPTEN)
    1212 #include <stdlib.h>
    1313#endif
  • cpp/frams/genetics/geno.h

    r348 r492  
    1717public:
    1818        virtual int testGenoValidity(Geno& g) = 0;/// -1=no information  0=invalid  1=valid
     19        virtual ~GenoValidator() { };
    1920};
    2021
     
    2526public:
    2627        int testGenoValidity(Geno& g);
     28        ~ModelGenoValidator() { }
    2729};
    2830
  • cpp/frams/model/similarity/simil_model.cpp

    r451 r492  
    1313#include "common/nonstd.h"
    1414#include <frams/vm/classes/genoobj.h>
    15 #include <stdlib.h>
     15#ifdef EMSCRIPTEN
     16  #include <cstdlib>
     17#else
     18  #include <stdlib.h>
     19#endif
    1620#include <math.h>
    1721#include <string>
  • cpp/frams/neuro/neuroimpl.cpp

    r484 r492  
    458458#endif
    459459
     460#ifndef SDK_WITHOUT_FRAMS
    460461extern ParamEntry creature_paramtab[];
    461462static Param creature_param(creature_paramtab,0);
     463#endif
    462464
    463465Creature* NeuroImpl::getCreature()
Note: See TracChangeset for help on using the changeset viewer.