Commit 875ec1e7 authored by Sylvestre Ledru's avatar Sylvestre Ledru

Temporary work about a global llvm-toolchain packages

parents
In the repack script (orig-tar.sh), we are creating a subdirectory tools/clang/
and storing all the sources of clang in it.
After that, the llvm sources are unpack, its patches applied
-- Sylvestre Ledru <sylvestre@debian.org> Tue, 12 Apr 2011 21:21:24 +0200
* moved the header at the right place in libclang-dev
* add the soname
This diff is collapsed.
tools/clang/docs/
# for clang 3.3, it will be: _build/html
usr/bin/clang /usr/bin/
usr/bin/clang++ /usr/bin/
usr/bin/clang-check /usr/bin/
usr/bin/clang-tblgen /usr/bin/
tools/clang/tools/scan-build /usr/share/clang/
tools/clang/tools/scan-view /usr/share/clang/
#usr/share/man/man1/clang.1 usr/share/man/man1/
usr/share/man/man1/clang.1.gz usr/share/man/man1/llvm-clang.1.gz
usr/share/man/man1/clang.1.gz usr/share/man/man1/clang++.1.gz
/usr/share/clang/scan-build/scan-build /usr/bin/scan-build
/usr/share/clang/scan-view/scan-view /usr/bin/scan-view
/usr/bin/clang /usr/bin/llvm-clang
#debian/man/scan*.1
#! /bin/sh -e
prio=10
update-alternatives --quiet \
--install /usr/bin/c++ \
c++ \
/usr/bin/clang++ \
$prio
update-alternatives --quiet \
--install /usr/bin/cc \
cc \
/usr/bin/clang \
$prio
update-alternatives --quiet \
--install /usr/bin/c89 \
c89 \
/usr/bin/clang \
$prio
update-alternatives --quiet \
--install /usr/bin/c99 \
c99 \
/usr/bin/clang \
$prio
#DEBHELPER#
exit 0
#!/bin/sh
set -e
if [ "$1" = "remove" ] || [ "$1" = "deconfigure" ]; then
update-alternatives --quiet --remove cc /usr/bin/clang
update-alternatives --quiet --remove c89 /usr/bin/clang
update-alternatives --quiet --remove c99 /usr/bin/clang
update-alternatives --quiet --remove c++ /usr/bin/clang++
fi
#DEBHELPER#
exit 0
build-clang/lib/clang/3.2/lib/linux/*.a /usr/lib/clang/3.2/
build-clang/lib/libprofile_rt.a /usr/lib/clang/3.2/
This diff is collapsed.
This package was debianized by Arthur Loiret <arthur.loiret@u-psud.fr> on
Sun, 10 Nov 2007 12:32:05 +0200.
It was downloaded from http://llvm.org/releases/download.html
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2004 Sam Hocevar
14 rue de Plaisance, 75014 Paris, France
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
0. You just DO WHAT THE FUCK YOU WANT TO.
==============================================================================
LLVM Release License
==============================================================================
University of Illinois/NCSA
Open Source License
Copyright (c) 2003-2007 University of Illinois at Urbana-Champaign.
All rights reserved.
Developed by:
LLVM Team
University of Illinois at Urbana-Champaign
http://llvm.org
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal with
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
of the Software, and to permit persons to whom the Software is furnished to do
so, subject to the following conditions:
* Redistributions of source code must retain the above copyright notice,
this list of conditions and the following disclaimers.
* Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimers in the
documentation and/or other materials provided with the distribution.
* Neither the names of the LLVM Team, University of Illinois at
Urbana-Champaign, nor the names of its contributors may be used to
endorse or promote products derived from this Software without specific
prior written permission.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
CONTRIBUTORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS WITH THE
SOFTWARE.
==============================================================================
Copyrights and Licenses for Third Party Software Distributed with LLVM:
==============================================================================
The LLVM software contains code written by third parties. Such software will
have its own individual LICENSE.TXT file in the directory in which it appears.
This file will describe the copyrights, license, and restrictions which apply
to that code.
The disclaimer of warranty in the University of Illinois Open Source License
applies to all code in the LLVM Distribution, and nothing in any of the
other licenses gives permission to use the names of the LLVM Team or the
University of Illinois to endorse or promote products derived from this
Software.
The following pieces of software have additional or alternate copyrights,
licenses, and/or restrictions:
Program Directory
------- ---------
System Library llvm/lib/System
Compiler Driver llvm/tools/llvmc
Autoconf llvm/autoconf
llvm/projects/ModuleMaker/autoconf
llvm/projects/sample/autoconf
//===----------------------------------------------------------------------===//
//
// Debian paths declaration management
//
// This file is distributed under the University of Illinois Open Source
// License. See LICENSE.TXT for details.
//
//===----------------------------------------------------------------------===//
#ifndef DEBIAN_PATH_H
#define DEBIAN_PATH_H
// To create the full path to libgcc and other.
// For example: /usr/lib/i386-linux-gnu/gcc/i486-linux-gnu/4.5/libgcc.a
#define DEB_HOST_MULTIARCH_TRIPLET "@DEB_HOST_MULTIARCH@"
#define DEB_HOST_GNU_TYPE_TRIPLET "@DEB_HOST_GNU_TYPE@"
// Provides the debian revision
#define DEB_PATCHSETVERSION "@DEB_PATCHSETVERSION@"
#endif
usr/lib/clang/3.2/include/ /usr/include/clang/3.2/
usr/lib/clang/3.2/lib /usr/lib/clang/3.2/
usr/include/clang /usr/include/
usr/include/clang-c /usr/include/
usr/lib/libclang.so /usr/lib/
usr/lib/libclang*a /usr/lib/
usr/lib/libclang.so.1
description = "Low Level Virtual Machine bindings"
version = "3.2"
directory = "+llvm-3.2"
archive(byte) = "llvm.cma"
archive(native) = "llvm.cmxa"
linkopts = "-cclib -lstdc++ -cclib -lllvm"
package "executionengine"
(
requires = "llvm-3_2"
version = "3.2"
archive(native) = "llvm_executionengine.cmxa"
archive(byte) = "llvm_executionengine.cma"
linkopts = "-cclib -lllvm_executionengine"
)
package "target"
(
requires = "llvm-3_2"
version = "3.2"
archive(native) = "llvm_target.cmxa"
archive(byte) = "llvm_target.cma"
linkopts = "-cclib -lllvm_target"
)
package "scalar_opts"
(
requires = "llvm-3_2 llvm-3_2.target"
version = "3.2"
archive(native) = "llvm_scalar_opts.cmxa"
archive(byte) = "llvm_scalar_opts.cma"
linkopts = "-cclib -lllvm_scalar_opts"
)
package "analysis"
(
requires = "llvm-3_2"
version = "3.2"
archive(native) = "llvm_analysis.cmxa"
archive(byte) = "llvm_analysis.cma"
linkopts = "-cclib -lllvm_analysis"
)
package "bitwriter"
(
requires = "llvm-3_2"
version = "3.2"
archive(native) = "llvm_bitwriter.cmxa"
archive(byte) = "llvm_bitwriter.cma"
linkopts = "-cclib -lllvm_bitwriter"
)
package "bitreader"
(
requires = "llvm-3_2 llvm-3_2.bitwriter"
version = "3.2"
archive(native) = "llvm_bitreader.cmxa"
archive(byte) = "llvm_bitreader.cma"
linkopts = "-cclib -lllvm_bitreader"
)
Document: libllvm-3.2-ocaml-dev-ocamldoc-api-reference
Title: Llvm OCamldoc API Reference
Abstract: API reference manual for libllvm-ocaml-dev (generated via OCamldoc)
Section: Programming/OCaml
Format: HTML
Index: /usr/share/doc/libllvm-3.2-ocaml-dev/html/index.html
Files: /usr/share/doc/libllvm-3.2-ocaml-dev/html/*
debian/tmp/@OCAML_STDLIB_DIR@/llvm-3.2 @OCAML_STDLIB_DIR@/
debian/tmp//usr/lib/llvm-3.2/docs/llvm/ocamldoc/html usr/share/doc/libllvm-3.2-ocaml-dev/
# It is in the section ocaml which is fine.
libllvm-3.2-ocaml-dev: wrong-section-according-to-package-name libllvm-3.2-ocaml-dev => libdevel
usr/lib/llvm-3.2/lib/libLLVM-3.2.so.1 /usr/lib/@DEB_HOST_MULTIARCH@/
/usr/lib/llvm-3.2/lib
/usr/lib/llvm-3.2/build
/usr/lib/llvm-3.2/include
usr/share/doc/llvm-3.2-dev
usr/share/emacs/site-lisp/llvm-3.2
debian/tmp//usr/lib/llvm-3.2/lib/* /usr/lib/llvm-3.2/lib/
debian/tmp//usr/lib/llvm-3.2/include/llvm/ usr/include/llvm-3.2/
debian/tmp//usr/lib/llvm-3.2/include/llvm-c/ usr/include/llvm-c-3.2/
build-llvm/Makefile.common /usr/lib/llvm-3.2/build/
build-llvm/Makefile.config /usr/lib/llvm-3.2/build/
build-llvm/config.status /usr/lib/llvm-3.2/build/
Makefile.rules /usr/lib/llvm-3.2/build/
configure /usr/lib/llvm-3.2/build/
autoconf/ /usr/lib/llvm-3.2/build/
utils/vim/llvm.vim usr/share/vim/addons/syntax/llvm-3.2.vim
utils/vim/tablegen.vim usr/share/vim/addons/syntax/tablegen-3.2.vim
utils/emacs/emacs.el usr/share/emacs/site-lisp/llvm-3.2/
utils/emacs/llvm-mode.el usr/share/emacs/site-lisp/llvm-3.2/
utils/emacs/tablegen-mode.el usr/share/emacs/site-lisp/llvm-3.2/
usr/lib/@DEB_HOST_MULTIARCH@/libLLVM-3.2.so.1 usr/lib/@DEB_HOST_MULTIARCH@/libLLVM-3.2.so
usr/include/llvm-c-3.2/llvm-c usr/lib/llvm-3.2/include/llvm-c
usr/include/llvm-3.2/llvm usr/lib/llvm-3.2/include/llvm
usr/share/doc/llvm-3.2-doc
docs/_build/html usr/share/doc/llvm-3.2-doc/
usr/share/doc/llvm-3.2-examples
/usr/lib/llvm-3.2/build/Makefile.common usr/share/doc/llvm-3.2-examples/Makefile.common
/usr/lib/llvm-3.2/build/Makefile.config usr/share/doc/llvm-3.2-examples/Makefile.config
/usr/lib/llvm-3.2/build/Makefile.rules usr/share/doc/llvm-3.2-examples/Makefile.rules
package llvm-@LLVM_VERSION@-runtime
interpreter /usr/bin/lli-@LLVM_VERSION@
magic BC
debian/tmp/usr/lib/llvm-3.2/bin/lli /usr/lib/llvm-3.2/bin/
debian/tmp/usr/bin/lli-3.2 /usr/bin/
debian/llvm-3.2-runtime.binfmt usr/share/binfmts/
# AUTOGENERATED in debian/rules.d/binary.mk.
debian/tmp//usr/lib/llvm-3.2/share/man/man1/lli*
#!/bin/sh -e
if test "$1" = "configure"; then
if test -x /usr/sbin/update-binfmts; then
update-binfmts --import llvm-3.2-runtime.binfmt || true
fi
fi
#DEBHELPER#
#!/bin/sh -e
if test "$1" = "remove"; then
if test -x /usr/sbin/update-binfmts; then
update-binfmts --package llvm-@LLVM_VERSION@-runtime \
--remove llvm-@LLVM_VERSION@-runtime.binfmt /usr/bin/lli-@LLVM_VERSION@ || true
if test -f /var/lib/binfmts/llvm-@LLVM_VERSION@.binfmt; then
# Purge old file
update-binfmts --package llvm-@LLVM_VERSION@-runtime \
--remove llvm-@LLVM_VERSION@.binfmt /usr/bin/lli-@LLVM_VERSION@ || true
fi
fi
fi
#DEBHELPER#
/usr/lib/llvm-3.2/bin
usr/share/man/man1
usr/share/doc/llvm-3.2
debian/tmp//usr/lib/llvm-3.2/bin/* /usr/lib/llvm-3.2/bin/
debian/tmp/usr/bin/* /usr/bin
# AUTOGENERATED in debian/rules.d/binary.mk.
docs/_build/man/*
\ No newline at end of file
/usr/lib/llvm-3.1/build
debian/tmp//usr/lib/llvm-3.1/bin/* /usr/lib/llvm-3.1/bin/
debian/tmp//usr/lib/llvm-3.1/lib/* /usr/lib/llvm-3.1/lib/
debian/tmp//usr/lib/llvm-3.1/include/* /usr/lib/llvm-3.1/include/
debian/tmp//usr/lib/llvm-3.1/docs/llvm/html usr/share/doc/llvm-snapshot/
debian/tmp//usr/lib/llvm-3.1/docs/llvm/ps usr/share/doc/llvm-snapshot/
build-llvm/Makefile.common /usr/lib/llvm-3.1/build/
build-llvm/Makefile.config /usr/lib/llvm-3.1/build/
build-llvm/config.status /usr/lib/llvm-3.1/build/
Makefile.rules /usr/lib/llvm-3.1/build/
configure /usr/lib/llvm-3.1/build/
autoconf/ /usr/lib/llvm-3.1/build/
.\" generated with Ronn/v0.7.3
.\" http://github.com/rtomayko/ronn/tree/0.7.3
.
.TH "SCAN\-BUILD" "1" "December 2010" "" ""
.
.SH "NAME"
\fBscan\-build\fR
.
.P
scan\-build(1) \-\- An utility for running the clang(1) analyzer from the command line
.
.SH "SYNOPSIS"
\fBscan\-build\fR \fIoptions\fR \fIbuild command\fR [build options]
.
.SH "DESCRIPTION"
\fBscan\-build\fR is a command line utility that enables a user to run the clang static analyzer over their codebase as part of performing a regular build (from the command line)\.
.
.SH "OPTIONS"
.
.TP
\fB\-analyze\-headers\fR
Also analyze functions in #included files\.
.
.TP
\fB\-o\fR
Target directory for HTML report files\. Subdirectories will be created as needed to represent separate "runs" of the analyzer\. If this option is not specified, a directory is created in /tmp (TMPDIR on Mac OS X) to store the reports\.
.
.TP
\fB\-h\fR, \fB\-\-help\fR
Display the help message\.
.
.TP
\fB\-k\fR
Add a "keep on going" option to the specified build command\.
.
.TP
\fB\-\-keep\-going\fR
This option currently supports make and xcodebuild\. This is a convenience option; one can specify this behavior directly using build options\.
.
.TP
\fB\-\-html\-title\fR [title]
Specify the title used on generated HTML pages\.
.
.TP
\fB\-\-html\-title=\fR[title]
If not specified, a default title will be used\.
.
.TP
\fB\-plist\fR
By default the output of scan\-build is a set of HTML files\. This option outputs the results as a set of \.plist files\.
.
.TP
\fB\-\-status\-bugs\fR
By default, the exit status of scan\-build is the same as the executed build command\. Specifying this option causes the exit status of scan\-build to be 1 if it found potential bugs and 0 otherwise\.
.
.TP
\fB\-\-use\-cc\fR [compiler path]
By default, scan\-build uses \'gcc\' to compile and link
.
.TP
\fB\-\-use\-cc=\fR[compiler path]
your C and Objective\-C code\. Use this option to specify an alternate compiler\.
.
.TP
\fB\-\-use\-c++\fR [compiler path]
By default, scan\-build uses \'g++\' to compile and link
.
.TP
\fB\-\-use\-c++=\fR[compiler path]
your C++ and Objective\-C++ code\. Use this option to specify an alternate compiler\.
.
.TP
\fB\-v\fR
Verbose output from scan\-build and the analyzer\. A second and third \'\-v\' increases verbosity\.
.
.TP
\fB\-V\fR
View analysis results in a web browser when the build
.
.TP
\fB\-\-view\fR
completes\.
.
.SH "ADVANCED OPTIONS:"
.
.TP
\fB\-constraints\fR [model]
Specify the contraint engine used by the analyzer\. By default the \'range\' model is used\. Specifying \'basic\' uses a simpler, less powerful constraint model used by checker\-0\.160 and earlier\.
.
.TP
\fB\-store\fR [model]
Specify the store model used by the analyzer\. By default, the \'region\' store model is used\. \'region\' specifies a field sensitive store model\. Users can also specify \'basic\', which is far less precise but can more quickly analyze code\. \'basic\' was the default store model for checker\-0\.221 and earlier\.
.
.TP
\fB\-no\-failure\-reports\fR
Do not create a \'failures\' subdirectory that includes analyzer crash reports and preprocessed source files\.
.
.SH "EXAMPLES"
Basic usage of scan\-build is designed to be simple: just place the word "scan\-build" in front of your build command:
.
.P
$ scan\-build make
.
.P
$ scan\-build xcodebuild
.
.P
In the first case scan\-build analyzes the code of a project built with make and in the second case scan\-build analyzes a project built using xcodebuild\.
.
.P
It is also possible to use scan\-build to analyze specific files:
.
.P
$ scan\-build gcc \-c t1\.c t2\.c
.
.P
This example causes the files t1\.c and t2\.c to be analyzed\.
.
.SH "AUTHORS"
Maintained by the Clang / LLVM Team \fIhttp://clang\.llvm\.org\fR\.
.
.P
This manual page was written by Ermenegildo Fiorito \fIfiorito\.g@gmail\.com\fR for the Debian Project\.
.
.SH "SEE ALSO"
clang(1) scan\-view(1) \fIhttp://clang\-analyzer\.llvm\.org\fR
.\" generated with Ronn/v0.7.3
.\" http://github.com/rtomayko/ronn/tree/0.7.3
.
.TH "SCAN\-VIEW" "1" "December 2010" "" ""
.
.SH "NAME"
\fBscan\-view\fR
.
.P
scan\-view(1) \-\- The clang(1) static analyzer results viewer\.
.
.SH "SYNOPSIS"
\fBscan\-view\fR \fIoptions\fR \fIresults directory\fR
.
.SH "DESCRIPTION"
\fBscan\-view\fR a companion comannd line utility to scan\-build(1), scan\-view is used to view analysis results generated by scan\-build(1)\. There is an option that one can pass to scan\-build to cause scan\-view to run as soon as it the analysis of a build completes
.
.SH "OPTIONS"
.
.TP
\fB\-h\fR, \fB\-\-help\fR
show the help message and exit\.
.
.TP
\fB\-\-host=\fRHOST
Host interface to listen on\. (default=127\.0\.0\.1)
.
.TP
\fB\-\-port=\fRPORT
Port to listen on\. (default=8181)
.
.TP
\fB\-\-debug\fR
Print additional debugging information\.
.
.TP
\fB\-\-auto\-reload\fR
Automatically update module for each request\.
.
.TP
\fB\-\-no\-browser\fR
Don\'t open a webbrowser on startup\.
.
.TP
\fB\-\-allow\-all\-hosts\fR
Allow connections from any host (access restricted to "127\.0\.0\.1" by default)
.
.SH "AUTHORS"
Maintained by the Clang / LLVM Team \fIhttp://clang\.llvm\.org\fR\.
.
.P
This manual page was written by Ermenegildo Fiorito \fIfiorito\.g@gmail\.com\fR for the Debian Project\.
.
.SH "SEE ALSO"
clang(1) scan\-build(1) \fIhttp://clang\-analyzer\.llvm\.org\fR
#!/bin/sh
# called by uscan with '--upstream-version' <version> <file>
DIR=clang-*.src
DIRIN=clang-$2
TAR=../clang_$2.orig.tar.bz2
# clean up the upstream tarball
tar zxvf $3
mkdir -p $DIRIN/tools/clang
mv $DIR/* $DIRIN/tools/clang/
tar -c -j -f $TAR $DIRIN
rm -rf $DIRIN $DIR
# move to directory 'tarballs'
if [ -r .svn/deb-layout ]; then
. .svn/deb-layout
mv $TAR $origDir
echo "moved $TAR to $origDir"
fi
exit 0
Index: clang-3.2~rc1/tools/clang/tools/libclang/Makefile
===================================================================
--- clang-3.2~rc1.orig/tools/clang/tools/libclang/Makefile 2012-11-13 21:13:57.000000000 +0100
+++ clang-3.2~rc1/tools/clang/tools/libclang/Makefile 2012-11-17 15:42:01.000000000 +0100
@@ -14,6 +14,7 @@
LINK_LIBS_IN_SHARED = 1
SHARED_LIBRARY = 1
+SONAME_MAJOR=1
include $(CLANG_LEVEL)/../../Makefile.config
LINK_COMPONENTS := $(TARGETS_TO_BUILD) asmparser support mc
@@ -27,7 +28,7 @@
# Add soname to the library.
ifeq ($(HOST_OS), $(filter $(HOST_OS), Linux FreeBSD GNU))
- LDFLAGS += -Wl,-soname,lib$(LIBRARYNAME)$(SHLIBEXT)
+ LDFLAGS += -Wl,-soname,lib$(LIBRARYNAME)$(SHLIBEXT).$(SONAME_MAJOR)
endif
##===----------------------------------------------------------------------===##
Index: clang-3.2~rc1/tools/clang/lib/Basic/Version.cpp
===================================================================
--- clang-3.2~rc1.orig/tools/clang/lib/Basic/Version.cpp 2012-11-13 21:13:57.000000000 +0100
+++ clang-3.2~rc1/tools/clang/lib/Basic/Version.cpp 2012-11-17 15:43:03.000000000 +0100
@@ -15,6 +15,7 @@
#include "clang/Basic/LLVM.h"
#include "llvm/Support/raw_ostream.h"
#include "llvm/Config/config.h"
+#include "clang/Debian/debian_path.h"
#include <cstring>
#include <cstdlib>
@@ -117,7 +118,8 @@
#ifdef CLANG_VENDOR
OS << CLANG_VENDOR;
#endif
- OS << "clang version " CLANG_VERSION_STRING " "
+ OS << "clang version " CLANG_VERSION_STRING "-" DEB_PATCHSETVERSION " "
+
<< getClangFullRepositoryVersion();
// If vendor supplied, include the base LLVM version as well.
Index: clang-3.2~rc1/tools/clang/Makefile
===================================================================
--- clang-3.2~rc1.orig/tools/clang/Makefile 2012-11-13 21:13:57.000000000 +0100
+++ clang-3.2~rc1/tools/clang/Makefile 2012-11-17 15:43:15.000000000 +0100
@@ -47,9 +47,7 @@
# Set common Clang build flags.
CPP.Flags += -I$(PROJ_SRC_DIR)/$(CLANG_LEVEL)/include -I$(PROJ_OBJ_DIR)/$(CLANG_LEVEL)/include
-ifdef CLANG_VENDOR
-CPP.Flags += -DCLANG_VENDOR='"$(CLANG_VENDOR) "'
-endif
+CPP.Flags += -DCLANG_VENDOR='"Debian "'
ifdef CLANG_REPOSITORY_STRING
CPP.Flags += -DCLANG_REPOSITORY_STRING='"$(CLANG_REPOSITORY_STRING)"'
endif
Index: clang-3.2~rc1/tools/clang/lib/Driver/ToolChains.cpp
===================================================================
--- clang-3.2~rc1.orig/tools/clang/lib/Driver/ToolChains.cpp 2012-11-13 21:13:57.000000000 +0100
+++ clang-3.2~rc1/tools/clang/lib/Driver/ToolChains.cpp 2012-11-17 15:43:18.000000000 +0100
@@ -2174,6 +2174,11 @@
addSystemInclude(DriverArgs, CC1Args, P.str());
}
+ // Under Debian, clang headers are installed into
+ // '/usr/include/clang/VERSION/include/'
+ addSystemInclude(DriverArgs, CC1Args, "/usr/include/clang/" + std::string(CLANG_VERSION_STRING) + "/include/");
+
+
if (DriverArgs.hasArg(options::OPT_nostdlibinc))
return;
Index: clang-3.2~rc1/tools/clang/include/clang/Basic/Builtins.def
===================================================================
--- clang-3.2~rc1.orig/tools/clang/include/clang/Basic/Builtins.def 2012-11-13 21:13:57.000000000 +0100
+++ clang-3.2~rc1/tools/clang/include/clang/Basic/Builtins.def 2012-11-17 15:43:20.000000000 +0100
@@ -461,8 +461,8 @@
BUILTIN(__builtin___stpcpy_chk, "c*c*cC*z", "nF")
BUILTIN(__builtin___strcat_chk, "c*c*cC*z", "nF")
BUILTIN(__builtin___strcpy_chk, "c*c*cC*z", "nF")
-BUILTIN(__builtin___strlcat_chk, "c*c*cC*zz", "nF")
-BUILTIN(__builtin___strlcpy_chk, "c*c*cC*zz", "nF")
+//BUILTIN(__builtin___strlcat_chk, "c*c*cC*zz", "nF")
+//BUILTIN(__builtin___strlcpy_chk, "c*c*cC*zz", "nF")
BUILTIN(__builtin___strncat_chk, "c*c*cC*zz", "nF")
BUILTIN(__builtin___strncpy_chk, "c*c*cC*zz", "nF")
BUILTIN(__builtin___stpncpy_chk, "c*c*cC*zz", "nF")
@@ -755,8 +755,8 @@
LIBBUILTIN(_longjmp, "vJi", "fr", "setjmp.h", ALL_LANGUAGES)
LIBBUILTIN(siglongjmp, "vSJi", "fr", "setjmp.h", ALL_LANGUAGES)
// non-standard but very common
-LIBBUILTIN(strlcpy, "zc*cC*z", "f", "string.h", ALL_LANGUAGES)
-LIBBUILTIN(strlcat, "zc*cC*z", "f", "string.h", ALL_LANGUAGES)
+//LIBBUILTIN(strlcpy, "zc*cC*z", "f", "string.h", ALL_LANGUAGES)
+//LIBBUILTIN(strlcat, "zc*cC*z", "f", "string.h", ALL_LANGUAGES)
// id objc_msgSend(id, SEL, ...)
LIBBUILTIN(objc_msgSend, "GGH.", "f", "objc/message.h", OBJC_LANG)
Index: clang-3.2~rc1/tools/clang/lib/Sema/SemaChecking.cpp