You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@teaclave.apache.org by di...@apache.org on 2020/04/20 05:55:14 UTC

[incubator-teaclave-sgx-sdk] branch v1.1.2-testing updated: Add unfinished centos

This is an automated email from the ASF dual-hosted git repository.

dingyu pushed a commit to branch v1.1.2-testing
in repository https://gitbox.apache.org/repos/asf/incubator-teaclave-sgx-sdk.git


The following commit(s) were added to refs/heads/v1.1.2-testing by this push:
     new ae240ed  Add unfinished centos
     new 93c9521  Merge branch 'v1.1.2-testing' of github.com:baidu/rust-sgx-sdk into v1.1.2-testing
ae240ed is described below

commit ae240edb4dfbb8a7cb4c4952f68948c0ce16210f
Author: Yu Ding <di...@gmail.com>
AuthorDate: Sun Apr 19 22:54:28 2020 -0700

    Add unfinished centos
---
 dockerfile/03_protobuf.sh                        |   4 +
 dockerfile/04_psw_rpm.sh                         |  15 ++
 dockerfile/Dockerfile.centos7.notworking.nightly |  45 ++++++
 dockerfile/Dockerfile.fedora27.nightly           |   4 +-
 dockerfile/centos_dcap_patch                     |  34 ++++
 dockerfile/centos_patch                          | 189 +++++++++++++++++++++++
 6 files changed, 289 insertions(+), 2 deletions(-)

diff --git a/dockerfile/03_protobuf.sh b/dockerfile/03_protobuf.sh
new file mode 100644
index 0000000..1426f92
--- /dev/null
+++ b/dockerfile/03_protobuf.sh
@@ -0,0 +1,4 @@
+cd /root && wget -O /root/v3.11.4.tar.gz https://github.com/google/protobuf/archive/v3.11.4.tar.gz && \
+tar xzf v3.11.4.tar.gz && \
+cd /root/protobuf-3.11.4 && \
+./autogen.sh && ./configure && make -j && make -j install && ldconfig && cd .. && rm -rf protobuf-3.11.4 v3.11.4.tar.gz
diff --git a/dockerfile/04_psw_rpm.sh b/dockerfile/04_psw_rpm.sh
new file mode 100644
index 0000000..2750f59
--- /dev/null
+++ b/dockerfile/04_psw_rpm.sh
@@ -0,0 +1,15 @@
+source /opt/sgxsdk/environment && \
+cd /root && \
+git clone --recursive https://github.com/intel/linux-sgx && \
+cd linux-sgx && \
+git checkout sgx_2.9.1 && \
+git apply /root/centos_patch && \
+./download_prebuilt.sh && \
+cd external/dcap_source && \
+git apply /root/centos_dcap_patch && \
+cd /root/linux-sgx && \
+echo 'source /opt/sgxsdk/environment' >> /root/.bashrc && \
+make rpm_local_repo
+#cd linux/installer/rpm && \
+#find . -maxdepth 2 -name '*.deb' | grep -v pccs | xargs dpkg -i
+#cd /root && \ rm -rf /root/linux-sgx
diff --git a/dockerfile/Dockerfile.centos7.notworking.nightly b/dockerfile/Dockerfile.centos7.notworking.nightly
new file mode 100644
index 0000000..127f28a
--- /dev/null
+++ b/dockerfile/Dockerfile.centos7.notworking.nightly
@@ -0,0 +1,45 @@
+FROM centos:7
+
+RUN yum-builddep gcc binutils -y && \
+    yum install -y which libcurl-devel bzip2 ocaml ocaml-ocamlbuild wget python2 openssl-devel git cmake rpm-build createrepo yum-utils && \
+    yum groupinstall -y "Development Tools"
+
+ADD 01_gcc_8.sh /root
+RUN bash /root/01_gcc_8.sh
+
+ENV BINUTILS_PREFIX=/opt/binutils
+ENV LD_LIBRARY_PATH=/usr/lib
+
+ADD 02_binutils.sh /root
+RUN bash /root/02_binutils.sh && \
+    cp -r /opt/binutils/bin/* /usr/bin/ && \
+    cp -r /opt/binutils/lib/* /usr/lib/
+
+ADD 03_protobuf.sh /root
+RUN bash /root/03_protobuf.sh
+
+ADD 03_sdk.sh /root
+RUN bash /root/03_sdk.sh
+
+# Sixth, PSW
+
+ENV BINUTILS_PREFIX=/usr \
+    LD_LIBRARY_PATH=/usr/lib64:$LD_LIBRARY_PATH
+
+ADD centos_dcap_patch /root
+ADD centos_patch /root
+ADD 04_psw_rpm.sh /root
+RUN bash /root/04_psw_rpm.sh
+
+## Seventh, Rust
+#
+#ENV rust_toolchain  nightly-2020-04-07
+#ADD 05_rust.sh /root
+#RUN bash /root/05_rust.sh
+#
+#ENV rust_toolchain=
+#ENV CODENAME=
+#ENV VERSION=
+#ENV PSW_REPO=
+#
+#WORKDIR /root
diff --git a/dockerfile/Dockerfile.fedora27.nightly b/dockerfile/Dockerfile.fedora27.nightly
index f71c1ff..f4d9970 100644
--- a/dockerfile/Dockerfile.fedora27.nightly
+++ b/dockerfile/Dockerfile.fedora27.nightly
@@ -7,7 +7,7 @@ RUN yum install yum-utils bzip2 ocaml ocaml-ocamlbuild wget python2 openssl-deve
 ADD 01_gcc_8.sh /root
 RUN bash /root/01_gcc_8.sh
 
-ENV BINUTILS_PREFIX=/usr/lib
+ENV BINUTILS_PREFIX=/usr
 
 ADD 02_binutils.sh /root
 RUN bash /root/02_binutils.sh
@@ -19,7 +19,7 @@ RUN bash /root/03_sdk.sh
 
 ENV PSW_REPO=https://download.01.org/intel-sgx/sgx-linux/2.9.1/distro/fedora27-server/sgx_rpm_local_repo.tgz
 
-RUN wget --output /root/repo.tgz $PSW_REPO && \
+RUN curl --output /root/repo.tgz $PSW_REPO && \
     cd /root && \
     tar xzf repo.tgz && \
     cd sgx_rpm_local_repo && \
diff --git a/dockerfile/centos_dcap_patch b/dockerfile/centos_dcap_patch
new file mode 100644
index 0000000..5af8a7b
--- /dev/null
+++ b/dockerfile/centos_dcap_patch
@@ -0,0 +1,34 @@
+diff --git a/QuoteGeneration/installer/linux/rpm/libsgx-pce-logic/libsgx-pce-logic.spec b/QuoteGeneration/installer/linux/rpm/libsgx-pce-logic/libsgx-pce-logic.spec
+index 2423e17..bc5e65e 100644
+--- a/QuoteGeneration/installer/linux/rpm/libsgx-pce-logic/libsgx-pce-logic.spec
++++ b/QuoteGeneration/installer/linux/rpm/libsgx-pce-logic/libsgx-pce-logic.spec
+@@ -43,6 +43,8 @@ Source0:        %{name}-%{version}.tar.gz
+ %description
+ Intel(R) Software Guard Extensions PCE logic
+
++%undefine _missing_build_ids_terminate_build
++
+ %prep
+ %setup -qc
+
+@@ -57,6 +59,7 @@ done
+
+ %debug_package
+
++
+ %changelog
+ * Tue Jan 21 2020 SGX Team
+ - Initial Release
+diff --git a/QuoteGeneration/installer/linux/rpm/libsgx-qe3-logic/libsgx-qe3-logic.spec b/QuoteGeneration/installer/linux/rpm/libsgx-qe3-logic/libsgx-qe3-logic.spec
+index b108e4d..a0e15af 100644
+--- a/QuoteGeneration/installer/linux/rpm/libsgx-qe3-logic/libsgx-qe3-logic.spec
++++ b/QuoteGeneration/installer/linux/rpm/libsgx-qe3-logic/libsgx-qe3-logic.spec
+@@ -43,6 +43,8 @@ Source0:        %{name}-%{version}.tar.gz
+ %description
+ Intel(R) Software Guard Extensions QE3 logic
+
++%undefine _missing_build_ids_terminate_build
++
+ %prep
+ %setup -qc
+
diff --git a/dockerfile/centos_patch b/dockerfile/centos_patch
new file mode 100644
index 0000000..736797c
--- /dev/null
+++ b/dockerfile/centos_patch
@@ -0,0 +1,189 @@
+diff --git a/external/dcap_source b/external/dcap_source
+--- a/external/dcap_source
++++ b/external/dcap_source
+@@ -1 +1 @@
+-Subproject commit 4605fae1c606de4ff1191719433f77f050f1c33c
++Subproject commit 4605fae1c606de4ff1191719433f77f050f1c33c-dirty
+diff --git a/linux/installer/rpm/libsgx-enclave-common/libsgx-enclave-common.spec b/linux/installer/rpm/libsgx-enclave-common/libsgx-enclave-common.spec
+index 1f0382d..cca09fa 100644
+--- a/linux/installer/rpm/libsgx-enclave-common/libsgx-enclave-common.spec
++++ b/linux/installer/rpm/libsgx-enclave-common/libsgx-enclave-common.spec
+@@ -52,6 +52,8 @@ Requires:       %{name} = %{version}-%{release}
+ %description devel
+ Intel(R) Software Guard Extensions Enclave Common Loader for Developers
+
++%undefine _missing_build_ids_terminate_build
++
+ %prep
+ %setup -qc
+
+diff --git a/linux/installer/rpm/libsgx-epid/libsgx-epid.spec b/linux/installer/rpm/libsgx-epid/libsgx-epid.spec
+index 8c7ac9d..e58517f 100644
+--- a/linux/installer/rpm/libsgx-epid/libsgx-epid.spec
++++ b/linux/installer/rpm/libsgx-epid/libsgx-epid.spec
+@@ -51,6 +51,8 @@ Requires:       %{name} = %{version}-%{release}
+ %description devel
+ Intel(R) Software Guard Extensions EPID Quote Service for Developers
+
++%undefine _missing_build_ids_terminate_build
++
+ %prep
+ %setup -qc
+
+diff --git a/linux/installer/rpm/libsgx-launch/libsgx-launch.spec b/linux/installer/rpm/libsgx-launch/libsgx-launch.spec
+index efad250..0ff1e02 100644
+--- a/linux/installer/rpm/libsgx-launch/libsgx-launch.spec
++++ b/linux/installer/rpm/libsgx-launch/libsgx-launch.spec
+@@ -51,6 +51,8 @@ Requires:       %{name} = %{version}-%{release}
+ %description devel
+ Intel(R) Software Guard Extensions Launch Service for Developers
+
++%undefine _missing_build_ids_terminate_build
++
+ %prep
+ %setup -qc
+
+diff --git a/linux/installer/rpm/libsgx-quote-ex/libsgx-quote-ex.spec b/linux/installer/rpm/libsgx-quote-ex/libsgx-quote-ex.spec
+index e76c7c9..c14c2f0 100644
+--- a/linux/installer/rpm/libsgx-quote-ex/libsgx-quote-ex.spec
++++ b/linux/installer/rpm/libsgx-quote-ex/libsgx-quote-ex.spec
+@@ -51,6 +51,8 @@ Requires:       %{name} = %{version}-%{release}
+ %description devel
+ Intel(R) Software Guard Extensions Unified Quote Service for Developers
+
++%undefine _missing_build_ids_terminate_build
++
+ %prep
+ %setup -qc
+
+diff --git a/linux/installer/rpm/libsgx-uae-service/libsgx-uae-service.spec b/linux/installer/rpm/libsgx-uae-service/libsgx-uae-service.spec
+index 212cce6..cda2c0b 100644
+--- a/linux/installer/rpm/libsgx-uae-service/libsgx-uae-service.spec
++++ b/linux/installer/rpm/libsgx-uae-service/libsgx-uae-service.spec
+@@ -43,6 +43,8 @@ Source0:        %{name}-%{version}.tar.gz
+ %description
+ Intel(R) Software Guard Extensions Untrusted AE Service
+
++%undefine _missing_build_ids_terminate_build
++
+ %prep
+ %setup -qc
+
+@@ -59,4 +61,4 @@ done
+
+ %changelog
+ * Mon Jul 29 2019 SGX Team
+-- Initial Release
+\ No newline at end of file
++- Initial Release
+diff --git a/linux/installer/rpm/libsgx-urts/libsgx-urts.spec b/linux/installer/rpm/libsgx-urts/libsgx-urts.spec
+index d2d67fb..d79e1dc 100644
+--- a/linux/installer/rpm/libsgx-urts/libsgx-urts.spec
++++ b/linux/installer/rpm/libsgx-urts/libsgx-urts.spec
+@@ -43,6 +43,8 @@ Source0:        %{name}-%{version}.tar.gz
+ %description
+ Intel(R) Software Guard Extensions uRTS
+
++%undefine _missing_build_ids_terminate_build
++
+ %prep
+ %setup -qc
+
+@@ -59,4 +61,4 @@ done
+
+ %changelog
+ * Mon Jul 29 2019 SGX Team
+-- Initial Release
+\ No newline at end of file
++- Initial Release
+diff --git a/linux/installer/rpm/sgx-aesm-service/libsgx-ae-pce.spec b/linux/installer/rpm/sgx-aesm-service/libsgx-ae-pce.spec
+index 415d98d..6b0e54f 100644
+--- a/linux/installer/rpm/sgx-aesm-service/libsgx-ae-pce.spec
++++ b/linux/installer/rpm/sgx-aesm-service/libsgx-ae-pce.spec
+@@ -64,6 +64,8 @@ rm -fr %{?buildroot}/%{name}
+
+ %debug_package
+
++%global _missing_build_ids_terminate_build 0
++
+ %changelog
+ * Mon Jul 29 2019 SGX Team
+ - Initial Release
+diff --git a/linux/installer/rpm/sgx-aesm-service/libsgx-aesm-ecdsa-plugin.spec b/linux/installer/rpm/sgx-aesm-service/libsgx-aesm-ecdsa-plugin.spec
+index de6d2bb..8e44316 100644
+--- a/linux/installer/rpm/sgx-aesm-service/libsgx-aesm-ecdsa-plugin.spec
++++ b/linux/installer/rpm/sgx-aesm-service/libsgx-aesm-ecdsa-plugin.spec
+@@ -46,6 +46,8 @@ Source0:        %{name}-%{version}.tar.gz
+ %description
+ ECDSA Quote Plugin for Intel(R) Software Guard Extensions AESM Service
+
++%undefine _missing_build_ids_terminate_build
++
+ %prep
+ %setup -qc
+
+diff --git a/linux/installer/rpm/sgx-aesm-service/libsgx-aesm-epid-plugin.spec b/linux/installer/rpm/sgx-aesm-service/libsgx-aesm-epid-plugin.spec
+index 8bc6ab3..00d5cbc 100644
+--- a/linux/installer/rpm/sgx-aesm-service/libsgx-aesm-epid-plugin.spec
++++ b/linux/installer/rpm/sgx-aesm-service/libsgx-aesm-epid-plugin.spec
+@@ -46,6 +46,8 @@ Source0:        %{name}-%{version}.tar.gz
+ %description
+ EPID Quote Plugin for Intel(R) Software Guard Extensions AESM Service
+
++%undefine _missing_build_ids_terminate_build
++
+ %prep
+ %setup -qc
+
+diff --git a/linux/installer/rpm/sgx-aesm-service/libsgx-aesm-launch-plugin.spec b/linux/installer/rpm/sgx-aesm-service/libsgx-aesm-launch-plugin.spec
+index e6e3639..f6f21b8 100644
+--- a/linux/installer/rpm/sgx-aesm-service/libsgx-aesm-launch-plugin.spec
++++ b/linux/installer/rpm/sgx-aesm-service/libsgx-aesm-launch-plugin.spec
+@@ -46,6 +46,8 @@ Source0:        %{name}-%{version}.tar.gz
+ %description
+ Launch Plugin for Intel(R) Software Guard Extensions AESM Service
+
++%undefine _missing_build_ids_terminate_build
++
+ %prep
+ %setup -qc
+
+diff --git a/linux/installer/rpm/sgx-aesm-service/libsgx-aesm-pce-plugin.spec b/linux/installer/rpm/sgx-aesm-service/libsgx-aesm-pce-plugin.spec
+index 714e028..ccf7588 100644
+--- a/linux/installer/rpm/sgx-aesm-service/libsgx-aesm-pce-plugin.spec
++++ b/linux/installer/rpm/sgx-aesm-service/libsgx-aesm-pce-plugin.spec
+@@ -46,6 +46,8 @@ Source0:        %{name}-%{version}.tar.gz
+ %description
+ PCE Plugin for Intel(R) Software Guard Extensions AESM Service
+
++%undefine _missing_build_ids_terminate_build
++
+ %prep
+ %setup -qc
+
+diff --git a/linux/installer/rpm/sgx-aesm-service/libsgx-aesm-quote-ex-plugin.spec b/linux/installer/rpm/sgx-aesm-service/libsgx-aesm-quote-ex-plugin.spec
+index be47f63..06692a6 100644
+--- a/linux/installer/rpm/sgx-aesm-service/libsgx-aesm-quote-ex-plugin.spec
++++ b/linux/installer/rpm/sgx-aesm-service/libsgx-aesm-quote-ex-plugin.spec
+@@ -47,6 +47,8 @@ Source0:        %{name}-%{version}.tar.gz
+ %description
+ Unified Quote Plugin for Intel(R) Software Guard Extensions AESM Service
+
++%undefine _missing_build_ids_terminate_build
++
+ %prep
+ %setup -qc
+
+diff --git a/linux/installer/rpm/sgx-aesm-service/sgx-aesm-service.spec b/linux/installer/rpm/sgx-aesm-service/sgx-aesm-service.spec
+index ea97439..df0eef0 100644
+--- a/linux/installer/rpm/sgx-aesm-service/sgx-aesm-service.spec
++++ b/linux/installer/rpm/sgx-aesm-service/sgx-aesm-service.spec
+@@ -45,6 +45,8 @@ Source0:        %{name}-%{version}.tar.gz
+ %description
+ Intel(R) Software Guard Extensions AESM Service
+
++%undefine _missing_build_ids_terminate_build
++
+ %prep
+ %setup -qc
+


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@teaclave.apache.org
For additional commands, e-mail: commits-help@teaclave.apache.org