Merge pull request #267817 from dali99/update_liquidsoap

liquidsoap: 2.1.4 -> 2.2.2, update dependencies, clean up
This commit is contained in:
Vincent Laporte 2023-11-16 16:30:08 +01:00 committed by GitHub
commit 8a20dfad5a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
14 changed files with 105 additions and 44 deletions

View File

@ -2,19 +2,21 @@
buildDunePackage rec {
pname = "cry";
version = "0.6.7";
version = "1.0.1";
src = fetchFromGitHub {
owner = "savonet";
repo = "ocaml-cry";
rev = "v${version}";
sha256 = "sha256-1Omp3LBKGTPVwEBd530H0Djn3xiEjOHLqso6S8yIJSQ=";
sha256 = "sha256-wn9hLqbydzFTdYsJ1e76dmDLtwcZ7CGjbzFe5o9veYQ=";
};
postPatch = ''
substituteInPlace src/dune --replace bytes ""
'';
minimalOCamlVersion = "4.12";
meta = with lib; {
homepage = "https://github.com/savonet/ocaml-cry";
description = "OCaml client for the various icecast & shoutcast source protocols";

View File

@ -1,15 +1,13 @@
{ lib, fetchFromGitHub }:
rec {
version = "1.1.7";
duneVersion = "3";
version = "1.1.8";
src = fetchFromGitHub {
owner = "savonet";
repo = "ocaml-ffmpeg";
rev = "v${version}";
sha256 = "sha256-0QDy0ZUAtojYIuNliiDV2uywBnWxtKUhZ/LPqkfSOZ4=";
sha256 = "sha256-XqZATaxpW0lEdrRTXVTc0laQAx437+eoa/zOzZV1kHk=";
};
meta = with lib; {

View File

@ -14,7 +14,7 @@ buildDunePackage {
minimalOCamlVersion = "4.08";
inherit (ffmpeg-base) version src duneVersion;
inherit (ffmpeg-base) version src;
propagatedBuildInputs = [
ffmpeg-avutil

View File

@ -11,7 +11,7 @@ buildDunePackage {
minimalOCamlVersion = "4.08";
inherit (ffmpeg-base) version src duneVersion;
inherit (ffmpeg-base) version src;
nativeBuildInputs = [ pkg-config ];
buildInputs = [ dune-configurator ] ++ lib.optionals stdenv.isDarwin [ AudioToolbox VideoToolbox ];

View File

@ -11,7 +11,7 @@ buildDunePackage {
minimalOCamlVersion = "4.08";
inherit (ffmpeg-base) version src duneVersion;
inherit (ffmpeg-base) version src;
nativeBuildInputs = [ pkg-config ];
buildInputs = [ dune-configurator ]

View File

@ -17,7 +17,7 @@ buildDunePackage {
minimalOCamlVersion = "4.08";
inherit (ffmpeg-base) version src duneVersion;
inherit (ffmpeg-base) version src;
nativeBuildInputs = [ pkg-config ];
buildInputs = [ dune-configurator ]

View File

@ -13,7 +13,7 @@ buildDunePackage {
minimalOCamlVersion = "4.08";
inherit (ffmpeg-base) version src duneVersion;
inherit (ffmpeg-base) version src;
nativeBuildInputs = [ pkg-config ];
buildInputs = [ dune-configurator ]

View File

@ -9,7 +9,7 @@ buildDunePackage {
minimalOCamlVersion = "4.08";
inherit (ffmpeg-base) version src duneVersion;
inherit (ffmpeg-base) version src;
nativeBuildInputs = [ pkg-config ];
buildInputs = [ dune-configurator ] ++ lib.optionals stdenv.isDarwin [ AudioToolbox VideoToolbox ];

View File

@ -10,7 +10,7 @@ buildDunePackage {
minimalOCamlVersion = "4.08";
inherit (ffmpeg-base) version src duneVersion;
inherit (ffmpeg-base) version src;
nativeBuildInputs = [ pkg-config ];
buildInputs = [ dune-configurator ] ++ lib.optionals stdenv.isDarwin [ VideoToolbox ];

View File

@ -10,7 +10,7 @@ buildDunePackage {
minimalOCamlVersion = "4.08";
inherit (ffmpeg-base) version src duneVersion;
inherit (ffmpeg-base) version src;
nativeBuildInputs = [ pkg-config ];
buildInputs = [ dune-configurator ] ++ lib.optionals stdenv.isDarwin [ VideoToolbox ];

View File

@ -2,13 +2,13 @@
buildDunePackage rec {
pname = "flac";
version = "0.3.1";
version = "0.5.0";
src = fetchFromGitHub {
owner = "savonet";
repo = "ocaml-flac";
rev = "v${version}";
sha256 = "sha256-oMmxZtphEX/OPfyTumjkWQJidAjSRqriygaTjVJTCG0=";
sha256 = "sha256-HRRQd//e6Eh2HuyO+U00ILu5FoBT9jf/nRJzDOie70A=";
};
nativeBuildInputs = [ pkg-config ];

View File

@ -0,0 +1,22 @@
{ lib, buildDunePackage, fetchFromGitHub, dune-configurator, pkg-config, ogg, flac }:
buildDunePackage rec {
pname = "metadata";
version = "0.2.0";
src = fetchFromGitHub {
owner = "savonet";
repo = "ocaml-metadata";
rev = "v${version}";
sha256 = "sha256-sSekkyJ8D6mCCmxIyd+pBk/khaehA3BcpUQl2Gln+Ic=";
};
minimalOCamlVersion = "4.14";
meta = with lib; {
homepage = "https://github.com/savonet/ocaml-metadata";
description = "Library to read metadata from files in various formats. ";
license = licenses.gpl3Plus;
maintainers = with maintainers; [ dandellion ];
};
}

View File

@ -1,35 +1,68 @@
{ lib, stdenv, makeWrapper, fetchurl, which, pkg-config
{ lib, stdenv, makeWrapper, fetchFromGitHub, which, pkg-config
, libjpeg
, ocamlPackages
, awscli2, curl, ffmpeg, youtube-dl
, runtimePackages ? [ awscli2 curl ffmpeg youtube-dl ]
, awscli2, bubblewrap, curl, ffmpeg, yt-dlp
, runtimePackages ? [ awscli2 bubblewrap curl ffmpeg yt-dlp ]
}:
let
pname = "liquidsoap";
version = "2.1.4";
version = "2.2.2";
in
stdenv.mkDerivation {
inherit pname version;
src = fetchurl {
url = "https://github.com/savonet/${pname}/releases/download/v${version}/${pname}-${version}.tar.bz2";
sha256 = "sha256-GQuG7f9U+/HqPcuj6hnBoH5mWEhxSwWgBnkCuLqHTAc=";
src = fetchFromGitHub {
owner = "savonet";
repo = "liquidsoap";
rev = "refs/tags/v${version}";
hash = "sha256-t7rkWHSAd3DaTCXaGfL9NcIQYT+f4Od9D6huuZlwhWk=";
};
postFixup = ''
postPatch = ''
substituteInPlace src/lang/dune \
--replace "(run git rev-parse --short HEAD)" "(run echo -n nixpkgs)"
'';
dontConfigure = true;
buildPhase = ''
runHook preBuild
dune build
runHook postBuild
'';
installPhase = ''
runHook preInstall
dune install --prefix "$out"
runHook postInstall
'';
fixupPhase = ''
runHook preFixup
wrapProgram $out/bin/liquidsoap \
--set LIQ_LADSPA_PATH /run/current-system/sw/lib/ladspa \
--prefix PATH : ${lib.makeBinPath runtimePackages}
'';
runHook postFixup
'';
strictDeps = true;
nativeBuildInputs =
[ makeWrapper pkg-config which
ocamlPackages.ocaml ocamlPackages.findlib ocamlPackages.menhir
];
nativeBuildInputs = [
makeWrapper
pkg-config
which
ocamlPackages.ocaml
ocamlPackages.dune_3
ocamlPackages.findlib
ocamlPackages.menhir
];
buildInputs = [
libjpeg
@ -38,29 +71,36 @@ stdenv.mkDerivation {
ocamlPackages.dtools
ocamlPackages.duppy
ocamlPackages.mm
ocamlPackages.ocaml_pcre
ocamlPackages.menhir ocamlPackages.menhirLib
(ocamlPackages.camomile.override { version = "1.0.2"; })
ocamlPackages.ocurl
ocamlPackages.cry
ocamlPackages.camomile
ocamlPackages.uri
ocamlPackages.sedlex
ocamlPackages.fileutils
ocamlPackages.menhir # liquidsoap-lang
ocamlPackages.menhirLib
ocamlPackages.metadata
ocamlPackages.dune-build-info
ocamlPackages.re
ocamlPackages.sedlex # liquidsoap-lang
ocamlPackages.ppx_string
# Recommended dependencies
ocamlPackages.ffmpeg
# Optional dependencies
ocamlPackages.camlimages
ocamlPackages.gd4o
ocamlPackages.alsa
ocamlPackages.ao
ocamlPackages.bjack
ocamlPackages.cry
ocamlPackages.camlimages
ocamlPackages.dssi
ocamlPackages.faad
ocamlPackages.fdkaac
ocamlPackages.flac
ocamlPackages.frei0r
ocamlPackages.gd4o
ocamlPackages.graphics
ocamlPackages.gstreamer
ocamlPackages.imagelib
ocamlPackages.inotify
ocamlPackages.ladspa
ocamlPackages.lame
@ -72,25 +112,22 @@ stdenv.mkDerivation {
ocamlPackages.ogg
ocamlPackages.opus
ocamlPackages.portaudio
ocamlPackages.posix-time2
ocamlPackages.pulseaudio
ocamlPackages.shine
ocamlPackages.samplerate
ocamlPackages.shine
ocamlPackages.soundtouch
ocamlPackages.speex
ocamlPackages.srt
ocamlPackages.ssl
ocamlPackages.taglib
ocamlPackages.theora
ocamlPackages.vorbis
ocamlPackages.xmlplaylist
ocamlPackages.posix-time2
ocamlPackages.tsdl
ocamlPackages.tsdl-image
ocamlPackages.tsdl-ttf
# Undocumented dependencies
ocamlPackages.graphics
ocamlPackages.cohttp-lwt-unix
ocamlPackages.vorbis
ocamlPackages.xmlplaylist
ocamlPackages.yaml
];
meta = with lib; {

View File

@ -1046,6 +1046,8 @@ let
merlin-lib = callPackage ../development/tools/ocaml/merlin/lib.nix { };
metadata = callPackage ../development/ocaml-modules/metadata { };
metrics = callPackage ../development/ocaml-modules/metrics { };
metrics-influx = callPackage ../development/ocaml-modules/metrics/influx.nix { };