Diff tensorflow-2.4.0 with a tensorflow-2.5.0

/usr/portage/sci-libs/tensorflow/tensorflow-2.5.0.ebuild 2021-06-21 01:10:00.000000000 +0300
25 25

  
26 26
# distfiles that bazel uses for the workspace, will be copied to basel-distdir
27 27
bazel_external_uris="
28
	https://github.com/petewarden/OouraFFT/archive/v1.0.tar.gz -> OouraFFT-v1.0.tar.gz
29
	https://gitlab.com/libeigen/eigen/-/archive/011e0db31d1bed8b7f73662be6d57d9f30fa457a/eigen-011e0db31d1bed8b7f73662be6d57d9f30fa457a.tar.gz
30
	https://github.com/abseil/abseil-cpp/archive/df3ea785d8c30a9503321a3d35ee7d35808f190d.tar.gz -> abseil-cpp-df3ea785d8c30a9503321a3d35ee7d35808f190d.tar.gz
31
	https://github.com/bazelbuild/bazel-skylib/releases/download/0.9.0/bazel_skylib-0.9.0.tar.gz
32
	https://github.com/bazelbuild/rules_android/archive/v0.1.1.zip -> bazelbuild-rules_android-v0.1.1.zip
28
	https://github.com/abseil/abseil-cpp/archive/6f9d96a1f41439ac172ee2ef7ccd8edf0e5d068c.tar.gz -> abseil-cpp-6f9d96a1f41439ac172ee2ef7ccd8edf0e5d068c.tar.gz
29
	https://github.com/bazelbuild/bazel-skylib/releases/download/1.0.3/bazel-skylib-1.0.3.tar.gz
33 30
	https://github.com/bazelbuild/bazel-toolchains/archive/92dd8a7a518a2fb7ba992d47c8b38299fe0be825.tar.gz -> bazel-toolchains-92dd8a7a518a2fb7ba992d47c8b38299fe0be825.tar.gz
31
	https://github.com/bazelbuild/rules_android/archive/v0.1.1.zip -> bazelbuild-rules_android-v0.1.1.zip
34 32
	https://github.com/bazelbuild/rules_cc/archive/01d4a48911d5e7591ecb1c06d3b8af47fe872371.zip -> bazelbuild-rules_cc-01d4a48911d5e7591ecb1c06d3b8af47fe872371.zip
35 33
	https://github.com/bazelbuild/rules_closure/archive/308b05b2419edb5c8ee0471b67a40403df940149.tar.gz -> bazelbuild-rules_closure-308b05b2419edb5c8ee0471b67a40403df940149.tar.gz
36 34
	https://github.com/bazelbuild/rules_docker/releases/download/v0.10.0/rules_docker-v0.10.0.tar.gz -> bazelbuild-rules_docker-v0.10.0.tar.gz
......
43 41
	https://github.com/google/gemmlowp/archive/fda83bdc38b118cc6b56753bd540caa49e570745.zip -> gemmlowp-fda83bdc38b118cc6b56753bd540caa49e570745.zip
44 42
	https://github.com/google/highwayhash/archive/fd3d9af80465e4383162e4a7c5e2f406e82dd968.tar.gz -> highwayhash-fd3d9af80465e4383162e4a7c5e2f406e82dd968.tar.gz
45 43
	https://github.com/google/re2/archive/506cfa4bffd060c06ec338ce50ea3468daa6c814.tar.gz -> re2-506cfa4bffd060c06ec338ce50ea3468daa6c814.tar.gz
44
	https://github.com/google/ruy/archive/54774a7a2cf85963777289193629d4bd42de4a59.zip -> ruy-54774a7a2cf85963777289193629d4bd42de4a59.zip
46 45
	https://github.com/joe-kuo/sobol_data/archive/835a7d7b1ee3bc83e575e302a985c66ec4b65249.tar.gz -> sobol_data-835a7d7b1ee3bc83e575e302a985c66ec4b65249.tar.gz
47
	https://github.com/llvm/llvm-project/archive/f402e682d0ef5598eeffc9a21a691b03e602ff58.tar.gz -> llvm-f402e682d0ef5598eeffc9a21a691b03e602ff58.tar.gz
46
	https://github.com/llvm/llvm-project/archive/1f6a57c1a0fad922e04a2b1f414b092d4b0cd8b0.tar.gz -> llvm-1f6a57c1a0fad922e04a2b1f414b092d4b0cd8b0.tar.gz
47
	https://github.com/llvm/llvm-project/releases/download/llvmorg-10.0.1/openmp-10.0.1.src.tar.xz -> llvmorg-10.0.1-openmp-10.0.1.src.tar.xz
48 48
	https://github.com/mborgerding/kissfft/archive/36dbc057604f00aacfc0288ddad57e3b21cfc1b8.tar.gz -> kissfft-36dbc057604f00aacfc0288ddad57e3b21cfc1b8.tar.gz
49
	https://github.com/google/ruy/archive/5bb02fbf90824c2eb6cd7418f766c593106a332b.zip -> ruy-5bb02fbf90824c2eb6cd7418f766c593106a332b.zip
49
	https://github.com/oneapi-src/oneDNN/archive/v2.2.tar.gz -> oneDNN-v2.2.tar.gz
50
	https://github.com/petewarden/OouraFFT/archive/v1.0.tar.gz -> OouraFFT-v1.0.tar.gz
51
	https://github.com/pytorch/cpuinfo/archive/5916273f79a21551890fd3d56fc5375a78d1598d.zip -> pytorch-cpuinfo-5916273f79a21551890fd3d56fc5375a78d1598d.zip
50 52
	https://github.com/pytorch/cpuinfo/archive/d5e37adf1406cf899d7d9ec1d317c47506ccb970.tar.gz -> pytorch-cpuinfo-d5e37adf1406cf899d7d9ec1d317c47506ccb970.tar.gz
51
	https://github.com/pytorch/cpuinfo/archive/6cecd15784fcb6c5c0aa7311c6248879ce2cb8b2.zip -> pytorch-cpuinfo-6cecd15784fcb6c5c0aa7311c6248879ce2cb8b2.zip
53
	https://github.com/tensorflow/toolchains/archive/v1.1.10.tar.gz -> tensorflow-toolchains-v1.1.10.tar.gz
54
	https://gitlab.com/libeigen/eigen/-/archive/f612df273689a19d25b45ca4f8269463207c4fee/eigen-f612df273689a19d25b45ca4f8269463207c4fee.tar.gz
52 55
	cuda? (
53
		https://github.com/nvidia/nccl/archive/195232556936b39b01cc908296e1650b80d4a3e9.tar.gz -> nvidia-nccl-195232556936b39b01cc908296e1650b80d4a3e9.tar.gz
56
		https://github.com/NVIDIA/cudnn-frontend/archive/360d6e7164dfb7c802493fd1c0464f0d815b852a.zip -> cudnn-frontend-360d6e7164dfb7c802493fd1c0464f0d815b852a.zip
54 57
		https://github.com/NVlabs/cub/archive/1.9.9.zip -> cub-1.9.9.zip
58
		https://github.com/nvidia/nccl/archive/v2.8.3-1.tar.gz -> nvidia-nccl-v2.8.3-1.tar.gz
55 59
	)
56 60
	python? (
57 61
		https://github.com/intel/ARM_NEON_2_x86_SSE/archive/1200fe90bb174a6224a525ee60148671a786a71f.tar.gz -> ARM_NEON_2_x86_SSE-1200fe90bb174a6224a525ee60148671a786a71f.tar.gz
......
85 89
	cuda? (
86 90
		|| (
87 91
			( =dev-util/nvidia-cuda-toolkit-11.1*[profiler] =dev-libs/cudnn-8* )
92
			( =dev-util/nvidia-cuda-toolkit-11.2*[profiler] =dev-libs/cudnn-8* )
88 93
		)
89 94
	)
90 95
	mpi? ( virtual/mpi )
......
112 117
		>=net-libs/google-cloud-cpp-0.10.0
113 118
		>=sci-libs/keras-applications-1.0.8[${PYTHON_USEDEP}]
114 119
		>=sci-libs/keras-preprocessing-1.1.2[${PYTHON_USEDEP}]
115
		>=sci-visualization/tensorboard-2.4.0[${PYTHON_USEDEP}]
120
		>=sci-visualization/tensorboard-2.5.0[${PYTHON_USEDEP}]
116 121
	)"
117 122
DEPEND="${RDEPEND}
118 123
	python? (
......
120 125
		dev-python/setuptools
121 126
	)"
122 127
PDEPEND="python? (
123
		>=sci-libs/tensorflow-estimator-2.4.0[${PYTHON_USEDEP}]
128
		>=sci-libs/tensorflow-estimator-2.5.0[${PYTHON_USEDEP}]
124 129
	)"
125 130
BDEPEND="
126 131
	app-arch/unzip
127 132
	>=dev-libs/protobuf-3.8.0
128 133
	dev-java/java-config
129
	=dev-util/bazel-3*
130
	virtual/pkgconfig
134
	>=dev-util/bazel-3.7.2
131 135
	cuda? (
132 136
		>=dev-util/nvidia-cuda-toolkit-9.1[profiler]
133 137
	)
......
189 193

  
190 194
	# Relax version checks in setup.py
191 195
	sed -i "/^    '/s/==/>=/g" tensorflow/tools/pip_package/setup.py || die
192
	sed -i "/config_googleapis/d" WORKSPACE || die
196
	sed -i "/config_googleapis/d" tensorflow/workspace0.bzl || die
193 197

  
194 198
	# Prefixify hard-coded command locations
195 199
	hprefixify -w /host_compiler_prefix/ third_party/gpus/cuda_configure.bzl
......
202 206

  
203 207
src_configure() {
204 208
	export JAVA_HOME=$(java-config --jre-home) # so keepwork works
209
	export KERAS_HOME="${T}/.keras" # otherwise sandbox violation writing ~/.keras
205 210

  
206 211
	do_configure() {
207 212
		export CC_OPT_FLAGS=" "
......
242 247
			fi
243 248

  
244 249
			if [[ -z "$TF_CUDA_COMPUTE_CAPABILITIES" ]]; then
245
				ewarn "WARNING: Tensorflow is being built with its default CUDA compute capabilities: 3.5 and 7.0."
250
				ewarn "WARNING: TensorFlow is being built with its default CUDA compute capabilities: 3.5 and 7.0."
246 251
				ewarn "These may not be optimal for your GPU."
247 252
				ewarn ""
248
				ewarn "To configure Tensorflow with the CUDA compute capability that is optimal for your GPU,"
253
				ewarn "To configure TensorFlow with the CUDA compute capability that is optimal for your GPU,"
249 254
				ewarn "set TF_CUDA_COMPUTE_CAPABILITIES in your make.conf, and re-emerge tensorflow."
250 255
				ewarn "For example, to use CUDA capability 7.5 & 3.5, add: TF_CUDA_COMPUTE_CAPABILITIES=7.5,3.5"
251 256
				ewarn ""
......
255 260
		fi
256 261

  
257 262
		# com_googlesource_code_re2 weird branch using absl, doesnt work with released re2
263
		#com_github_googleapis_googleapis
258 264
		local SYSLIBS=(
259 265
			absl_py
260 266
			astor_archive
261 267
			astunparse_archive
262 268
			boringssl
263
			com_github_googleapis_googleapis
264 269
			com_github_googlecloudplatform_google_cloud_cpp
265 270
			com_github_grpc_grpc
266 271
			com_google_protobuf
......
303 308

  
304 309
		echo 'build --config=noaws --config=nohdfs' >> .bazelrc || die
305 310
		echo 'build --define tensorflow_mkldnn_contraction_kernel=0' >> .bazelrc || die
311
		echo "build --action_env=KERAS_HOME=\"${T}/.keras\"" >> .bazelrc || die
312
		echo "build --host_action_env=KERAS_HOME=\"${T}/.keras\"" >> .bazelrc || die
306 313

  
307 314
		for cflag in $($(tc-getPKG_CONFIG) jsoncpp --cflags)
308 315
		do
309
			echo "build --copt=\"$cflag\"" >> .bazelrc || die
310
			echo "build --host_copt=\"$cflag\"" >> .bazelrc || die
316
			echo "build --copt=\"${cflag}\"" >> .bazelrc || die
317
			echo "build --host_copt=\"${cflag}\"" >> .bazelrc || die
311 318
		done
312 319
	}
313 320
	if use python; then
......
319 326

  
320 327
src_compile() {
321 328
	export JAVA_HOME=$(java-config --jre-home) # so keepwork works
329
	export KERAS_HOME="${T}/.keras" # otherwise sandbox violation writing ~/.keras
322 330

  
323 331
	if use python; then
324 332
		python_setup
......
350 358
src_install() {
351 359
	local i j
352 360
	export JAVA_HOME=$(java-config --jre-home) # so keepwork works
361
	export KERAS_HOME="${T}/.keras" # otherwise sandbox violation writing ~/.keras
353 362

  
354 363
	do_install() {
355 364
		einfo "Installing ${EPYTHON} files"
Thank you!