Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.
README.md Import hello-java repository. Sep 14, 2017
shell.nix Import hello-java repository. Sep 14, 2017


hello-java: A demo of calling the JVM from Haskell

This directory uses the release version of inline-java (see the stack.yaml).


  • the Stack build tool (version 1.2 or above);
  • either, the Nix package manager,
  • or, OpenJDK installed from your distro.

On OS X, you'll need to install the Legacy Java SE 6 runtime when prompted, even when using Nix.

To build:

$ stack --nix build

This will get Stack to download a JDK in a local sandbox (using Nix) for good build results reproducibility. This is the recommended way to build inline-java. Alternatively, you'll need it installed through your OS distribution's package manager (and you'll need to tell Stack how to find the JVM header files and shared libraries). Drop the --nix argument if you don't whish to use Nix.

To run:

$ stack --nix exec -- hello-java