[LLVMbugs] [Bug 21098] New: clang++ 3.5 Uncorrectly set paths searched for includes - bits/c++config.h not found

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Tue Sep 30 07:26:40 PDT 2014


http://llvm.org/bugs/show_bug.cgi?id=21098

            Bug ID: 21098
           Summary: clang++ 3.5 Uncorrectly set paths searched for
                    includes - bits/c++config.h not found
           Product: clang
           Version: unspecified
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: P
         Component: Driver
          Assignee: unassignedclangbugs at nondot.org
          Reporter: arturcz at hell.pl
                CC: llvmbugs at cs.uiuc.edu
    Classification: Unclassified

Using branch release_35 from llvm and clang on Ubuntu I cannot compile sample
program because of bits/c++config.h file not found.

Procedure to replicate the bug:
svn co http://llvm.org/svn/llvm-project/llvm/trunk llvm
cd llvm
svn switch ^/llvm/branches/release_35
cd tools/
svn co http://llvm.org/svn/llvm-project/cfe/trunk clang
cd clang
svn switch ^/cfe/branches/release_35
cd ../../../
mkdir build
cd build
../llvm/configure  --enable-cxx11 --enable-optimized --enable-assertions
--with-optimize-option=-O2
make -j8
cd ..
echo '#include <string>' > bug.cpp
echo 'int main() { return 0; }' >> bug.cpp
build/Release+Asserts/bin/clang++ bug.cpp

Expected result: program is compiled correctly.

Achieved result:
In file included from bug.cpp:1:
/usr/lib/gcc/x86_64-linux-gnu/4.8/../../../../include/c++/4.8/string:38:10:
fatal error: 
      'bits/c++config.h' file not found
#include <bits/c++config.h>
         ^
1 error generated.


Additional information:
arturcz at box:/tmp/clang/llvm$ svn info
Path: .
Working Copy Root Path: /tmp/clang/llvm
URL: http://llvm.org/svn/llvm-project/llvm/branches/release_35
Relative URL: ^/llvm/branches/release_35
Repository Root: http://llvm.org/svn/llvm-project
Repository UUID: 91177308-0d34-0410-b5e6-96231b3b80d8
Revision: 218674
Node Kind: directory
Schedule: normal
Last Changed Author: delcypher
Last Changed Rev: 217640
Last Changed Date: 2014-09-12 01:00:09 +0200 (Fri, 12 Sep 2014)


arturcz at box:/tmp/clang/llvm/tools/clang$ svn info
Path: .
Working Copy Root Path: /tmp/clang/llvm/tools/clang
URL: http://llvm.org/svn/llvm-project/cfe/branches/release_35
Relative URL: ^/cfe/branches/release_35
Repository Root: http://llvm.org/svn/llvm-project
Repository UUID: 91177308-0d34-0410-b5e6-96231b3b80d8
Revision: 218674
Node Kind: directory
Schedule: normal
Last Changed Author: hans
Last Changed Rev: 218644
Last Changed Date: 2014-09-30 01:33:05 +0200 (Tue, 30 Sep 2014)

arturcz at box:/tmp/clang$ dpkg -l g++-4.8
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name                        Version            Architecture      
Description
+++-===========================-==================-==================-===========================================================
ii  g++-4.8                     4.8.2-19ubuntu1    amd64              GNU C++
compiler

arturcz at box:/tmp/clang$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 14.04.1 LTS
Release:        14.04
Codename:       trusty

I believe the problem is in the commit r216531 in clang (please note r216572
depends on r216531). After reverting changes made to file
lib/Drivers/ToolChains.{cpp,h} from those commits, the example code can be
compiled successfully.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20140930/e2edbdc4/attachment.html>


More information about the llvm-bugs mailing list