[LLVMdev] Compiling zlib to static bytecode archive
Maarten ter Huurne
maarten at treewalker.org
Wed Sep 26 09:45:13 PDT 2007
On Wednesday 26 September 2007, Chris Lattner wrote:
> > Assuming those steps are correct, step 6 and 7 could be implemented
> > by using
> > the original collect2 and adding the generated native object to the
> > list of
> > files to link. In other words, llvm-collect2 could be a separate
> > process,
> > which is called instead of collect2, does some processing and then
> > runs the
> > original, unmodified collect2:
> > llvm-gcc -> llvm-collect2(liblto) -> collect2 -> ld
>
> Sure, this would also work. Is there any reason not to merge them
> together?
Ease of maintenance, mainly. Having it in a separate file makes it easier to
migrate the code to new GCC releases. Also, collect2.c is already 2658 lines,
which is more than I typically like to have in a single source file.
I'd like to turn the question around: is there an advantage to merging them?
In any case, if I can make it work as a separate process, it shouldn't be hard
to merge it into collect2 later.
Bye,
Maarten
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part.
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20070926/ea8d9762/attachment.sig>
More information about the llvm-dev
mailing list