From 0c32757fd9269a18b827fa33230d2997c98571a0 Mon Sep 17 00:00:00 2001 From: David Steele Date: Tue, 25 Jun 2024 16:04:02 +0800 Subject: [PATCH] Require the lz4 library in the meson build. We would like to use lz4 for protocol compression instead of gz but first we need to make sure this is not going to cause a problem for packaging. To do this make lz4 required in meson but make no changes to the code so this is an easy revert for packagers if there is an issue. --- doc/xml/release/2024/2.53.xml | 4 ++++ meson.build | 6 ++---- meson_options.txt | 1 - 3 files changed, 6 insertions(+), 5 deletions(-) diff --git a/doc/xml/release/2024/2.53.xml b/doc/xml/release/2024/2.53.xml index 5af191f8a..034cd5f01 100644 --- a/doc/xml/release/2024/2.53.xml +++ b/doc/xml/release/2024/2.53.xml @@ -1,5 +1,9 @@ + +

NOTE TO PACKAGERS: The lz4 library is now required by the meson build.

+
+ diff --git a/meson.build b/meson.build index 517b39a98..a88fdb37b 100644 --- a/meson.build +++ b/meson.build @@ -146,11 +146,9 @@ endif lib_bz2 = cc.find_library('bz2') # Find optional lz4 library -lib_lz4 = dependency('liblz4', required: get_option('liblz4')) +lib_lz4 = dependency('liblz4') -if lib_lz4.found() - configuration.set('HAVE_LIBLZ4', true, description: 'Is liblz4 present?') -endif +configuration.set('HAVE_LIBLZ4', true, description: 'Is liblz4 present?') # Find required openssl library lib_openssl = dependency('openssl') diff --git a/meson_options.txt b/meson_options.txt index f08aced7d..c304d2d7c 100644 --- a/meson_options.txt +++ b/meson_options.txt @@ -1,5 +1,4 @@ option('configdir', type: 'string', value: '/etc/pgbackrest', description: 'Configuration directory') option('fatal-errors', type: 'boolean', value: false, description: 'Stop compilation on first error') -option('liblz4', type: 'feature', value: 'auto', description: 'Enable LZ4 compression support') option('libssh2', type: 'feature', value: 'auto', description: 'Enable SFTP storage support') option('libzstd', type: 'feature', value: 'auto', description: 'Enable Zstandard compression support')