mirror of
https://git.proxmox.com/git/mirror_lxc
synced 2025-08-15 05:26:12 +00:00
commit
5730c268f1
22
meson.build
22
meson.build
@ -16,7 +16,7 @@ project(
|
||||
'c_std=gnu11',
|
||||
'warning_level=2',
|
||||
],
|
||||
meson_version: '>= 0.60')
|
||||
meson_version: '>= 0.61')
|
||||
|
||||
cc = meson.get_compiler('c')
|
||||
pkgconfig = import('pkgconfig')
|
||||
@ -206,9 +206,8 @@ threads = dependency('threads')
|
||||
## Seccomp.
|
||||
libseccomp = dependency('libseccomp')
|
||||
conf.set10('HAVE_SECCOMP', libseccomp.found())
|
||||
pkgconfig_libs += libseccomp
|
||||
if libseccomp.found()
|
||||
pkgconfig_libs += '-lseccomp'
|
||||
|
||||
if libseccomp.version().version_compare('>=2.5.0')
|
||||
# https://github.com/seccomp/libseccomp/commit/dead12bc788b259b148cc4d93b970ef0bd602b1a
|
||||
conf.set10('HAVE_DECL_SECCOMP_NOTIFY_FD', true)
|
||||
@ -245,9 +244,7 @@ endif
|
||||
## SELinux.
|
||||
libselinux = dependency('libselinux', required: false)
|
||||
conf.set10('HAVE_SELINUX', libselinux.found())
|
||||
if libselinux.found()
|
||||
pkgconfig_libs += '-lselinux'
|
||||
endif
|
||||
pkgconfig_libs += libselinux
|
||||
|
||||
## AppArmor.
|
||||
libapparmor = dependency('libapparmor', required: false)
|
||||
@ -256,9 +253,7 @@ conf.set10('HAVE_APPARMOR', libapparmor.found())
|
||||
## OpenSSL.
|
||||
libopenssl = dependency('openssl', required: false)
|
||||
conf.set10('HAVE_OPENSSL', libopenssl.found())
|
||||
if libopenssl.found()
|
||||
pkgconfig_libs += '-lssl -lcrypto'
|
||||
endif
|
||||
pkgconfig_libs += libopenssl
|
||||
|
||||
## Libcap..
|
||||
libcap = dependency('libcap', required: false)
|
||||
@ -267,9 +262,7 @@ if not libcap.found()
|
||||
libcap = cc.find_library('cap', required: false)
|
||||
endif
|
||||
conf.set10('HAVE_LIBCAP', libcap.found())
|
||||
if libcap.found()
|
||||
pkgconfig_libs += '-lcap'
|
||||
endif
|
||||
pkgconfig_libs += libcap
|
||||
|
||||
libcap_static = dependency('libcap', required: false, static: true)
|
||||
if not libcap_static.found()
|
||||
@ -282,9 +275,7 @@ conf.set10('HAVE_STATIC_LIBCAP', libcap_static.found())
|
||||
pam = cc.find_library('pam',
|
||||
has_headers: 'security/pam_modules.h')
|
||||
conf.set10('HAVE_PAM', pam.found())
|
||||
if pam.found()
|
||||
pkgconfig_libs += '-lpam'
|
||||
endif
|
||||
pkgconfig_libs += pam
|
||||
|
||||
## Others.
|
||||
have = cc.has_function('strchrnul', prefix: '#include <string.h>', args: '-D_GNU_SOURCE')
|
||||
@ -615,7 +606,6 @@ pkg_config_file = pkgconfig.generate(liblxc,
|
||||
url: 'http://linuxcontainers.org',
|
||||
libraries: '-lutil -lpthread -ldl',
|
||||
libraries_private: pkgconfig_libs,
|
||||
install_dir: join_paths(libdir, 'pkgconfig')
|
||||
)
|
||||
|
||||
# Empty dirs.
|
||||
|
Loading…
Reference in New Issue
Block a user