Search code examples
virtualboxubuntu-12.04vagrantberkeley-db-xml

"error: 'ptrdiff_t' does not name a type" on installing Berkley DB XML 2.5.16 in Ubuntu 12.04


An error is received when running the build script for Berkley DB XML 2.5.16 in Ubuntu 12.04 with vagrant on a virtualbox:

../include/xqilla/framework/XPath2MemoryManager.hpp:90:11: error: 'ptrdiff_t' does not name a type
make[1]: *** [ReferenceCounted.lo] Error 1
make[1]: Leaving directory `/usr/share/dbxml-2.5.16/xqilla/build'

Solution

  • Resolution was to add the following line after line 26 to the file XPath2MemoryManager.hpp:

    #include <cstddef>
    

    The full path to the file is:

    /usr/share/dbxml-2.5.16/xqilla/include/xqilla/framework/XPath2MemoryManager.hpp
    

    Credit to http://tlmaloney.ruhoh.com/sysadmin/installing-bdb-xml-in-ubuntu/