Clang 3.5, 3.6 and 3.7 can't compile a C++11 program with std::bind
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
llvm-toolchain-3.8 (Ubuntu) |
New
|
Undecided
|
Unassigned |
Bug Description
I'm working on Ubuntu 16 x86_64, fully patched. I'm trying to compile Jack Lloyd's Botan library. Its a C++11 TLS library. It can be found at https:/
The compile fails with Clang 3.5, 3.6, 3.7 (3.8 is OK). The library fails with the error below.
I found a GCC error report about it, but it was marked as Invalid because its Clang's bug: https:/
I was not able to find a LLVM bug report for the issue.
According to Andrew Pinksi from the 71809 bug, here's the discussion about it on CFE-dev: http://
The short of it is, Ubuntu ships with GCC 6.0. All the affected Clang's need to be compiled against GCC 6.0 and not the GCC 5.3 its currently compiled against.
Please rebuild Clang 3.5, 3.6, 3.7 against the GCC 6.0 gear.
**********
/usr/bin/
In file included from ./src/lib/
In file included from build/include/
In file included from build/include/
In file included from build/include/
In file included from build/include/
In file included from build/include/
In file included from /usr/bin/
In file included from /usr/bin/
/usr/bin/
no matching constructor for initialization of 'tuple<unsigned short &&,
unsigned char &&, const std::vector<
char> > &&>'
{ return tuple<_
^ ~~~~~~~
/usr/bin/
in instantiation of function template specialization
'
std:
here
/usr/bin/
in instantiation of function template specialization
'
unsigned char, const std::vector<
char> > &)> (Botan:
std:
unsigned char, const std::vector<
char> > &, void>' requested here
^
/usr/bin/
in instantiation of member function 'std::_
short, unsigned char, const std::vector<
std:
(
std:
(
std:
./src/lib/
template specialization 'std::function<void (unsigned short, unsigned
char, const std::vector<
&
(
std:
(
std:
^
1 warning and 1 error generated.
Makefile:1219: recipe for target 'build/
make: *** [build/
make: *** Waiting for unfinished jobs....
I don't have a minimal, reduced case to reproduce it. But here's how to reproduce it using Botan:
git clone git://github. com/randombit/ botan
cd botan
./configure.py --cc=clang --cc-bin= /usr/bin/ clang++ -3.{5|6| 7}
make -j 4
When make gets to the file src/lib/ tls/tls_ handshake_ hash.cpp, the compile will fail.