From 3f0a8494c98071720dc4b9beae6cd8bf3aeb5424 Mon Sep 17 00:00:00 2001 From: Marc Weber Date: Tue, 14 Oct 2008 13:59:56 +0000 Subject: [PATCH] fftw also with single support now, new name suffix indecating which one is used svn path=/nixpkgs/trunk/; revision=13064 --- pkgs/development/libraries/fftw/default.nix | 7 +++++-- pkgs/top-level/all-packages.nix | 5 +++++ 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/pkgs/development/libraries/fftw/default.nix b/pkgs/development/libraries/fftw/default.nix index ec8cff5f32d7..b5b0a84777e4 100644 --- a/pkgs/development/libraries/fftw/default.nix +++ b/pkgs/development/libraries/fftw/default.nix @@ -6,11 +6,14 @@ args : with args; sha256 = "1gr63hf5vvsg50b2xwqaxwpvs1y9g8l0sb91a38wpvr7zsbjxfg1"; }; buildInputs = []; - configureFlags = ["--enable-float --enable-shared"]; + configureFlags = ["--enable-shared"] + ++ (if args.singlePrecision then [ /*"--enable-single" */] else ["--enable-float"]); + # some distros seem to be shipping both versions within the same package? + # why does --enable-single still result in ..3f.so instead of ..3.so? }; in with localDefs; stdenv.mkDerivation { - name = "fftw-3.1.2"; + name = "fftw-3.1.2" + ( if args.singlePrecision then "-single" else "-float" ); builder = writeScript "fftw-3.1.2-builder" (textClosure localDefs [doConfigure doMakeInstall doForceShare]); meta = { diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 7bac5379623c..5b1310734f84 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -2714,6 +2714,11 @@ let fftw = import ../development/libraries/fftw { inherit fetchurl stdenv builderDefs stringsWithDeps; + singlePrecision = false; + }; + fftwSinglePrec = import ../development/libraries/fftw { + inherit fetchurl stdenv builderDefs stringsWithDeps; + singlePrecision = true; }; fltk20 = (import ../development/libraries/fltk) {