2021-06-04 09:07:49 +00:00
|
|
|
{ lib, stdenv, fetchurl, pkg-config, libsndfile, portaudio, gtk2 }:
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "gnaural";
|
|
|
|
version = "20110606";
|
|
|
|
|
|
|
|
src = fetchurl {
|
|
|
|
url = "mirror://sourceforge/${pname}/${pname}_${version}.tar.xz";
|
|
|
|
hash = "sha256-0a09DUMfHEIGYuIYSBGJalBiIHIgejr/KVDXCFgKBb8=";
|
|
|
|
};
|
|
|
|
|
|
|
|
nativeBuildInputs = [ pkg-config ];
|
|
|
|
buildInputs = [ gtk2 libsndfile portaudio ];
|
|
|
|
|
2022-06-16 17:23:12 +00:00
|
|
|
# Workaround build failure on -fno-common toolchains:
|
|
|
|
# ld: src/net/../gnauralnet.h:233: multiple definition of `GN_ScheduleFingerprint';
|
|
|
|
# src/net/../../src/gnauralnet.h:233: first defined here
|
2023-03-04 12:14:45 +00:00
|
|
|
env.NIX_CFLAGS_COMPILE = "-fcommon";
|
2022-06-16 17:23:12 +00:00
|
|
|
|
2021-06-04 09:07:49 +00:00
|
|
|
postInstall = ''
|
|
|
|
mkdir -p $out/share/applications
|
|
|
|
substitute \
|
|
|
|
$out/share/gnome/apps/Multimedia/gnaural.desktop \
|
|
|
|
$out/share/applications/gnaural.desktop \
|
|
|
|
--replace \
|
|
|
|
"/usr/share/gnaural/pixmaps/gnaural-icon.png" \
|
|
|
|
"$out/share/gnaural/pixmaps/gnaural-icon.png" \
|
|
|
|
|
|
|
|
rm -rf $out/share/gnome
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Programmable auditory binaural-beat synthesizer";
|
2023-02-02 18:25:31 +00:00
|
|
|
homepage = "https://gnaural.sourceforge.net/";
|
2021-06-04 09:07:49 +00:00
|
|
|
maintainers = with maintainers; [ ehmry ];
|
|
|
|
license = with licenses; [ gpl2Only ];
|
|
|
|
};
|
|
|
|
}
|