> On Dec 21, 2016, at 11:11, Joe Groff <jgr...@apple.com> wrote: > > >> On Dec 19, 2016, at 10:23 AM, Jordan Rose via swift-dev >> <swift-dev@swift.org> wrote: >> >> [+swift-dev, swift-build-dev] Once upon a time I think I had the idea that >> swiftc should be useful independent of having a Clang install, but we've >> long since given up on that on Linux and it's not such an interesting >> configuration on Darwin. I don't have strong objections to merging them, >> though there might be some trickiness around picking the right profiling >> libraries (if Swift and Clang are ever out of sync we would ideally prefer >> Swift's). >> >> The other thing floating around here is something Daniel Dunbar once brought >> up: usually each compiler wants to own the linker invocation, but then you >> have a hard time linking object files from multiple compilers using the same >> linker invocation. (Consider linking with clang vs. clang++, and then >> needing to add custom arguments for Swift.) It would be nice⢠if instead a >> build system could ask "what additional linker flags do you need >> before/after your object files?", and put that in as necessary. > > Could something like the autolinking mechanism be used to pull in necessary > runtime object files, such as the swift_begin/end.o stubs, without direct > help from the driver?
I'm not sure, but it's probably very linker-dependent, since we actually need the bracketing. This also applies to non-autolinking things like, say, enabling or disabling dead code stripping, but those flags can usually appear anywhere in the list. Jordan _______________________________________________ swift-dev mailing list swift-dev@swift.org https://lists.swift.org/mailman/listinfo/swift-dev