]> git.lizzy.rs Git - rust.git/commit
msvc: Get codegen-units working
authorAlex Crichton <alex@alexcrichton.com>
Tue, 7 Jul 2015 01:21:57 +0000 (18:21 -0700)
committerAlex Crichton <alex@alexcrichton.com>
Wed, 8 Jul 2015 03:07:20 +0000 (20:07 -0700)
commitd23239b48e2066d3f38eb03e2429427bffade822
tree84500a1b8710ce20e06e86ea4c9b6903ba38458f
parente6a9be10bc1b178dc0b23c505fc8f17e925cabb2
msvc: Get codegen-units working

This commit alters the implementation of multiple codegen units slightly to be
compatible with the MSVC linker. Currently the implementation will take the N
object files created by each codegen unit and will run `ld -r` to create a new
object file which is then passed along. The MSVC linker, however, is not able to
do this operation.

The compiler will now no longer attempt to assemble object files together but
will instead just pass through all the object files as usual. This implies that
rlibs may not contain more than one object file (if the library is compiled with
more than one codegen unit) and the output of `-C save-temps` will have changed
slightly as object files with the extension `0.o` will not be renamed to `o`
unless requested otherwise.
src/librustc_trans/back/link.rs
src/librustc_trans/back/write.rs
src/test/run-make/extra-filename-with-temp-outputs/Makefile