diff options
author | Moritz Angermann <moritz.angermann@gmail.com> | 2019-01-30 09:47:20 +0800 |
---|---|---|
committer | Marge Bot <ben+marge-bot@smart-cactus.org> | 2019-02-28 02:20:05 -0500 |
commit | f838809f1e73c20bc70926fe98e735297572ac60 (patch) | |
tree | 8369ec06977939219970bbc2f2f63814253d1498 /docs | |
parent | 2e8f664957dc3763dc4375894b8dc4d046d2e95b (diff) | |
download | haskell-f838809f1e73c20bc70926fe98e735297572ac60.tar.gz |
Cleanup iserv/iserv-proxy
This adds trace messages that include the processes name and as such
make debugging and following the communication easier.
It also adds a note regarding the fwd*Call proxy-communication logic
between the proxy and the slave.
The proxy will now also poll for 60s to wait for the remote iserv
to come up. (Alternatively you can start the remote process
beforehand; and just have iserv-proxy connect to it)
Diffstat (limited to 'docs')
-rw-r--r-- | docs/users_guide/ghci.rst | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/docs/users_guide/ghci.rst b/docs/users_guide/ghci.rst index 05b64f9340..a9c280a8ec 100644 --- a/docs/users_guide/ghci.rst +++ b/docs/users_guide/ghci.rst @@ -3287,6 +3287,38 @@ dynamically-linked) from GHC itself. So for example: This feature is experimental in GHC 8.0.x, but it may become the default in future releases. +.. _external-interpreter-proxy: + +Running the interpreter on a different host +------------------------------------------- + +When using the flag :ghc-flag:`-fexternal-interpreter` GHC will +spawn and communicate with the separate process using pipes. There +are scenarios (e.g. when cross compiling) where it is favourable to +have the communication happen over the network. GHC provides two +utilities for this, which can be found in the ``utils`` directory. + +- ``remote-iserv`` needs to be built with the cross compiler to be + executed on the remote host. Or in the case of using it on the + same host the stage2 compiler will do as well. + +- ``iserv-proxy`` needs to be built on the build machine by the + build compiler. + +After starting ``remote-iserv ⟨tmp_dir⟩ ⟨port⟩`` on the target and +providing it with a temporary folder (where it will copy the +necessary libraries to load to) and port it will listen for +the proxy to connect. + +Providing :ghc-flag:`-pgmi /path/to/iserv-proxy`, :ghc-flag:`-pgmo ⟨option⟩` +and :ghc-flag:`-pgmo ⟨port⟩` in addition to :ghc-flag:`-fexternal-interpreter` +will then make ghc go through the proxy instead. + +There are some limitations when using this. File and process IO +will be executed on the target. As such packages like git-embed, +file-embed and others might not behave as expected if the target +and host do not share the same filesystem. + .. _ghci-faq: FAQ and Things To Watch Out For |