Archive

Archive for June 16th, 2011

no include path in which to search for limits.h

June 16th, 2011 No comments

Why compiling STLport 5.1.5 using g++-4.4, one might get an error like the following:-

Building CXX object libs/bgt/CMakeFiles/bgt.dir/error.o
In file included from /opt/projects/stl/stlport/limits.h:27,
            from /usr/include/c++/4.4/../4.4.5/climits:43,
            from /opt/projects/stl/stlport/climits:27,
            from /opt/projects/stl/stlport/stl/_algobase.h:42,
            from /opt/projects/stl/stlport/stl/_alloc.h:47,
            from /opt/projects/stl/stlport/stl/_string.h:23,
            from /opt/projects/stl/stlport/stl/_ios_base.h:34,
            from /opt/projects/stl/stlport/stl/_ios.h:23,
            from /opt/projects/stl/stlport/stl/_ostream.h:24,
            from /opt/projects/stl/stlport/ostream:31,
            from /opt/projects/dev/libs/bgt/error.cpp:18:
/usr/include/../include/limits.h:125: error: no include path in which to search for limits.h
In file included from /opt/projects/stl/stlport/stl/_num_put.c:26,
            from /opt/projects/stl/stlport/stl/_num_put.h:183,
            from /opt/projects/stl/stlport/stl/_ostream.c:26,
            from /opt/projects/stl/stlport/stl/_ostream.h:380,
            from /opt/projects/stl/stlport/ostream:31,
            from /opt/projects/dev/libs/bgt/error.cpp:18:
/opt/projects/stl/stlport/stl/_limits.h:148: error: ‘CHAR_BIT’ was not declared in this scope
/opt/projects/stl/stlport/stl/_limits.h:253: error: ‘CHAR_MIN’ was not declared in this scope
..

Looks like it is a bug in the STLport package itself as per the Release notes of STLport.  After updating to STLport-5.2.1, the issue got fixed automatically.

Tags: