aboutsummaryrefslogtreecommitdiff
path: root/tools/ccc/ccclib/ToolChain.py
AgeCommit message (Collapse)Author
2009-05-02ccc is dead.Daniel Dunbar
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@70649 91177308-0d34-0410-b5e6-96231b3b80d8
2009-03-24Install clang-cc to libexec/clang-cc (instead of bin/clang-cc).Daniel Dunbar
- Updated ccc & driver to look in libexec/ for tools. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@67607 91177308-0d34-0410-b5e6-96231b3b80d8
2009-03-24ccc: Have generic GCC tool chain search the driver directory forDaniel Dunbar
executables (e.g., clang). - This matches the clang-driver behavior. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@67590 91177308-0d34-0410-b5e6-96231b3b80d8
2009-03-11ccc: -x assembler-with-cpp was broken for darwin, and it wasn't usingDaniel Dunbar
clang as the preprocessor even when it should. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66737 91177308-0d34-0410-b5e6-96231b3b80d8
2009-02-20Unbreak Darwin PIC handling; my refactoring yesterday was bogus.Daniel Dunbar
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65154 91177308-0d34-0410-b5e6-96231b3b80d8
2009-02-20ccc: Basic translation of gcc subtarget feature options to LLVMDaniel Dunbar
options (i.e., -mno-red-zone, -msoft-float, -mno-sse, etc.) - Also, make sure unwind tables default to on Darwin/x86_64. - PR3604. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65118 91177308-0d34-0410-b5e6-96231b3b80d8
2009-02-20ccc: Use toolchain hook for default relocation model value.Daniel Dunbar
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65116 91177308-0d34-0410-b5e6-96231b3b80d8
2009-02-20ccc: Use toolChain arch name instead of looking for arch command lineDaniel Dunbar
argument; the toolchain should always know the arch. - Fixes: <rdar://problem/6582911> -ccc-clang-archs doesn't work for excluding ppc git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65104 91177308-0d34-0410-b5e6-96231b3b80d8
2009-02-20ccc: Store arch name in all toolchains.Daniel Dunbar
- No functionality change. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65102 91177308-0d34-0410-b5e6-96231b3b80d8
2009-02-20ccc: Give all tools access to the toolchain they are in.Daniel Dunbar
- No functionality change. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65100 91177308-0d34-0410-b5e6-96231b3b80d8
2009-02-17ccc: Pass -f[no-]math-errno to clang.Daniel Dunbar
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@64709 91177308-0d34-0410-b5e6-96231b3b80d8
2009-02-06ccc/Darwin: Add a missing Darwin argument translation, -shared becomesDaniel Dunbar
-dynamiclib. Re-audited translations to make sure I didn't miss something else. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@63953 91177308-0d34-0410-b5e6-96231b3b80d8
2009-01-29ccc: Embrace destiny as a clang compiler driver.Daniel Dunbar
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. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@63346 91177308-0d34-0410-b5e6-96231b3b80d8
2009-01-29ccc: Honor -ccc-clang for generic GCC toolchain.Daniel Dunbar
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@63277 91177308-0d34-0410-b5e6-96231b3b80d8
2009-01-26ccc: Recognize -emit-llvm [-S].Daniel Dunbar
- Unlike llvm-gcc, this doesn't yet treat -emit-llvm output as a linker input. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@63014 91177308-0d34-0410-b5e6-96231b3b80d8
2009-01-21ccc: Add appropriate file search prefixes when on x86_64 Darwin, andDaniel Dunbar
look for crt3.o appropriately. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@62694 91177308-0d34-0410-b5e6-96231b3b80d8
2009-01-21ccc: Implement file & path searching.Daniel Dunbar
- Toolchain is responsible for providing list of prefixes to search. - Implement -print-file-name=xxx and -print-prog-name=xxx driver options. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@62659 91177308-0d34-0410-b5e6-96231b3b80d8
2009-01-21ccc: Add --analyze driver mode (for running static analyzer).Daniel Dunbar
- 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. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@62649 91177308-0d34-0410-b5e6-96231b3b80d8
2009-01-20ccc: Darwin/x86: Teach compile tool how to build .pch files. xcc isDaniel Dunbar
now fully independent of the gcc driver when targetting Darwin/x86. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@62570 91177308-0d34-0410-b5e6-96231b3b80d8
2009-01-20ccc: Darwin/x86: Add direct cpp support.Daniel Dunbar
- 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). git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@62551 91177308-0d34-0410-b5e6-96231b3b80d8
2009-01-16ccc: Darwin/X86: Implement remainder of (non -Z...) generic argumentDaniel Dunbar
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'. ;) git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@62353 91177308-0d34-0410-b5e6-96231b3b80d8
2009-01-14ccc: Implement support clang PTH using gcc PCH style interface.Daniel Dunbar
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. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@62246 91177308-0d34-0410-b5e6-96231b3b80d8
2009-01-14ccc: Use Clang/Compile for Objective-C files as well.Daniel Dunbar
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@62206 91177308-0d34-0410-b5e6-96231b3b80d8
2009-01-14ccc: Add dummy Clang/Compile tool and use on Darwin/X86 for C files.Daniel Dunbar
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@62204 91177308-0d34-0410-b5e6-96231b3b80d8
2009-01-13ccc: Darwin: Implement some important general argument translationsDaniel Dunbar
for the Darwin tool chain. - Ideally we would localize these to tool specific argument processing but for now this matches gcc closely. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@62181 91177308-0d34-0410-b5e6-96231b3b80d8
2009-01-13ccc: Allow internal tool chain specific argument translation.Daniel Dunbar
- Pulled -Xarch processing into this. - Get rid of manual creation of forwarding arg array. - Use Darwin/CC1 instead of generic GCC cc1 on X86. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@62172 91177308-0d34-0410-b5e6-96231b3b80d8
2009-01-12ccc: (Darwin) More argument translation for Darwin/Compile tool.Daniel Dunbar
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@62093 91177308-0d34-0410-b5e6-96231b3b80d8
2009-01-12ccc: (Darwin) Move path resolution into ToolChain.Daniel Dunbar
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@62082 91177308-0d34-0410-b5e6-96231b3b80d8
2009-01-12ccc: Generalize Darwin/Link tool based on Darwin version.Daniel Dunbar
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@62078 91177308-0d34-0410-b5e6-96231b3b80d8
2009-01-11ccc: Add fairly complete argument translation for Darwin link step.Daniel Dunbar
- Some things are still hardcoded, and macosx-version-min comparison isn't implemented, but otherwise this very closely matches gcc. - The one exception is that arguments (like -framework or -Wl,) which are treated as linker inputs instead of options are not being forwarded yet. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@62059 91177308-0d34-0410-b5e6-96231b3b80d8
2009-01-10ccc: Introduce ToolChains for mapping Actions to Tools which canDaniel Dunbar
perform them. - A ToolChain is a coherent set of tools use in a compilation process. The idea is that a ToolChain holds roughly the information (specs, search paths, etc.) that is in a single gcc binary. - The default ToolChain is selected by the host and will generally correspond to what the default system compiler would do. However, this can be over-riden for a variety of purposes, for example the by the driver driver or for testing. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@62021 91177308-0d34-0410-b5e6-96231b3b80d8