Changeset 358

Show
Ignore:
Timestamp:
06/08/09 15:22:12 (15 years ago)
Author:
smidl
Message:

compilation fixes for Linux

Location:
bdm
Files:
14 modified

Legend:

Unmodified
Added
Removed
  • bdm/CMakeLists.txt

    r357 r358  
    66SET(BdmUI libconfig/libconfigcpp.cc libconfig/grammar.c libconfig/libconfig.c libconfig/scanner.c user_info.cpp user_info.h ) 
    77 
     8# add BDMLIB compile flag 
     9ADD_DEFINITIONS(-DBDMLIB) 
     10 
    811# Normal BDM library 
    912add_library (bdm STATIC bdmroot.cpp bdmroot.h itpp_ext.cpp itpp_ext.h osutils.cpp osutils.h ${BdmMath} ${BdmStat} ${BdmEstim} ${BdmUI}) 
  • bdm/estim/arx.cpp

    r357 r358  
    11#include "arx.h" 
    2 #include "..\user_info.h" 
    32 
    43namespace bdm { 
  • bdm/estim/arx.h

    r357 r358  
    1616#include "../stat/libFN.h" 
    1717#include "../stat/libEF.h" 
     18#include "../user_info.h" 
    1819 
    1920namespace bdm { 
  • bdm/estim/libKF.cpp

    r357 r358  
    11 
    22#include "libKF.h" 
    3 #include "..\user_info.h" 
    43 
    54namespace bdm{ 
  • bdm/estim/libKF.h

    r357 r358  
    1818#include "../stat/libEF.h" 
    1919#include "../math/chmat.h" 
     20#include "../user_info.h" 
    2021 
    2122namespace bdm 
  • bdm/stat/libBM.h

    r357 r358  
    195195}; 
    196196 
    197 UIREGISTER(RV); 
    198197 
    199198//! Concat two random variables 
  • bdm/stat/libDS.cpp

    r357 r358  
    11 
    22#include "libDS.h" 
    3 #include "..\user_info.h" 
     3//#include "..\user_info.h" 
    44 
    55using namespace bdm; 
  • bdm/stat/libDS.h

    r357 r358  
    1717#include "libBM.h" 
    1818#include "libEF.h" 
    19  
     19#include "../user_info.h" 
    2020 
    2121namespace bdm { 
  • bdm/stat/libEF.cpp

    r357 r358  
    33#include <itpp/base/bessel.h> 
    44#include "libEF.h" 
    5 #include "..\user_info.h" 
    65 
    76namespace bdm{ 
  • bdm/stat/libEF.h

    r357 r358  
    1717#include "libBM.h" 
    1818#include "../math/chmat.h" 
    19 #include "../user_info.h" 
     19//#include "../user_info.h" 
    2020 
    2121namespace bdm 
  • bdm/stat/loggers.cpp

    r357 r358  
    3030{        
    3131        // TODO tady se natvrdo ocekava existence stringu, nejsou zadne defaulty.. je to tak OK? 
    32         string itfilename = (string)root["filename"]; 
     32        string itfilename = (const char*)root["filename"]; 
    3333        maxlen = root["maxlen"]; 
    3434} 
     
    162162{        
    163163        // TODO tady se natvrdo ocekava existence stringu, nejsou zadne defaulty.. je to tak OK? 
    164         dirname = (string)root["dirname"]; 
     164        dirname = (const char*)root["dirname"]; 
    165165        maxlen = root["maxlen"]; 
    166166        scalarnames.set_length(0); 
  • bdm/stat/loggers.h

    r357 r358  
    1515 
    1616#include "libBM.h" 
    17 #include "..\user_info.h" 
     17#include "../user_info.h" 
    1818 
    1919namespace bdm{ 
  • bdm/user_info.cpp

    r357 r358  
    110110        return; 
    111111 
    112     string link = (string) potential_link; 
     112    string link = (const char*) potential_link; 
    113113    size_t aerobase = link.find('@'); 
    114114    if ( aerobase != string::npos ) 
     
    397397{ 
    398398    ASSERT_UITYPE(element,TypeString); 
    399     str = (string) element; 
     399    str = (const char*) element; 
    400400} 
    401401 
  • bdm/user_info.h

    r357 r358  
    1616using namespace libconfig; 
    1717 
    18 #define UIREGISTER(class_name) template<> Particular_UI<class_name>& Particular_UI<class_name>::ui = Particular_UI<class_name>(#class_name) 
     18#ifdef BDMLIB  
     19#define UIREGISTER(class_name) template<> const Particular_UI<class_name>& Particular_UI<class_name>::ui = Particular_UI<class_name>(#class_name)  
     20#else 
     21#define UIREGISTER(class_name) 
     22#endif 
    1923 
    2024#define ASSERT_UITYPE(S,Type) it_assert_debug(S.getType()==Setting::Type, string("Wrong setting type, see input path \"")+string(S.getPath())+string("\"")) 
     
    314318template<typename T> class Particular_UI : private UI 
    315319{ 
    316         // to permit acces to the Particular_UI<T>::ui to the UI class 
    317         friend UI; 
     320        public: 
    318321 
    319322        //! default constructor, which is intentionally declared as private 
     
    324327        //! the only instance of this class (each type T has its own instance) 
    325328        //! which is used as a factory for processing related UI 
    326         static Particular_UI<T>& ui;     
     329        static const Particular_UI<T>& ui;       
    327330 
    328331        bdmroot* new_instance() const