BUILDING ======== cabal configure cabal build llvm-as lib/main.ll gcc -c lib/fold.c --std=c99 -o lib/fold.o ln -s dist/build/lambdapic/lambdapic lambdapic Ideally I'd use a custom Setup.hs file that would build everything, but invoking the build system programmatically is giving me errors I don't get with the standalone cabal tool. Also, note that you'll get a number of "atom sorting errors" from the cabal build. These come from the LLVM bindings, and Lennart claims they are harmless. RUNNING ======= The executable is built as ./dist/build/lambdapic/lambdapic and takes the source file as an argument. It produces an executable with the source file's base name. Options to the compiler are: --libdir DIR (library directory, containing external primitive functions, default is ./lib) -- prelude FILE (include a source file of standard definitions, default is none some examples use Prelude.lp) --output FILE (path to output file; used by the test script) --fast-math (replace calls to "plus" and "mult" with native operators; off by default) So for examples, we could compile the arithmetic example using: cd examples/ ../lambdapic math.lp --lib ../lib --fast-math We could then view the intermediate code using llvm-dis: llvm-dis math.bc -o - TESTING ======= runhaskell Test Runs several test cases in tests/. More tests would be nice, but could get slow since we're compiling the Prelude each time.