Skip to content

Files

Latest commit

author
Noga Cohen
Feb 3, 2022
9359de5 · Feb 3, 2022

History

History
64 lines (39 loc) · 1.56 KB

BUILD.md

File metadata and controls

64 lines (39 loc) · 1.56 KB

How to Build

List the steps to build the binary and requirements from build environment

Software Requirements

  • Clang 9.0.0

  • Python 3.6.3

Environment dependencies

  1. IPP can be automatically built by the project's makefile.

    • IPP sources needs to be placed under ./libs/ipp/ipp-crypto-ippcp_2021.4 folder.

    • Tools that are required to build IPP crypto lib described in the following link

  2. It can also be built separately with the following flags:

	CC=clang CXX=clang++ cmake CMakeLists.txt -B_build -DARCH=intel64 -DMERGED_BLD:BOOL=off -DPLATFORM_LIST="y8"
	cd _build
	make ippcp_s_y8

Make targets

The binary generation contains the date of the created binary.

The date and the build num can be extracted from the production binary using SEAMCALL TDH.SYS.INFO (leaf #32), and taking the values of "build_date" and "build_num" fields.

In order to reproduce the exact binary, it is required to include the origin date, and the build number:

make RELEASE=1 TDX_MODULE_BUILD_DATE=<origin date in format YYYYMMDD> TDX_MODULE_BUILD_NUM=<build number>
  1. Build the project:
make RELEASE=1
  1. Clean everything:
make clean
  1. Clean everything including the IPP:
make cleanall