You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@teaclave.apache.org by AdamsLee <no...@github.com.INVALID> on 2021/05/09 01:57:50 UTC

[apache/incubator-teaclave] Failed to build the Teaclave platform using docker with the -DSGX_SIM_MODE=ON option (#499)

I tried to build the Teaclave platform using docker with the -DSGX_SIM_MODE=ON option 
```
$ git clone https://github.com/apache/incubator-teaclave.git
$ cd incubator-teaclave
$ docker run --rm -v $(pwd):/teaclave -w /teaclave \
  -it teaclave/teaclave-build-ubuntu-1804-sgx-2.9.1:latest \
   bash -c ". /root/.cargo/env && \
     . /opt/sgxsdk/environment && \
     mkdir -p build && cd build && \
     cmake -DTEST_MODE=ON -DSGX_SIM_MODE=ON .. && \
     make"
```

I expected to see this happen: *platform was built successfully*

Instead, this happened: *error occurred: failed to select a version for the requirement `sgx_rand = "^1.1.2"`*

[  3%] Building teaclave_client_sdk as dynamic and static libraries
    Updating git repository `https://github.com/apache/teaclave-sgx-sdk`
    Updating git submodule `https://github.com/WebAssembly/testsuite`
    Updating crates.io index
    Updating git repository `https://github.com/SergioBenitez/Rocket`
error: failed to select a version for the requirement `sgx_rand = "^1.1.2"`
  candidate versions found which didn't match: 1.1.1, 1.1.0, 1.0.9, ...
  location searched: crates.io index
required by package `teaclave_attestation v0.2.0 (/teaclave/build/cmake_tomls/unix_app/attestation)`
cp: cannot stat '/teaclave/build/target/unix/debug/libteaclave_client_sdk.so': No such file or directory
cp: cannot stat '/teaclave/build/target/unix/debug/libteaclave_client_sdk.a': No such file or directory
CMakeFiles/teaclave_client_sdk.dir/build.make:57: recipe for target 'CMakeFiles/teaclave_client_sdk' failed
make[2]: *** [CMakeFiles/teaclave_client_sdk] Error 1
CMakeFiles/Makefile2:67: recipe for target 'CMakeFiles/teaclave_client_sdk.dir/all' failed
make[1]: *** [CMakeFiles/teaclave_client_sdk.dir/all] Error 2
Makefile:83: recipe for target 'all' failed
make: *** [all] Error 2


-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/apache/incubator-teaclave/issues/499

Re: [apache/incubator-teaclave] Failed to build the Teaclave platform using docker with the -DSGX_SIM_MODE=ON option (#499)

Posted by AdamsLee <no...@github.com.INVALID>.
Closed #499.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/apache/incubator-teaclave/issues/499#event-4751029608

Re: [apache/incubator-teaclave] Failed to build the Teaclave platform using docker with the -DSGX_SIM_MODE=ON option (#499)

Posted by Mingshen Sun <no...@github.com.INVALID>.
We only use vendored third-party crates. Therefore, any upstream changes/updates won't affect our build process.

Did you change anything with the building system?

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/apache/incubator-teaclave/issues/499#issuecomment-841394608

Re: [apache/incubator-teaclave] Failed to build the Teaclave platform using docker with the -DSGX_SIM_MODE=ON option (#499)

Posted by Mingshen Sun <no...@github.com.INVALID>.
Hi, thanks for your report. I cannot reproduce your issue.

Basically, I followed your steps and built Teaclave successfully.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/apache/incubator-teaclave/issues/499#issuecomment-840915262

Re: [apache/incubator-teaclave] Failed to build the Teaclave platform using docker with the -DSGX_SIM_MODE=ON option (#499)

Posted by AdamsLee <no...@github.com.INVALID>.
After investigation, I think I find the root cause. This isn't the code bug. It should be caused by the GitHub network connection issue within mainland in China. The vendored third-party crates failed to be fully updated. 

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/apache/incubator-teaclave/issues/499#issuecomment-841821122

Re: [apache/incubator-teaclave] Failed to build the Teaclave platform using docker with the -DSGX_SIM_MODE=ON option (#499)

Posted by AdamsLee <no...@github.com.INVALID>.
hi, thanks for your response. 
I checked https://crates.io/crates/sgx_rand/versions and found that there is no 1.1.2 version and the latest version is 1.1.1.
Looks like that's the reason why it failed. Isn't it?

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/apache/incubator-teaclave/issues/499#issuecomment-841062172

Re: [apache/incubator-teaclave] Failed to build the Teaclave platform using docker with the -DSGX_SIM_MODE=ON option (#499)

Posted by AdamsLee <no...@github.com.INVALID>.
> Hi, thanks for your report. I cannot reproduce your issue.
> 
> Basically, I followed your steps and built Teaclave successfully.

hi, thanks for your response.
I checked https://crates.io/crates/sgx_rand/versions and found that there is no 1.1.2 version and the latest version is 1.1.1.
Looks like that's the reason why it failed. Isn't it?


-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/apache/incubator-teaclave/issues/499#issuecomment-841062524