[SLOF] [PATCH v2 6/6] tcgbios: Add test cases and test script to run them

Stefan Berger stefanb at linux.ibm.com
Fri Jul 9 12:34:26 AEST 2021


On 7/8/21 10:46 AM, Stefan Berger wrote:
> diff --git a/lib/libtpm/sha_test.h b/lib/libtpm/sha_test.h
> new file mode 100644
> index 0000000..5e57e3c
> --- /dev/null
> +++ b/lib/libtpm/sha_test.h
> @@ -0,0 +1,53 @@
> +/*****************************************************************************
> + * Copyright (c) 2021 IBM Corporation
> + * All rights reserved.
> + * This program and the accompanying materials
> + * are made available under the terms of the BSD License
> + * which accompanies this distribution, and is available at
> + * http://www.opensource.org/licenses/bsd-license.php
> + *
> + * Contributors:
> + *     IBM Corporation - initial implementation
> + *****************************************************************************/
> +
> +#ifndef SHA_TEST_H
> +#define SHA_TEST_H
> +
> +#include <stdio.h>
> +
> +#include <openssl/sha.h>

The inclusion of this file creates compilation issues when libssl1.1 is 
used on Ubuntu for example. The work-around is either to use -include 
/usr/include/stdint.h when compiling or to declare the few prototypes we 
need here SHA1(...), SHA256(...), etc.

Here are some builds on Travis:

https://travis-ci.com/github/stefanberger/SLOF-tpm/builds

I'll post v3 shortly to fix this issue.

    Stefan



More information about the SLOF mailing list