Uploaded image for project: 'Couchbase C client library libcouchbase'
  1. Couchbase C client library libcouchbase
  2. CCBC-1232

libcouchbase 2.10.6 doesn't compile anymore on CentOS6

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Major
    • 2.10.7
    • 2.10.6
    • library
    • CentOS 6.8, gcc 4.4.7
    • 1
    • Medium

    Description

      In 2.10.6 the std:random_shuffle() has been replaced by std::random_device() and std::shuffle(). These are not supported by gcc 4.4.7. (random_device is available by enabling experimental extensions via -std=gnu++0x, but than still shuffle() is missing).

      The following commits cause this:
      d4220fdc5e1950
      a20cb22301e2e5

       

      [ 34%] Building CXX object CMakeFiles/lcbcore-cxx.dir/src/hostlist.cc.o
      In file included from /usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../include/c++/4.4.7/random:35,
      from /var/tmp/libcouchbase/src/hostlist.cc:23:
      /usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../include/c+/4.4.7/c0x_warning.h:31:2: error: #error This file requires compiler and library support for the upcoming ISO C+ standard, C+0x. This support is currently experimental, and must be enabled with the -std=c0x or -std=gnu+0x compiler options.
      /var/tmp/libcouchbase/src/hostlist.cc: In member function ‘void lcb::Hostlist::randomize()’:
      /var/tmp/libcouchbase/src/hostlist.cc:260: error: ‘random_device’ is not a member of ‘std’
      /var/tmp/libcouchbase/src/hostlist.cc:260: error: expected ‘;’ before ‘rd’
      /var/tmp/libcouchbase/src/hostlist.cc:261: error: ‘mt19937’ is not a member of ‘std’
      /var/tmp/libcouchbase/src/hostlist.cc:261: error: expected ‘;’ before ‘g’
      /var/tmp/libcouchbase/src/hostlist.cc:262: error: ‘shuffle’ is not a member of ‘std’
      /var/tmp/libcouchbase/src/hostlist.cc:262: error: ‘g’ was not declared in this scope

      Attachments

        For Gerrit Dashboard: CCBC-1232
        # Subject Branch Project Status CR V

        Activity

          People

            avsej Sergey Avseyev
            penacho Robert Groenenberg
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes

                PagerDuty