From d4b128959210e45df8bdbe4b0a5e3844a73a9953 Mon Sep 17 00:00:00 2001 From: Matthew Bauer Date: Wed, 10 Aug 2016 21:04:16 -0500 Subject: [PATCH 1/8] lie: LiE -> lie Attributes need to be lowercase, see https://nixos.org/nixpkgs/manual/#sec-package-naming. --- pkgs/applications/science/math/LiE/default.nix | 2 +- pkgs/top-level/all-packages.nix | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/applications/science/math/LiE/default.nix b/pkgs/applications/science/math/LiE/default.nix index b448b511421..8e284f5c328 100644 --- a/pkgs/applications/science/math/LiE/default.nix +++ b/pkgs/applications/science/math/LiE/default.nix @@ -5,7 +5,7 @@ stdenv.mkDerivation rec { version = "2.2.2"; # The current version of LiE is 2.2.2, which is more or less unchanged # since about the year 2000. Minor bugfixes do get applied now and then. - name = "LiE-${version}"; + name = "lie-${version}"; meta = { description = "A Computer algebra package for Lie group computations"; diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index eea96fdc3c4..ae0a86dcab5 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -16537,7 +16537,7 @@ in openspecfun = callPackage ../development/libraries/science/math/openspecfun {}; - LiE = callPackage ../applications/science/math/LiE { }; + lie = callPackage ../applications/science/math/LiE { }; magma = callPackage ../development/libraries/science/math/magma { }; From b3cb07e1300ce1be30f14011a8274615de38e23d Mon Sep 17 00:00:00 2001 From: Matthew Bauer Date: Wed, 10 Aug 2016 21:06:22 -0500 Subject: [PATCH 2/8] lie: only build on linux Darwin build fails from conflicts in libSystem: In file included from altdom.c:1: In file included from /private/var/folders/7t/4vz31njj37b8y_bg6z3t7tk00000gn/T/nix-build-LiE-2.2.2.drv-0/LiE/lie.h:34: In file included from /nix/store/9ll4m9yx854hr64fn1w9ra3qimm3pzdk-Libsystem-osx-10.9.5/include/string.h:176: /nix/store/9ll4m9yx854hr64fn1w9ra3qimm3pzdk-Libsystem-osx-10.9.5/include/strings.h:73:7: error: redefinition of 'index' as different kind of symbol char *index(const char *, int) __POSIX_C_DEPRECATED(200112L); ^ /private/var/folders/7t/4vz31njj37b8y_bg6z3t7tk00000gn/T/nix-build-LiE-2.2.2.drv-0/LiE/lie.h:6:14: note: previous definition is here typedef long index; ^ 1 error generated. --- pkgs/applications/science/math/LiE/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/applications/science/math/LiE/default.nix b/pkgs/applications/science/math/LiE/default.nix index 8e284f5c328..515b7e27289 100644 --- a/pkgs/applications/science/math/LiE/default.nix +++ b/pkgs/applications/science/math/LiE/default.nix @@ -19,7 +19,7 @@ stdenv.mkDerivation rec { characteristics, we refer to the following sources of information. ''; # take from the website - platforms = stdenv.lib.platforms.unix; + platforms = stdenv.lib.platforms.linux; maintainers = [ ]; # this package is probably not going to change anyway }; From ee6305647677dc370a966437dfb7476701e7a871 Mon Sep 17 00:00:00 2001 From: Matthew Bauer Date: Wed, 10 Aug 2016 22:29:18 -0500 Subject: [PATCH 3/8] aspino: patch to use c++ instead of g++ --- pkgs/applications/science/logic/aspino/default.nix | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/pkgs/applications/science/logic/aspino/default.nix b/pkgs/applications/science/logic/aspino/default.nix index 5207245b0ba..ee9e580a7b8 100644 --- a/pkgs/applications/science/logic/aspino/default.nix +++ b/pkgs/applications/science/logic/aspino/default.nix @@ -11,6 +11,11 @@ stdenv.mkDerivation rec { buildInputs = [ zlib boost ]; + patchPhase = '' + substituteInPlace Makefile \ + --replace "GCC = g++" "GCC = c++" + ''; + preBuild = '' cp ${glucose.src} patches/glucose-syrup.tgz ./bootstrap.sh From db89bdcab08b7d7748b971ff921f740b9ce82a4b Mon Sep 17 00:00:00 2001 From: Matthew Bauer Date: Wed, 10 Aug 2016 22:29:45 -0500 Subject: [PATCH 4/8] alure: only build on linux --- pkgs/development/libraries/alure/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/development/libraries/alure/default.nix b/pkgs/development/libraries/alure/default.nix index 200ff1ca2e7..fe2892c9627 100644 --- a/pkgs/development/libraries/alure/default.nix +++ b/pkgs/development/libraries/alure/default.nix @@ -15,6 +15,6 @@ stdenv.mkDerivation rec { description = "A utility library to help manage common tasks with OpenAL applications"; homepage = http://kcat.strangesoft.net/alure.html; license = licenses.mit; - platforms = platforms.unix; + platforms = platforms.linux; }; } From 7af81d99ddf1be788bf70d07bd7933ebb851759b Mon Sep 17 00:00:00 2001 From: Matthew Bauer Date: Wed, 10 Aug 2016 22:29:58 -0500 Subject: [PATCH 5/8] arduino: only build on linux --- pkgs/development/arduino/arduino-core/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/development/arduino/arduino-core/default.nix b/pkgs/development/arduino/arduino-core/default.nix index f1f598c1359..f89947d7d61 100644 --- a/pkgs/development/arduino/arduino-core/default.nix +++ b/pkgs/development/arduino/arduino-core/default.nix @@ -112,7 +112,7 @@ stdenv.mkDerivation rec { description = "Open-source electronics prototyping platform"; homepage = http://arduino.cc/; license = stdenv.lib.licenses.gpl2; - platforms = platforms.all; + platforms = platforms.linux; maintainers = with maintainers; [ antono robberer bjornfor ]; }; } From 93d0d6f25fa86696f80cf36c18646ed2df7e25d2 Mon Sep 17 00:00:00 2001 From: Matthew Bauer Date: Wed, 10 Aug 2016 22:42:32 -0500 Subject: [PATCH 6/8] atomicparsley: lowercase derivation name --- pkgs/tools/video/atomicparsley/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/tools/video/atomicparsley/default.nix b/pkgs/tools/video/atomicparsley/default.nix index 9cabfe31a18..d32d125ccd5 100644 --- a/pkgs/tools/video/atomicparsley/default.nix +++ b/pkgs/tools/video/atomicparsley/default.nix @@ -1,7 +1,7 @@ { stdenv, pkgs, fetchurl }: stdenv.mkDerivation rec { - name = "${product}-${version}"; + name = "atomicparsley-${version}"; product = "AtomicParsley"; version = "0.9.0"; From 0a1cb79908aabb8c9f8a404e8d7a0133a3861592 Mon Sep 17 00:00:00 2001 From: Matthew Bauer Date: Wed, 10 Aug 2016 22:42:51 -0500 Subject: [PATCH 7/8] atomicparsley: fix darwin build --- pkgs/tools/video/atomicparsley/default.nix | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/pkgs/tools/video/atomicparsley/default.nix b/pkgs/tools/video/atomicparsley/default.nix index d32d125ccd5..bb44fe044e8 100644 --- a/pkgs/tools/video/atomicparsley/default.nix +++ b/pkgs/tools/video/atomicparsley/default.nix @@ -10,12 +10,20 @@ stdenv.mkDerivation rec { sha256 = "de83f219f95e6fe59099b277e3ced86f0430ad9468e845783092821dff15a72e"; }; - buildInputs = with pkgs; [ unzip ]; + buildInputs = with pkgs; [ unzip ] + ++ stdenv.lib.optional stdenv.isDarwin [ darwin.apple_sdk.frameworks.Cocoa ]; patches = [ ./casts.patch ]; setSourceRoot = "sourceRoot=${product}-source-${version}"; buildPhase = "bash build"; installPhase = "install -D AtomicParsley $out/bin/AtomicParsley"; + postPatch = '' + substituteInPlace build \ + --replace 'g++' 'c++' + substituteInPlace AP_NSImage.mm \ + --replace '_NSBitmapImageFileType' 'NSBitmapImageFileType' + ''; + meta = with stdenv.lib; { description = '' A lightweight command line program for reading, parsing and From 96322f6926622c31a078fbdefc5a623a8f7a6577 Mon Sep 17 00:00:00 2001 From: Matthew Bauer Date: Wed, 10 Aug 2016 22:48:19 -0500 Subject: [PATCH 8/8] bcftools: fix darwin building gcc not available --- pkgs/applications/science/biology/bcftools/default.nix | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/pkgs/applications/science/biology/bcftools/default.nix b/pkgs/applications/science/biology/bcftools/default.nix index d4e4ed5b954..71ceca12224 100644 --- a/pkgs/applications/science/biology/bcftools/default.nix +++ b/pkgs/applications/science/biology/bcftools/default.nix @@ -12,9 +12,11 @@ stdenv.mkDerivation rec { buildInputs = [ zlib ]; - preBuild = '' - makeFlagsArray=("HSTDIR=${htslib}" "prefix=$out") - ''; + makeFlags = [ + "HSTDIR=${htslib}" + "prefix=$out" + "CC=cc" + ]; meta = with stdenv.lib; { description = "Tools for manipulating BCF2/VCF/gVCF format, SNP and short indel sequence variants";