Bosma / Scheduler

Modern C++ Scheduling Library
MIT License
272 stars 74 forks source link

compile error #16

Open mitch85 opened 6 years ago

mitch85 commented 6 years ago

c++ example.cpp -o example -std=c++11

get an error and dont know why?!:(

Scheduler.h: In function ‘bool Bosma::try_parse(tm&, const string&, const string&)’: Scheduler.h:59:22: error: ‘get_time’ is not a member of ‘std’ return !(ss >> std::get_time(&tm, format.c_str())).fail();

TizianoFranzoi commented 6 years ago

you need a compiler with std::get_time its there since GCC >= V5.0

For Crosscompiling I only had GCC 4.85 so I could replace get_time with

the C equivalent:

char *result = strptime ( expression.c_str(), format.c_cstr(), &tim); if(result) return true else return false;