sgx sdk
https://github.com/aminueza/sgx-docker
in the container:
-
git clone https://github.com/intel/linux-sgx.git
-
apt-get install build-essential ocaml ocamlbuild automake autoconf libtool wget python libssl-dev git cmake perl -y
-
apt-get install libssl-dev libcurl4-openssl-dev protobuf-compiler libprotobuf-dev debhelper cmake reprepro -y
-
cd linux-sgx
-
./download_prebuilt.sh
-
make sdk_install_pkg_no_mitigation
-
cd linux/installer/bin/
-
./sgx_linux_x64_sdk_2.9.101.2.bin
-
cd ../../../
-
make psw_install_pkg
-
apt-get install -y libcurl4 libprotobuf10 libssl1.1 make module-init-tools
-
cd linux/installer/bin/
-
./sgx_linux_x64_psw_2.9.101.2.bin --no-start-aesm
-
source /opt/intel/sgxsdk/environment
-
cd /opt/intel/sgxpsw/aesm
-
./aesm_service --no-daemon
./aesm_service: error while loading shared libraries: libCppMicroServices.so.4.0.0: cannot open shared object file: No such file or directory
config.log
@llly According to your advice, I have made some changes. Now the installation process is as follows, but there are new problems. (log file is attached)
-
scl enable devtoolset-9 bash
Using built-in specs.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/opt/rh/devtoolset-9/root/usr/libexec/gcc/x86_64-redhat-linux/9/lto-wrapper
Target: x86_64-redhat-linux
Configured with: ../configure --enable-bootstrap --enable-languages=c,c++,fortran,lto --prefix=/opt/rh/devtoolset-9/root/usr --mandir=/opt/rh/devtoolset-9/root/usr/share/man --infodir=/opt/rh/devtoolset-9/root/usr/share/info --with-bugurl=http://bugzilla.redhat.com/bugzilla --enable-shared --enable-threads=posix --enable-checking=release --enable-multilib --with-system-zlib --enable-__cxa_atexit --disable-libunwind-exceptions --enable-gnu-unique-object --enable-linker-build-id --with-gcc-major-version-only --with-linker-hash-style=gnu --with-default-libstdcxx-abi=gcc4-compatible --enable-plugin --enable-initfini-array --with-isl=/builddir/build/BUILD/gcc-9.1.1-20190605/obj-x86_64-redhat-linux/isl-install --disable-libmpx --enable-gnu-indirect-function --with-tune=generic --with-arch_32=x86-64 --build=x86_64-redhat-linux
Thread model: posix
gcc version 9.1.1 20190605 (Red Hat 9.1.1-2) (GCC) -
sudo yum groupinstall 'Development Tools' --setopt=group_package_types=mandatory,default,optional
-
sudo yum install ocaml ocaml-ocamlbuild wget python2 openssl-devel git cmake perl
-
yum install autoconf automake libtool
-
sudo yum update binutils
-
sudo ./download_prebuilt.sh
-
sudo cp external/toolset/{as,ld,ld.gold,objdump} /opt/rh/devtoolset-9/root/usr/bin
-
which as ld ld.gold objdump
/opt/rh/devtoolset-9/root/usr/bin/as
/opt/rh/devtoolset-9/root/usr/bin/ld
/opt/rh/devtoolset-9/root/usr/bin/ld.gold
/opt/rh/devtoolset-9/root/usr/bin/objdump -
sudo make sdk
aclocal: warning: couldn't open directory 'm4': No such file or directory
autoreconf: configure.ac: tracing
autoreconf: configure.ac: creating directory config
autoreconf: running: libtoolize --copy --force
libtoolize: putting auxiliary files in AC_CONFIG_AUX_DIR,config'. libtoolize: copying file
config/ltmain.sh'
libtoolize: Consider addingAC_CONFIG_MACRO_DIR([m4])' to configure.ac and libtoolize: rerunning libtoolize, to keep the correct libtool macros in-tree. libtoolize: Consider adding
-I m4' to ACLOCAL_AMFLAGS in Makefile.am.
aclocal: warning: couldn't open directory 'm4': No such file or directory
autoreconf: running: /usr/bin/autoconf --force
autoreconf: running: /usr/bin/autoheader --force
autoreconf: running: automake --add-missing --copy --force-missing
configure.ac:22: installing 'config/ar-lib'
configure.ac:25: installing 'config/compile'
configure.ac:10: installing 'config/config.guess'
configure.ac:10: installing 'config/config.sub'
configure.ac:11: installing 'config/install-sh'
configure.ac:11: installing 'config/missing'
Makefile.am: installing './INSTALL'
src/Makefile.am:366: warning: whitespace following trailing backslash
src/Makefile.am:367: warning: whitespace following trailing backslash
src/Makefile.am: installing 'config/depcomp'
src/Makefile.am:160: warning: variable 'libunwind_dwarf_generic_la_SOURCES' is defined but no program or
src/Makefile.am:160: library has 'libunwind_dwarf_generic_la' as canonical name (possible typo)
src/Makefile.am:614: warning: variable 'libunwind_x86_64_la_SOURCES' is defined but no program or
src/Makefile.am:614: library has 'libunwind_x86_64_la' as canonical name (possible typo)
src/Makefile.am:616: warning: variable 'libunwind_x86_64_la_LIBADD' is defined but no program or
src/Makefile.am:616: library has 'libunwind_x86_64_la' as canonical name (possible typo)
src/Makefile.am:163: warning: variable 'libunwind_dwarf_generic_la_LIBADD' is defined but no program or
src/Makefile.am:163: library has 'libunwind_dwarf_generic_la' as canonical name (possible typo)
src/Makefile.am:615: warning: variable 'libunwind_x86_64_la_LDFLAGS' is defined but no program or
src/Makefile.am:615: library has 'libunwind_x86_64_la' as canonical name (possible typo)
parallel-tests: installing 'config/test-driver'
autoreconf: Leaving directory.' checking build system type... x86_64-unknown-linux-gnu checking host system type... x86_64-unknown-linux-gnu checking target system type... x86_64-unknown-linux-gnu checking for a BSD-compatible install... /usr/bin/install -c checking whether build environment is sane... yes checking for a thread-safe mkdir -p... /usr/bin/mkdir -p checking for gawk... gawk checking whether make sets $(MAKE)... yes checking whether make supports nested variables... yes checking whether to enable maintainer-specific portions of Makefiles... no checking for gcc... gcc checking whether the C compiler works... no configure: error: in
/home/pengfei/sgx/linux-sgx/sdk/cpprt/linux/libunwind':
configure: error: C compiler cannot create executables
Seeconfig.log' for more details sed: can't read include/config.h: No such file or directory make[3]: *** [libunwind] Error 2 make[3]: Leaving directory
/home/pengfei/sgx/linux-sgx/sdk/cpprt'
make[2]: *** [cpprt] Error 2
make[2]: Leaving directory/home/pengfei/sgx/linux-sgx/sdk' make[1]: *** [all] Error 2 make[1]: Leaving directory
/home/pengfei/sgx/linux-sgx/sdk'
make: *** [sdk] Error 2 -
wget https://github.com/protocolbuffers/protobuf/releases/download/v3.5.1/protobuf-all-3.5.1.tar.gz
- https://cmake.org/download/