2012-08-25 01:43:48 +01:00
|
|
|
{ stdenv, fetchurl, pkgconfig, libsndfile }:
|
2007-10-22 01:51:40 +01:00
|
|
|
|
2012-08-25 01:43:48 +01:00
|
|
|
stdenv.mkDerivation rec {
|
2013-12-18 15:51:57 +00:00
|
|
|
name = "libsamplerate-0.1.8";
|
2008-12-20 01:20:35 +00:00
|
|
|
|
2010-07-28 12:55:54 +01:00
|
|
|
src = fetchurl {
|
|
|
|
url = "http://www.mega-nerd.com/SRC/${name}.tar.gz";
|
2013-12-18 15:51:57 +00:00
|
|
|
sha256 = "01hw5xjbjavh412y63brcslj5hi9wdgkjd3h9csx5rnm8vglpdck";
|
2008-12-20 01:20:35 +00:00
|
|
|
};
|
2007-10-22 01:51:40 +01:00
|
|
|
|
2015-05-02 01:49:58 +01:00
|
|
|
nativeBuildInputs = [ pkgconfig ];
|
2015-10-03 12:33:13 +01:00
|
|
|
buildInputs = [ libsndfile ];
|
2010-07-30 21:17:37 +01:00
|
|
|
|
2008-12-20 01:20:35 +00:00
|
|
|
# maybe interesting configure flags:
|
|
|
|
#--disable-fftw disable usage of FFTW
|
|
|
|
#--disable-cpu-clip disable tricky cpu specific clipper
|
2007-10-22 01:51:40 +01:00
|
|
|
|
2012-08-23 21:21:45 +01:00
|
|
|
outputs = [ "dev" "bin" "out" ];
|
|
|
|
|
2014-07-23 10:45:44 +01:00
|
|
|
postConfigure = stdenv.lib.optionalString stdenv.isDarwin
|
|
|
|
''
|
|
|
|
# need headers from the Carbon.framework in /System/Library/Frameworks to
|
|
|
|
# compile this on darwin -- not sure how to handle
|
2014-07-24 20:53:46 +01:00
|
|
|
NIX_CFLAGS_COMPILE+=" -I$SDKROOT/System/Library/Frameworks/Carbon.framework/Versions/A/Headers"
|
2014-07-23 10:45:44 +01:00
|
|
|
|
|
|
|
substituteInPlace examples/Makefile --replace "-fpascal-strings" ""
|
|
|
|
'';
|
2013-07-04 05:59:41 +01:00
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
2008-12-20 01:20:35 +00:00
|
|
|
description = "Sample Rate Converter for audio";
|
2013-07-04 05:59:41 +01:00
|
|
|
homepage = http://www.mega-nerd.com/SRC/index.html;
|
2008-12-20 01:20:35 +00:00
|
|
|
# you can choose one of the following licenses:
|
2013-07-04 05:59:41 +01:00
|
|
|
# GPL or a commercial-use license (available at
|
|
|
|
# http://www.mega-nerd.com/SRC/libsamplerate-cul.pdf)
|
2013-07-13 20:54:39 +01:00
|
|
|
licenses = with licenses; [ gpl3.shortName unfree ];
|
2015-05-02 01:49:58 +01:00
|
|
|
maintainers = with maintainers; [ lovek323 wkennington ];
|
2013-07-04 05:59:41 +01:00
|
|
|
platforms = platforms.all;
|
2007-10-22 01:51:40 +01:00
|
|
|
};
|
2008-12-20 01:20:35 +00:00
|
|
|
}
|