tree-wide: drop gcrypt dependency from all binaries except for unit tests
With this change, gcrypt dependency is not mandatory. Hence, allow to build systemd even when -D gcrypt=enabled but gcrypt devel package is not installed.
This commit is contained in:
@@ -230,7 +230,6 @@ REQUIREMENTS:
|
||||
libarchive >= 3.0 (optional)
|
||||
libxkbcommon >= 0.3.0 (optional)
|
||||
libpcre2 (optional)
|
||||
libgcrypt (optional)
|
||||
libqrencode >= 3 (optional)
|
||||
libmicrohttpd >= 0.9.33 (optional)
|
||||
libcurl >= 7.32.0 (optional)
|
||||
|
||||
+2
-1
@@ -1206,8 +1206,9 @@ libqrencode = dependency('libqrencode',
|
||||
libqrencode_cflags = libqrencode.partial_dependency(includes: true, compile_args: true)
|
||||
conf.set10('HAVE_QRENCODE', libqrencode.found())
|
||||
|
||||
feature = get_option('gcrypt')
|
||||
libgcrypt = dependency('libgcrypt',
|
||||
required : get_option('gcrypt'))
|
||||
required : feature.disabled() ? feature : false)
|
||||
conf.set10('HAVE_GCRYPT', libgcrypt.found())
|
||||
if libgcrypt.found()
|
||||
libgcrypt_cflags = libgcrypt.partial_dependency(includes: true, compile_args: true)
|
||||
|
||||
@@ -64,12 +64,6 @@ const char* const systemd_features =
|
||||
|
||||
/* cryptographic libraries */
|
||||
|
||||
#if HAVE_GCRYPT
|
||||
" +GCRYPT"
|
||||
#else
|
||||
" -GCRYPT"
|
||||
#endif
|
||||
|
||||
#if HAVE_GNUTLS
|
||||
" +GNUTLS"
|
||||
#else
|
||||
|
||||
@@ -87,10 +87,8 @@ shared_sources = files(
|
||||
'firewall-util.c',
|
||||
'fork-notify.c',
|
||||
'format-table.c',
|
||||
'fsprg.c',
|
||||
'fsprg-openssl.c',
|
||||
'fstab-util.c',
|
||||
'gcrypt-util.c',
|
||||
'generator.c',
|
||||
'geneve-util.c',
|
||||
'gnutls-util.c',
|
||||
@@ -409,7 +407,6 @@ libshared_deps = [libacl_cflags,
|
||||
libelf_cflags,
|
||||
libfdisk_cflags,
|
||||
libfido2_cflags,
|
||||
libgcrypt_cflags,
|
||||
libgnutls_cflags,
|
||||
libidn2_cflags,
|
||||
libkmod_cflags,
|
||||
|
||||
@@ -300,10 +300,14 @@ executables += [
|
||||
'type' : 'manual',
|
||||
},
|
||||
test_template + {
|
||||
'sources' : files('test-dlopen-so.c'),
|
||||
'sources' : files(
|
||||
'test-dlopen-so.c',
|
||||
'gcrypt-util.c',
|
||||
),
|
||||
'dependencies' : [
|
||||
libblkid_cflags,
|
||||
libfdisk_cflags,
|
||||
libgcrypt_cflags,
|
||||
libgnutls_cflags,
|
||||
libkmod_cflags,
|
||||
libmicrohttpd_cflags,
|
||||
@@ -339,6 +343,8 @@ executables += [
|
||||
test_template + {
|
||||
'sources' : files(
|
||||
'test-fsprg.c',
|
||||
'fsprg.c',
|
||||
'gcrypt-util.c',
|
||||
),
|
||||
'dependencies' : [
|
||||
libgcrypt_cflags,
|
||||
|
||||
Reference in New Issue
Block a user