diff options
author | Eduardo Sánchez Muñoz <esm@eduardosm.net> | 2021-04-03 04:40:29 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-04-03 04:40:29 +0200 |
commit | 142418d94118ea7431f9d8ea4116f3be1845adfd (patch) | |
tree | 816d62f5f4aba2fd026ce4264bc64071d2b4803d /pkgs/tools/audio | |
parent | 13bfd7046276d356afe49a3fadee0131544db760 (diff) | |
download | nixlib-142418d94118ea7431f9d8ea4116f3be1845adfd.tar nixlib-142418d94118ea7431f9d8ea4116f3be1845adfd.tar.gz nixlib-142418d94118ea7431f9d8ea4116f3be1845adfd.tar.bz2 nixlib-142418d94118ea7431f9d8ea4116f3be1845adfd.tar.lz nixlib-142418d94118ea7431f9d8ea4116f3be1845adfd.tar.xz nixlib-142418d94118ea7431f9d8ea4116f3be1845adfd.tar.zst nixlib-142418d94118ea7431f9d8ea4116f3be1845adfd.zip |
acousticbrainz-client: init at 0.1 (#115780)
Co-authored-by: Sandro <sandro.jaeckel@gmail.com>
Diffstat (limited to 'pkgs/tools/audio')
-rw-r--r-- | pkgs/tools/audio/acousticbrainz-client/default.nix | 41 |
1 files changed, 41 insertions, 0 deletions
diff --git a/pkgs/tools/audio/acousticbrainz-client/default.nix b/pkgs/tools/audio/acousticbrainz-client/default.nix new file mode 100644 index 000000000000..a08710fe1219 --- /dev/null +++ b/pkgs/tools/audio/acousticbrainz-client/default.nix @@ -0,0 +1,41 @@ +{ lib, fetchFromGitHub, python3Packages, essentia-extractor }: + +python3Packages.buildPythonApplication rec { + pname = "acousticbrainz-client"; + version = "0.1"; + + src = fetchFromGitHub { + owner = "MTG"; + repo = "acousticbrainz-client"; + rev = version; + sha256 = "1g1nxh58939vysfxplrgdz366dlqnic05pkzbqh75m79brg4yrv1"; + }; + + propagatedBuildInputs = [ essentia-extractor python3Packages.requests ]; + + postPatch = '' + # The installer needs the streaming_extractor_music binary in the source directoy, + # so we provide a symlink to it. + ln -s ${essentia-extractor}/bin/streaming_extractor_music streaming_extractor_music + ''; + + postInstall = '' + # The installer includes a copy of the streaming_extractor_music binary (not a symlink), + # which we don't need, because the wrapper adds essentia-extractor/binary to PATH. + rm $out/bin/streaming_extractor_music + ''; + + # Tests seem to be broken, but the tool works + doCheck = false; + + pythonImportsCheck = [ "abz" ]; + + meta = with lib; { + description = "A client to upload data to an AcousticBrainz server"; + license = licenses.gpl3Plus; + homepage = "https://github.com/MTG/acousticbrainz-client"; + # essentia-extractor is only available for those platforms + platforms = [ "x86_64-linux" "i686-linux" ]; + maintainers = with maintainers; [ eduardosm ]; + }; +} |