The -package flag currently does two things:
- it makes the package avaliable, and
- it eagerly links the package when running under the interpreter.
When compiling a program using Template Haskell this is unnecessarily
expensive when only a small part of the packages is used for evaluating
TH splices.
This introduces a new flag: -link-package that preserves the current
behavior of -package and changes the behavior of -package so that
it only makes the package avaliable and since the interpreter already
implements lazy loading everything still works.
There are still reasons to want the behavior that -link-package provides, like
C library referring to a symbol from a Haskell package.