6.4 Build Output and Integration

### Output directory structure 
pic32cmsg-psa-crypto-build/ 

├── README.md                         # MPLAB X integration instructions 

├── include/                          # PSA Crypto header files 

│   ├── mbedtls/ 

│   ├── psa/ 

│   └── tf-psa-crypto/ 

├── lib/ 

│   └── libtfpsacrypto.a              # PSA Crypto static library 

└── hsmlite/                          # HSM-Lite hardware driver 

    ├── include/                      # HSM-Lite headers (cam_*.h) 

    └── lib/ 

        └── libhsmlite04777-pic32cm.a # HSM-Lite library 

After a successful build, the following library and headers are available:

  • scripts\microchip\pic32cmsg-psa-crypto-build\lib\libtfpsacrypto.a—PSA Crypto static library for the selected profile
  • scripts\microchip\pic32cmsg-psa-crypto-build\hsmlite\lib\libhsmlite04777-pic32cm.a—HSM-Lite driver library for TRNG support
  • scripts\microchip\pic32cmsg-psa-crypto-build\include\psa—PSA Crypto API headers, including crypto.h, crypto_types.h, crypto_values.h and the selected configuration, are available in the header file crypto_config.h
  • scripts\microchip\pic32cmsg-psa-crypto-build\include\mbedtls—Supporting headers required by the library
  • scripts\microchip\pic32cmsg-psa-crypto-build\include\tf-psa-crypto—Version information and internal headers for tweaking crypto configurations

Integration Steps

Copy the above contents to a location within or accessible to your MPLAB® X project. Add the library files to your Secure Project Libraries and configure the include paths to reference the header directories appropriately. The library is then ready for use through the PSA Crypto API. Details on adding the library are available in Steps 1–3 from the Integration With MPLAB® X IDE section and are the same for any standard MPLAB application project.