diff --git a/tensorflow.spec b/tensorflow.spec index a9d1c38493e8aecc60736b3db2b7db845822bcf5..6bca0066b1be11848944620424217f77c0aaca42 100644 --- a/tensorflow.spec +++ b/tensorflow.spec @@ -199,7 +199,7 @@ TensorFlow provides stable Python and C++ APIs, as well as non-guaranteed backwa Summary: An Open Source Machine Learning Framework for Everyone Provides: python-tensorflow #It is because external-$(arch).tar.bz2 is built on bazel 3.5.0 -BuildRequires: bazel == 3.5.0 gcc gcc-c++ +BuildRequires: bazel == 3.5.0 gcc gcc-c++ chrpath BuildRequires: python3-numpy python3-devel python3-Keras-Preprocessing BuildRequires: python3-pip python3-wheel @@ -225,12 +225,36 @@ bazel --output_user_root=`pwd`/../output_user_root build --host_copt=-Wno-string %install %py3_install_wheel * +chrpath -d %{buildroot}%{_libdir}/python3.8/site-packages/tensorflow/libtensorflow_framework.so.2 +chrpath -d %{buildroot}%{_libdir}/python3.8/site-packages/tensorflow/core/kernels/*.so +chrpath -d %{buildroot}%{_libdir}/python3.8/site-packages/tensorflow/python/*.so +chrpath -d %{buildroot}%{_libdir}/python3.8/site-packages/tensorflow/python/autograph/impl/testing/*.so +chrpath -d %{buildroot}%{_libdir}/python3.8/site-packages/tensorflow/python/profiler/internal/*.so +chrpath -d %{buildroot}%{_libdir}/python3.8/site-packages/tensorflow/python/data/experimental/service/*.so +chrpath -d %{buildroot}%{_libdir}/python3.8/site-packages/tensorflow/compiler/tf2xla/ops/*.so +chrpath -d %{buildroot}%{_libdir}/python3.8/site-packages/tensorflow/compiler/tf2tensorrt/*.so +chrpath -d %{buildroot}%{_libdir}/python3.8/site-packages/tensorflow/lite/python/optimize/*.so +chrpath -d %{buildroot}%{_libdir}/python3.8/site-packages/tensorflow/lite/python/interpreter_wrapper/*.so +chrpath -d %{buildroot}%{_libdir}/python3.8/site-packages/tensorflow/lite/experimental//microfrontend/python/ops/*.so + +mkdir -p %{buildroot}/etc/ld.so.conf.d +echo "%{_libdir}/openmpi/lib" > %{buildroot}/etc/ld.so.conf.d/%{name}-%{_arch}.conf + +%post +/sbin/ldconfig + +%postun +/sbin/ldconfig %files -n python3-tensorflow %{python3_sitearch}/* %{_bindir}/* +%config(noreplace) /etc/ld.so.conf.d/* + %changelog +* Thu Stp 10 2021 Shaowei Cheng - 2.3.1-9 +- fix rpath * Mon Sep 13 2021 houyingchao - 2.3.1-9 - Fix CVE-2020-26267 CVE-2021-29515 CVE-2021-29551 CVE-2021-37645 CVE-2021-37681 CVE-2021-29516 CVE-2021-37679