This redoes the default mode that ccc runs in w.r.t. using clang. Now
ccc defaults to always using clang for any task clang can
handle. However, the following options exist to tweak this behavior:
-ccc-no-clang: Don't use clang at all for compilation (still used for
static analysis).
-ccc-no-clang-cxx: Don't use clang for C++ and Objective-C++ inputs.
-ccc-no-clang-cpp: Don't use clang as a preprocessor.
-ccc-clang-archs <archs>: If present, only use clang for the given
comma separated list of architectures. This only works on Darwin for
now.
Note that all -ccc options must be first on the command line.
llvm-svn: 63346
- However, these last ones do not actually work; the issue is that
they translate to batches of options and need to be reparsed. For
now we just give an unsupported error on them.
llvm-svn: 62872
--assert, --classpath).
- Requires providing some option parameters to over-ride rendering in
order to match gcc. There may be a cleaner way to do this (probably
by introducing a new option type for long JoinedOrSeparate forms).
llvm-svn: 62825
- Unlike groups (which gather distinct but related options), aliases
are for options like '--all-warnings' which are effectively treated
like some other option ('-Wall') both in the driver logic and when
passing to tools.
llvm-svn: 62820
- Toolchain is responsible for providing list of prefixes to search.
- Implement -print-file-name=xxx and -print-prog-name=xxx driver options.
llvm-svn: 62659
- For now forces generation of plist files, need to think about the
right interface.
- Changed -fsyntax-only mode to be its own phase (more consistent).
- Add -WA, for passing options verbatim to analyzer.
llvm-svn: 62649
- This is a hack to allow the Darwin linker to get -final_output when
doing universal builds; the mechanism should be generalized.
- Handle multiple redundant -arch arguments correctly.
- Forward -arch_multiple and -final_output to gcc when necessary.
- Simplified implementation of derived gcc tools.
llvm-svn: 62618
- Add Darwin_X86_CC1Tool which is shared by Darwin/x86/Compile and
Darwin/x86/Preprocess tools.
- Minor bug fixes (CmpDriver exit code, -x cpp-output handling, some
linker argument translation).
llvm-svn: 62551
- This doesn't follow normal installation procedure of python
code, but no sense trying too hard since ccc will be moved to
C++.
- Entry point is now tools/ccc.
llvm-svn: 62517
translation.
- As is my general strategy, this is initially pedantically
compatible with gcc and can be cleaned up later. So, for example,
we still pass -static to collect2 4 times if you say '-mkernel
-fapple-kext'. ;)
llvm-svn: 62353
This requires some hackery, as gcc's PCH mechanism changes behavior,
whereas while PTH is simply a cache. Notably:
- Automatically cause clang to load a .pth file if we find one that
matches a command line -include argument (similar to how gcc
looks for .gch files).
- When generating precompiled headers, translate the suffix from .gch
to .pth (so we do not conflict with actual gcc PCH files).
- When generating precompiled headers, copy the input header to the
same location as the output PTH file. This is necessary because gcc
supports -include xxx.h even if xxx.h doesn't exist, but for clang
we need to actually have the contents of this file available.
llvm-svn: 62246