uboot: (firmwareOdroidC2/C4) don't invoke patch tool, use patches = [] instead
https://github.com/NixOS/nixpkgs/blob/master/pkgs/stdenv/generic/setup.sh#L948 this can do it nicely. Signed-off-by: Anton Arapov <anton@deadbeef.mx>
This commit is contained in:
commit
56de2bcd43
30691 changed files with 3076956 additions and 0 deletions
90
pkgs/development/python-modules/tensorboard/default.nix
Normal file
90
pkgs/development/python-modules/tensorboard/default.nix
Normal file
|
|
@ -0,0 +1,90 @@
|
|||
{ lib
|
||||
, fetchPypi
|
||||
, buildPythonPackage
|
||||
, pythonOlder
|
||||
, pythonAtLeast
|
||||
, numpy
|
||||
, wheel
|
||||
, werkzeug
|
||||
, protobuf
|
||||
, grpcio
|
||||
, markdown
|
||||
, absl-py
|
||||
, google-auth-oauthlib
|
||||
, setuptools
|
||||
, tensorboard-data-server
|
||||
, tensorboard-plugin-wit
|
||||
, tensorboard-plugin-profile
|
||||
}:
|
||||
|
||||
# tensorflow/tensorboard is built from a downloaded wheel, because
|
||||
# https://github.com/tensorflow/tensorboard/issues/719 blocks
|
||||
# buildBazelPackage.
|
||||
|
||||
buildPythonPackage rec {
|
||||
pname = "tensorboard";
|
||||
version = "2.8.0";
|
||||
format = "wheel";
|
||||
disabled = pythonOlder "3.6" || pythonAtLeast "3.11";
|
||||
|
||||
src = fetchPypi {
|
||||
inherit pname version format;
|
||||
dist = "py3";
|
||||
python = "py3";
|
||||
hash = "sha256-ZaM45EJOkHnyYEkjvb4wF5KtzirOG+aNprPd8AUXDe8=";
|
||||
};
|
||||
|
||||
postPatch = ''
|
||||
chmod u+rwx -R ./dist
|
||||
pushd dist
|
||||
wheel unpack --dest unpacked ./*.whl
|
||||
pushd unpacked/tensorboard-${version}
|
||||
|
||||
substituteInPlace tensorboard-${version}.dist-info/METADATA \
|
||||
--replace "google-auth (<2,>=1.6.3)" "google-auth (<3,>=1.6.3)" \
|
||||
--replace "google-auth-oauthlib (<0.5,>=0.4.1)" "google-auth-oauthlib (<0.6,>=0.4.1)"
|
||||
|
||||
popd
|
||||
wheel pack ./unpacked/tensorboard-${version}
|
||||
popd
|
||||
'';
|
||||
|
||||
propagatedBuildInputs = [
|
||||
absl-py
|
||||
grpcio
|
||||
google-auth-oauthlib
|
||||
markdown
|
||||
numpy
|
||||
protobuf
|
||||
setuptools
|
||||
tensorboard-data-server
|
||||
tensorboard-plugin-profile
|
||||
tensorboard-plugin-wit
|
||||
werkzeug
|
||||
# not declared in install_requires, but used at runtime
|
||||
# https://github.com/NixOS/nixpkgs/issues/73840
|
||||
wheel
|
||||
];
|
||||
|
||||
# in the absence of a real test suite, run cli and imports
|
||||
checkPhase = ''
|
||||
$out/bin/tensorboard --help > /dev/null
|
||||
'';
|
||||
|
||||
pythonImportsCheck = [
|
||||
"tensorboard"
|
||||
"tensorboard.backend"
|
||||
"tensorboard.compat"
|
||||
"tensorboard.data"
|
||||
"tensorboard.plugins"
|
||||
"tensorboard.summary"
|
||||
"tensorboard.util"
|
||||
];
|
||||
|
||||
meta = with lib; {
|
||||
description = "TensorFlow's Visualization Toolkit";
|
||||
homepage = "https://www.tensorflow.org/";
|
||||
license = licenses.asl20;
|
||||
maintainers = with maintainers; [ abbradar ];
|
||||
};
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue