meson: cleanup version detection
Tell Meson what version the project is, so that we set the right versioning on libnethogs.
This commit is contained in:
@@ -5,11 +5,11 @@
|
||||
project('nethogs',
|
||||
['c', 'cpp'],
|
||||
default_options : ['warning_level=3',
|
||||
'cpp_std=c++14']
|
||||
'cpp_std=c++14'],
|
||||
version : run_command('./determineVersion.sh').stdout().strip(),
|
||||
)
|
||||
|
||||
cc = meson.get_compiler('cpp')
|
||||
version = run_command('./determineVersion.sh', check: true).stdout().strip()
|
||||
|
||||
#######################################
|
||||
## Dependencies and flags definition ##
|
||||
@@ -19,7 +19,7 @@ projectinc = [include_directories('.', 'src')]
|
||||
|
||||
# flags
|
||||
c_args = [
|
||||
'-DVERSION="' + version + '"'
|
||||
'-DVERSION="' + meson.project_version() + '"'
|
||||
]
|
||||
|
||||
# dependencies
|
||||
@@ -42,5 +42,5 @@ pkgconfig = import('pkgconfig')
|
||||
pkgconfig_install_dir = join_paths(get_option('libdir'), 'pkgconfig')
|
||||
pkgconfig.generate(libnethogs,
|
||||
requires: ['libpcap'],
|
||||
version: version
|
||||
version: meson.project_version()
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user