jsoncons
jsoncons copied to clipboard
compiling on RHEL8 / g++ 8.5
The documented cmake build fails on rhel8 as does attempted cmake permutation: cmake .. -DJSONCONS_BUILD_TESTS=On -DCMAKE_CXX_STANDARD=17 -DCMAKE_CXX_STANDARD_REQUIRED=ON && cmake --build . -- VERBOSE=1 && ctest --output-on-failure
[ 12%] Building CXX object test/CMakeFiles/unit_tests.dir/cbor/src/encode_cbor_tests.cpp.o
cd /tlt/app-data-collection/jsoncons/build/test && /usr/bin/c++ -I/tlt/app-data-collection/jsoncons/include -I/tlt/app-data-collection/jsoncons/test -/tlt/app-data-collection/jsoncons/third_party -I/tlt/app-data-collection/jsoncons/third_party/catch -O3 -DNDEBUG -Werror=maybe-uninitialized -Wnon-virtual-dtor -Werror=stringop-overflow -Werror -Wall -Wextra -Wcast-align -Wcast-qual -Wimplicit-fallthrough -Wsign-compare -pedantic -Wnonnull -Werror=nonnull -std=gnu++17 -MD -MT test/CMakeFiles/unit_tests.dir/cbor/src/encode_cbor_tests.cpp.o -MF CMakeFiles/unit_tests.dir/cbor/src/encode_cbor_tests.cpp.o.d -o CMakeFiles/unit_tests.dir/cbor/src/encode_cbor_tests.cpp.o -c /tlt/app-data-collection/jsoncons/test/cbor/src/encode_cbor_tests.cpp
In file included from /tlt/app-data-collection/jsoncons/test/cbor/src/encode_cbor_tests.cpp:9:
/usr/include/c++/8/scoped_allocator: In instantiation of ‘std::scoped_allocator_adaptor<_OuterAlloc, _InnerAllocs>::scoped_allocator_adaptor() [with _OuterAlloc = FreeListAllocator<char>; _InnerAllocs = {}]’:
/usr/include/c++/8/bits/basic_string.h:619:28: required from ‘std::__cxx11::basic_string<_CharT, _Traits, _Allocator>& std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::_M_replace_dispatch(std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::const_iterator, std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::const_iterator, _InputIterator, _InputIterator, std::__false_type) [with _InputIterator = __gnu_cxx::__normal_iterator<const char*, std::__cxx11::basic_string<char> >; _CharT = char; _Traits = std::char_traits<char>; _Alloc = std::scoped_allocator_adaptor<FreeListAllocator<char> >; std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::const_iterator = __gnu_cxx::__normal_iterator<const char*, std::__cxx11::basic_string<char, std::char_traits<char>, std::scoped_allocator_adaptor<FreeListAllocator<char> > > >; typename __gnu_cxx::__alloc_traits<typename __gnu_cxx::__alloc_traits<_Alloc>::rebind<_CharT>::other>::const_pointer = const char*]’
/usr/include/c++/8/bits/basic_string.h:2095:28: required from ‘std::__cxx11::basic_string<_CharT, _Traits, _Alloc>& std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::replace(std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::const_iterator, std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::const_iterator, _InputIterator, _InputIterator) [with _InputIterator = __gnu_cxx::__normal_iterator<const char*, std::__cxx11::basic_string<char> >; <template-parameter-2-2> = void; _CharT = char; _Traits = std::char_traits<char>; _Alloc = std::scoped_allocator_adaptor<FreeListAllocator<char> >; std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::const_iterator = __gnu_cxx::__normal_iterator<const char*, std::__cxx11::basic_string<char, std::char_traits<char>, std::scoped_allocator_adaptor<FreeListAllocator<char> > > >; typename __gnu_cxx::__alloc_traits<typename __gnu_cxx::__alloc_traits<_Alloc>::rebind<_CharT>::other>::const_pointer = const char*]’
/usr/include/c++/8/bits/basic_string.h:1585:4: required from ‘std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::iterator std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::insert(std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::const_iterator, _InputIterator, _InputIterator) [with _InputIterator = __gnu_cxx::__normal_iterator<const char*, std::__cxx11::basic_string<char> >; <template-parameter-2-2> = void; _CharT = char; _Traits = std::char_traits<char>; _Alloc = std::scoped_allocator_adaptor<FreeListAllocator<char> >; std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::iterator = __gnu_cxx::__normal_iterator<char*, std::__cxx11::basic_string<char, std::char_traits<char>, std::scoped_allocator_adaptor<FreeListAllocator<char> > > >; typename __gnu_cxx::__alloc_traits<typename __gnu_cxx::__alloc_traits<_Alloc>::rebind<_CharT>::other>::pointer = char*; std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::const_iterator = __gnu_cxx::__normal_iterator<const char*, std::__cxx11::basic_string<char, std::char_traits<char>, std::scoped_allocator_adaptor<FreeListAllocator<char> > > >; typename __gnu_cxx::__alloc_traits<typename __gnu_cxx::__alloc_traits<_Alloc>::rebind<_CharT>::other>::const_pointer = const char*]’
/tlt/app-data-collection/jsoncons/include/jsoncons/item_event_visitor.hpp:1477:17: required from ‘bool jsoncons::basic_item_event_visitor_to_json_visitor<CharT, Allocator>::visit_null(jsoncons::semantic_tag, const jsoncons::ser_context&, std::error_code&) [with CharT = char; Allocator = std::scoped_allocator_adaptor<FreeListAllocator<char> >]’
/tlt/app-data-collection/jsoncons/include/jsoncons/item_event_visitor.hpp:1472:14: required from here
/usr/include/c++/8/scoped_allocator:287:60: error: no matching function for call to ‘FreeListAllocator<char>::FreeListAllocator()’
scoped_allocator_adaptor() : _OuterAlloc(), _M_inner() { }
^
In file included from/tlt/app-data-collection/jsoncons/test/cbor/src/encode_cbor_tests.cpp:10:
/tlt/app-data-collection/jsoncons/test/common/FreeListAllocator.hpp:45:5: note: candidate: ‘FreeListAllocator<T>::FreeListAllocator(FreeListAllocator<T>&&) [with T = char]’
FreeListAllocator(FreeListAllocator&& other) noexcept : list(other.list) {
^~~~~~~~~~~~~~~~~
/tlt/app-data-collection/jsoncons/test/common/FreeListAllocator.hpp:45:5: note: candidate expects 1 argument, 0 provided
/tlt/app-data-collection/jsoncons/test/common/FreeListAllocator.hpp:44:5: note: candidate: ‘template<class U> FreeListAllocator<T>::FreeListAllocator(const FreeListAllocator<U>&)’
FreeListAllocator(const FreeListAllocator<U>&) noexcept {}
^~~~~~~~~~~~~~~~~
/tlt/app-data-collection/jsoncons/test/common/FreeListAllocator.hpp:44:5: note: template argument deduction/substitution failed:
In file included from /tlt/app-data-collection/jsoncons/test/cbor/src/encode_cbor_tests.cpp:9:
/usr/include/c++/8/scoped_allocator:287:60: note: candidate expects 1 argument, 0 provided
scoped_allocator_adaptor() : _OuterAlloc(), _M_inner() { }
^
In file included from /tlt/app-data-collection/jsoncons/test/cbor/src/encode_cbor_tests.cpp:10:
/tlt/app-data-collection/jsoncons/test/common/FreeListAllocator.hpp:42:5: note: candidate: ‘FreeListAllocator<T>::FreeListAllocator(const FreeListAllocator<T>&) [with T = char]’
FreeListAllocator(const FreeListAllocator&) noexcept {}
^~~~~~~~~~~~~~~~~
/tlt/app-data-collection/jsoncons/test/common/FreeListAllocator.hpp:42:5: note: candidate expects 1 argument, 0 provided
/tlt/app-data-collection/jsoncons/test/common/FreeListAllocator.hpp:40:5: note: candidate: ‘FreeListAllocator<T>::FreeListAllocator(int) [with T = char]’
FreeListAllocator(int) noexcept
^~~~~~~~~~~~~~~~~
/tlt/app-data-collection/jsoncons/test/common/FreeListAllocator.hpp:40:5: note: candidate expects 1 argument, 0 provided
gmake[2]: *** [test/CMakeFiles/unit_tests.dir/build.make:300: test/CMakeFiles/unit_tests.dir/cbor/src/encode_cbor_tests.cpp.o] Error 1
gmake[2]: Leaving directory '/tlt/app-data-collection/jsoncons/build'
gmake[1]: *** [CMakeFiles/Makefile2:854: test/CMakeFiles/unit_tests.dir/all] Error 2
gmake[1]: Leaving directory '/tlt/app-data-collection/jsoncons/build'
gmake: *** [Makefile:146: all] Error 2
What compiler, architecture, and operating system?
- Compiler:g++ 8.5
- Architecture x86_64
- Operating system: rhel8
What jsoncons library version?
- [ x] Latest release 0.175.0
- [ ] Other release ______
- [x ] master