| tools/lld |
| ~~~~~~~~~ |
| |
| Driver |
| ------ |
| |
| lld needs a driver that supports gnu-ld_, ld64_, and link.exe_ arguments. It |
| would be nice to refactor the argument parsing parts of `Clang's`_ driver support |
| out to LLVM's Support library. |
| |
| .. _gnu-ld: http://sourceware.org/binutils/docs-2.22/ld/Options.html#Options |
| .. _ld64: https://developer.apple.com/library/mac/#documentation/Darwin/Reference/ManPages/Xcode-3.2.5/man1/ld.1.html |
| .. _link.exe: http://msdn.microsoft.com/en-us/library/y0zzbyt4(v=vs.110).aspx |
| .. _Clang's: http://clang.llvm.org/docs/DriverInternals.html |
| |
| Driver Requirements |
| ******************* |
| |
| The following are the different types of arguments that the driver will need to |
| support for compatibility with each linker. |
| |
| link.exe |
| ^^^^^^^^ |
| |
| Output: Default output filename is the name of the first file with .obj on the |
| command line with .exe or .dll appended. Override with /OUT. |
| |
| Options are case insensitive and can begin with - or /. |
| |
| Types of options: |
| |
| * @response_file |
| * {-/}flag |
| * {-/}flag[:number] |
| * {-/}flag[:string] |
| * {-/}flag:string |
| * {-/}flag:string[,[string][,string]] |
| * {-/}flag:string[,number] |
| * {-/}flag:@string,string |
| * {-/}flag:string[,@string[,string]][,string] |
| * {-/}flag:[string\]string |
| * {-/}flag:[string | string=string] |
| * {-/}flag:string,[[!]{DEKPRSW}][,ALIGN=#] |
| |
| When options conflict, the last one wins. |
| |
| ld64 |
| ^^^^ |
| |
| gnuld |
| ^^^^^ |