Merge pull request #56026 from oxij/tree/move-defaults-to-package-files-half-cuda
all-packages.nix: move defaults to package files continues^2
This commit is contained in:
commit
446520bb9b
@ -1,10 +1,10 @@
|
|||||||
{ stdenv, lib, fetchurl, boost, cmake, ffmpeg, gettext, glew
|
{ config, stdenv, lib, fetchurl, boost, cmake, ffmpeg, gettext, glew
|
||||||
, ilmbase, libXi, libX11, libXext, libXrender
|
, ilmbase, libXi, libX11, libXext, libXrender
|
||||||
, libjpeg, libpng, libsamplerate, libsndfile
|
, libjpeg, libpng, libsamplerate, libsndfile
|
||||||
, libtiff, libGLU_combined, openal, opencolorio, openexr, openimageio, openjpeg_1, pythonPackages
|
, libtiff, libGLU_combined, openal, opencolorio, openexr, openimageio, openjpeg_1, pythonPackages
|
||||||
, zlib, fftw, opensubdiv, freetype, jemalloc, ocl-icd
|
, zlib, fftw, opensubdiv, freetype, jemalloc, ocl-icd
|
||||||
, jackaudioSupport ? false, libjack2
|
, jackaudioSupport ? false, libjack2
|
||||||
, cudaSupport ? false, cudatoolkit
|
, cudaSupport ? config.cudaSupport or false, cudatoolkit
|
||||||
, colladaSupport ? true, opencollada
|
, colladaSupport ? true, opencollada
|
||||||
, enableNumpy ? false, makeWrapper
|
, enableNumpy ? false, makeWrapper
|
||||||
}:
|
}:
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
{ stdenv, lib, runCommand
|
{ config, stdenv, lib, runCommand
|
||||||
, fetchFromGitHub
|
, fetchFromGitHub
|
||||||
, fetchurl
|
, fetchurl
|
||||||
, cmake
|
, cmake
|
||||||
@ -13,8 +13,8 @@
|
|||||||
, Accelerate, CoreGraphics, CoreVideo
|
, Accelerate, CoreGraphics, CoreVideo
|
||||||
, lmdbSupport ? true, lmdb
|
, lmdbSupport ? true, lmdb
|
||||||
, leveldbSupport ? true, leveldb, snappy
|
, leveldbSupport ? true, leveldb, snappy
|
||||||
, cudaSupport ? stdenv.isLinux, cudatoolkit
|
, cudaSupport ? config.cudaSupport or false, cudatoolkit
|
||||||
, cudnnSupport ? false, cudnn ? null
|
, cudnnSupport ? cudaSupport, cudnn ? null
|
||||||
, ncclSupport ? false, nccl ? null
|
, ncclSupport ? false, nccl ? null
|
||||||
, pythonSupport ? false, python ? null, numpy ? null
|
, pythonSupport ? false, python ? null, numpy ? null
|
||||||
, substituteAll
|
, substituteAll
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
{ lib, stdenv, fetchgit, fetchFromGitHub, cmake
|
{ config, lib, stdenv, fetchgit, fetchFromGitHub, cmake
|
||||||
, openblas, opencv3, libzip, boost, protobuf, openmpi
|
, openblas, opencv3, libzip, boost, protobuf, openmpi
|
||||||
, onebitSGDSupport ? false
|
, onebitSGDSupport ? false
|
||||||
, cudaSupport ? false, cudatoolkit, nvidia_x11
|
, cudaSupport ? config.cudaSupport or false, cudatoolkit, nvidia_x11
|
||||||
, cudnnSupport ? false, cudnn
|
, cudnnSupport ? cudaSupport, cudnn
|
||||||
}:
|
}:
|
||||||
|
|
||||||
assert cudnnSupport -> cudaSupport;
|
assert cudnnSupport -> cudaSupport;
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
{ stdenv, lib, fetchurl, bash, cmake
|
{ config, stdenv, lib, fetchurl, bash, cmake
|
||||||
, opencv, gtest, openblas, liblapack, perl
|
, opencv, gtest, openblas, liblapack, perl
|
||||||
, cudaSupport ? false, cudatoolkit, nvidia_x11
|
, cudaSupport ? config.cudaSupport or false, cudatoolkit, nvidia_x11
|
||||||
, cudnnSupport ? false, cudnn
|
, cudnnSupport ? cudaSupport, cudnn
|
||||||
}:
|
}:
|
||||||
|
|
||||||
assert cudnnSupport -> cudaSupport;
|
assert cudnnSupport -> cudaSupport;
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
{ stdenv, fetchFromGitHub, pkgconfig, autoreconfHook, glib, dbus-glib
|
{ stdenv, fetchFromGitHub, pkgconfig, autoreconfHook, glib, dbus-glib
|
||||||
, desktopSupport, xorg
|
, desktopSupport ? "gnomeflashback", xorg
|
||||||
, gtk2
|
, gtk2
|
||||||
, gtk3, gnome3, mate
|
, gtk3, gnome3, mate
|
||||||
, libxfce4util, xfce4-panel
|
, libxfce4util, xfce4-panel
|
||||||
|
@ -1,5 +1,7 @@
|
|||||||
{ stdenv, fetchurl, pkgconfig, libtool, zip, libffi, libsigsegv, readline, gmp,
|
{ config, stdenv, fetchurl, pkgconfig, libtool
|
||||||
gnutls, gnome2, cairo, SDL, sqlite, emacsSupport ? false, emacs ? null }:
|
, zip, libffi, libsigsegv, readline, gmp
|
||||||
|
, gnutls, gnome2, cairo, SDL, sqlite
|
||||||
|
, emacsSupport ? config.emacsSupport or false, emacs ? null }:
|
||||||
|
|
||||||
assert emacsSupport -> (emacs != null);
|
assert emacsSupport -> (emacs != null);
|
||||||
|
|
||||||
|
@ -1,8 +1,10 @@
|
|||||||
{ stdenv, fetchurl, pkgconfig, libiconv
|
{ config, stdenv, fetchurl, pkgconfig, libiconv
|
||||||
, libintl, expat, zlib, libpng, pixman, fontconfig, freetype, xorg
|
, libintl, expat, zlib, libpng, pixman, fontconfig, freetype, xorg
|
||||||
, gobjectSupport ? true, glib
|
, gobjectSupport ? true, glib
|
||||||
, xcbSupport ? true # no longer experimental since 1.12
|
, xcbSupport ? true # no longer experimental since 1.12
|
||||||
, glSupport ? true, libGL ? null # libGLU_combined is no longer a big dependency
|
, libGLSupported
|
||||||
|
, glSupport ? config.cairo.gl or (libGLSupported && stdenv.isLinux && !stdenv.isAarch32 && !stdenv.isMips)
|
||||||
|
, libGL ? null # libGLU_combined is no longer a big dependency
|
||||||
, pdfSupport ? true
|
, pdfSupport ? true
|
||||||
, darwin
|
, darwin
|
||||||
}:
|
}:
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
{ stdenv, fetchurl, pkgconfig, gettext, glib, atk, pango, cairo, perl, xorg
|
{ config, stdenv, fetchurl, pkgconfig, gettext, glib, atk, pango, cairo, perl, xorg
|
||||||
, gdk_pixbuf, xlibsWrapper, gobject-introspection
|
, gdk_pixbuf, xlibsWrapper, gobject-introspection
|
||||||
, xineramaSupport ? stdenv.isLinux
|
, xineramaSupport ? stdenv.isLinux
|
||||||
, cupsSupport ? true, cups ? null
|
, cupsSupport ? config.gtk2.cups or stdenv.isLinux, cups ? null
|
||||||
, gdktarget ? if stdenv.isDarwin then "quartz" else "x11"
|
, gdktarget ? if stdenv.isDarwin then "quartz" else "x11"
|
||||||
, AppKit, Cocoa
|
, AppKit, Cocoa
|
||||||
, fetchpatch
|
, fetchpatch
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
{ stdenv
|
{ config, stdenv
|
||||||
, fetchurl
|
, fetchurl
|
||||||
, patchelf
|
, patchelf
|
||||||
, cudaSupport ? false, symlinkJoin, cudatoolkit, cudnn, nvidia_x11
|
, cudaSupport ? config.cudaSupport or false, symlinkJoin, cudatoolkit, cudnn, nvidia_x11
|
||||||
}:
|
}:
|
||||||
with stdenv.lib;
|
with stdenv.lib;
|
||||||
let
|
let
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig, xorg, libGLU
|
{ config, lib, stdenv, fetchFromGitHub, cmake, pkgconfig, xorg, libGLU
|
||||||
, libGL, glew, ocl-icd, python3
|
, libGL, glew, ocl-icd, python3
|
||||||
, cudaSupport ? false, cudatoolkit
|
, cudaSupport ? config.cudaSupport or false, cudatoolkit
|
||||||
, darwin
|
, darwin
|
||||||
}:
|
}:
|
||||||
|
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
{ stdenv, lib, fetchgit, cmake
|
{ config, stdenv, lib, fetchgit, cmake
|
||||||
, cudaSupport ? false, cudatoolkit
|
, cudaSupport ? config.cudaSupport or false, cudatoolkit
|
||||||
, ncclSupport ? false, nccl
|
, ncclSupport ? false, nccl
|
||||||
, llvmPackages
|
, llvmPackages
|
||||||
}:
|
}:
|
||||||
|
@ -1,10 +1,9 @@
|
|||||||
{ stdenv, fetchurl
|
{ config, lib, stdenv, fetchurl
|
||||||
, yacc, flex
|
, yacc, flex
|
||||||
, sysfsutils, kmod, udev
|
, sysfsutils, kmod, udev
|
||||||
, firmware # Special pcmcia cards.
|
, firmware ? config.pcmciaUtils.firmware or [] # Special pcmcia cards.
|
||||||
, config # Special hardware (map memory & port & irq)
|
, configOpts ? config.pcmciaUtils.config or null # Special hardware (map memory & port & irq)
|
||||||
, lib # used to generate postInstall script.
|
}: # used to generate postInstall script.
|
||||||
}:
|
|
||||||
|
|
||||||
# FIXME: should add an option to choose between hotplug and udev.
|
# FIXME: should add an option to choose between hotplug and udev.
|
||||||
stdenv.mkDerivation rec {
|
stdenv.mkDerivation rec {
|
||||||
@ -28,8 +27,8 @@ stdenv.mkDerivation rec {
|
|||||||
" src/{startup.c,pcmcia-check-broken-cis.c} # fix-color */
|
" src/{startup.c,pcmcia-check-broken-cis.c} # fix-color */
|
||||||
''
|
''
|
||||||
+ (if firmware == [] then ''sed -i "s,STARTUP = true,STARTUP = false," Makefile'' else "")
|
+ (if firmware == [] then ''sed -i "s,STARTUP = true,STARTUP = false," Makefile'' else "")
|
||||||
+ (if config == null then "" else ''
|
+ (if configOpts == null then "" else ''
|
||||||
ln -sf ${config} ./config/config.opts'')
|
ln -sf ${configOpts} ./config/config.opts'')
|
||||||
;
|
;
|
||||||
|
|
||||||
makeFlags = "LEX=flex";
|
makeFlags = "LEX=flex";
|
||||||
|
@ -936,7 +936,6 @@ in
|
|||||||
tensor = libsForQt5.callPackage ../applications/networking/instant-messengers/tensor { };
|
tensor = libsForQt5.callPackage ../applications/networking/instant-messengers/tensor { };
|
||||||
|
|
||||||
libtensorflow = callPackage ../development/libraries/libtensorflow {
|
libtensorflow = callPackage ../development/libraries/libtensorflow {
|
||||||
cudaSupport = config.cudaSupport or false;
|
|
||||||
inherit (linuxPackages) nvidia_x11;
|
inherit (linuxPackages) nvidia_x11;
|
||||||
cudatoolkit = cudatoolkit_9_0;
|
cudatoolkit = cudatoolkit_9_0;
|
||||||
cudnn = cudnn_cudatoolkit_9_0;
|
cudnn = cudnn_cudatoolkit_9_0;
|
||||||
@ -6962,9 +6961,7 @@ in
|
|||||||
inherit (gnome2) libart_lgpl;
|
inherit (gnome2) libart_lgpl;
|
||||||
});
|
});
|
||||||
|
|
||||||
gnu-smalltalk = callPackage ../development/compilers/gnu-smalltalk {
|
gnu-smalltalk = callPackage ../development/compilers/gnu-smalltalk { };
|
||||||
emacsSupport = config.emacsSupport or false;
|
|
||||||
};
|
|
||||||
|
|
||||||
gccgo = gccgo6;
|
gccgo = gccgo6;
|
||||||
gccgo6 = wrapCC (gcc6.cc.override {
|
gccgo6 = wrapCC (gcc6.cc.override {
|
||||||
@ -10188,11 +10185,7 @@ in
|
|||||||
|
|
||||||
pixman = callPackage ../development/libraries/pixman { };
|
pixman = callPackage ../development/libraries/pixman { };
|
||||||
|
|
||||||
cairo = callPackage ../development/libraries/cairo {
|
cairo = callPackage ../development/libraries/cairo { };
|
||||||
glSupport = config.cairo.gl or (stdenv.isLinux &&
|
|
||||||
!stdenv.isAarch32 && !stdenv.isMips);
|
|
||||||
};
|
|
||||||
|
|
||||||
|
|
||||||
cairomm = callPackage ../development/libraries/cairomm { };
|
cairomm = callPackage ../development/libraries/cairomm { };
|
||||||
|
|
||||||
@ -10220,7 +10213,6 @@ in
|
|||||||
elementary-cmake-modules = callPackage ../development/libraries/elementary-cmake-modules { };
|
elementary-cmake-modules = callPackage ../development/libraries/elementary-cmake-modules { };
|
||||||
|
|
||||||
gtk2 = callPackage ../development/libraries/gtk+/2.x.nix {
|
gtk2 = callPackage ../development/libraries/gtk+/2.x.nix {
|
||||||
cupsSupport = config.gtk2.cups or stdenv.isLinux;
|
|
||||||
inherit (darwin.apple_sdk.frameworks) AppKit Cocoa;
|
inherit (darwin.apple_sdk.frameworks) AppKit Cocoa;
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -11944,7 +11936,6 @@ in
|
|||||||
openssl-chacha = callPackage ../development/libraries/openssl/chacha.nix { };
|
openssl-chacha = callPackage ../development/libraries/openssl/chacha.nix { };
|
||||||
|
|
||||||
opensubdiv = callPackage ../development/libraries/opensubdiv {
|
opensubdiv = callPackage ../development/libraries/opensubdiv {
|
||||||
cudaSupport = config.cudaSupport or false;
|
|
||||||
cmake = cmake_2_8;
|
cmake = cmake_2_8;
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -13084,9 +13075,7 @@ in
|
|||||||
|
|
||||||
xalanc = callPackage ../development/libraries/xalanc {};
|
xalanc = callPackage ../development/libraries/xalanc {};
|
||||||
|
|
||||||
xgboost = callPackage ../development/libraries/xgboost {
|
xgboost = callPackage ../development/libraries/xgboost { };
|
||||||
cudaSupport = config.cudaSupport or false;
|
|
||||||
};
|
|
||||||
|
|
||||||
xgeometry-select = callPackage ../tools/X11/xgeometry-select { };
|
xgeometry-select = callPackage ../tools/X11/xgeometry-select { };
|
||||||
|
|
||||||
@ -15113,10 +15102,7 @@ in
|
|||||||
|
|
||||||
pax-utils = callPackage ../os-specific/linux/pax-utils { };
|
pax-utils = callPackage ../os-specific/linux/pax-utils { };
|
||||||
|
|
||||||
pcmciaUtils = callPackage ../os-specific/linux/pcmciautils {
|
pcmciaUtils = callPackage ../os-specific/linux/pcmciautils { };
|
||||||
firmware = config.pcmciaUtils.firmware or [];
|
|
||||||
config = config.pcmciaUtils.config or null;
|
|
||||||
};
|
|
||||||
|
|
||||||
pcstat = callPackage ../tools/system/pcstat { };
|
pcstat = callPackage ../tools/system/pcstat { };
|
||||||
|
|
||||||
@ -16303,7 +16289,6 @@ in
|
|||||||
bleachbit = callPackage ../applications/misc/bleachbit { };
|
bleachbit = callPackage ../applications/misc/bleachbit { };
|
||||||
|
|
||||||
blender = callPackage ../applications/misc/blender {
|
blender = callPackage ../applications/misc/blender {
|
||||||
cudaSupport = config.cudaSupport or false;
|
|
||||||
pythonPackages = python35Packages;
|
pythonPackages = python35Packages;
|
||||||
stdenv = overrideCC stdenv gcc6;
|
stdenv = overrideCC stdenv gcc6;
|
||||||
};
|
};
|
||||||
@ -20311,18 +20296,15 @@ in
|
|||||||
};
|
};
|
||||||
|
|
||||||
xmonad_log_applet = callPackage ../applications/window-managers/xmonad/log-applet {
|
xmonad_log_applet = callPackage ../applications/window-managers/xmonad/log-applet {
|
||||||
desktopSupport = "gnomeflashback";
|
|
||||||
inherit (xfce) libxfce4util xfce4-panel;
|
inherit (xfce) libxfce4util xfce4-panel;
|
||||||
};
|
};
|
||||||
|
|
||||||
xmonad_log_applet_mate = xmonad_log_applet.override {
|
xmonad_log_applet_mate = xmonad_log_applet.override {
|
||||||
desktopSupport = "mate";
|
desktopSupport = "mate";
|
||||||
inherit (xfce) libxfce4util xfce4-panel;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
xmonad_log_applet_xfce = xmonad_log_applet.override {
|
xmonad_log_applet_xfce = xmonad_log_applet.override {
|
||||||
desktopSupport = "xfce4";
|
desktopSupport = "xfce4";
|
||||||
inherit (xfce) libxfce4util xfce4-panel;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
xmpp-client = callPackage ../applications/networking/instant-messengers/xmpp-client { };
|
xmpp-client = callPackage ../applications/networking/instant-messengers/xmpp-client { };
|
||||||
@ -22014,28 +21996,21 @@ in
|
|||||||
|
|
||||||
### SCIENCE / MATH
|
### SCIENCE / MATH
|
||||||
|
|
||||||
caffe = callPackage ../applications/science/math/caffe rec {
|
caffe = callPackage ../applications/science/math/caffe ({
|
||||||
cudaSupport = config.caffe.cudaSupport or config.cudaSupport or false;
|
opencv3 = opencv3WithoutCuda; # Used only for image loading.
|
||||||
cudnnSupport = cudaSupport;
|
|
||||||
# Used only for image loading.
|
|
||||||
opencv3 = opencv3WithoutCuda;
|
|
||||||
inherit (darwin.apple_sdk.frameworks) Accelerate CoreGraphics CoreVideo;
|
inherit (darwin.apple_sdk.frameworks) Accelerate CoreGraphics CoreVideo;
|
||||||
};
|
} // (config.caffe or {}));
|
||||||
|
|
||||||
caffe2 = callPackage ../development/libraries/science/math/caffe2 (rec {
|
caffe2 = callPackage ../development/libraries/science/math/caffe2 (rec {
|
||||||
inherit (python36Packages) python future six numpy pydot;
|
inherit (python36Packages) python future six numpy pydot;
|
||||||
protobuf = protobuf3_1;
|
protobuf = protobuf3_1;
|
||||||
python-protobuf = python36Packages.protobuf.override { inherit protobuf; };
|
python-protobuf = python36Packages.protobuf.override { inherit protobuf; };
|
||||||
# Used only for image loading.
|
opencv3 = opencv3WithoutCuda; # Used only for image loading.
|
||||||
opencv3 = opencv3WithoutCuda;
|
|
||||||
});
|
});
|
||||||
|
|
||||||
cntk = callPackage ../applications/science/math/cntk rec {
|
cntk = callPackage ../applications/science/math/cntk {
|
||||||
cudaSupport = pkgs.config.cudaSupport or false;
|
|
||||||
cudnnSupport = cudaSupport;
|
|
||||||
inherit (linuxPackages) nvidia_x11;
|
inherit (linuxPackages) nvidia_x11;
|
||||||
# Used only for image loading.
|
opencv3 = opencv3WithoutCuda; # Used only for image loading.
|
||||||
opencv3 = opencv3WithoutCuda;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
ecm = callPackage ../applications/science/math/ecm { };
|
ecm = callPackage ../applications/science/math/ecm { };
|
||||||
@ -22066,9 +22041,7 @@ in
|
|||||||
sbcl = null;
|
sbcl = null;
|
||||||
};
|
};
|
||||||
|
|
||||||
mxnet = callPackage ../applications/science/math/mxnet rec {
|
mxnet = callPackage ../applications/science/math/mxnet {
|
||||||
cudaSupport = config.cudaSupport or false;
|
|
||||||
cudnnSupport = cudaSupport;
|
|
||||||
inherit (linuxPackages) nvidia_x11;
|
inherit (linuxPackages) nvidia_x11;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user