Mikhail Glushenkov the.dead.shall.rise at gmail.com
Thu Dec 19 03:00:53 UTC 2013


The problem in https://github.com/haskell/cabal/issues/1611 is with
that we have a module (say, A) from which we're only importing a
single value, and this module is a part of the cabal-install source
tree. It would be nice if the whole contents of A weren't linked with
the final executable. So I tried to compile cabal-install with
--split-objs, but apparently this doesn't work because in this case
the linker's input is A.o instead of A_split_0.o A_split_1.o ...
A_split_N.o. And apparently that's why the documentation says that
"--split-objs doesn't make sense for executables".

Note that if cabal-install was split into an executable and a library,
then this would work.

So the question is why --split-objs only works for libraries and
whether this behaviour can be fixed.

()  ascii ribbon campaign - against html e-mail
/\  www.asciiribbon.org   - against proprietary attachments

More information about the Glasgow-haskell-users mailing list