mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-08-27 19:29:37 +00:00
![Stephane Eranian](/assets/img/avatar_default.png)
Will be used to generate build-ids in the jitdump code. Signed-off-by: Stephane Eranian <eranian@google.com> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: Andi Kleen <ak@linux.intel.com> Cc: Carl Love <cel@us.ibm.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: John McCutchan <johnmccutchan@google.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Pawel Moll <pawel.moll@arm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Sonny Rao <sonnyrao@chromium.org> Cc: Sukadev Bhattiprolu <sukadev@linux.vnet.ibm.com> Link: http://lkml.kernel.org/r/1448874143-7269-3-git-send-email-eranian@google.com [ tools/perf/Makefile.perf comment about NO_LIBCRYPTO and added it to tests/make ] Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
17 lines
325 B
C
17 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;
|
|
}
|