4 license: ' GPL-2.0-or-later',
5 meson_version: '>= 0.53.0',
13 project_description = 'Library to access J-Link devices'
14 project_url = 'https://gitlab.zapb.de/libjaylink/libjaylink.git'
16 cc = meson.get_compiler('c')
17 build_system = build_machine.system()
19 option_usb = get_option('usb')
21 include_dirs = include_directories('libjaylink')
29 ws2_32 = cc.find_library('ws2_32', required: build_system == 'windows')
31 have_usb = libusb.found()
34 add_project_arguments('-DHAVE_LIBUSB', language: 'c')
37 version = meson.project_version()
38 version_array = version.split('.')
39 major_version = version_array[0].to_int()
40 minor_version = version_array[1].to_int()
41 version_micro = version_array[2].to_int()
44 'major': version_array[0],
45 'minor': version_array[1],
46 'micro': version_array[2],
49 git = find_program('git', required: false)
52 git_tag = run_command([git, 'describe', '--dirty'], check: false).stdout().strip()
55 package_version_string = git_tag
57 package_version_string = version
60 package_version_string = version
63 # Libtool interface version of libjaylink. This is not the same as the package
64 # version. For information about the versioning system of libtool, see:
65 # http://www.gnu.org/software/libtool/manual/libtool.html#Libtool-versioning
73 library_version_string = '@0@.@1@.@2@'.format(
74 library_version['current'] - library_version['age'],
75 library_version['age'],
76 library_version['revision'])
81 'Package version': package_version_string,
82 'Library version': library_version_string,
84 section: 'Project details'
91 section: 'Enabled transports',