2014-11-20 07:02:45 +00:00
|
|
|
<!--
|
2020-03-09 06:18:30 +00:00
|
|
|
Copyright 2014, General Dynamics C4 Systems
|
2014-11-20 07:02:45 +00:00
|
|
|
|
2020-03-09 06:18:30 +00:00
|
|
|
SPDX-License-Identifier: GPL-2.0-only
|
2014-11-20 07:02:45 +00:00
|
|
|
-->
|
|
|
|
|
|
|
|
The seL4 Haskell Model
|
|
|
|
======================
|
|
|
|
|
|
|
|
The sources in this directory can be used to build a Haskell Cabal package
|
|
|
|
containing an executable model of the seL4 kernel. The model cannot run
|
|
|
|
stand-alone; it must be integrated into a simulator that can run user-level
|
|
|
|
binaries and generate events that the kernel model can process.
|
|
|
|
|
|
|
|
To build it:
|
2017-02-03 00:24:40 +00:00
|
|
|
- install the Haskell build tool [stack][].
|
2015-05-22 05:19:36 +00:00
|
|
|
- run `make`
|
2014-11-20 07:02:45 +00:00
|
|
|
|
2017-02-03 00:24:40 +00:00
|
|
|
The `Makefile` will use `stack` to fetch appropriate versions of `ghc` and
|
|
|
|
`cabal-install`.
|
2014-11-20 07:02:45 +00:00
|
|
|
|
|
|
|
After that, you can compile Haskell programs using the simulator by adding
|
2017-02-03 00:24:40 +00:00
|
|
|
`-package SEL4` to the `ghc` command line. Note that the qemu target requires
|
|
|
|
some callback functions to be accessible via the FFI, so it is not possible to
|
|
|
|
load a model compiled for those targets in GHCi.
|
2014-11-20 07:02:45 +00:00
|
|
|
|
|
|
|
Currently, the simulator interface is out of date, so this model is currently
|
|
|
|
only useful as documentation and as intermediate artefact in the seL4
|
|
|
|
correctness proof. The model itself is kept up to date with the C code, only
|
2015-05-22 05:19:36 +00:00
|
|
|
the simulator interface is outdated.
|
2017-02-03 00:24:40 +00:00
|
|
|
|
|
|
|
[stack]: https://haskellstack.org/
|