!2 init package
From: @xiezhipeng1 Reviewed-by: @sinever Signed-off-by: @sinever
This commit is contained in:
commit
c6208c3088
25
0001-Add-arm-source-file-into-aws-checksums.patch
Normal file
25
0001-Add-arm-source-file-into-aws-checksums.patch
Normal file
@ -0,0 +1,25 @@
|
|||||||
|
From c6f06c2f1b17508670601894378bb89b71fbe37e Mon Sep 17 00:00:00 2001
|
||||||
|
From: bzhaoopenstack <bzhaojyathousandy@gmail.com>
|
||||||
|
Date: Tue, 23 Jun 2020 12:04:12 +0800
|
||||||
|
Subject: [PATCH] Add arm source file into aws-checksums
|
||||||
|
|
||||||
|
According to https://github.com/tensorflow/tensorflow/issues/40463#issuecomment-647640030 , seem the aws libs need to add the arm related libs during build tensorflow package.
|
||||||
|
---
|
||||||
|
third_party/aws/aws-checksums.bazel | 1 +
|
||||||
|
1 file changed, 1 insertion(+)
|
||||||
|
|
||||||
|
diff --git a/third_party/aws/aws-checksums.bazel b/third_party/aws/aws-checksums.bazel
|
||||||
|
index 759cb2e6fc..f620a96d2c 100644
|
||||||
|
--- a/third_party/aws/aws-checksums.bazel
|
||||||
|
+++ b/third_party/aws/aws-checksums.bazel
|
||||||
|
@@ -16,6 +16,7 @@ cc_library(
|
||||||
|
"//conditions:default": [],
|
||||||
|
}) + glob([
|
||||||
|
"source/intel/*.c",
|
||||||
|
+ "source/arm/*.c",
|
||||||
|
"source/*.c",
|
||||||
|
]),
|
||||||
|
hdrs = glob([
|
||||||
|
--
|
||||||
|
2.23.0
|
||||||
|
|
||||||
36
README.en.md
36
README.en.md
@ -1,36 +0,0 @@
|
|||||||
# tensorflow
|
|
||||||
|
|
||||||
#### Description
|
|
||||||
A framework for deep learning
|
|
||||||
|
|
||||||
#### Software Architecture
|
|
||||||
Software architecture description
|
|
||||||
|
|
||||||
#### Installation
|
|
||||||
|
|
||||||
1. xxxx
|
|
||||||
2. xxxx
|
|
||||||
3. xxxx
|
|
||||||
|
|
||||||
#### Instructions
|
|
||||||
|
|
||||||
1. xxxx
|
|
||||||
2. xxxx
|
|
||||||
3. xxxx
|
|
||||||
|
|
||||||
#### Contribution
|
|
||||||
|
|
||||||
1. Fork the repository
|
|
||||||
2. Create Feat_xxx branch
|
|
||||||
3. Commit your code
|
|
||||||
4. Create Pull Request
|
|
||||||
|
|
||||||
|
|
||||||
#### Gitee Feature
|
|
||||||
|
|
||||||
1. You can use Readme\_XXX.md to support different languages, such as Readme\_en.md, Readme\_zh.md
|
|
||||||
2. Gitee blog [blog.gitee.com](https://blog.gitee.com)
|
|
||||||
3. Explore open source project [https://gitee.com/explore](https://gitee.com/explore)
|
|
||||||
4. The most valuable open source project [GVP](https://gitee.com/gvp)
|
|
||||||
5. The manual of Gitee [https://gitee.com/help](https://gitee.com/help)
|
|
||||||
6. The most popular members [https://gitee.com/gitee-stars/](https://gitee.com/gitee-stars/)
|
|
||||||
37
README.md
37
README.md
@ -1,37 +0,0 @@
|
|||||||
# tensorflow
|
|
||||||
|
|
||||||
#### 介绍
|
|
||||||
A framework for deep learning
|
|
||||||
|
|
||||||
#### 软件架构
|
|
||||||
软件架构说明
|
|
||||||
|
|
||||||
|
|
||||||
#### 安装教程
|
|
||||||
|
|
||||||
1. xxxx
|
|
||||||
2. xxxx
|
|
||||||
3. xxxx
|
|
||||||
|
|
||||||
#### 使用说明
|
|
||||||
|
|
||||||
1. xxxx
|
|
||||||
2. xxxx
|
|
||||||
3. xxxx
|
|
||||||
|
|
||||||
#### 参与贡献
|
|
||||||
|
|
||||||
1. Fork 本仓库
|
|
||||||
2. 新建 Feat_xxx 分支
|
|
||||||
3. 提交代码
|
|
||||||
4. 新建 Pull Request
|
|
||||||
|
|
||||||
|
|
||||||
#### 码云特技
|
|
||||||
|
|
||||||
1. 使用 Readme\_XXX.md 来支持不同的语言,例如 Readme\_en.md, Readme\_zh.md
|
|
||||||
2. 码云官方博客 [blog.gitee.com](https://blog.gitee.com)
|
|
||||||
3. 你可以 [https://gitee.com/explore](https://gitee.com/explore) 这个地址来了解码云上的优秀开源项目
|
|
||||||
4. [GVP](https://gitee.com/gvp) 全称是码云最有价值开源项目,是码云综合评定出的优秀开源项目
|
|
||||||
5. 码云官方提供的使用手册 [https://gitee.com/help](https://gitee.com/help)
|
|
||||||
6. 码云封面人物是一档用来展示码云会员风采的栏目 [https://gitee.com/gitee-stars/](https://gitee.com/gitee-stars/)
|
|
||||||
BIN
external-aarch64.tar.bz2
Normal file
BIN
external-aarch64.tar.bz2
Normal file
Binary file not shown.
BIN
external-x86_64.tar.bz2
Normal file
BIN
external-x86_64.tar.bz2
Normal file
Binary file not shown.
2830
resolved-aarch64.bzl
Normal file
2830
resolved-aarch64.bzl
Normal file
File diff suppressed because it is too large
Load Diff
2864
resolved-x86_64.bzl
Normal file
2864
resolved-x86_64.bzl
Normal file
File diff suppressed because it is too large
Load Diff
BIN
tensorflow-2.3.1.tar.gz
Normal file
BIN
tensorflow-2.3.1.tar.gz
Normal file
Binary file not shown.
61
tensorflow.spec
Normal file
61
tensorflow.spec
Normal file
@ -0,0 +1,61 @@
|
|||||||
|
%global _empty_manifest_terminate_build 0
|
||||||
|
Name: tensorflow
|
||||||
|
Version: 2.3.1
|
||||||
|
Release: 1
|
||||||
|
Summary: An Open Source Machine Learning Framework for Everyone
|
||||||
|
License: Apache License 2.0
|
||||||
|
URL: https://www.tensorflow.org/
|
||||||
|
Source0: https://github.com/tensorflow/tensorflow/archive/v%{version}.tar.gz#/tensorflow-%{version}.tar.gz
|
||||||
|
#sh -x updateSource1.sh
|
||||||
|
Source1: external-%{_arch}.tar.bz2
|
||||||
|
|
||||||
|
Patch0001: 0001-Add-arm-source-file-into-aws-checksums.patch
|
||||||
|
|
||||||
|
Requires: python3-future
|
||||||
|
Requires: python3-numpy
|
||||||
|
|
||||||
|
%description
|
||||||
|
TensorFlow is an end-to-end open source platform for machine learning. It has a comprehensive, flexible ecosystem of tools, libraries, and community resources that lets researchers push the state-of-the-art in ML and developers easily build and deploy ML-powered applications.
|
||||||
|
|
||||||
|
TensorFlow was originally developed by researchers and engineers working on the Google Brain team within Google's Machine Intelligence Research organization to conduct machine learning and deep neural networks research. The system is general enough to be applicable in a wide variety of other domains, as well.
|
||||||
|
|
||||||
|
TensorFlow provides stable Python and C++ APIs, as well as non-guaranteed backward compatible API for other languages.
|
||||||
|
|
||||||
|
%package -n python3-tensorflow
|
||||||
|
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
|
||||||
|
BuildRequires: python3-numpy python3-devel python3-Keras-Preprocessing
|
||||||
|
BuildRequires: python3-pip python3-wheel
|
||||||
|
|
||||||
|
%description -n python3-tensorflow
|
||||||
|
TensorFlow is an end-to-end open source platform for machine learning. It has a comprehensive, flexible ecosystem of tools, libraries, and community resources that lets researchers push the state-of-the-art in ML and developers easily build and deploy ML-powered applications.
|
||||||
|
|
||||||
|
TensorFlow was originally developed by researchers and engineers working on the Google Brain team within Google's Machine Intelligence Research organization to conduct machine learning and deep neural networks research. The system is general enough to be applicable in a wide variety of other domains, as well.
|
||||||
|
|
||||||
|
TensorFlow provides stable Python and C++ APIs, as well as non-guaranteed backward compatible API for other languages.
|
||||||
|
|
||||||
|
%prep
|
||||||
|
%autosetup -p1
|
||||||
|
extdir=$(bazel --output_user_root=`pwd`/../output_user_root info output_base)
|
||||||
|
mkdir -p ${extdir}
|
||||||
|
tar xf %{SOURCE1} -C ${extdir}
|
||||||
|
ln -sfn $(find ${extdir}/../install -name embedded_tools) ${extdir}/external/bazel_tools
|
||||||
|
ln -sfn $(find ${extdir}/../install -maxdepth 2 -name platforms) ${extdir}/external/platforms
|
||||||
|
rm -rf ${extdir}/external/local_config*
|
||||||
|
|
||||||
|
%build
|
||||||
|
bazel --output_user_root=`pwd`/../output_user_root build //tensorflow/tools/pip_package:build_pip_package
|
||||||
|
./bazel-bin/tensorflow/tools/pip_package/build_pip_package dist
|
||||||
|
|
||||||
|
%install
|
||||||
|
%py3_install_wheel *
|
||||||
|
|
||||||
|
%files -n python3-tensorflow
|
||||||
|
%{python3_sitearch}/*
|
||||||
|
%{_bindir}/*
|
||||||
|
|
||||||
|
%changelog
|
||||||
|
* Wed Sep 30 2020 Zhipeng Xie<xiezhipeng1@huawei.com> - 2.3.1-1
|
||||||
|
- Package init
|
||||||
4
tensorflow.yaml
Normal file
4
tensorflow.yaml
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
version_control: github
|
||||||
|
src_repo: tensorflow/tensorflow
|
||||||
|
tag_prefix: ^v
|
||||||
|
seperator: .
|
||||||
23
updateSource1.sh
Normal file
23
updateSource1.sh
Normal file
@ -0,0 +1,23 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
set -e
|
||||||
|
version=2.3.1
|
||||||
|
topdir=$(pwd)
|
||||||
|
builddir=/home/abuild/rpmbuild/BUILD
|
||||||
|
rm -rf ${builddir}
|
||||||
|
mkdir -p ${builddir}
|
||||||
|
cp tensorflow-${version}.tar.gz ${builddir}
|
||||||
|
cd ${builddir}
|
||||||
|
rm -rf tensorflow-${version}
|
||||||
|
rm -rf output_user_root
|
||||||
|
tar xf tensorflow-${version}.tar.gz
|
||||||
|
cd tensorflow-${version}
|
||||||
|
patch -p1 < ${topdir}/0001-Add-arm-source-file-into-aws-checksums.patch
|
||||||
|
#some packages will be checked in build
|
||||||
|
bazel --output_user_root=`pwd`/../output_user_root build //tensorflow/tools/pip_package:build_pip_package --experimental_repository_resolved_file=${topdir}/resolved-$(arch).bzl
|
||||||
|
bazel --output_user_root=`pwd`/../output_user_root clean
|
||||||
|
extdir=$(bazel --output_user_root=`pwd`/../output_user_root info output_base)
|
||||||
|
cd ${extdir}
|
||||||
|
rm -rf ${extdir}/external/local_config*
|
||||||
|
tar -cjf external-$(arch).tar.bz2 external
|
||||||
|
mv external-$(arch).tar.bz2 ${topdir}
|
||||||
|
cd ${topdir}
|
||||||
Loading…
x
Reference in New Issue
Block a user