about summary refs log tree commit diff
path: root/pkgs/applications/audio/mi2ly
diff options
context:
space:
mode:
authorFelix Buehler <account@buehler.rocks>2021-12-21 13:14:43 +0100
committerFelix Buehler <account@buehler.rocks>2021-12-21 13:14:43 +0100
commite7876ed40261ea7a0905fa82f0aab4277c34cb8f (patch)
tree225801c8929027e3913a98370c5723ecc097041a /pkgs/applications/audio/mi2ly
parent459f9fe2bea3546a95002dcfe2aa55b1e4d6bef9 (diff)
mi2ly: fix build and refactor
Diffstat (limited to 'pkgs/applications/audio/mi2ly')
-rw-r--r--pkgs/applications/audio/mi2ly/default.nix41
-rw-r--r--pkgs/applications/audio/mi2ly/default.upstream3
2 files changed, 16 insertions, 28 deletions
diff --git a/pkgs/applications/audio/mi2ly/default.nix b/pkgs/applications/audio/mi2ly/default.nix
index b4f7668394f1f..9a046a2e11aac 100644
--- a/pkgs/applications/audio/mi2ly/default.nix
+++ b/pkgs/applications/audio/mi2ly/default.nix
@@ -1,28 +1,20 @@
-{lib, stdenv, fetchurl}:
-let
-  s = # Generated upstream information
-  rec {
-    baseName="mi2ly";
-    version="0.12";
-    name="${baseName}-${version}";
-    hash="1b14zcwlvnxhjxr3ymyzg0mg4sbijkinzpxm641s859jxcgylmll";
-    url="https://download.savannah.gnu.org/releases/mi2ly/mi2ly.0.12.tar.bz2";
-    sha256="1b14zcwlvnxhjxr3ymyzg0mg4sbijkinzpxm641s859jxcgylmll";
-  };
-  buildInputs = [
-  ];
-in
-stdenv.mkDerivation {
-  inherit (s) name version;
-  inherit buildInputs;
+{ lib, stdenv, fetchurl }:
+
+stdenv.mkDerivation rec {
+  pname = "mi2ly";
+  version = "0.12";
+
   src = fetchurl {
-    inherit (s) url sha256;
+    url = "https://download.savannah.gnu.org/releases/mi2ly/mi2ly.${version}.tar.bz2";
+    sha256 = "sha256-lFbqH+syFaQDMbXfb+OUcWnyKnjfVz9yl7DbTTn7JKw=";
   };
 
-  sourceRoot=".";
+  sourceRoot = ".";
 
   hardeningDisable = [ "format" ];
 
+  NIX_CFLAGS_COMPILE = [ "-fgnu89-inline" ];
+
   buildPhase = "./cc";
   installPhase = ''
     mkdir -p "$out"/{bin,share/doc/mi2ly}
@@ -30,12 +22,11 @@ stdenv.mkDerivation {
     cp README Doc.txt COPYING Manual.txt "$out/share/doc/mi2ly"
   '';
 
-  meta = {
-    inherit (s) version;
+  meta = with lib; {
     description = "MIDI to Lilypond converter";
-    license = lib.licenses.gpl2Plus ;
-    maintainers = [lib.maintainers.raskin];
-    platforms = lib.platforms.linux;
-    broken = true; # 2018-04-11
+    license = licenses.gpl2Plus;
+    maintainers = with maintainers; [ raskin ];
+    platforms = platforms.linux;
+    homepage = "https://www.nongnu.org/mi2ly/";
   };
 }
diff --git a/pkgs/applications/audio/mi2ly/default.upstream b/pkgs/applications/audio/mi2ly/default.upstream
deleted file mode 100644
index 0b2607989aa2f..0000000000000
--- a/pkgs/applications/audio/mi2ly/default.upstream
+++ /dev/null
@@ -1,3 +0,0 @@
-url https://download.savannah.gnu.org/releases/mi2ly/
-ensure_choice
-version '.*/mi2ly[.]([0-9.]+)[.]tar.*' '\1'