[MacPorts] #63364: mu @1.6.3: error: no matching constructor for initialization of 'value_type' (aka 'pair<const std::__1::basic_string<char>, Container>')
MacPorts
noreply at macports.org
Fri Aug 13 07:06:44 UTC 2021
#63364: mu @1.6.3: error: no matching constructor for initialization of
'value_type' (aka 'pair<const std::__1::basic_string<char>, Container>')
--------------------------------+----------------------
Reporter: ryandesign | Owner: ra1nb0w
Type: defect | Status: assigned
Priority: Normal | Milestone:
Component: ports | Version: 2.7.1
Keywords: yosemite elcapitan | Port: mu
--------------------------------+----------------------
mu fails to build on
[https://build.macports.org/builders/ports-10.10_x86_64-builder/builds/152312/steps
/install-port/logs/stdio Yosemite] and
[https://build.macports.org/builders/ports-10.11_x86_64-builder/builds/150942/steps
/install-port/logs/stdio El Capitan] using Xcode clang:
{{{
In file included from mu-query-threads.cc:20:
In file included from ./mu-query-threads.hh:23:
In file included from ./mu-query-results.hh:34:
In file included from /opt/local/include/xapian.h:77:
In file included from /opt/local/include/xapian/matchspy.h:36:
/Library/Developer/CommandLineTools/usr/bin/../include/c++/v1/map:634:11:
error: no matching constructor for initialization of 'value_type' (aka
'pair<const std::__1::basic_string<char>, Container>')
: __cc(std::forward<_Args>(__args)...) {}
^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~
/Library/Developer/CommandLineTools/usr/bin/../include/c++/v1/memory:1740:31:
note: in instantiation of function template specialization
'std::__1::__value_type<std::__1::basic_string<char>,
Container>::__value_type<const std::__1::basic_string<char> &,
Mu::QueryMatch &>' requested here
::new((void*)__p) _Up(_VSTD::forward<_Args>(__args)...);
^
/Library/Developer/CommandLineTools/usr/bin/../include/c++/v1/memory:1656:18:
note: in instantiation of function template specialization
'std::__1::allocator<std::__1::__tree_node<std::__1::__value_type<std::__1::basic_string<char>,
Container>, void *>
>::construct<std::__1::__value_type<std::__1::basic_string<char>,
Container>, const std::__1::basic_string<char> &, Mu::QueryMatch &>'
requested here
{__a.construct(__p, _VSTD::forward<_Args>(__args)...);}
^
/Library/Developer/CommandLineTools/usr/bin/../include/c++/v1/memory:1502:14:
note: in instantiation of function template specialization
'std::__1::allocator_traits<std::__1::allocator<std::__1::__tree_node<std::__1::__value_type<std::__1::basic_string<char>,
Container>, void *> >
>::__construct<std::__1::__value_type<std::__1::basic_string<char>,
Container>, const std::__1::basic_string<char> &, Mu::QueryMatch &>'
requested here
{__construct(__has_construct<allocator_type, _Tp*,
_Args...>(),
^
/Library/Developer/CommandLineTools/usr/bin/../include/c++/v1/map:2140:20:
note: in instantiation of function template specialization
'std::__1::allocator_traits<std::__1::allocator<std::__1::__tree_node<std::__1::__value_type<std::__1::basic_string<char>,
Container>, void *> >
>::construct<std::__1::__value_type<std::__1::basic_string<char>,
Container>, const std::__1::basic_string<char> &, Mu::QueryMatch &>'
requested here
__node_traits::construct(__na, _VSTD::addressof(__h->__value_),
^
/Library/Developer/CommandLineTools/usr/bin/../include/c++/v1/map:2158:25:
note: in instantiation of function template specialization
'std::__1::multimap<std::__1::basic_string<char>, Container,
std::__1::less<std::__1::basic_string<char> >,
std::__1::allocator<std::__1::pair<const std::__1::basic_string<char>,
Container> > >::__construct_node<const std::__1::basic_string<char> &,
Mu::QueryMatch &>' requested here
__node_holder __h =
__construct_node(_VSTD::forward<_Args>(__args)...);
^
mu-query-threads.cc:159:30: note: in instantiation of function template
specialization 'std::__1::multimap<std::__1::basic_string<char>,
Container, std::__1::less<std::__1::basic_string<char> >,
std::__1::allocator<std::__1::pair<const std::__1::basic_string<char>,
Container> > >::emplace<const std::__1::basic_string<char> &,
Mu::QueryMatch &>' requested here
dups.emplace(msgid, mi.query_match());
^
mu-query-threads.cc:571:23: note: in instantiation of function template
specialization 'determine_id_table<Mu::QueryResults>' requested here
auto id_table{determine_id_table(qres)};
^
mu-query-threads.cc:604:9: note: in instantiation of function template
specialization 'calculate_threads_real<Mu::QueryResults>' requested here
calculate_threads_real(qres, descending);
^
/Library/Developer/CommandLineTools/usr/bin/../include/c++/v1/utility:273:5:
note: candidate constructor not viable: no known conversion from
'Mu::QueryMatch' to 'const Container' for 2nd argument
pair(const _T1& __x, const _T2& __y)
^
/Library/Developer/CommandLineTools/usr/bin/../include/c++/v1/utility:278:9:
note: candidate template ignored: could not match 'pair' against
'basic_string'
pair(const pair<_U1, _U2>& __p
^
/Library/Developer/CommandLineTools/usr/bin/../include/c++/v1/utility:313:42:
note: candidate template ignored: disabled by 'enable_if' [with _U1 =
const std::__1::basic_string<char> &, _U2 = Mu::QueryMatch &]
class = typename enable_if<is_convertible<_U1,
first_type>::value &&
^
/Library/Developer/CommandLineTools/usr/bin/../include/c++/v1/utility:323:9:
note: candidate template ignored: could not match 'pair' against
'basic_string'
pair(pair<_U1, _U2>&& __p,
^
/Library/Developer/CommandLineTools/usr/bin/../include/c++/v1/utility:270:49:
note: candidate constructor template not viable: requires 0 arguments, but
2 were provided
_LIBCPP_INLINE_VISIBILITY _LIBCPP_CONSTEXPR pair() : first(), second()
{}
^
/Library/Developer/CommandLineTools/usr/bin/../include/c++/v1/utility:357:9:
note: candidate constructor template not viable: requires single argument
'__p', but 2 arguments were provided
pair(_Tuple&& __p)
^
/Library/Developer/CommandLineTools/usr/bin/../include/c++/v1/utility:368:9:
note: candidate constructor template not viable: requires 3 arguments, but
2 were provided
pair(piecewise_construct_t __pc, tuple<_Args1...> __first_args,
^
/Library/Developer/CommandLineTools/usr/bin/../include/c++/v1/utility:405:9:
note: candidate constructor template not viable: requires 5 arguments, but
2 were provided
pair(piecewise_construct_t,
^
/Library/Developer/CommandLineTools/usr/bin/../include/c++/v1/utility:288:5:
note: candidate constructor not viable: requires single argument '__p',
but 2 arguments were provided
pair(const pair& __p) = default;
^
/Library/Developer/CommandLineTools/usr/bin/../include/c++/v1/utility:331:5:
note: candidate constructor not viable: requires single argument '__p',
but 2 arguments were provided
pair(pair&& __p) = default;
^
}}}
It succeeds on Sierra and later using Xcode clang, and it succeeds on
Mavericks and earlier using newer MacPorts clang. So the simplest fix
would be to blacklist older clangs. Perhaps (a guess):
{{{
compiler.blacklist {clang < 900}
}}}
Plus at the top:
{{{
PortGroup compiler_blacklist_versions 1.0
}}}
--
Ticket URL: <https://trac.macports.org/ticket/63364>
MacPorts <https://www.macports.org/>
Ports system for macOS
More information about the macports-tickets
mailing list