Блог пользователя bluemmb

Автор bluemmb, 11 лет назад, По-английски

Hello. When i try to use testlib with c++11 , arise this error :

In file included from test.cpp:7:0:
testlib.h: In function 'void __testlib_set_binary(FILE*)':
testlib.h:346:20: error: 'fileno' was not declared in this scope
 setmode(fileno(file), O_BINARY);
                    ^

Is compatible version released (couldn't find)? or Problem is removable easily ?

  • Проголосовать: нравится
  • +8
  • Проголосовать: не нравится

»
11 лет назад, скрыть # |
 
Проголосовать: нравится +6 Проголосовать: не нравится

Try compiling it with -std=gnu++11 instead of =std=c++11.

»
11 лет назад, скрыть # |
 
Проголосовать: нравится +3 Проголосовать: не нравится

I think that the latest testlib from trunk (0.9.9) can be compiled on C++11 without any issues.