mirror of
https://github.com/Dasharo/systemd.git
synced 2026-03-06 15:02:31 -08:00
gcrypt: dlopenify for libsystemd
gcrypt is used only for journal sealing operations in libsystemd, so it can be made into a dlopen dependency that is used only on demand. This allows to reduce the footprint of libsystemd in the most common cases. Keep systemd-pull and systemd-resolved with normal linking, as they are executables, and usually built with OpenSSL support anyway.
This commit is contained in:
+5
-4
@@ -1319,6 +1319,9 @@ if not have
|
||||
# link to neither of the libs if one is not found
|
||||
libgcrypt = []
|
||||
libgpg_error = []
|
||||
libgcrypt_cflags = []
|
||||
else
|
||||
libgcrypt_cflags = libgcrypt.partial_dependency(includes: true, compile_args: true)
|
||||
endif
|
||||
conf.set10('HAVE_GCRYPT', have)
|
||||
|
||||
@@ -1951,8 +1954,7 @@ libsystemd = shared_library(
|
||||
include_directories : libsystemd_includes,
|
||||
link_args : ['-shared',
|
||||
'-Wl,--version-script=' + libsystemd_sym_path],
|
||||
link_with : [libbasic,
|
||||
libbasic_gcrypt],
|
||||
link_with : [libbasic],
|
||||
link_whole : [libsystemd_static],
|
||||
dependencies : [librt,
|
||||
threads,
|
||||
@@ -1968,7 +1970,6 @@ install_libsystemd_static = static_library(
|
||||
'systemd',
|
||||
libsystemd_sources,
|
||||
basic_sources,
|
||||
basic_gcrypt_sources,
|
||||
fundamental_sources,
|
||||
include_directories : libsystemd_includes,
|
||||
build_by_default : static_libsystemd != 'false',
|
||||
@@ -1979,7 +1980,7 @@ install_libsystemd_static = static_library(
|
||||
dependencies : [libblkid,
|
||||
libcap,
|
||||
libdl,
|
||||
libgcrypt,
|
||||
libgcrypt_cflags,
|
||||
liblz4_cflags,
|
||||
libmount,
|
||||
libopenssl,
|
||||
|
||||
Reference in New Issue
Block a user