Clean up the `ProgramRunner` class:
* use llvm-provided wrappers and system-agnostic variables to compute
the `Paths` variable
* pre-compute the list of path variables so it's not re-computed on
every invocation of `run` or `isProgramAvailable`
* Wrap the logging code so that it's not triggered if the logger is
disabled
This commit introduces some changes to how the revng pipeline handles
serializing to disk. Specificaly:
* Pipeline globals (specifically model.yml) are better handled if they
are in a subdirectory. They are now saved in the "context"
subdirectory.
* In python:revng.api the pipeline is serialized whenever there is a
non-reproducible change to the state (e.g. binary upload or model
change).
In the case of analyses this is done conservatively by checking that
the diff produced is not empty.
* The logic for computing a step's subdirectory has been moved to the
pipeline runner, consequently if a step is asked to serialize it
will not create any subdirectories.
* Functionality for saving a single step/context has been exposed in
Pipeline C.
* Finally, all path concatenations are now handled by
llvm::sys::path::append, for extra os-agnosticism.
We used to collect all binaries into the `bin/` directory. However this
led to confusions since certain commands where available both as
`revng-command` and `revng command`.
This commit moves all the executables except `revng` into
`libexec/revng`, which, according to FHS, is dedicated to "internal
binaries that are not intended to be executed directly by users or shell
scripts".
`main` is not in all cases a dynamically exported symbol, therefore,
it's not safe to rely on it.
This commit switches to use `PathList`'s `getCurrentExecutableFullPath`,
which reads `/proc/self/exe`.