Merge remote-tracking branch 'origin/master' into staging

Conflicts:
	pkgs/development/libraries/libav/default.nix
	pkgs/shells/bash/bash-4.2-patches.nix
	pkgs/stdenv/generic/default.nix
This commit is contained in:
Eelco Dolstra
2014-10-07 00:09:37 +02:00
1001 changed files with 20043 additions and 5648 deletions
@@ -4,6 +4,9 @@ let
version = "1.0.9";
webpage = "http://mjambon.com/${pname}.html";
in
assert stdenv.lib.versionAtLeast (stdenv.lib.getVersion ocaml) "3.11";
stdenv.mkDerivation rec {
name = "${pname}-${version}";
@@ -23,10 +26,11 @@ stdenv.mkDerivation rec {
mkdir $out/bin
'';
meta = {
meta = with stdenv.lib; {
description = "A binary data format designed for speed, safety, ease of use and backward compatibility as protocols evolve";
homepage = "${webpage}";
license = stdenv.lib.licenses.bsd3;
license = licenses.bsd3;
maintainers = [ maintainers.vbgl ];
platforms = ocaml.meta.platforms;
};
}
@@ -1,4 +1,4 @@
{stdenv, fetchurl, ocaml, findlib}:
{stdenv, fetchurl, ocaml, findlib, camlp4}:
let
ocaml_version = (builtins.parseDrvName ocaml.name).version;
@@ -13,7 +13,7 @@ stdenv.mkDerivation {
sha256 = "0x43pjxx70kgip86mmdn08s97k4qzdqc8i79xfyyx28smy1bsa00";
};
buildInputs = [ocaml findlib];
buildInputs = [ocaml findlib camlp4];
createFindlibDestdir = true;
@@ -1,4 +1,4 @@
{stdenv, fetchurl, ocaml, findlib}:
{stdenv, fetchurl, ocaml, findlib, camlp4}:
let
ocaml_version = (builtins.parseDrvName ocaml.name).version;
@@ -12,7 +12,7 @@ stdenv.mkDerivation {
sha256 = "003ikpvpaliy5hblhckfmln34zqz0mk3y2m1fqvbjngh3h2np045";
};
buildInputs = [ocaml findlib];
buildInputs = [ocaml findlib camlp4];
createFindlibDestdir = true;
@@ -5,6 +5,9 @@ let
version = "0.9.5";
ocaml_version = (builtins.parseDrvName ocaml.name).version;
in
assert stdenv.lib.versionAtLeast ocaml_version "3.12";
stdenv.mkDerivation {
name = "ocaml-${pname}-${version}";
@@ -31,6 +34,7 @@ stdenv.mkDerivation {
homepage = http://erratique.ch/software/cmdliner;
description = "An OCaml module for the declarative definition of command line interfaces";
license = licenses.bsd3;
maintainers = [ maintainers.vbgl ];
platforms = ocaml.meta.platforms;
};
}
@@ -4,6 +4,8 @@ let
ocaml_version = (builtins.parseDrvName ocaml.name).version;
in
assert stdenv.lib.versionAtLeast ocaml_version "3.12";
stdenv.mkDerivation {
name = "cryptokit-1.9";
@@ -1,4 +1,7 @@
{stdenv, fetchurl, ocaml, findlib}:
assert stdenv.lib.versionAtLeast (stdenv.lib.getVersion ocaml) "3.11";
stdenv.mkDerivation {
name = "ocaml-csv-1.3.3";
@@ -18,10 +21,11 @@ stdenv.mkDerivation {
installPhase = "ocaml setup.ml -install";
meta = {
meta = with stdenv.lib; {
description = "A pure OCaml library to read and write CSV files";
homepage = "https://forge.ocamlcore.org/projects/csv/";
license = stdenv.lib.licenses.lgpl21;
license = licenses.lgpl21;
maintainers = [ maintainers.vbgl ];
platforms = ocaml.meta.platforms;
};
}
@@ -17,11 +17,10 @@ stdenv.mkDerivation rec {
createFindlibDestdir = true;
meta = {
meta = with stdenv.lib; {
description = "A high-level and functional interface to the Format module of the OCaml standard library";
homepage = "${webpage}";
license = "bsd";
license = licenses.bsd3;
maintainers = [ maintainers.vbgl ];
};
}
@@ -26,4 +26,25 @@ stdenv.mkDerivation
dontAddPrefix = true;
createFindlibDestdir = true;
meta = {
homepage = http://ocsigen.org/eliom/;
description = "Ocaml Framework for programming Web sites and client/server Web applications";
longDescription =''Eliom is a framework for programming Web sites
and client/server Web applications. It introduces new concepts to
simplify programming common behaviours and uses advanced static
typing features of OCaml to check many properties of the Web site
at compile time. If you want to write a Web application, Eliom
makes possible to write the whole application as a single program
(client and server parts). A syntax extension is used to
distinguish both parts and the client side is compiled to JS using
Ocsigen Js_of_ocaml.'';
license = stdenv.lib.licenses.lgpl21;
platforms = ocaml.meta.platforms;
maintainers = [ stdenv.lib.maintainers.gal_bolle ];
};
}
@@ -1,4 +1,6 @@
{stdenv, fetchurl, ocaml, findlib, minimal ? true}:
{stdenv, fetchurl, ocaml, findlib, camlp4, minimal ? true}:
assert stdenv.lib.versionAtLeast (stdenv.lib.getVersion ocaml) "3.11";
stdenv.mkDerivation {
name = "ocaml-extlib-1.6.1";
@@ -8,7 +10,7 @@ stdenv.mkDerivation {
sha256 = "1jmfj2w0f3ap0swz8k3qqmrl6x2y4gkmg88vv024xnmliiiv7m48";
};
buildInputs = [ocaml findlib];
buildInputs = [ocaml findlib camlp4];
createFindlibDestdir = true;
@@ -0,0 +1,25 @@
{stdenv, fetchurl, ocaml, findlib}:
assert stdenv.lib.versionAtLeast (stdenv.lib.getVersion ocaml) "3.12";
stdenv.mkDerivation {
name = "ocaml-fix-20130611";
src = fetchurl {
url = http://gallium.inria.fr/~fpottier/fix/fix-20130611.tar.gz;
sha256 = "1phlqcs1nb93x9cf0w0hnq2ck4dmn71zm4mxf60w96vb9yb9qzp0";
};
buildInputs = [ ocaml findlib ];
createFindlibDestdir = true;
meta = with stdenv.lib; {
homepage = http://gallium.inria.fr/~fpottier/fix/;
description = "A simple OCaml module for computing the least solution of a system of monotone equations";
license = licenses.cecill-c;
maintainers = [ maintainers.vbgl ];
platforms = ocaml.meta.platforms;
};
}
@@ -0,0 +1,27 @@
{stdenv, fetchurl, ocaml, findlib}:
assert stdenv.lib.versionAtLeast (stdenv.lib.getVersion ocaml) "3.11";
stdenv.mkDerivation {
name = "ocaml-functory-0.5";
src = fetchurl {
url = https://www.lri.fr/~filliatr/functory/download/functory-0.5.tar.gz;
sha256 = "1j17rhifdjv1z262dma148ywg34x0zjn8vczdrnkwajsm4qg1hw3";
};
buildInputs = [ ocaml findlib ];
installTargets = "ocamlfind-install";
createFindlibDestdir = true;
meta = with stdenv.lib; {
homepage = https://www.lri.fr/~filliatr/functory/;
description = "A distributed computing library for Objective Caml which facilitates distributed execution of parallelizable computations in a seamless fashion";
license = licenses.lgpl21;
maintainers = [ maintainers.vbgl ];
platforms = ocaml.meta.platforms;
};
}
@@ -1,4 +1,4 @@
{stdenv, fetchurl, which, ocaml, findlib, camlzip, extlib}:
{stdenv, fetchurl, which, ocaml, findlib, camlzip, extlib, camlp4}:
let
pname = "javalib";
version = "2.3";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
sha256 = "1i8djcanzm250mwilm3jfy37cz0k0x7jbnrz8a5vvdi91kyzh52j";
};
buildInputs = [ which ocaml findlib camlzip extlib ];
buildInputs = [ which ocaml findlib camlp4 ];
patches = [ ./configure.sh.patch ./Makefile.config.example.patch ];
@@ -33,10 +33,11 @@ stdenv.mkDerivation rec {
propagatedBuildInputs = [ camlzip extlib ];
meta = {
meta = with stdenv.lib; {
description = "A library that parses Java .class files into OCaml data structures";
homepage = "${webpage}";
license = stdenv.lib.licenses.lgpl3;
license = licenses.lgpl3;
maintainers = [ maintainers.vbgl ];
platforms = ocaml.meta.platforms;
};
}
@@ -0,0 +1,37 @@
{stdenv, fetchurl, ocaml, findlib, pkgconfig, gtk, libgnomecanvas, libglade, gtksourceview}:
let
ocaml_version = (builtins.parseDrvName ocaml.name).version;
pname = "lablgtk";
version = "2.14.0";
in
stdenv.mkDerivation (rec {
name = "${pname}-${version}";
src = fetchurl {
url = "https://forge.ocamlcore.org/frs/download.php/561/${name}.tar.gz";
sha256 = "1fnh0amm7lwgyjdhmlqgsp62gwlar1140425yc1j6inwmgnsp0a9";
};
buildInputs = [ocaml findlib pkgconfig gtk libgnomecanvas libglade gtksourceview];
configureFlags = "--with-libdir=$(out)/lib/ocaml/${ocaml_version}/site-lib";
buildFlags = "world";
preInstall = ''
mkdir -p $out/lib/ocaml/${ocaml_version}/site-lib
export OCAMLPATH=$out/lib/ocaml/${ocaml_version}/site-lib/:$OCAMLPATH
'';
meta = {
platforms = ocaml.meta.platforms;
maintainers = [
stdenv.lib.maintainers.z77z
stdenv.lib.maintainers.roconnor
];
homepage = http://wwwfun.kurims.kyoto-u.ac.jp/soft/lsl/lablgtk.html;
description = "LablGTK is is an Objective Caml interface to gtk+";
license = stdenv.lib.licenses.lgpl21Plus;
};
})
@@ -1,4 +1,4 @@
{stdenv, fetchurl, ocaml, findlib, pkgconfig, gtk, libgnomecanvas, libglade, gtksourceview}:
{stdenv, fetchurl, ocaml, findlib, pkgconfig, gtk, libgnomecanvas, libglade, gtksourceview, camlp4}:
let
ocaml_version = (builtins.parseDrvName ocaml.name).version;
@@ -6,6 +6,8 @@ let
version = "2.16.0";
in
assert stdenv.lib.versionAtLeast ocaml_version "3.12";
stdenv.mkDerivation (rec {
name = "${pname}-${version}";
src = fetchurl {
@@ -13,7 +15,7 @@ stdenv.mkDerivation (rec {
sha256 = "a0ea9752eb257dadcfc2914408fff339d4c34357802f02c63329dd41b777de2f";
};
buildInputs = [ocaml findlib pkgconfig gtk libgnomecanvas libglade gtksourceview];
buildInputs = [ocaml findlib pkgconfig gtk libgnomecanvas libglade gtksourceview camlp4];
configureFlags = "--with-libdir=$(out)/lib/ocaml/${ocaml_version}/site-lib";
buildFlags = "world";
@@ -1,4 +1,4 @@
{stdenv, fetchurl, automake, ocaml, autoconf, gnum4, pkgconfig, freetype, lablgtk, unzip, cairo, findlib, gdk_pixbuf, glib, gtk, pango }:
{stdenv, fetchurl, automake, ocaml, autoconf, gnum4, pkgconfig, freetype, lablgtk, unzip, cairo, findlib, gdk_pixbuf, glib, gtk, pango }:
let
ocaml_version = (builtins.parseDrvName ocaml.name).version;
@@ -9,21 +9,22 @@ in
stdenv.mkDerivation {
name = "${pname}-${version}";
src = fetchurl {
src = fetchurl {
url = "http://cgit.freedesktop.org/cairo-ocaml/snapshot/cairo-ocaml-${version}.zip";
sha256 = "2d59678e322c331e3f4bc02a77240fce4a0917acb0d3ae75953a6ac62d70a125";
sha256 = "0l4p9bp6kclr570mxma8wafibr1g5fsjj8h10yr4b507g0hmlh0l";
};
patches = [ ./META.patch ];
buildInputs = [ocaml automake gnum4 autoconf unzip pkgconfig findlib freetype lablgtk cairo gdk_pixbuf gtk pango ];
buildInputs = [ ocaml automake gnum4 autoconf unzip pkgconfig
findlib freetype lablgtk cairo gdk_pixbuf gtk pango ];
createFindlibDestdir = true;
preConfigure = ''
aclocal -I support
autoconf
export NIX_CFLAGS_COMPILE="$NIX_CFLAGS_COMPILE `pkg-config --cflags cairo gdk-pixbuf glib gtk+ pango`"
export NIX_CFLAGS_COMPILE="$NIX_CFLAGS_COMPILE `pkg-config --cflags cairo gdk-pixbuf glib gtk+ pango`"
export LABLGTKDIR=${lablgtk}/lib/ocaml/${ocaml_version}/site-lib/lablgtk2
cp ${lablgtk}/lib/ocaml/${ocaml_version}/site-lib/lablgtk2/pango.ml ./src
cp ${lablgtk}/lib/ocaml/${ocaml_version}/site-lib/lablgtk2/gaux.ml ./src
@@ -39,6 +40,6 @@ stdenv.mkDerivation {
homepage = http://cairographics.org/cairo-ocaml;
description = "ocaml bindings for cairo library";
license = stdenv.lib.licenses.gpl2;
# maintainers = [ stdenv.lib.maintainers.roconnor ];
platforms = ocaml.meta.platforms;
};
}
@@ -1,15 +1,23 @@
{ocaml, findlib, stdenv, fetchurl}:
{ocaml, findlib, stdenv, fetchurl, ocaml_sexplib}:
assert stdenv.lib.versionAtLeast (stdenv.lib.getVersion ocaml) "3.12";
stdenv.mkDerivation {
name = "ocaml-ipaddr-2.4.0";
name = "ocaml-ipaddr-2.5.0";
src = fetchurl {
url = https://github.com/mirage/ocaml-ipaddr/archive/2.4.0.tar.gz;
sha256 = "0g7qg35w3vzcg37798rhbx7iia83286md3gj5gdhs1qgizlg56wx";
url = https://github.com/mirage/ocaml-ipaddr/archive/2.5.0.tar.gz;
sha256 = "0zpslxzjs5zdw20j3jaf6fr0w2imnidhrzggmnvwp198r76aq917";
};
buildInputs = [ocaml findlib];
propagatedBuildInputs = [ocaml_sexplib];
createFindlibDestdir = true;
meta = with stdenv.lib; {
description = "An OCaml library for manipulation of IP (and MAC) address representations";
license = licenses.isc;
maintainers = [ maintainers.vbgl ];
platforms = ocaml.meta.platforms;
};
}
@@ -13,7 +13,7 @@ stdenv.mkDerivation {
sha256 = "0bxqxzd5sd7siz57vhzb8bmiz1ddhgdv49gcsmwwfmd16mj4cryi";
};
buildInputs = [ ocaml findlib ocamlPackages.lablgtk ];
buildInputs = [ ocaml findlib ocamlPackages.lablgtk ocamlPackages.camlp4 ];
patches = ./destdir.patch;
@@ -1,63 +0,0 @@
diff -Naur ocamlnet-3.6.3.ori/configure ocamlnet-3.6.3/configure
--- ocamlnet-3.6.3.ori/configure 2013-01-14 00:04:59.000000000 +0000
+++ ocamlnet-3.6.3/configure 2013-06-02 21:33:08.000000000 +0000
@@ -642,59 +642,6 @@
exit 1
fi
- printf "%s" "Checking whether lablgtk2 has GMain.Io.remove... "
- mkdir -p tmp
- cat <<EOF >tmp/gtk.ml
-let _ = GMain.Io.remove;;
-EOF
-
- if ocamlfind ocamlc -package lablgtk2 -c tmp/gtk.ml >/dev/null 2>/dev/null;
- then
- echo "yes"
- else
- echo "no"
- echo "Your version of lablgtk2 is too old!"
- exit 1
- fi
-
- printf "%s" "Checking whether lablgtk2 has GMain.Io.add_watch with list support... "
- mkdir -p tmp
- cat <<'EOF' >tmp/gtk.ml
-open GMain.Io
-let _ = (add_watch : cond:condition list -> callback:(condition list -> bool) -> ?prio:int -> channel -> id);;
-exit 0
-EOF
- # Note: this newer API is never broken in the sense checked below, i.e.
- # such lablgtk2 versions do not exist.
- if ocamlfind ocamlc -package unix,lablgtk2 -linkpkg -o tmp/gtk tmp/gtk.ml >/dev/null 2>/dev/null && tmp/gtk; then
- echo "yes"
- gtk2_io_add_watch_supports_lists="-ppopt -DGTK2_IO_ADD_WATCH_SUPPORTS_LISTS"
- else
- echo "no"
- printf "%s" "Checking whether lablgtk2's GMain.Io.add_watch is broken... "
- mkdir -p tmp
- cat <<'EOF' >tmp/gtk.ml
-GMain.Main.init();;
-let ch = GMain.Io.channel_of_descr (Unix.stdout) in
-let w = GMain.Io.add_watch
- ~cond:`OUT ~callback:(fun () -> true) ch in
-(* add_watch is broken when it just returns Val_unit, and ok when it
- * returns a positive int
- *)
-if (Obj.magic w : int) > 0 then
- exit 0
-else
- exit 1
-EOF
- if ocamlfind ocamlc -package unix,lablgtk2 -linkpkg -o tmp/gtk tmp/gtk.ml >/dev/null 2>/dev/null && tmp/gtk; then
- echo "no"
- else
- echo "yes"
- echo "You should apply the patch-ab-ml_glib.c to lablgtk2 to fix this!"
- exit 1
- fi
- fi
-
for f in Makefile uq_gtk.ml uq_gtk.mli uq_gtk_helper.ml; do
rm -f src/equeue-gtk2/$f
ln -s ../equeue-gtk1/$f src/equeue-gtk2
@@ -5,19 +5,17 @@ let
in
stdenv.mkDerivation {
name = "ocamlnet-3.7.3";
name = "ocamlnet-3.7.6";
src = fetchurl {
url = http://download.camlcity.org/download/ocamlnet-3.7.3.tar.gz;
sha256 = "0s24icyrxkqqai91rgxpf52s1fx70j7p12c8vq9vcmvdhll6kp2d";
url = http://download.camlcity.org/download/ocamlnet-3.7.6.tar.gz;
sha256 = "0z17kxn1cyn1x5wgajw737m9rsjwji823rxdwvv8a5239xd1whji";
};
buildInputs = [ncurses ocaml findlib ocaml_pcre camlzip openssl ocaml_ssl cryptokit];
propagatedbuildInputs = [ncurses ocaml_pcre camlzip openssl ocaml_ssl cryptokit];
patches = [ ./configure.patch ];
createFindlibDestdir = true;
dontAddPrefix = true;
@@ -1,4 +1,4 @@
{stdenv, fetchurl, ocaml, findlib}:
{stdenv, fetchurl, ocaml, findlib, camlp4}:
let
ocaml_version = (builtins.parseDrvName ocaml.name).version;
@@ -12,7 +12,7 @@ stdenv.mkDerivation {
sha256 = "1qw8k2czy0bxhsf25kfpgywhpqmg7bi57rmyhlnmbddmvc61pg76";
};
buildInputs = [ocaml findlib];
buildInputs = [ocaml findlib camlp4];
dontAddPrefix = true;
@@ -0,0 +1,28 @@
{stdenv, fetchurl, ocaml, findlib}:
assert stdenv.lib.versionAtLeast (stdenv.lib.getVersion ocaml) "3.12";
stdenv.mkDerivation {
name = "ocaml-pprint-20140424";
src = fetchurl {
url = http://gallium.inria.fr/~fpottier/pprint/pprint-20140424.tar.gz;
sha256 = "0sc9q89dnyarcg24czyhr6ams0ylqvia3745s6rfwd2nldpygsdk";
};
buildInputs = [ ocaml findlib ];
createFindlibDestdir = true;
dontBuild = true;
installFlags = "-C src";
meta = with stdenv.lib; {
homepage = http://gallium.inria.fr/~fpottier/pprint/;
description = "An OCaml adaptation of Wadlers and Leijens prettier printer";
license = licenses.cecill-c;
maintainers = [ maintainers.vbgl ];
platforms = ocaml.meta.platforms;
};
}
@@ -1,4 +1,7 @@
{stdenv, fetchurl, which, perl, ocaml, findlib, javalib }:
{stdenv, fetchurl, which, perl, ocaml, findlib, javalib, camlp4 }:
assert stdenv.lib.versionAtLeast (stdenv.lib.getVersion ocaml) "3.12";
let
pname = "sawja";
version = "1.5";
@@ -13,7 +16,7 @@ stdenv.mkDerivation rec {
sha256 = "0i8qgqkw9vgj6k2g6npss268ivxdkzx5qj2a52jbd8ih59rn68cm";
};
buildInputs = [ which perl ocaml findlib javalib ];
buildInputs = [ which perl ocaml findlib camlp4 ];
patches = [ ./configure.sh.patch ./Makefile.config.example.patch ];
@@ -26,10 +29,11 @@ stdenv.mkDerivation rec {
propagatedBuildInputs = [ javalib ];
meta = {
meta = with stdenv.lib; {
description = "A library written in OCaml, relying on Javalib to provide a high level representation of Java bytecode programs";
homepage = "${webpage}";
license = stdenv.lib.licenses.gpl3Plus;
license = licenses.gpl3Plus;
maintainers = [ maintainers.vbgl ];
platforms = ocaml.meta.platforms;
};
}
@@ -0,0 +1,29 @@
{stdenv, fetchurl, ocaml, findlib, typeconv, camlp4}:
let
ocaml_version = (builtins.parseDrvName ocaml.name).version;
in
assert stdenv.lib.versionOlder "3.12" ocaml_version;
stdenv.mkDerivation {
name = "ocaml-sexplib-108.08.00";
src = fetchurl {
url = https://ocaml.janestreet.com/ocaml-core/108.08.00/individual/sexplib-108.08.00.tar.gz;
sha256 = "11z1k1d7dbb5m957klgalimpr0r602xp5zkkbgbffib1bphasarg";
};
buildInputs = [ocaml findlib];
propagatedBuildInputs = [typeconv camlp4];
createFindlibDestdir = true;
meta = with stdenv.lib; {
homepage = https://ocaml.janestreet.com/;
description = "Library for serializing OCaml values to and from S-expressions";
license = licenses.asl20;
maintainers = [ maintainers.vbgl ];
platforms = ocaml.meta.platforms;
};
}
@@ -1,22 +1,29 @@
{stdenv, fetchurl, ocaml, findlib, ocaml_typeconv}:
{stdenv, fetchurl, ocaml, findlib, ocaml_typeconv, camlp4}:
let
ocaml_version = (builtins.parseDrvName ocaml.name).version;
in
assert stdenv.lib.versionOlder "4.00" ocaml_version;
stdenv.mkDerivation {
name = "ocaml-sexplib-7.0.5";
name = "ocaml-sexplib-111.25.0";
src = fetchurl {
url = "http://forge.ocamlcore.org/frs/download.php/832/sexplib-7.0.5.tar.gz";
sha256 = "b1022da052254581aae51fb634345920364439f715a2c786abcd0b828c2ce697";
url = https://ocaml.janestreet.com/ocaml-core/111.25.00/individual/sexplib-111.25.00.tar.gz;
sha256 = "0qh0zqp5nakqpmmhh4x7cg03vqj3j2bj4zj0nqdlksai188p9ila";
};
patches = [ ./sexp-3.10-compat.patch ./sexplib-7.0.5-patch-ocamlbuild-ocaml4.patch ];
buildInputs = [ocaml findlib ocaml_typeconv ];
buildInputs = [ocaml findlib];
propagatedBuildInputs = [ocaml_typeconv camlp4];
createFindlibDestdir = true;
meta = {
homepage = "http://forge.ocamlcore.org/projects/sexplib/";
meta = with stdenv.lib; {
homepage = https://ocaml.janestreet.com/;
description = "Library for serializing OCaml values to and from S-expressions";
license = "LGPL";
license = licenses.asl20;
maintainers = [ maintainers.vbgl ];
platforms = ocaml.meta.platforms;
};
}
@@ -1,167 +0,0 @@
diff -ur orig/sexplib-7.0.5/lib/conv.ml sexplib-7.0.5/lib/conv.ml
--- orig/sexplib-7.0.5/lib/conv.ml 2012-03-20 17:41:54.000000000 +0100
+++ sexplib-7.0.5/lib/conv.ml 2012-03-26 20:04:58.128032729 +0200
@@ -665,7 +665,7 @@
| Parse_error pe ->
let ppos =
match pe.parse_state with
- | `Sexp { parse_pos } | `Annot { parse_pos } -> parse_pos
+ | `Sexp { parse_pos = parse_pos } | `Annot { parse_pos = parse_pos } -> parse_pos
in
List [
Atom "Sexplib.Sexp.Parse_error";
diff -ur orig/sexplib-7.0.5/lib/pre_sexp.ml sexplib-7.0.5/lib/pre_sexp.ml
--- orig/sexplib-7.0.5/lib/pre_sexp.ml 2012-03-20 17:41:54.000000000 +0100
+++ sexplib-7.0.5/lib/pre_sexp.ml 2012-03-26 20:04:58.129032741 +0200
@@ -172,13 +172,7 @@
(* Output of S-expressions to file *)
let save_of_output ?perm output_function file sexp =
- let tmp_name, oc =
- let temp_dir =
- if Filename.is_relative file then "."
- else Filename.dir_sep
- in
- Filename.open_temp_file ~temp_dir file "tmp"
- in
+ let tmp_name, oc = Filename.open_temp_file file "tmp" in
try
output_function oc sexp;
close_out oc;
@@ -316,9 +310,9 @@
else if text_char < 0 then fail "text_char < 0"
else if global_offset < 0 then fail "global_offset < 0"
else if buf_pos < 0 then fail "buf_pos < 0"
- else { text_line; text_char; global_offset; buf_pos }
+ else { text_line = text_line; text_char = text_char; global_offset = global_offset; buf_pos = buf_pos }
- let with_buf_pos t buf_pos = { t with buf_pos }
+ let with_buf_pos t buf_pos = { t with buf_pos = buf_pos }
end
type ('a, 't) parse_result =
@@ -347,11 +341,11 @@
exception Parse_error of parse_error
-let bump_text_line { parse_pos } =
+let bump_text_line { parse_pos = parse_pos } =
parse_pos.Parse_pos.text_line <- parse_pos.Parse_pos.text_line + 1;
parse_pos.Parse_pos.text_char <- 0
-let bump_text_pos { parse_pos } =
+let bump_text_pos { parse_pos = parse_pos } =
parse_pos.Parse_pos.text_char <- parse_pos.Parse_pos.text_char + 1
let bump_pos_cont state str ~max_pos ~pos cont =
@@ -378,18 +372,18 @@
parse_pos.Parse_pos.buf_pos <- buf_pos;
parse_pos.Parse_pos.global_offset <- parse_pos.Parse_pos.global_offset + len
-let mk_parse_pos { parse_pos } buf_pos =
+let mk_parse_pos { parse_pos = parse_pos } buf_pos =
set_parse_pos parse_pos buf_pos;
parse_pos
let raise_parse_error parse_state location buf_pos err_msg =
begin
match parse_state with
- | `Sexp { parse_pos } | `Annot { parse_pos } ->
+ | `Sexp { parse_pos = parse_pos } | `Annot { parse_pos = parse_pos } ->
set_parse_pos parse_pos buf_pos;
parse_pos.Parse_pos.text_char <- parse_pos.Parse_pos.text_char + 1;
end;
- let parse_error = { location; err_msg; parse_state } in
+ let parse_error = { location = location; err_msg = err_msg; parse_state = parse_state } in
raise (Parse_error parse_error)
let raise_unexpected_char parse_state location buf_pos c =
@@ -657,7 +651,7 @@
let max_pos = check_str_bounds "parse" ~pos ~len str in \
let state = \
{ \
- parse_pos; \
+ parse_pos = parse_pos; \
pstack = INIT_PSTACK; \
pbuf = Buffer.create 128; \
} \
@@ -681,20 +675,20 @@
let mk_annot_pos
({ Parse_pos.text_line = line; text_char = col } as parse_pos) pos =
- { Annot.line; col; offset = get_glob_ofs parse_pos pos }
+ { Annot.line = line; col = col; offset = get_glob_ofs parse_pos pos }
let mk_annot_pos1
({ Parse_pos.text_line = line; text_char = col } as parse_pos) pos =
- { Annot.line; col = col + 1; offset = get_glob_ofs parse_pos pos }
+ { Annot.line = line; col = col + 1; offset = get_glob_ofs parse_pos pos }
-let add_annot_pos { parse_pos; pstack } pos =
+let add_annot_pos { parse_pos = parse_pos; pstack = pstack } pos =
pstack.Annot.positions <- mk_annot_pos parse_pos pos :: pstack.Annot.positions
-let add_annot_pos1 { parse_pos; pstack } pos =
+let add_annot_pos1 { parse_pos = parse_pos; pstack = pstack } pos =
pstack.Annot.positions <-
mk_annot_pos1 parse_pos pos :: pstack.Annot.positions
-let get_annot_range { parse_pos; pstack } pos =
+let get_annot_range { parse_pos = parse_pos; pstack = pstack } pos =
let start_pos =
match pstack.Annot.positions with
| [] -> assert false (* impossible *)
@@ -708,7 +702,7 @@
offset = get_glob_ofs parse_pos pos;
}
in
- { Annot.start_pos; end_pos }
+ { Annot.start_pos = start_pos; end_pos = end_pos }
let mk_annot_atom parse_state str pos =
Annot.Atom (get_annot_range parse_state pos, Atom str)
@@ -780,7 +774,7 @@
let rec loop this_parse ~pos ~len ~is_incomplete =
if len > 0 then
match this_parse ~pos ~len buf with
- | Done (sexp, ({ Parse_pos.buf_pos } as parse_pos)) ->
+ | Done (sexp, ({ Parse_pos.buf_pos = buf_pos } as parse_pos)) ->
rev_sexps_ref := sexp :: !rev_sexps_ref;
let n_parsed = buf_pos - pos in
let this_parse = mk_this_parse ~parse_pos my_parse in
@@ -813,7 +807,7 @@
let of_string_bigstring loc this_parse ws_buf get_len get_sub str =
match this_parse str with
- | Done (_, { Parse_pos.buf_pos }) when buf_pos <> get_len str ->
+ | Done (_, { Parse_pos.buf_pos = buf_pos }) when buf_pos <> get_len str ->
let prefix_len = min (get_len str - buf_pos) 20 in
let prefix = get_sub str buf_pos prefix_len in
let msg =
@@ -874,7 +868,7 @@
failwith (sprintf "Sexplib.Sexp.gen_load_sexp: end of file: %s" file)
else
match this_parse ~pos:0 ~len buf with
- | Done (sexp, ({ Parse_pos.buf_pos } as parse_pos))
+ | Done (sexp, ({ Parse_pos.buf_pos = buf_pos } as parse_pos))
when strict ->
let rec strict_loop this_parse ~pos ~len =
match this_parse ~pos ~len buf with
@@ -938,7 +932,7 @@
let get_conv_exn ~file ~exc annot_sexp =
let range = get_range annot_sexp in
- let { start_pos = { line; col } } = range in
+ let { start_pos = { line = line; col = col } } = range in
let loc = sprintf "%s:%d:%d" file line col in
Of_sexp_error (Annot.Conv_exn (loc, exc), get_sexp annot_sexp)
end
@@ -1003,7 +997,7 @@
let sexp = of_string str in
try f sexp
with Of_sexp_error (exc, sub_sexp) ->
- raise (Of_string_conv_exn.E { Of_string_conv_exn.exc; sexp; sub_sexp })
+ raise (Of_string_conv_exn.E { Of_string_conv_exn.exc = exc; sexp = sexp; sub_sexp = sub_sexp })
let of_string_conv_exn str f = gen_of_string_conv_exn of_string str f
let of_bigstring_conv_exn bstr f = gen_of_string_conv_exn of_bigstring bstr f
@@ -1,29 +0,0 @@
Patch from the fedora repository.
--- sexplib-7.0.5.old/myocamlbuild.ml 2012-03-20 16:41:54.000000000 +0000
+++ sexplib-7.0.5/myocamlbuild.ml 2012-07-30 11:38:21.829869635 +0100
@@ -438,7 +438,13 @@
BaseEnvLight.var_choose cond_specs env
in
flag tags & spec)
- t.flags
+ t.flags;
+
+ flag ["ocaml"; "compile"; "byte"; "use_toploop"] (S[A"-I"; A"+compiler-libs"]);
+ flag ["ocaml"; "link"; "byte"; "use_toploop"] (S[A"-I"; A"+compiler-libs"; A"+compiler-libs/ocamltoplevel.cma"]);
+ flag ["ocaml"; "compile"; "native"; "use_toploop"] (S[A"-I"; A"+compiler-libs"]);
+ flag ["ocaml"; "link"; "native"; "use_toploop"] (S[A"-I"; A"+compiler-libs"; A"+compiler-libs/ocamltoplevel.cmxa"]);
+
| _ ->
()
--- sexplib-7.0.5.old/_tags 2012-03-20 16:41:54.000000000 +0000
+++ sexplib-7.0.5/_tags 2012-07-30 11:37:01.749255839 +0100
@@ -49,6 +49,7 @@
<lib_test/*.ml{,i}>: pkg_camlp4.extend
# Library sexplib_top
"top": include
+<top/*.ml{,i}>: use_toploop
# Executable sexp_test
"lib_test/sexp_test.byte": use_sexplib
"lib_test/sexp_test.byte": pkg_unix
@@ -1,5 +1,7 @@
{stdenv, fetchurl, ocaml, findlib, twt, ocaml_sqlite3 }:
assert stdenv.lib.versionAtLeast (stdenv.lib.getVersion ocaml) "3.12";
stdenv.mkDerivation {
name = "ocaml-sqlite3EZ-0.1.0";
@@ -14,10 +16,11 @@ stdenv.mkDerivation {
createFindlibDestdir = true;
meta = {
meta = with stdenv.lib; {
homepage = http://github.com/mlin/ocaml-sqlite3EZ;
description = "A thin wrapper for sqlite3-ocaml with a simplified interface";
license = stdenv.lib.licenses.mit;
license = licenses.mit;
maintainers = [ maintainers.vbgl ];
platforms = ocaml.meta.platforms;
};
}
@@ -20,10 +20,11 @@ stdenv.mkDerivation {
installFlags = "PREFIX=$(out)";
meta = {
meta = with stdenv.lib; {
homepage = http://people.csail.mit.edu/mikelin/ocaml+twt/;
description = "The Whitespace Thing for OCaml";
license = stdenv.lib.licenses.mit;
license = licenses.mit;
maintainers = [ maintainers.vbgl ];
platforms = ocaml.meta.platforms;
};
}
@@ -0,0 +1,28 @@
{stdenv, fetchurl, ocaml, findlib, camlp4}:
let
ocaml_version = (builtins.parseDrvName ocaml.name).version;
in
assert stdenv.lib.versionOlder "3.12" ocaml_version;
stdenv.mkDerivation {
name = "ocaml-typeconv-108.08.00";
src = fetchurl {
url = https://ocaml.janestreet.com/ocaml-core/108.08.00/individual/type_conv-108.08.00.tar.gz;
sha256 = "08ysikwwp69zvc147lzzg79nwlrzrk738rj0ggcfadi8h5il42sl";
};
buildInputs = [ocaml findlib camlp4];
createFindlibDestdir = true;
meta = with stdenv.lib; {
homepage = https://ocaml.janestreet.com/;
description = "Support library for OCaml preprocessor type conversions";
#license = licenses.apl20; invalid license
platforms = ocaml.meta.platforms;
maintainers = with maintainers; [ z77z ];
};
}
@@ -1,23 +0,0 @@
{stdenv, fetchurl, ocaml, findlib}:
# note: works only with ocaml >3.12
stdenv.mkDerivation {
name = "ocaml-typeconv-3.0.5";
src = fetchurl {
url = "http://forge.ocamlcore.org/frs/download.php/821/type_conv-3.0.5.tar.gz";
sha256 = "90ac6c401a600a23012a3f513def6f67d4979b11bd551f4d0af78f0f0b479198";
};
buildInputs = [ocaml findlib ];
createFindlibDestdir = true;
meta = {
homepage = "http://forge.ocamlcore.org/projects/type-conv/";
description = "Support library for OCaml preprocessor type conversions";
license = "LGPL";
platforms = ocaml.meta.platforms;
};
}
@@ -1,4 +1,10 @@
{stdenv, fetchurl, ocaml, findlib}:
{stdenv, fetchurl, ocaml, findlib, camlp4}:
let
ocaml_version = (builtins.parseDrvName ocaml.name).version;
in
assert stdenv.lib.versionOlder "4.00" ocaml_version;
stdenv.mkDerivation {
name = "ocaml-typeconv-109.60.01";
@@ -8,7 +14,7 @@ stdenv.mkDerivation {
sha256 = "0lpxri68glgq1z2pp02rp45cb909xywbff8d4idljrf6fzzil2zx";
};
buildInputs = [ocaml findlib ];
buildInputs = [ocaml findlib camlp4];
createFindlibDestdir = true;
@@ -1,29 +1,24 @@
{stdenv, fetchurl, ocaml, findlib, ocaml_oasis}:
{stdenv, fetchurl, ocaml, findlib, ocaml_oasis, camlp4}:
stdenv.mkDerivation {
name = "tyxml-3.0.0";
name = "tyxml-3.1.1";
src = fetchurl {
url = http://ocsigen.org/download/tyxml-3.0.0.tar.gz;
sha256 = "0cvbmyg4g0lg4f23032cjlxqklisccbjgj47117wm6gva8xi7xa3";
url = http://github.com/ocsigen/tyxml/archive/3.1.1.tar.gz;
sha256 = "1r8im382r68kn8qy0857nv3y7h42i6ajyclxzmigfai7v2xdd05z";
};
buildInputs = [ocaml findlib ocaml_oasis];
buildInputs = [ocaml findlib ocaml_oasis camlp4];
createFindlibDestdir = true;
configurePhase = ''
make setup-dev.exe
./setup-dev.exe -configure --prefix $out
'';
meta = {
meta = with stdenv.lib; {
homepage = http://ocsigen.org/tyxml/;
description = "A library that makes it almost impossible for your OCaml programs to generate wrong XML ouput, using static typing";
license = "LGPL";
license = licenses.lgpl21;
platforms = ocaml.meta.platforms;
maintainers = [
stdenv.lib.maintainers.gal_bolle
maintainers = with maintainers; [
gal_bolle vbgl
];
};
@@ -30,10 +30,11 @@ stdenv.mkDerivation rec {
propagatedBuildInputs = [ xmlm ];
meta = {
meta = with stdenv.lib; {
description = "An OCaml module to decode the data of the Unicode character database from its XML representation";
homepage = "${webpage}";
platforms = ocaml.meta.platforms;
license = stdenv.lib.licenses.bsd3;
maintainers = [ maintainers.vbgl ];
license = licenses.bsd3;
};
}
@@ -5,6 +5,9 @@ let
webpage = "http://erratique.ch/software/${pname}";
ocaml_version = (builtins.parseDrvName ocaml.name).version;
in
assert stdenv.lib.versionAtLeast ocaml_version "3.12";
stdenv.mkDerivation rec {
name = "ocaml-${pname}-${version}";
@@ -28,10 +31,11 @@ stdenv.mkDerivation rec {
ln -s $out/lib/${pname} $out/lib/ocaml/${ocaml_version}/site-lib/
'';
meta = {
meta = with stdenv.lib; {
description = "An OCaml module for normalizing Unicode text";
homepage = "${webpage}";
platforms = ocaml.meta.platforms;
license = stdenv.lib.licenses.bsd3;
license = licenses.bsd3;
maintainers = [ maintainers.vbgl ];
};
}
@@ -5,6 +5,9 @@ let
webpage = "http://erratique.ch/software/${pname}";
ocaml_version = (builtins.parseDrvName ocaml.name).version;
in
assert stdenv.lib.versionAtLeast ocaml_version "3.12";
stdenv.mkDerivation rec {
name = "ocaml-${pname}-${version}";
@@ -28,10 +31,11 @@ stdenv.mkDerivation rec {
ln -s $out/lib/${pname} $out/lib/ocaml/${ocaml_version}/site-lib/
'';
meta = {
meta = with stdenv.lib; {
description = "Non-blocking streaming Unicode codec for OCaml";
homepage = "${webpage}";
platforms = ocaml.meta.platforms;
license = stdenv.lib.licenses.bsd3;
license = licenses.bsd3;
maintainers = [ maintainers.vbgl ];
};
}
@@ -5,6 +5,9 @@ let
webpage = "http://erratique.ch/software/${pname}";
ocaml_version = (builtins.parseDrvName ocaml.name).version;
in
assert stdenv.lib.versionAtLeast ocaml_version "3.12";
stdenv.mkDerivation rec {
name = "ocaml-${pname}-${version}";
@@ -28,10 +31,11 @@ stdenv.mkDerivation rec {
ln -s $out/lib/${pname} $out/lib/ocaml/${ocaml_version}/site-lib/
'';
meta = {
meta = with stdenv.lib; {
description = "An OCaml streaming codec to decode and encode the XML data format";
homepage = "${webpage}";
platforms = ocaml.meta.platforms;
license = stdenv.lib.licenses.bsd3;
maintainers = [ maintainers.vbgl ];
license = licenses.bsd3;
};
}
@@ -25,10 +25,11 @@ stdenv.mkDerivation {
mkdir $out/bin
'';
meta = {
meta = with stdenv.lib; {
description = "An optimized parsing and printing library for the JSON format";
homepage = "${webpage}";
license = stdenv.lib.licenses.bsd3;
license = licenses.bsd3;
maintainers = [ maintainers.vbgl ];
platforms = ocaml.meta.platforms;
};
}