mirror of
https://github.com/stefanberger/libtpms
synced 2026-01-06 18:17:49 +00:00
feat: Add OpenSSL dependency and header installation
This commit implements Step 2 of the Meson migration plan. - The build system now finds and links against the OpenSSL library. - Public header files are now installed to the correct location. - The 'include' directory has been added to the Meson build process. Signed-off-by: Gemini <gemini@google.com> Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
This commit is contained in:
parent
37b412fd43
commit
9ef45de8b0
9
include/libtpms/meson.build
Normal file
9
include/libtpms/meson.build
Normal file
@ -0,0 +1,9 @@
|
||||
install_headers(
|
||||
'tpm_error.h',
|
||||
'tpm_library.h',
|
||||
'tpm_memory.h',
|
||||
'tpm_nvfilename.h',
|
||||
'tpm_tis.h',
|
||||
'tpm_types.h',
|
||||
subdir: 'libtpms'
|
||||
)
|
||||
1
include/meson.build
Normal file
1
include/meson.build
Normal file
@ -0,0 +1 @@
|
||||
subdir('libtpms')
|
||||
@ -16,5 +16,6 @@ configure_file(
|
||||
configuration: conf_data
|
||||
)
|
||||
|
||||
# Add the src subdirectory to the build
|
||||
subdir('src')
|
||||
# Add subdirectories to the build
|
||||
subdir('include')
|
||||
subdir('src')
|
||||
@ -1,9 +1,8 @@
|
||||
# Define an include directory that points to the library's public headers
|
||||
project_inc = include_directories('../include/libtpms')
|
||||
# Find the OpenSSL dependency (libcrypto)
|
||||
crypto_dep = dependency('openssl', version: '>=1.1.0', required: true)
|
||||
|
||||
# Define an include directory for the generated config.h in the build directory
|
||||
# This is where config.h will be generated.
|
||||
build_inc = include_directories('.')
|
||||
# Include directory for the library's own public headers
|
||||
lib_inc = include_directories('../include/libtpms')
|
||||
|
||||
# Start with the absolute minimum common files to prove compilation works
|
||||
libtpms_sources = files(
|
||||
@ -21,6 +20,7 @@ libtpms = shared_library('tpms',
|
||||
'-DTPM_NV_DISK',
|
||||
'-include', 'tpm_library_conf.h'
|
||||
],
|
||||
include_directories: [project_inc, build_inc],
|
||||
dependencies: crypto_dep,
|
||||
include_directories: [lib_inc],
|
||||
install: true,
|
||||
)
|
||||
)
|
||||
|
||||
Loading…
Reference in New Issue
Block a user