mirror of
https://github.com/torvalds/linux.git
synced 2026-11-23 23:11:40 +00:00
Will be used to generate build-ids in the jitdump code. Signed-off-by: Stephane Eranian <[email protected]> Cc: Adrian Hunter <[email protected]> Cc: Andi Kleen <[email protected]> Cc: Carl Love <[email protected]> Cc: David Ahern <[email protected]> Cc: Jiri Olsa <[email protected]> Cc: John McCutchan <[email protected]> Cc: Namhyung Kim <[email protected]> Cc: Pawel Moll <[email protected]> Cc: Peter Zijlstra <[email protected]> Cc: Sonny Rao <[email protected]> Cc: Sukadev Bhattiprolu <[email protected]> Link: http://lkml.kernel.org/r/[email protected] [ tools/perf/Makefile.perf comment about NO_LIBCRYPTO and added it to tests/make ] Signed-off-by: Arnaldo Carvalho de Melo <[email protected]>
18 lines
325 B
C
18 lines
325 B
C
#include <openssl/sha.h>
|
|
#include <openssl/md5.h>
|
|
|
|
int main(void)
|
|
{
|
|
MD5_CTX context;
|
|
unsigned char md[MD5_DIGEST_LENGTH + SHA_DIGEST_LENGTH];
|
|
unsigned char dat[] = "12345";
|
|
|
|
MD5_Init(&context);
|
|
MD5_Update(&context, &dat[0], sizeof(dat));
|
|
MD5_Final(&md[0], &context);
|
|
|
|
SHA1(&dat[0], sizeof(dat), &md[0]);
|
|
|
|
return 0;
|
|
}
|