summary refs log tree commit diff
diff options
context:
space:
mode:
authorVincent Laporte <Vincent.Laporte@gmail.com>2015-02-14 10:29:41 +0100
committerVincent Laporte <Vincent.Laporte@gmail.com>2015-02-16 13:31:13 +0100
commitf31d4b6adb636fac26c259b1161a6f5e912c090a (patch)
tree90f9dd61b2fde3cb2267fed31a0314327f4849e0
parent9c8a89e9f4b92d2eabb7418216965c0a53e69530 (diff)
downloadnixlib-f31d4b6adb636fac26c259b1161a6f5e912c090a.tar
nixlib-f31d4b6adb636fac26c259b1161a6f5e912c090a.tar.gz
nixlib-f31d4b6adb636fac26c259b1161a6f5e912c090a.tar.bz2
nixlib-f31d4b6adb636fac26c259b1161a6f5e912c090a.tar.lz
nixlib-f31d4b6adb636fac26c259b1161a6f5e912c090a.tar.xz
nixlib-f31d4b6adb636fac26c259b1161a6f5e912c090a.tar.zst
nixlib-f31d4b6adb636fac26c259b1161a6f5e912c090a.zip
Adds ocaml-top
OCaml-Top is a simple cross-platform OCaml code editor built for
top-level evaluation.

Homepage: http://www.typerex.org/ocaml-top.html
-rw-r--r--pkgs/development/tools/ocaml/ocaml-top/default.nix31
-rw-r--r--pkgs/top-level/all-packages.nix2
2 files changed, 33 insertions, 0 deletions
diff --git a/pkgs/development/tools/ocaml/ocaml-top/default.nix b/pkgs/development/tools/ocaml/ocaml-top/default.nix
new file mode 100644
index 000000000000..cf0a16cef68d
--- /dev/null
+++ b/pkgs/development/tools/ocaml/ocaml-top/default.nix
@@ -0,0 +1,31 @@
+{ stdenv, fetchzip, ncurses, ocamlPackages, opam }:
+
+stdenv.mkDerivation {
+  name = "ocaml-top-1.1.2";
+  src = fetchzip {
+    url = https://github.com/OCamlPro/ocaml-top/archive/1.1.2.tar.gz;
+    sha256 = "10wfz8d6c1lbh31kayvlb5fj7qmgh5c6xhs3q595dnf9skrf091j";
+  };
+
+  buildInputs = [ ncurses opam ]
+    ++ (with ocamlPackages; [ ocaml ocpBuild findlib lablgtk ocp-index ]);
+
+  configurePhase = ''
+    export TERM=xterm
+    ocp-build -init
+  '';
+
+  buildPhase = "ocp-build ocaml-top";
+
+  installPhase = ''
+    opam-installer --script --prefix=$out ocaml-top.install | sh
+  '';
+
+  meta = {
+    homepage = http://www.typerex.org/ocaml-top.html;
+    license = stdenv.lib.licenses.gpl3;
+    description = "A simple cross-platform OCaml code editor built for top-level evaluation";
+    platforms = ocamlPackages.ocaml.meta.platforms;
+    maintainer = with stdenv.lib.maintainers; [ vbgl ];
+  };
+}
diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix
index 89c6f8318809..19e3eb8b6b9e 100644
--- a/pkgs/top-level/all-packages.nix
+++ b/pkgs/top-level/all-packages.nix
@@ -4077,6 +4077,8 @@ let
 
   ocaml_make = callPackage ../development/ocaml-modules/ocamlmake { };
 
+  ocaml-top = callPackage ../development/tools/ocaml/ocaml-top { };
+
   opa = callPackage ../development/compilers/opa {
     ocamlPackages = ocamlPackages_4_00_1;
   };