kyamagu / matlab-leveldb

Matlab LevelDB wrapper

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

make fails with ISO C++ 2011 standard support error

mrmartin opened this issue · comments

Make fails on a fresh install of matlab-leveldb in Matlab R2013b, using gcc 4.8.2 in Ubuntu. The error is:

In file included from /usr/include/c++/4.8/type_traits:35:0,
                 from include/mexplus/mxtypes.h:10,
                 [...]
/usr/include/c++/4.8/bits/c++0x_warning.h:32:2: error: #error This file requires compiler and library support for the ISO C++ 2011 standard. This support is currently experimental, and must be enabled with the -std=c++11 or -std=gnu++11 compiler options.
[...]

These are enabled. By adding $(MEX) -v to Makefile, the command which is executed is also printed:

g++ -c  -Iinclude -Ileveldb-1.18/include -I/usr/local/MATLAB/extern/include -I/usr/local/MATLAB/simulink/include -DMATLAB_MEX_FILE -std=c++11 -ansi -D_GNU_SOURCE -fPIC -fno-omit-frame-pointer -pthread  -DMX_COMPAT_32 -O -DNDEBUG  "src/LevelDB_.cc"

It also fails with -std=gnu++11 and -std=c++0x.

Any idea what's wrong?

@mrmartin Just added a quick fix in the latest commit. Please checkout.

Now, compiling "src/LevelDB_.cc" works fine. However, a new error comes, but I will put it in a separate issue.
Thank you