Merge remote-tracking branch 'upstream/master' into gcc-8

This commit is contained in:
Robin Gloster
2019-08-25 18:55:46 +02:00
5048 changed files with 266048 additions and 268080 deletions
@@ -1,4 +1,4 @@
{ stdenv, lib, gtest, fetchFromGitHub, cmake, boost, eigen, python, vtk, zlib }:
{ stdenv, gtest, fetchFromGitHub, cmake, boost, eigen, python, vtk, zlib }:
stdenv.mkDerivation rec {
version = "2.0.0";
@@ -8,14 +8,14 @@
}:
stdenv.mkDerivation rec {
version = "1.2.4";
version = "1.2.5";
name = "brial-${version}";
src = fetchFromGitHub {
owner = "BRiAl";
repo = "BRiAl";
rev = version;
sha256 = "08skgmwz190mvpkh0ddx92ilva6bxidxwh1qg16ipi768x92193s";
sha256 = "1nv56fp3brpzanxj7vwvxqdafqfsfhdgq5imr3m94psw5gdfqwja";
};
# FIXME package boost-test and enable checks
@@ -1,6 +1,6 @@
{ stdenv, lib, config, fetchFromGitHub
, cmake
, glog, google-gflags, gtest
, glog, gflags, gtest
, protobuf, snappy
, python, future, six, python-protobuf, numpy, pydot
, eigen
@@ -74,7 +74,7 @@ stdenv.mkDerivation rec {
outputs = [ "bin" "out" ];
propagatedBuildOutputs = [ ]; # otherwise propagates out -> bin cycle
buildInputs = [ glog google-gflags protobuf snappy eigen ]
buildInputs = [ glog gflags protobuf snappy eigen ]
++ lib.optional useCuda cudatoolkit
++ lib.optional useCudnn cudnn
++ lib.optional useOpenmp openmp
@@ -83,7 +83,7 @@ let
'';
meta = {
description = "A domain-specific language for finite element variational forms";
homepage = http://fenicsproject.org/;
homepage = https://fenicsproject.org/;
platforms = stdenv.lib.platforms.all;
license = stdenv.lib.licenses.lgpl3;
};
@@ -102,7 +102,7 @@ let
'';
meta = {
description = "A compiler for finite element variational forms";
homepage = http://fenicsproject.org/;
homepage = https://fenicsproject.org/;
platforms = stdenv.lib.platforms.all;
license = stdenv.lib.licenses.lgpl3;
};
@@ -117,7 +117,7 @@ let
buildInputs = [ numpy six ];
meta = {
description = "Instant inlining of C and C++ code in Python";
homepage = http://fenicsproject.org/;
homepage = https://fenicsproject.org/;
platforms = stdenv.lib.platforms.all;
license = stdenv.lib.licenses.lgpl3;
};
@@ -162,7 +162,7 @@ stdenv.mkDerivation {
postInstall = "source $out/share/dolfin/dolfin.conf";
meta = {
description = "The FEniCS Problem Solving Environment in Python and C++";
homepage = http://fenicsproject.org/;
homepage = https://fenicsproject.org/;
platforms = stdenv.lib.platforms.darwin;
license = stdenv.lib.licenses.lgpl3;
};
@@ -7,8 +7,7 @@
shared ? false
}:
let
usedLibExtension = if shared then ".so" else ".a";
inherit (stdenv.lib) optional optionals;
inherit (stdenv.lib) optional;
version = "3.8.0";
in
@@ -1,4 +1,4 @@
{ stdenvNoCC, writeText, fetchurl, rpmextract, undmg, darwin }:
{ stdenvNoCC, fetchurl, rpmextract, undmg, darwin }:
/*
For details on using mkl as a blas provider for python packages such as numpy,
numexpr, scipy, etc., see the Python section of the NixPkgs manual.
@@ -2,13 +2,13 @@
stdenv.mkDerivation rec {
name = "nccl-${version}-cuda-${cudatoolkit.majorVersion}";
version = "2.4.2-1";
version = "2.4.8-1";
src = fetchFromGitHub {
owner = "NVIDIA";
repo = "nccl";
rev = "v${version}";
sha256 = "0aa4gv51nbmmdhx6vp40l249m4arp30sijrn6kwxdfi1k9kajiq5";
sha256 = "05m66y64rgsdyybvjybhy6clikwv438b1m484ikai78fb2b7mvyq";
};
outputs = [ "out" "dev" ];
@@ -1,4 +1,4 @@
{ stdenv, fetchFromGitHub, fetchpatch, gfortran, perl, which, config
{ stdenv, fetchFromGitHub, perl, which
# Most packages depending on openblas expect integer width to match
# pointer width, but some expect to use 32-bit integers always
# (for compatibility with reference BLAS).
@@ -1,4 +1,4 @@
{ stdenv, fetchFromGitHub, cmake, abseil-cpp, google-gflags, which
{ stdenv, fetchFromGitHub, cmake, abseil-cpp, gflags, which
, lsb-release, glog, protobuf, cbc, zlib
, ensureNewerSourcesForZipFilesHook, python, swig
, pythonProtobuf }:
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
configurePhase = ''
cat <<EOF > Makefile.local
UNIX_ABSL_DIR=${abseil-cpp}
UNIX_GFLAGS_DIR=${google-gflags}
UNIX_GFLAGS_DIR=${gflags}
UNIX_GLOG_DIR=${glog}
UNIX_PROTOBUF_DIR=${protobuf}
UNIX_CBC_DIR=${cbc}
@@ -50,7 +50,7 @@ stdenv.mkDerivation rec {
python.pkgs.setuptools python.pkgs.wheel
];
propagatedBuildInputs = [
abseil-cpp google-gflags glog protobuf cbc
abseil-cpp gflags glog protobuf cbc
pythonProtobuf python.pkgs.six
];
@@ -0,0 +1,42 @@
{ stdenv, lib, fetchurl, gfortran, pkgconfig
, blas, zlib, bzip2
, withGurobi ? false, gurobi
, withCplex ? false, cplex }:
stdenv.mkDerivation rec {
pname = "osi";
version = "0.108.4";
src = fetchurl {
url = "https://www.coin-or.org/download/source/Osi/Osi-${version}.tgz";
sha256 = "13bwhdh01g37vp3kjwl9nvij5s5ikh5f7zgrqgwrqfyk35q2x9s5";
};
buildInputs =
[ blas zlib bzip2 ]
++ lib.optional withGurobi gurobi
++ lib.optional withCplex cplex;
nativeBuildInputs = [ gfortran pkgconfig ];
configureFlags =
lib.optionals withGurobi [ "--with-gurobi-incdir=${gurobi}/include" "--with-gurobi-lib=-lgurobi${gurobi.libSuffix}" ]
++ lib.optionals withCplex [ "--with-cplex-incdir=${cplex}/cplex/include/ilcplex" "--with-cplex-lib=-lcplex${cplex.libSuffix}" ];
NIX_LDFLAGS =
lib.optional withCplex "-L${cplex}/cplex/bin/${cplex.libArch}";
# Compile errors
NIX_CFLAGS_COMPILE = [ "-Wno-cast-qual" ];
hardeningDisable = [ "format" ];
enableParallelBuilding = true;
passthru = { inherit withGurobi withCplex; };
meta = with stdenv.lib; {
description = "An abstract base class to a generic linear programming (LP) solver";
homepage = "https://github.com/coin-or/Osi";
license = licenses.epl10;
platforms = platforms.unix;
maintainers = with maintainers; [ abbradar ];
};
}
@@ -0,0 +1,48 @@
{ stdenv, fetchurl, gfortran, perl }:
stdenv.mkDerivation rec {
pname = "spooles";
version = "2.2";
src = fetchurl {
url = "http://www.netlib.org/linalg/spooles/spooles.${version}.tgz";
sha256 = "1pf5z3vvwd8smbpibyabprdvcmax0grzvx2y0liy98c7x6h5jid8";
};
sourceRoot = ".";
patches = [
./spooles.patch
];
buildPhase = ''
make lib
'';
installPhase = ''
mkdir -p $out/lib $out/include/spooles
cp libspooles.a libspooles.so.2.2 $out/lib/
ln -s libspooles.so.2.2 $out/lib/libspooles.so.2
ln -s libspooles.so.2 $out/lib/libspooles.so
for h in *.h; do
if [ $h != 'MPI.h' ]; then
cp $h $out/include/spooles
d=`basename $h .h`
if [ -d $d ]; then
mkdir $out/include/spooles/$d
cp $d/*.h $out/include/spooles/$d
fi
fi
done
'';
nativeBuildInputs = [ perl ];
meta = with stdenv.lib; {
homepage = "http://www.netlib.org/linalg/spooles/";
description = "Library for solving sparse real and complex linear systems of equations";
license = licenses.publicDomain;
maintainers = with maintainers; [ gebner ];
platforms = platforms.unix;
};
}
@@ -0,0 +1,188 @@
diff --git a/I2Ohash/src/util.c b/I2Ohash/src/util.c
index 72d082e..f32f667 100644
--- a/I2Ohash/src/util.c
+++ b/I2Ohash/src/util.c
@@ -39,9 +39,10 @@ fflush(stdout) ;
*/
loc1 = (key1 + 1) % hashtable->nlist ;
loc2 = (key2 + 1) % hashtable->nlist ;
-loc = (loc1*loc2) % hashtable->nlist ;
+long int loc3 = (long int)loc1*(long int)loc2 % hashtable->nlist ;
+loc =(int) loc3;
#if MYDEBUG > 0
-fprintf(stdout, "\n loc1 = %d, loc2 = %d, loc3 = %d", loc1, loc2, loc) ;
+fprintf(stdout, "\n loc1 = %d, loc2 = %d, loc3 = %ld, loc = %d", loc1, loc2, loc3, loc) ;
fflush(stdout) ;
#endif
/*
@@ -158,9 +159,10 @@ fflush(stdout) ;
#endif
loc1 = (key1 + 1) % hashtable->nlist ;
loc2 = (key2 + 1) % hashtable->nlist ;
-loc = (loc1*loc2) % hashtable->nlist ;
+long int loc3 = (long int)loc1*(long int)loc2 % hashtable->nlist ;
+loc =(int) loc3;
#if MYDEBUG > 0
-fprintf(stdout, "\n loc1 = %d, loc2 = %d, loc3 = %d", loc1, loc2, loc) ;
+fprintf(stdout, "\n loc1 = %d, loc2 = %d, loc3 = %ld, loc = %d", loc1, loc2, loc3, loc) ;
fflush(stdout) ;
#endif
/*
diff --git a/MPI/makefile b/MPI/makefile
index 0c09f86..d25e70a 100644
--- a/MPI/makefile
+++ b/MPI/makefile
@@ -2,7 +2,7 @@ all_drivers :
cd drivers ; make drivers
lib :
- cd src ; make spoolesMPI.a
+ cd src ; make makeLib
clean :
cd src ; make clean
diff --git a/MPI/src/makefile b/MPI/src/makefile
index f7650b7..71e4c49 100644
--- a/MPI/src/makefile
+++ b/MPI/src/makefile
@@ -42,3 +42,8 @@ $(OBJ).a : \
clean :
- rm -f *.a *.o
+
+makeLib :
+ perl ../../makeLib > makeG
+ make -f makeG
+ rm -f makeG
diff --git a/MT/makefile b/MT/makefile
index 9b86a32..d25e70a 100644
--- a/MT/makefile
+++ b/MT/makefile
@@ -2,7 +2,7 @@ all_drivers :
cd drivers ; make drivers
lib :
- cd src ; make spoolesMT.a
+ cd src ; make makeLib
clean :
cd src ; make clean
diff --git a/Make.inc b/Make.inc
index f99eb8f..2de8a25 100644
--- a/Make.inc
+++ b/Make.inc
@@ -12,7 +12,7 @@
# for solaris
#
# CC = gcc
- CC = /usr/lang-4.0/bin/cc
+# CC = /usr/lang-4.0/bin/cc
#
# for sgi
#
@@ -28,7 +28,7 @@
#
# OPTLEVEL =
# OPTLEVEL = -g -v
- OPTLEVEL = -O
+ OPTLEVEL = -O3
# OPTLEVEL = -xO5 -v
# OPTLEVEL = -O3
# OPTLEVEL = -O4
@@ -43,7 +43,7 @@
# set any load flags
#
# LDFLAGS = -Wl,+parallel -Wl,+tm,spp2000 # for hp exemplar
- LDFLAGS =
+# LDFLAGS =
#
#---------------------------------------------------------------------
#
@@ -103,7 +103,7 @@
# MPI install library
#
# MPI_INSTALL_DIR =
- MPI_INSTALL_DIR = /usr/local/mpich-1.0.13
+# MPI_INSTALL_DIR = /usr/lib/openmpi
#
#---------------------------------------------------------------------
#
@@ -142,6 +142,6 @@
# MPI include path
#
# MPI_INCLUDE_DIR =
- MPI_INCLUDE_DIR = -I$(MPI_INSTALL_DIR)/include
+# MPI_INCLUDE_DIR = -I/usr/include/mpi
#
#---------------------------------------------------------------------
diff --git a/Utilities/src/iohb.c b/Utilities/src/iohb.c
index ac38f7b..ac34034 100644
--- a/Utilities/src/iohb.c
+++ b/Utilities/src/iohb.c
@@ -1725,7 +1725,7 @@ static void upcase(char* S)
static void IOHBTerminate(char* message)
{
- fprintf(stderr,message);
+ fputs(message, stderr);
exit(1);
}
diff --git a/makeLib b/makeLib
index 1780f39..7697b06 100755
--- a/makeLib
+++ b/makeLib
@@ -64,14 +64,19 @@ foreach $src ( @srcnames ) {
$srcname = " \\\n " . $src ;
print $srcname ;
}
+print "\n\n.SUFFIXES: .c .o .lo .a .so" ;
print "\n\nOBJ_FILES = \$\{SRC:.c=.o\}" ;
+print "\n\nLOBJ_FILES = \$\{SRC:.c=.lo\}" ;
print "\n\n" ;
print <<'EOF' ;
.c.o :
- $(PURIFY) $(CC) -c $(CFLAGS) $*.c -o $(OBJ)_$*.o
+ $(PURIFY) $(CC) -c $(CFLAGS) $*.c -o $(OBJ)_$*.o $(MPI_INCLUDE_DIR)
-../../spooles.a : ${OBJ_FILES}
- $(AR) $(ARFLAGS) ../../spooles.a $(OBJ)_*.o
+.c.lo :
+ $(PURIFY) $(CC) -c $(CFLAGS) $*.c -fPIC -DPIC -o $(OBJ)_$*.lo $(MPI_INCLUDE_DIR)
+
+../../libspooles.a : ${OBJ_FILES} ${LOBJ_FILES}
+ $(AR) $(ARFLAGS) ../../libspooles.a $(OBJ)_*.o
rm -f $(OBJ)_*.o
- $(RANLIB) ../../spooles.a
+ $(RANLIB) ../../libspooles.a
EOF
diff --git a/makefile b/makefile
index f014c7d..7c8042a 100755
--- a/makefile
+++ b/makefile
@@ -124,7 +124,9 @@ lib :
cd ZV ; make lib
cd misc ; make lib
#cd MPI ; make lib
-#cd MT ; make lib
+ cd MT ; make lib
+ gcc -shared */*/*.lo -Wl,-soname,libspooles.so.2.2 -o libspooles.so.2.2 -lpthread -lm
+ ln -s libspooles.so.2.2 libspooles.so
global :
cd A2/src ; make -f makeGlobalLib
diff --git a/timings.h b/timings.h
index 23df189..685800b 100644
--- a/timings.h
+++ b/timings.h
@@ -2,9 +2,8 @@
#define _TIMINGS_
#include <sys/time.h>
static struct timeval TV ;
-static struct timezone TZ ;
#define MARKTIME(t) \
- gettimeofday(&TV, &TZ) ; \
+ gettimeofday(&TV, NULL) ; \
t = (TV.tv_sec + 0.000001*TV.tv_usec)
#endif
@@ -1,89 +1,74 @@
{ stdenv
, fetchurl
, fetchpatch
, fetchFromGitLab
, makeWrapper
, which
, autoconf
, help2man
, file
, pari
}:
stdenv.mkDerivation rec {
version = "1.018.1";
version = "2.023.5";
name = "sympow-${version}";
src = fetchurl {
# Original website no longer reachable
url = "mirror://sageupstream/sympow/sympow-${version}.tar.bz2";
sha256 = "0hphs7ia1wr5mydf288zvwj4svrymfpadcg3pi6w80km2yg5bm3c";
src = fetchFromGitLab {
group = "rezozer";
owner = "forks";
repo = "sympow";
rev = "v${version}";
sha256 = "1c5a2pizgqsf3pjkf7rfj20022ym4ixhrddp8ivs2nbzxwz6qvv9";
};
postUnpack = ''
patchShebangs .
'';
nativeBuildInputs = [
makeWrapper
which
autoconf
help2man
file
pari
];
configurePhase = ''
runHook preConfigure
export PREFIX="$out"
export VARPREFIX="$out" # see comment on postInstall
./Configure # doesn't take any options
runHook postConfigure
'';
installPhase = ''
runHook preInstall
install -D datafiles/* --target-directory "$out/share/sympow/datafiles/"
install *.gp "$out/share/sympow/"
install -Dm755 sympow "$out/share/sympow/sympow"
install -D new_data "$out/bin/new_data"
makeWrapper "$out/share/sympow/sympow" "$out/bin/sympow" \
--run 'export SYMPOW_LOCAL="$HOME/.local/share/sympow"' \
--run 'if [ ! -d "$SYMPOW_LOCAL" ]; then
mkdir -p "$SYMPOW_LOCAL"
cp -r ${placeholder "out"}/share/sympow/* "$SYMPOW_LOCAL"
chmod -R +xw "$SYMPOW_LOCAL"
fi' \
--run 'cd "$SYMPOW_LOCAL"'
runHook postInstall
# Usually, sympow has 3 levels of caching: statically distributed in /usr/,
# shared in /var and per-user in ~/.sympow. The shared cache assumes trust in
# other users and a shared /var is not compatible with nix's approach, so we
# set VARPREFIX to the read-only $out. This effectively disables shared
# caching. See https://trac.sagemath.org/ticket/3360#comment:36 and sympow's
# README for more details on caching.
# sympow will complain at runtime about the lack of write-permissions on the
# shared cache. We pass the `-quiet` flag by default to disable this.
postInstall = ''
wrapProgram "$out/bin/sympow" --add-flags '-quiet'
'';
patches = [
# don't hardcode paths
(fetchpatch {
name = "do_not_hardcode_paths.patch";
url = "https://git.sagemath.org/sage.git/plain/build/pkgs/sympow/patches/Configure.patch?id=07d6c37d18811e2b377a9689790a7c5e24da16ba";
sha256 = "1611p8ra8zkxvmxn3gm2l64bd4ma4m6r4vd6vwswcic91k1fci04";
})
# bug on some platforms in combination with a newer gcc:
# https://trac.sagemath.org/ticket/11920
(fetchpatch {
name = "fix_newer_gcc1.patch";
url = "https://git.sagemath.org/sage.git/plain/build/pkgs/sympow/patches/fpu.patch?id=07d6c37d18811e2b377a9689790a7c5e24da16ba";
sha256 = "14gfa56w3ddfmd4d5ir9a40y2zi43cj1i4d2l2ij9l0qlqdy9jyx";
})
(fetchpatch {
name = "fix_newer_gcc2.patch";
url = "https://git.sagemath.org/sage.git/plain/build/pkgs/sympow/patches/execlp.patch?id=07d6c37d18811e2b377a9689790a7c5e24da16ba";
sha256 = "190gqhgz9wgw4lqwz0nwb1izc9zffx34bazsiw2a2sz94bmgb54v";
})
# fix pointer initialization bug (https://trac.sagemath.org/ticket/22862)
(fetchpatch {
name = "fix_pointer_initialization1.patch";
url = "https://git.sagemath.org/sage.git/plain/build/pkgs/sympow/patches/initialize-tacks.patch?id=07d6c37d18811e2b377a9689790a7c5e24da16ba";
sha256 = "02341vdbbidfs39s26vi4n5wigz619sw8fdbl0h9qsmwwhscgf85";
})
(fetchpatch {
name = "fix_pointer_initialization2.patch";
url = "https://git.archlinux.org/svntogit/community.git/plain/trunk/sympow-datafiles.patch?h=packages/sympow&id=5088e641a45b23d0385d8e63be65315129b4cf58";
sha256 = "1m0vz048layb47r1jjf7fplw650ccc9x0w3l322iqmppzmv3022a";
})
];
# Example from the README as a sanity check.
doInstallCheck = true;
installCheckPhase = ''
export HOME="$TMP/home"
mkdir -p "$HOME"
"$out/bin/sympow" -sp 2p16 -curve "[1,2,3,4,5]" | grep '8.3705'
'';
meta = with stdenv.lib; {
description = "A package to compute special values of symmetric power elliptic curve L-functions";
description = "Compute special values of symmetric power elliptic curve L-functions";
license = {
shortName = "sympow";
fullName = "Custom, BSD-like. See COPYING file.";
free = true;
};
maintainers = with maintainers; [ timokau ];
platforms = platforms.all;
platforms = platforms.linux;
};
}
@@ -0,0 +1,72 @@
{ stdenv
, fetchurl
, patchelf
, cudaSupport ? false, symlinkJoin, cudatoolkit, cudnn, nvidia_x11
}:
with stdenv.lib;
let
unavailable = throw "libtensorflow is not available for this platform!";
tfType = if cudaSupport then "gpu" else "cpu";
system =
if stdenv.isLinux then "linux"
else if stdenv.isDarwin then "darwin"
else unavailable;
platform =
if stdenv.isx86_64 then "x86_64"
else unavailable;
rpath = makeLibraryPath ([stdenv.cc.libc stdenv.cc.cc.lib] ++
optionals cudaSupport [ cudatoolkit.out cudatoolkit.lib cudnn nvidia_x11 ]);
packages = import ./binary-hashes.nix;
packageName = "${tfType}-${system}-${platform}";
url = packages.${packageName} or unavailable;
patchLibs =
if stdenv.isDarwin
then ''
install_name_tool -id $out/lib/libtensorflow.dylib $out/lib/libtensorflow.dylib
install_name_tool -id $out/lib/libtensorflow_framework.dylib $out/lib/libtensorflow_framework.dylib
''
else ''
patchelf --set-rpath "${rpath}:$out/lib" $out/lib/libtensorflow.so
patchelf --set-rpath "${rpath}" $out/lib/libtensorflow_framework.so
'';
in stdenv.mkDerivation rec {
pname = "libtensorflow";
inherit (packages) version;
src = fetchurl url;
# Patch library to use our libc, libstdc++ and others
buildCommand = ''
mkdir -pv $out
tar -C $out -xzf $src
chmod -R +w $out
${patchLibs}
# Write pkgconfig file.
mkdir $out/lib/pkgconfig
cat > $out/lib/pkgconfig/tensorflow.pc << EOF
Name: TensorFlow
Version: ${version}
Description: Library for computation using data flow graphs for scalable machine learning
Requires:
Libs: -L$out/lib -ltensorflow
Cflags: -I$out/include/tensorflow
EOF
'';
meta = {
description = "C API for TensorFlow";
homepage = https://www.tensorflow.org/install/lang_c;
license = licenses.asl20;
platforms = [ "x86_64-linux" "x86_64-darwin" ];
maintainers = with maintainers; [ basvandijk ];
};
}
@@ -0,0 +1,15 @@
{
version = "1.14.0";
"cpu-linux-x86_64" = {
url = "https://storage.googleapis.com/tensorflow/libtensorflow/libtensorflow-cpu-linux-x86_64-1.14.0.tar.gz";
sha256 = "04bi3ijq4sbb8c5vk964zlv0j9mrjnzzxd9q9knq3h273nc1a36k";
};
"gpu-linux-x86_64" = {
url = "https://storage.googleapis.com/tensorflow/libtensorflow/libtensorflow-gpu-linux-x86_64-1.14.0.tar.gz";
sha256 = "1ffnpyj9jjgwxpjfiyjvq4dm3n6nwiksim5jld9zw7fdswh215x6";
};
"cpu-darwin-x86_64" = {
url = "https://storage.googleapis.com/tensorflow/libtensorflow/libtensorflow-cpu-darwin-x86_64-1.14.0.tar.gz";
sha256 = "0zsd5ils1a17j6jzh0c7q1z56fw46gkzybbnms7h2rgg8al0rh92";
};
}
@@ -0,0 +1,24 @@
#!/usr/bin/env bash
version=1.14.0
hashfile=binary-hashes.nix
rm -f $hashfile
echo "{" >> $hashfile
echo "version = \"$version\";" >> $hashfile
for sys in "linux" "darwin"; do
for tfpref in "cpu" "gpu"; do
for platform in "x86_64"; do
if [ $sys = "darwin" ] && [ $tfpref = "gpu" ]; then
continue
fi
url=https://storage.googleapis.com/tensorflow/libtensorflow/libtensorflow-$tfpref-$sys-$platform-$version.tar.gz
hash=$(nix-prefetch-url $url)
echo "\"${tfpref}-${sys}-${platform}\" = {" >> $hashfile
echo " url = \"$url\";" >> $hashfile
echo " sha256 = \"$hash\";" >> $hashfile
echo "};" >> $hashfile
done
done
done
echo "}" >> $hashfile