From a07a4c1ea886e35a17847ff004495e2f18b8b489 Mon Sep 17 00:00:00 2001 From: Ailin Nemui Date: Mon, 30 Aug 2021 20:27:35 +0200 Subject: [PATCH] use an internal build of openssl when fuzzer is enabled --- meson.build | 7 ++++++- subprojects/openssl.wrap | 14 ++++++++++++++ 2 files changed, 20 insertions(+), 1 deletion(-) create mode 100644 subprojects/openssl.wrap diff --git a/meson.build b/meson.build index 1a5182af..fe5aa99f 100644 --- a/meson.build +++ b/meson.build @@ -273,7 +273,12 @@ endif dep += glib_dep dep += gmodule_dep -openssl_dep = dependency('openssl', static : want_static_dependency) +if glib_internal and want_static_dependency and want_fuzzer + openssl_proj = subproject('openssl', default_options : ['default_library=static', 'asm=disabled']) + openssl_dep = openssl_proj.get_variable('openssl_dep') +else + openssl_dep = dependency('openssl', static : want_static_dependency) +endif dep += openssl_dep ############ diff --git a/subprojects/openssl.wrap b/subprojects/openssl.wrap new file mode 100644 index 00000000..4aaaba38 --- /dev/null +++ b/subprojects/openssl.wrap @@ -0,0 +1,14 @@ +[wrap-file] +directory = openssl-1.1.1l +source_url = https://www.openssl.org/source/openssl-1.1.1l.tar.gz +source_filename = openssl-1.1.1l.tar.gz +source_hash = 0b7a3e5e59c34827fe0c3a74b7ec8baef302b98fa80088d7f9153aa16fa76bd1 +patch_filename = openssl_1.1.1l-1_patch.zip +patch_url = https://wrapdb.mesonbuild.com/v2/openssl_1.1.1l-1/get_patch +patch_hash = 670db31580039e06c17f48bcd31e489f453fe72c22006de6d693b9b033f1003a + +[provide] +libcrypto = libcrypto_dep +libssl = libssl_dep +openssl = openssl_dep +