From f7ef6329bb21c02342f315201eec0f71e50c0c4c Mon Sep 17 00:00:00 2001 From: Malo Bourgon Date: Fri, 13 May 2022 16:48:49 -0700 Subject: [PATCH] ocamlPackages: add meta.mainProgram to many packages --- pkgs/development/ocaml-modules/atd/default.nix | 3 ++- pkgs/development/ocaml-modules/awa/default.nix | 3 ++- pkgs/development/ocaml-modules/bisect_ppx/default.nix | 3 ++- .../development/ocaml-modules/ca-certs-nss/default.nix | 5 +++-- pkgs/development/ocaml-modules/checkseum/default.nix | 3 ++- pkgs/development/ocaml-modules/coin/default.nix | 3 ++- pkgs/development/ocaml-modules/cpdf/default.nix | 5 +++-- pkgs/development/ocaml-modules/decompress/default.nix | 3 ++- pkgs/development/ocaml-modules/dns/client.nix | 1 + pkgs/development/ocaml-modules/hidapi/default.nix | 3 ++- pkgs/development/ocaml-modules/irmin/pack.nix | 1 + pkgs/development/ocaml-modules/irmin/unix.nix | 1 + pkgs/development/ocaml-modules/janestreet/0.14.nix | 10 ++++++++-- pkgs/development/ocaml-modules/lablgl/default.nix | 3 ++- pkgs/development/ocaml-modules/lambda-term/default.nix | 8 ++++---- pkgs/development/ocaml-modules/letsencrypt/app.nix | 1 + pkgs/development/ocaml-modules/lustre-v6/default.nix | 3 ++- pkgs/development/ocaml-modules/lutils/default.nix | 1 + pkgs/development/ocaml-modules/mrmime/default.nix | 5 +++-- pkgs/development/ocaml-modules/ocaml-lsp/default.nix | 1 + pkgs/development/ocaml-modules/otfm/default.nix | 3 ++- .../ocaml-modules/phylogenetics/default.nix | 5 +++-- pkgs/development/ocaml-modules/tuntap/default.nix | 3 ++- pkgs/development/ocaml-modules/uuuu/default.nix | 5 +++-- pkgs/development/ocaml-modules/vg/default.nix | 3 ++- pkgs/development/ocaml-modules/wayland/default.nix | 3 ++- pkgs/development/ocaml-modules/webbrowser/default.nix | 1 + pkgs/development/ocaml-modules/wodan/unix.nix | 5 ++++- .../tools/ocaml/ocaml-recovery-parser/default.nix | 3 ++- pkgs/development/tools/ocaml/ocamlscript/default.nix | 1 + 30 files changed, 67 insertions(+), 31 deletions(-) diff --git a/pkgs/development/ocaml-modules/atd/default.nix b/pkgs/development/ocaml-modules/atd/default.nix index 5ff5496ed6f..81b9567fcdc 100644 --- a/pkgs/development/ocaml-modules/atd/default.nix +++ b/pkgs/development/ocaml-modules/atd/default.nix @@ -17,9 +17,10 @@ buildDunePackage rec { }; meta = with lib; { - homepage = "https://github.com/mjambon/atd"; description = "Syntax for cross-language type definitions"; + homepage = "https://github.com/mjambon/atd"; license = licenses.mit; maintainers = with maintainers; [ aij jwilberding ]; + mainProgram = "atdcat"; }; } diff --git a/pkgs/development/ocaml-modules/awa/default.nix b/pkgs/development/ocaml-modules/awa/default.nix index d870ab86505..eba150e3402 100644 --- a/pkgs/development/ocaml-modules/awa/default.nix +++ b/pkgs/development/ocaml-modules/awa/default.nix @@ -32,9 +32,10 @@ buildDunePackage rec { meta = with lib; { description = "SSH implementation in OCaml"; - license = licenses.isc; homepage = "https://github.com/mirage/awa-ssh"; changelog = "https://github.com/mirage/awa-ssh/raw/v${version}/CHANGES.md"; + license = licenses.isc; maintainers = [ maintainers.sternenseemann ]; + mainProgram = "awa_lwt_server"; }; } diff --git a/pkgs/development/ocaml-modules/bisect_ppx/default.nix b/pkgs/development/ocaml-modules/bisect_ppx/default.nix index 48b9684902c..fdfc61e73c3 100644 --- a/pkgs/development/ocaml-modules/bisect_ppx/default.nix +++ b/pkgs/development/ocaml-modules/bisect_ppx/default.nix @@ -21,8 +21,9 @@ buildDunePackage rec { meta = with lib; { description = "Bisect_ppx is a code coverage tool for OCaml and Reason. It helps you test thoroughly by showing what's not tested."; - license = licenses.mit; homepage = "https://github.com/aantron/bisect_ppx"; + license = licenses.mit; maintainers = with maintainers; [ ]; + mainProgram = "bisect-ppx-report"; }; } diff --git a/pkgs/development/ocaml-modules/ca-certs-nss/default.nix b/pkgs/development/ocaml-modules/ca-certs-nss/default.nix index 987c325ee00..9c71ca476c9 100644 --- a/pkgs/development/ocaml-modules/ca-certs-nss/default.nix +++ b/pkgs/development/ocaml-modules/ca-certs-nss/default.nix @@ -43,9 +43,10 @@ buildDunePackage rec { checkInputs = [ alcotest ]; meta = with lib; { - license = licenses.isc; description = "X.509 trust anchors extracted from Mozilla's NSS"; - maintainers = [ maintainers.sternenseemann ]; homepage = "https://github.com/mirage/ca-certs-nss"; + license = licenses.isc; + maintainers = [ maintainers.sternenseemann ]; + mainProgram = "extract-from-certdata"; }; } diff --git a/pkgs/development/ocaml-modules/checkseum/default.nix b/pkgs/development/ocaml-modules/checkseum/default.nix index 3a07707a4cd..13d9f2829af 100644 --- a/pkgs/development/ocaml-modules/checkseum/default.nix +++ b/pkgs/development/ocaml-modules/checkseum/default.nix @@ -39,9 +39,10 @@ buildDunePackage rec { doCheck = true; meta = { - homepage = "https://github.com/mirage/checkseum"; description = "ADLER-32 and CRC32C Cyclic Redundancy Check"; + homepage = "https://github.com/mirage/checkseum"; license = lib.licenses.mit; maintainers = [ lib.maintainers.vbgl ]; + mainProgram = "checkseum.checkseum"; }; } diff --git a/pkgs/development/ocaml-modules/coin/default.nix b/pkgs/development/ocaml-modules/coin/default.nix index 0ff2ce94041..5996cd7adb6 100644 --- a/pkgs/development/ocaml-modules/coin/default.nix +++ b/pkgs/development/ocaml-modules/coin/default.nix @@ -30,8 +30,9 @@ buildDunePackage rec { meta = { description = "A library to normalize an KOI8-{U,R} input to Unicode"; - license = lib.licenses.mit; homepage = "https://github.com/mirage/coin"; + license = lib.licenses.mit; maintainers = with lib.maintainers; [ ]; + mainProgram = "coin.generate"; }; } diff --git a/pkgs/development/ocaml-modules/cpdf/default.nix b/pkgs/development/ocaml-modules/cpdf/default.nix index 360848881a9..d9960f732c7 100644 --- a/pkgs/development/ocaml-modules/cpdf/default.nix +++ b/pkgs/development/ocaml-modules/cpdf/default.nix @@ -31,10 +31,11 @@ stdenv.mkDerivation rec { ''; meta = with lib; { - homepage = "https://www.coherentpdf.com/"; - inherit (ocaml.meta) platforms; description = "PDF Command Line Tools"; + homepage = "https://www.coherentpdf.com/"; license = licenses.unfree; maintainers = [ maintainers.vbgl ]; + mainProgram = "cpdf"; + inherit (ocaml.meta) platforms; }; } diff --git a/pkgs/development/ocaml-modules/decompress/default.nix b/pkgs/development/ocaml-modules/decompress/default.nix index 7629349c1d1..f329a0ff013 100644 --- a/pkgs/development/ocaml-modules/decompress/default.nix +++ b/pkgs/development/ocaml-modules/decompress/default.nix @@ -23,8 +23,9 @@ buildDunePackage rec { meta = { description = "Pure OCaml implementation of Zlib"; + homepage = "https://github.com/mirage/decompress"; license = lib.licenses.mit; maintainers = [ lib.maintainers.vbgl ]; - homepage = "https://github.com/mirage/decompress"; + mainProgram = "decompress.pipe"; }; } diff --git a/pkgs/development/ocaml-modules/dns/client.nix b/pkgs/development/ocaml-modules/dns/client.nix index a6dc40de24e..5178360f7b5 100644 --- a/pkgs/development/ocaml-modules/dns/client.nix +++ b/pkgs/development/ocaml-modules/dns/client.nix @@ -16,5 +16,6 @@ buildDunePackage { meta = dns.meta // { description = "Pure DNS resolver API"; + mainProgram = "dns-client.unix"; }; } diff --git a/pkgs/development/ocaml-modules/hidapi/default.nix b/pkgs/development/ocaml-modules/hidapi/default.nix index 44b1d5f150a..b4492f438cc 100644 --- a/pkgs/development/ocaml-modules/hidapi/default.nix +++ b/pkgs/development/ocaml-modules/hidapi/default.nix @@ -24,9 +24,10 @@ buildDunePackage rec { doCheck = true; meta = with lib; { - homepage = "https://github.com/vbmithr/ocaml-hidapi"; description = "Bindings to Signal11's hidapi library"; + homepage = "https://github.com/vbmithr/ocaml-hidapi"; license = licenses.isc; maintainers = [ maintainers.alexfmpe ]; + mainProgram = "ocaml-hid-enumerate"; }; } diff --git a/pkgs/development/ocaml-modules/irmin/pack.nix b/pkgs/development/ocaml-modules/irmin/pack.nix index 5955dda8ed9..12934007cf1 100644 --- a/pkgs/development/ocaml-modules/irmin/pack.nix +++ b/pkgs/development/ocaml-modules/irmin/pack.nix @@ -20,6 +20,7 @@ buildDunePackage rec { meta = irmin.meta // { description = "Irmin backend which stores values in a pack file"; + mainProgram = "irmin_fsck"; }; } diff --git a/pkgs/development/ocaml-modules/irmin/unix.nix b/pkgs/development/ocaml-modules/irmin/unix.nix index 89cf36979bd..2906e77b1b6 100644 --- a/pkgs/development/ocaml-modules/irmin/unix.nix +++ b/pkgs/development/ocaml-modules/irmin/unix.nix @@ -26,6 +26,7 @@ buildDunePackage rec { meta = irmin.meta // { description = "Unix backends for Irmin"; + mainProgram = "irmin"; }; } diff --git a/pkgs/development/ocaml-modules/janestreet/0.14.nix b/pkgs/development/ocaml-modules/janestreet/0.14.nix index cee30da45c9..b9a19f13410 100644 --- a/pkgs/development/ocaml-modules/janestreet/0.14.nix +++ b/pkgs/development/ocaml-modules/janestreet/0.14.nix @@ -405,7 +405,10 @@ with self; pname = "ppx_base"; hash = "1wv3q0qyghm0c5izq03y97lv3czqk116059mg62wx6valn22a000"; minimumOCamlVersion = "4.04.2"; - meta.description = "Base set of ppx rewriters"; + meta = { + description = "Base set of ppx rewriters"; + mainProgram = "ppx-base"; + }; propagatedBuildInputs = [ ppx_cold ppx_enumerate ppx_hash ppx_js_style ]; }; @@ -519,7 +522,10 @@ with self; pname = "ppx_jane"; hash = "1kk238fvrcylymwm7xwc7llbyspmx1y662ypq00vy70g112rir7j"; minimumOCamlVersion = "4.04.2"; - meta.description = "Standard Jane Street ppx rewriters"; + meta = { + description = "Standard Jane Street ppx rewriters"; + mainProgram = "ppx-jane"; + }; propagatedBuildInputs = [ base_quickcheck ppx_bin_prot ppx_expect ppx_fixed_literal ppx_module_timer ppx_optcomp ppx_optional ppx_pipebang ppx_stable ppx_string ppx_typerep_conv ppx_variants_conv ]; }; diff --git a/pkgs/development/ocaml-modules/lablgl/default.nix b/pkgs/development/ocaml-modules/lablgl/default.nix index fa525dbba81..b010272b54b 100644 --- a/pkgs/development/ocaml-modules/lablgl/default.nix +++ b/pkgs/development/ocaml-modules/lablgl/default.nix @@ -39,10 +39,11 @@ stdenv.mkDerivation rec { ''; meta = with lib; { - homepage = "http://wwwfun.kurims.kyoto-u.ac.jp/soft/lsl/lablgl.html"; description = "OpenGL bindings for ocaml"; + homepage = "http://wwwfun.kurims.kyoto-u.ac.jp/soft/lsl/lablgl.html"; license = licenses.gpl2; maintainers = with maintainers; [ pSub vbgl ]; + mainProgram = "lablglut"; broken = stdenv.isDarwin; }; } diff --git a/pkgs/development/ocaml-modules/lambda-term/default.nix b/pkgs/development/ocaml-modules/lambda-term/default.nix index b7ed4f24b1d..e44fdbe3ee8 100644 --- a/pkgs/development/ocaml-modules/lambda-term/default.nix +++ b/pkgs/development/ocaml-modules/lambda-term/default.nix @@ -25,7 +25,8 @@ buildDunePackage rec { propagatedBuildInputs = [ zed lwt_log lwt_react mew_vi ]; - meta = { description = "Terminal manipulation library for OCaml"; + meta = { + description = "Terminal manipulation library for OCaml"; longDescription = '' Lambda-term is a cross-platform library for manipulating the terminal. It provides an abstraction for keys, @@ -43,8 +44,7 @@ buildDunePackage rec { inherit (src.meta) homepage; license = lib.licenses.bsd3; - maintainers = [ - lib.maintainers.gal_bolle - ]; + maintainers = [ lib.maintainers.gal_bolle ]; + mainProgram = "lambda-term-actions"; }; } diff --git a/pkgs/development/ocaml-modules/letsencrypt/app.nix b/pkgs/development/ocaml-modules/letsencrypt/app.nix index de1dbbb8c84..1f6cc6e2b10 100644 --- a/pkgs/development/ocaml-modules/letsencrypt/app.nix +++ b/pkgs/development/ocaml-modules/letsencrypt/app.nix @@ -43,5 +43,6 @@ buildDunePackage { meta = letsencrypt.meta // { description = "An ACME client implementation of the ACME protocol (RFC 8555) for OCaml"; + mainProgram = "oacmel"; }; } diff --git a/pkgs/development/ocaml-modules/lustre-v6/default.nix b/pkgs/development/ocaml-modules/lustre-v6/default.nix index 4eeb01e9f3b..3cc7a25a36a 100644 --- a/pkgs/development/ocaml-modules/lustre-v6/default.nix +++ b/pkgs/development/ocaml-modules/lustre-v6/default.nix @@ -20,9 +20,10 @@ buildDunePackage rec { ]; meta = with lib; { - homepage = "https://www-verimag.imag.fr/lustre-v6.html"; description = "Lustre V6 compiler"; + homepage = "https://www-verimag.imag.fr/lustre-v6.html"; license = lib.licenses.cecill21; maintainers = [ lib.maintainers.delta ]; + mainProgram = "lv6"; }; } diff --git a/pkgs/development/ocaml-modules/lutils/default.nix b/pkgs/development/ocaml-modules/lutils/default.nix index 492a987dc9c..c462eb9fe15 100644 --- a/pkgs/development/ocaml-modules/lutils/default.nix +++ b/pkgs/development/ocaml-modules/lutils/default.nix @@ -21,5 +21,6 @@ buildDunePackage rec { homepage = "https://gricad-gitlab.univ-grenoble-alpes.fr/verimag/synchrone/lutils/"; description = "Tools and libs shared by Verimag/synchronous tools (lustre, lutin, rdbg)"; license = lib.licenses.cecill21; + mainProgram = "gnuplot-rif"; }; } diff --git a/pkgs/development/ocaml-modules/mrmime/default.nix b/pkgs/development/ocaml-modules/mrmime/default.nix index a5c2a68ee47..50cd04ddb0a 100644 --- a/pkgs/development/ocaml-modules/mrmime/default.nix +++ b/pkgs/development/ocaml-modules/mrmime/default.nix @@ -67,8 +67,9 @@ buildDunePackage rec { meta = { description = "Parser and generator of mail in OCaml"; - license = lib.licenses.mit; homepage = "https://github.com/mirage/mrmime"; - maintainers = with lib.maintainers; [ ]; + license = lib.licenses.mit; + maintainers = [ ]; + mainProgram = "mrmime.generate"; }; } diff --git a/pkgs/development/ocaml-modules/ocaml-lsp/default.nix b/pkgs/development/ocaml-modules/ocaml-lsp/default.nix index c1831e660f4..f5b69a3b1e3 100644 --- a/pkgs/development/ocaml-modules/ocaml-lsp/default.nix +++ b/pkgs/development/ocaml-modules/ocaml-lsp/default.nix @@ -17,5 +17,6 @@ buildDunePackage rec { meta = lsp.meta // { description = "OCaml Language Server Protocol implementation"; + mainProgram = "ocamllsp"; }; } diff --git a/pkgs/development/ocaml-modules/otfm/default.nix b/pkgs/development/ocaml-modules/otfm/default.nix index f6717458791..96ef1037cf6 100644 --- a/pkgs/development/ocaml-modules/otfm/default.nix +++ b/pkgs/development/ocaml-modules/otfm/default.nix @@ -34,8 +34,9 @@ stdenv.mkDerivation { of them. ''; homepage = webpage; - inherit (ocaml.meta) platforms; license = licenses.bsd3; maintainers = [ maintainers.jirkamarsik ]; + mainProgram = "otftrip"; + inherit (ocaml.meta) platforms; }; } diff --git a/pkgs/development/ocaml-modules/phylogenetics/default.nix b/pkgs/development/ocaml-modules/phylogenetics/default.nix index 366ad9cc24a..11da66bd760 100644 --- a/pkgs/development/ocaml-modules/phylogenetics/default.nix +++ b/pkgs/development/ocaml-modules/phylogenetics/default.nix @@ -46,9 +46,10 @@ buildDunePackage rec { doCheck = true; meta = with lib; { - homepage = "https://github.com/biocaml/phylogenetics"; description = "Algorithms and datastructures for phylogenetics"; - maintainers = [ maintainers.bcdarwin ]; + homepage = "https://github.com/biocaml/phylogenetics"; license = licenses.cecill-b; + maintainers = [ maintainers.bcdarwin ]; + mainProgram = "phylosim"; }; } diff --git a/pkgs/development/ocaml-modules/tuntap/default.nix b/pkgs/development/ocaml-modules/tuntap/default.nix index 981f05b01e3..2bbf89c6127 100644 --- a/pkgs/development/ocaml-modules/tuntap/default.nix +++ b/pkgs/development/ocaml-modules/tuntap/default.nix @@ -23,7 +23,8 @@ buildDunePackage rec { meta = { description = "Bindings to the UNIX tuntap facility"; - license = lib.licenses.isc; homepage = "https://github.com/mirage/ocaml-tuntap"; + license = lib.licenses.isc; + mainProgram = "otunctl"; }; } diff --git a/pkgs/development/ocaml-modules/uuuu/default.nix b/pkgs/development/ocaml-modules/uuuu/default.nix index d2895ce68e6..59dd7d56896 100644 --- a/pkgs/development/ocaml-modules/uuuu/default.nix +++ b/pkgs/development/ocaml-modules/uuuu/default.nix @@ -32,8 +32,9 @@ buildDunePackage rec { meta = { description = "A library to normalize an ISO-8859 input to Unicode code-point"; - license = lib.licenses.mit; homepage = "https://github.com/mirage/uuuu"; - maintainers = with lib.maintainers; [ ]; + license = lib.licenses.mit; + maintainers = [ ]; + mainProgram = "uuuu.generate"; }; } diff --git a/pkgs/development/ocaml-modules/vg/default.nix b/pkgs/development/ocaml-modules/vg/default.nix index 35a0e51cb09..94ebc1b8d81 100644 --- a/pkgs/development/ocaml-modules/vg/default.nix +++ b/pkgs/development/ocaml-modules/vg/default.nix @@ -57,8 +57,9 @@ stdenv.mkDerivation { module. An API allows to implement new renderers. ''; homepage = webpage; - inherit (ocaml.meta) platforms; license = licenses.isc; maintainers = [ maintainers.jirkamarsik ]; + mainProgram = "vecho"; + inherit (ocaml.meta) platforms; }; } diff --git a/pkgs/development/ocaml-modules/wayland/default.nix b/pkgs/development/ocaml-modules/wayland/default.nix index 7dfb46ce63c..12c385eac72 100644 --- a/pkgs/development/ocaml-modules/wayland/default.nix +++ b/pkgs/development/ocaml-modules/wayland/default.nix @@ -42,8 +42,9 @@ buildDunePackage rec { meta = { description = "Pure OCaml Wayland protocol library"; + homepage = "https://github.com/talex5/ocaml-wayland"; license = lib.licenses.asl20; maintainers = [ lib.maintainers.sternenseemann ]; - homepage = "https://github.com/talex5/ocaml-wayland"; + mainProgram = "wayland-scanner-ocaml"; }; } diff --git a/pkgs/development/ocaml-modules/webbrowser/default.nix b/pkgs/development/ocaml-modules/webbrowser/default.nix index a8adced9388..7ace251e553 100644 --- a/pkgs/development/ocaml-modules/webbrowser/default.nix +++ b/pkgs/development/ocaml-modules/webbrowser/default.nix @@ -23,6 +23,7 @@ stdenv.mkDerivation rec { homepage = "https://erratique.ch/software/webbrowser"; license = lib.licenses.isc; maintainers = [ lib.maintainers.vbgl ]; + mainProgram = "browse"; inherit (ocaml.meta) platforms; }; } diff --git a/pkgs/development/ocaml-modules/wodan/unix.nix b/pkgs/development/ocaml-modules/wodan/unix.nix index 64a18b6b83d..9b9cd841e0f 100644 --- a/pkgs/development/ocaml-modules/wodan/unix.nix +++ b/pkgs/development/ocaml-modules/wodan/unix.nix @@ -22,6 +22,9 @@ buildDunePackage rec { moveToOutput bin "''${!outputBin}" ''; - meta = wodan.meta // { description = "Wodan clients with Unix integration"; }; + meta = wodan.meta // { + description = "Wodan clients with Unix integration"; + mainProgram = "wodanc"; + }; } diff --git a/pkgs/development/tools/ocaml/ocaml-recovery-parser/default.nix b/pkgs/development/tools/ocaml/ocaml-recovery-parser/default.nix index 619d0ded7b3..19ce91574bf 100644 --- a/pkgs/development/tools/ocaml/ocaml-recovery-parser/default.nix +++ b/pkgs/development/tools/ocaml/ocaml-recovery-parser/default.nix @@ -27,9 +27,10 @@ buildDunePackage rec { ]; meta = with lib; { - homepage = "https://github.com/serokell/ocaml-recovery-parser"; description = "A simple fork of OCaml parser with support for error recovery"; + homepage = "https://github.com/serokell/ocaml-recovery-parser"; license = with licenses; [ lgpl2Only mit mpl20 ]; maintainers = with maintainers; [ romildo ]; + mainProgram = "menhir-recover"; }; } diff --git a/pkgs/development/tools/ocaml/ocamlscript/default.nix b/pkgs/development/tools/ocaml/ocamlscript/default.nix index 0b4b748f058..48b7d840a4f 100644 --- a/pkgs/development/tools/ocaml/ocamlscript/default.nix +++ b/pkgs/development/tools/ocaml/ocamlscript/default.nix @@ -29,5 +29,6 @@ stdenv.mkDerivation rec { inherit (ocaml.meta) platforms; description = "Natively-compiled OCaml scripts"; maintainers = [ maintainers.vbgl ]; + mainProgram = "ocamlscript"; }; }