[PATCH] Linux header search on Ubuntu 13.04 multiarch

Michael van der Westhuizen r1mikey at gmail.com
Sat Feb 16 10:18:43 PST 2013


On 15 Feb 2013, at 9:50 PM, Sanne Wouda <sanne.wouda at gmail.com> wrote:

> Hi,
> 
> I recently ran into a bug where Clang (svn) could not find some system
> header files (specifically <bits/*.h>). I am running Ubuntu 12.10 with
> some 13.04 (libstdc++ amongst others) packages to support Clang-3.2.

For what it's worth, this patch works correctly on an up to date 13.04 system.  Thanks for submitting this - fixing this up was on my list of things to get around to next week!

> 
> The root cause seems to be Ubuntu/Debian moving around the header
> files for multiarch support. E.g. on my system, <bits/predefs.h> is
> located in /usr/include/x86_64-linux-gnu/bits/predefs.h, which isn't
> searched by Clang.
> 
> Attached is a patch which fixes the problems on my system. A unittest
> (with the directory structure attached seperately) illustrates the
> problem and shows that it is fixed by the changes in the patch.
> 
> If there are any comments on the patch, or if this should be fixed in
> some different way, I will be happy to update it.
> 
> Cheers.
> - Sanne
> <ubuntu_13.04_multiarch_tree.tar.gz><linux-header-search.patch>_______________________________________________

Michael





More information about the cfe-commits mailing list