lol
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge pull request #41591 from vbgl/opaline

ocamlPackages: use opaline instead of opam-installer

authored by

xeji and committed by
GitHub
af5b8588 fc643ef9

+47 -92
+3 -8
pkgs/development/ocaml-modules/cmdliner/0.9.nix
··· 1 - { stdenv, fetchurl, ocaml, findlib, ocamlbuild, opam }: 1 + { stdenv, fetchurl, ocaml, findlib, ocamlbuild, opaline }: 2 2 3 3 let 4 4 pname = "cmdliner"; ··· 17 17 }; 18 18 19 19 unpackCmd = "tar xjf $src"; 20 - nativeBuildInputs = [ ocamlbuild opam ]; 20 + nativeBuildInputs = [ ocamlbuild opaline ]; 21 21 buildInputs = [ ocaml findlib ]; 22 22 23 - createFindlibDestdir = true; 24 - 25 23 configurePhase = "ocaml pkg/git.ml"; 26 24 buildPhase = "ocaml pkg/build.ml native=true native-dynlink=true"; 27 - installPhase = '' 28 - opam-installer --script --prefix=$out | sh 29 - ln -s $out/lib/${pname} $out/lib/ocaml/${ocaml.version}/site-lib/ 30 - ''; 25 + installPhase = "opaline -libdir $OCAMLFIND_DESTDIR"; 31 26 32 27 meta = with stdenv.lib; { 33 28 homepage = http://erratique.ch/software/cmdliner;
+3 -3
pkgs/development/ocaml-modules/eliom/default.nix
··· 1 1 { stdenv, fetchurl, which, ocsigen_server, ocsigen_deriving, ocaml, camlp4, 2 2 js_of_ocaml, lwt_react, cryptokit, 3 3 ipaddr, ocamlnet, lwt_ssl, ocaml_pcre, 4 - opam, ppx_tools, ppx_deriving, findlib 4 + opaline, ppx_tools, ppx_deriving, findlib 5 5 , js_of_ocaml-ocamlbuild, js_of_ocaml-ppx, js_of_ocaml-ppx_deriving_json 6 6 , js_of_ocaml-lwt 7 7 , js_of_ocaml-tyxml ··· 22 22 23 23 patches = [ ./camlp4.patch ]; 24 24 25 - buildInputs = [ ocaml which findlib js_of_ocaml-ocamlbuild js_of_ocaml-ppx_deriving_json opam ppx_tools 25 + buildInputs = [ ocaml which findlib js_of_ocaml-ocamlbuild js_of_ocaml-ppx_deriving_json opaline ppx_tools 26 26 ocsigen_deriving 27 27 ]; 28 28 ··· 40 40 ppx_deriving 41 41 ]; 42 42 43 - installPhase = "opam-installer -i --prefix=$out --libdir=$OCAMLFIND_DESTDIR"; 43 + installPhase = "opaline -prefix $out -libdir $OCAMLFIND_DESTDIR"; 44 44 45 45 setupHook = [ ./setup-hook.sh ]; 46 46
+3 -6
pkgs/development/ocaml-modules/gg/default.nix
··· 1 - { stdenv, fetchurl, ocaml, findlib, ocamlbuild, opam }: 1 + { stdenv, fetchurl, ocaml, findlib, ocamlbuild, opaline }: 2 2 3 3 let 4 4 inherit (stdenv.lib) getVersion versionAtLeast; ··· 19 19 sha256 = "0czj41sr8jsivl3z8wyblf9k971j3kx2wc3s0c1nhzcc8allg9i2"; 20 20 }; 21 21 22 - buildInputs = [ ocaml findlib ocamlbuild opam ]; 22 + buildInputs = [ ocaml findlib ocamlbuild opaline ]; 23 23 24 24 createFindlibDestdir = true; 25 25 ··· 27 27 28 28 buildPhase = "ocaml pkg/build.ml native=true native-dynlink=true"; 29 29 30 - installPhase = '' 31 - opam-installer --script --prefix=$out ${pname}.install | sh 32 - ln -s $out/lib/${pname} $out/lib/ocaml/${getVersion ocaml}/site-lib/${pname} 33 - ''; 30 + installPhase = "opaline -libdir $OCAMLFIND_DESTDIR"; 34 31 35 32 meta = with stdenv.lib; { 36 33 description = "Basic types for computer graphics in OCaml";
+3 -11
pkgs/development/ocaml-modules/janestreet/buildOcamlJane.nix
··· 1 - { buildOcaml, opam, js_build_tools, ocaml_oasis, fetchurl } : 1 + { buildOcaml, opaline, js_build_tools, ocaml_oasis, fetchurl } : 2 2 3 3 { name, version ? "113.33.03", buildInputs ? [], 4 4 hash ? "", ··· 14 14 15 15 hasSharedObjects = true; 16 16 17 - buildInputs = [ ocaml_oasis js_build_tools opam ] ++ buildInputs; 17 + buildInputs = [ ocaml_oasis js_build_tools opaline ] ++ buildInputs; 18 18 19 19 dontAddPrefix = true; 20 20 ··· 22 22 23 23 buildPhase = "OCAML_TOPLEVEL_PATH=`ocamlfind query findlib`/.. make"; 24 24 25 - installPhase = '' 26 - opam-installer -i --prefix $prefix --libdir `ocamlfind printconf destdir` --stubsdir `ocamlfind printconf destdir`/${name} ${name}.install 27 - if [ -d $out/lib/${name} ] 28 - then if [ "$(ls -A $out/lib/${name})" ] 29 - then mv $out/lib/${name}/* `ocamlfind printconf destdir`/${name} 30 - fi 31 - rmdir $out/lib/${name} 32 - fi 33 - ''; 25 + installPhase = "opaline -prefix $prefix -libdir $OCAMLFIND_DESTDIR ${name}.install"; 34 26 35 27 })
+3 -3
pkgs/development/ocaml-modules/janestreet/js-build-tools.nix
··· 1 - { stdenv, buildOcaml, fetchurl, ocaml_oasis, opam }: 1 + { stdenv, buildOcaml, fetchurl, ocaml_oasis, opaline }: 2 2 3 3 buildOcaml rec { 4 4 name = "js-build-tools"; ··· 13 13 14 14 hasSharedObjects = true; 15 15 16 - buildInputs = [ ocaml_oasis opam ]; 16 + buildInputs = [ ocaml_oasis opaline ]; 17 17 18 18 dontAddPrefix = true; 19 19 configurePhase = "./configure --prefix $prefix"; 20 - installPhase = "opam-installer -i --prefix $prefix --libdir `ocamlfind printconf destdir` ${name}.install"; 20 + installPhase = "opaline -prefix $prefix -libdir $OCAMLFIND_DESTDIR ${name}.install"; 21 21 22 22 patches = [ ./js-build-tools-darwin.patch ]; 23 23
+1 -4
pkgs/development/ocaml-modules/lambda-term/default.nix
··· 17 17 18 18 buildPhase = "jbuilder build -p lambda-term"; 19 19 20 - installPhase = '' 21 - ${jbuilder.installPhase} 22 - mv $out/lib/ocaml/${ocaml.version}/site-lib/{stubslibs,lambda-term}/dlllambda_term_stubs.so 23 - ''; 20 + inherit (jbuilder) installPhase; 24 21 25 22 hasSharedObjects = true; 26 23
+2 -2
pkgs/development/ocaml-modules/mstruct/default.nix
··· 1 - { stdenv, fetchFromGitHub, ocaml, findlib, jbuilder, opam 1 + { stdenv, fetchFromGitHub, ocaml, findlib, jbuilder 2 2 , cstruct 3 3 }: 4 4 ··· 17 17 sha256 = "1p4ygwzs3n1fj4apfib0z0sabpph21bkq1dgjk4bsa59pq4prncm"; 18 18 }; 19 19 20 - buildInputs = [ ocaml findlib jbuilder opam ]; 20 + buildInputs = [ ocaml findlib jbuilder ]; 21 21 22 22 propagatedBuildInputs = [ cstruct ]; 23 23
+1 -4
pkgs/development/ocaml-modules/nocrypto/default.nix
··· 22 22 ppx_sexp_conv ]; 23 23 propagatedBuildInputs = [ cstruct zarith sexplib ] ++ optional withLwt cstruct-lwt; 24 24 25 - buildPhase = '' 26 - LD_LIBRARY_PATH=${cpuid}/lib/ocaml/${ocaml.version}/site-lib/stubslibs/ \ 27 - ${topkg.buildPhase} --with-lwt ${boolToString withLwt} 28 - ''; 25 + buildPhase = "${topkg.buildPhase} --with-lwt ${boolToString withLwt}"; 29 26 inherit (topkg) installPhase; 30 27 31 28 meta = {
+3 -3
pkgs/development/ocaml-modules/ocsigen-toolkit/default.nix
··· 1 - { stdenv, fetchurl, buildOcaml, ocaml, opam 1 + { stdenv, fetchurl, buildOcaml, ocaml, opaline 2 2 , calendar, eliom, js_of_ocaml-ppx_deriving_json 3 3 }: 4 4 ··· 8 8 version = "1.1.0"; 9 9 10 10 propagatedBuildInputs = [ calendar eliom js_of_ocaml-ppx_deriving_json ]; 11 - buildInputs = [ opam ]; 11 + buildInputs = [ opaline ]; 12 12 13 13 installPhase = 14 14 '' 15 15 export OCAMLPATH=$out/lib/ocaml/${ocaml.version}/site-lib/:$OCAMLPATH 16 16 make install 17 - opam-installer --prefix=$out 17 + opaline -prefix $out 18 18 ''; 19 19 20 20 src = fetchurl {
+3 -6
pkgs/development/ocaml-modules/ppx_import/default.nix
··· 1 - {stdenv, fetchFromGitHub, buildOcaml, ocaml, opam, 1 + {stdenv, fetchFromGitHub, buildOcaml, ocaml, opaline, 2 2 cppo, ppx_tools, ounit, ppx_deriving}: 3 3 4 4 buildOcaml rec { ··· 15 15 sha256 = "14c2lp7r9080c4hsb1y1drbxxx3v44b7ib5wfh3kkh3f1jfsjwbk"; 16 16 }; 17 17 18 - buildInputs = [ cppo ounit ppx_deriving opam ]; 18 + buildInputs = [ cppo ounit ppx_deriving opaline ]; 19 19 20 20 doCheck = true; 21 21 checkTarget = "test"; 22 22 23 - installPhase = '' 24 - opam-installer --script --prefix=$out ppx_import.install | sh 25 - ln -s $out/lib/ppx_import $out/lib/ocaml/${ocaml.version}/site-lib 26 - ''; 23 + installPhase = "opaline -prefix $out -libdir $OCAMLFIND_DESTDIR"; 27 24 28 25 meta = with stdenv.lib; { 29 26 description = "A syntax extension that allows to pull in types or signatures from other compiled interface files";
+3 -3
pkgs/development/ocaml-modules/reactivedata/default.nix
··· 1 - { stdenv, fetchurl, ocaml, findlib, ocamlbuild, react, opam }: 1 + { stdenv, fetchurl, ocaml, findlib, ocamlbuild, react, opaline }: 2 2 3 3 assert stdenv.lib.versionAtLeast ocaml.version "3.11"; 4 4 ··· 9 9 sha256 = "0wcs0z50nia1cpk8mh6i5qbc6sff9cc8x7s7q1q89d7m73bnv4vf"; 10 10 }; 11 11 12 - buildInputs = [ ocaml findlib ocamlbuild opam ]; 12 + buildInputs = [ ocaml findlib ocamlbuild opaline ]; 13 13 propagatedBuildInputs = [ react ]; 14 14 15 15 buildPhase = "ocaml pkg/build.ml native=true native-dynlink=true"; 16 16 17 - installPhase = "opam-installer -i --prefix=$out --libdir=$OCAMLFIND_DESTDIR"; 17 + installPhase = "opaline -prefix $out -libdir $OCAMLFIND_DESTDIR"; 18 18 19 19 meta = with stdenv.lib; { 20 20 description = "An OCaml module for functional reactive programming (FRP) based on React";
+2 -2
pkgs/development/ocaml-modules/topkg/default.nix
··· 5 5 in many cases. When more fine-grained control on how to run the “topkg” 6 6 build system is required, the attribute `run` can be used. 7 7 */ 8 - { stdenv, fetchurl, ocaml, findlib, ocamlbuild, result, opam }: 8 + { stdenv, fetchurl, ocaml, findlib, ocamlbuild, result, opaline }: 9 9 10 10 if !stdenv.lib.versionAtLeast ocaml.version "4.01" 11 11 then throw "topkg is not available for OCaml ${ocaml.version}" ··· 35 35 unpackCmd = "tar xjf ${src}"; 36 36 buildPhase = "${run} build"; 37 37 createFindlibDestdir = true; 38 - installPhase = "${opam}/bin/opam-installer -i --prefix=$out --libdir=$OCAMLFIND_DESTDIR"; 38 + installPhase = "${opaline}/bin/opaline -prefix $out -libdir $OCAMLFIND_DESTDIR"; 39 39 40 40 passthru = { inherit run; }; 41 41
+3 -9
pkgs/development/ocaml-modules/uchar/default.nix
··· 1 - { stdenv, fetchurl, ocaml, ocamlbuild, opam }: 1 + { stdenv, fetchurl, ocaml, findlib, ocamlbuild, opaline }: 2 2 3 3 stdenv.mkDerivation { 4 4 name = "ocaml${ocaml.version}-uchar-0.0.2"; ··· 9 9 }; 10 10 11 11 unpackCmd = "tar xjf $src"; 12 - buildInputs = [ ocaml ocamlbuild opam ]; 12 + buildInputs = [ ocaml ocamlbuild findlib opaline ]; 13 13 buildPhase = "ocaml pkg/build.ml native=true native-dynlink=true"; 14 - installPhase = '' 15 - opam-installer --script --prefix=$out uchar.install > install.sh 16 - sh install.sh 17 - mkdir -p $out/lib/ocaml/${ocaml.version}/site-lib/ 18 - ln -s $out/lib/uchar $out/lib/ocaml/${ocaml.version}/site-lib/ 19 - ''; 20 - 14 + installPhase = "opaline -libdir $OCAMLFIND_DESTDIR"; 21 15 22 16 meta = { 23 17 description = "Compatibility library for OCaml’s Uchar module";
+8 -22
pkgs/development/ocaml-modules/xmlm/default.nix
··· 4 4 webpage = "http://erratique.ch/software/${pname}"; 5 5 in 6 6 7 - assert stdenv.lib.versionAtLeast ocaml.version "3.12"; 8 - 9 - let param = 10 - if stdenv.lib.versionAtLeast ocaml.version "4.02" 11 - then { 12 - version = "1.3.0"; 13 - sha256 = "1rrdxg5kh9zaqmgapy9bhdqyxbbvxxib3bdfg1vhw4rrkp1z0x8n"; 14 - buildInputs = [ topkg ]; 15 - inherit (topkg) buildPhase; 16 - } else { 17 - version = "1.2.0"; 18 - sha256 = "1jywcrwn5z3gkgvicr004cxmdaqfmq8wh72f81jqz56iyn5024nh"; 19 - buildInputs = []; 20 - buildPhase = "./pkg/build true"; 21 - }; 22 - in 7 + if !stdenv.lib.versionAtLeast ocaml.version "4.02" 8 + then throw "xmlm is not available for OCaml ${ocaml.version}" 9 + else 23 10 24 11 stdenv.mkDerivation rec { 25 - name = "ocaml-${pname}-${version}"; 26 - inherit (param) version; 12 + name = "ocaml${ocaml.version}-${pname}-${version}"; 13 + version = "1.3.0"; 27 14 28 15 src = fetchurl { 29 16 url = "${webpage}/releases/${pname}-${version}.tbz"; 30 - inherit (param) sha256; 17 + sha256 = "1rrdxg5kh9zaqmgapy9bhdqyxbbvxxib3bdfg1vhw4rrkp1z0x8n"; 31 18 }; 32 19 33 - buildInputs = [ ocaml findlib ocamlbuild ] ++ param.buildInputs; 20 + buildInputs = [ ocaml findlib ocamlbuild topkg ]; 34 21 35 22 unpackCmd = "tar xjf $src"; 36 23 37 - inherit (param) buildPhase; 38 - inherit (topkg) installPhase; 24 + inherit (topkg) buildPhase installPhase; 39 25 40 26 meta = with stdenv.lib; { 41 27 description = "An OCaml streaming codec to decode and encode the XML data format";
+2 -2
pkgs/development/tools/ocaml/findlib/default.nix
··· 50 50 if test -d "''$1/lib/ocaml/${ocaml.version}/site-lib"; then 51 51 export OCAMLPATH="''${OCAMLPATH}''${OCAMLPATH:+:}''$1/lib/ocaml/${ocaml.version}/site-lib/" 52 52 fi 53 - if test -d "''$1/lib/ocaml/${ocaml.version}/site-lib/stubslibs"; then 54 - export CAML_LD_LIBRARY_PATH="''${CAML_LD_LIBRARY_PATH}''${CAML_LD_LIBRARY_PATH:+:}''$1/lib/ocaml/${ocaml.version}/site-lib/stubslibs" 53 + if test -d "''$1/lib/ocaml/${ocaml.version}/site-lib/stublibs"; then 54 + export CAML_LD_LIBRARY_PATH="''${CAML_LD_LIBRARY_PATH}''${CAML_LD_LIBRARY_PATH:+:}''$1/lib/ocaml/${ocaml.version}/site-lib/stublibs" 55 55 fi 56 56 export OCAMLFIND_DESTDIR="''$out/lib/ocaml/${ocaml.version}/site-lib/" 57 57 if test -n "$createFindlibDestdir"; then
+4 -4
pkgs/development/tools/ocaml/jbuilder/default.nix
··· 1 - { stdenv, fetchFromGitHub, ocaml, opam }: 1 + { stdenv, fetchFromGitHub, ocamlPackages, opaline }: 2 2 3 3 stdenv.mkDerivation rec { 4 4 name = "jbuilder-${version}"; ··· 10 10 sha256 = "0571lzm8caq6wnia7imgy4a27x5l2bvxiflg0jrwwml0ylnii65f"; 11 11 }; 12 12 13 - buildInputs = [ ocaml ]; 13 + buildInputs = with ocamlPackages; [ ocaml findlib ]; 14 14 15 15 dontAddPrefix = true; 16 16 17 - installPhase = "${opam}/bin/opam-installer -i --prefix=$out --libdir=$OCAMLFIND_DESTDIR"; 17 + installPhase = "${opaline}/bin/opaline -prefix $out -libdir $OCAMLFIND_DESTDIR"; 18 18 19 19 preFixup = "rm -rf $out/jbuilder"; 20 20 ··· 23 23 description = "Fast, portable and opinionated build system"; 24 24 maintainers = [ stdenv.lib.maintainers.vbgl ]; 25 25 license = stdenv.lib.licenses.asl20; 26 - inherit (ocaml.meta) platforms; 26 + inherit (ocamlPackages.ocaml.meta) platforms; 27 27 }; 28 28 }