Skip to content

Commit 1bc1459

Browse files
committed
liburing: update to 2.2
Simplify the test definitions and bump the required meson version to use the filesystem module. Reflect the upstream changes to the custom ./configure script in the root meson build definition. Signed-off-by: Florian Fischer <[email protected]>
1 parent 8c5a5ac commit 1bc1459

File tree

7 files changed

+288
-135
lines changed

7 files changed

+288
-135
lines changed

releases.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1007,6 +1007,7 @@
10071007
"uring"
10081008
],
10091009
"versions": [
1010+
"2.2-1",
10101011
"2.1-1",
10111012
"2.0-1"
10121013
]

subprojects/liburing.wrap

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
[wrap-file]
2-
directory = liburing-liburing-2.1
3-
source_url = https://github.com/axboe/liburing/archive/refs/tags/liburing-2.1.tar.gz
4-
source_filename = liburing-2.1.tar.gz
5-
source_hash = f1e0500cb3934b0b61c5020c3999a973c9c93b618faff1eba75aadc95bb03e07
2+
directory = liburing-liburing-2.2
3+
source_url = https://github.com/axboe/liburing/archive/refs/tags/liburing-2.2.tar.gz
4+
source_filename = liburing-2.2.tar.gz
5+
source_hash = e092624af6aa244ade2d52181cc07751ac5caba2f3d63e9240790db9ed130bbc
66
patch_directory = liburing
77

88
[provide]
Lines changed: 107 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,107 @@
1-
install_man('io_uring.7',
2-
'io_uring_enter.2',
3-
'io_uring_get_sqe.3',
4-
'io_uring_queue_exit.3',
5-
'io_uring_queue_init.3',
6-
'io_uring_register.2',
7-
'io_uring_setup.2')
1+
install_man(
2+
'io_uring.7',
3+
'io_uring_buf_ring_add.3',
4+
'io_uring_buf_ring_advance.3',
5+
'io_uring_buf_ring_cq_advance.3',
6+
'io_uring_buf_ring_init.3',
7+
'io_uring_buf_ring_mask.3',
8+
'io_uring_cq_advance.3',
9+
'io_uring_cqe_get_data.3',
10+
'io_uring_cqe_get_data64.3',
11+
'io_uring_cqe_seen.3',
12+
'io_uring_cq_ready.3',
13+
'io_uring_enter.2',
14+
'io_uring_free_probe.3',
15+
'io_uring_get_probe.3',
16+
'io_uring_get_sqe.3',
17+
'io_uring_opcode_supported.3',
18+
'io_uring_peek_cqe.3',
19+
'io_uring_prep_accept.3',
20+
'io_uring_prep_accept_direct.3',
21+
'io_uring_prep_cancel.3',
22+
'io_uring_prep_close.3',
23+
'io_uring_prep_close_direct.3',
24+
'io_uring_prep_connect.3',
25+
'io_uring_prep_fadvise.3',
26+
'io_uring_prep_fallocate.3',
27+
'io_uring_prep_files_update.3',
28+
'io_uring_prep_fsync.3',
29+
'io_uring_prep_link.3',
30+
'io_uring_prep_linkat.3',
31+
'io_uring_prep_madvise.3',
32+
'io_uring_prep_mkdir.3',
33+
'io_uring_prep_mkdirat.3',
34+
'io_uring_prep_msg_ring.3',
35+
'io_uring_prep_multishot_accept.3',
36+
'io_uring_prep_multishot_accept_direct.3',
37+
'io_uring_prep_openat2.3',
38+
'io_uring_prep_openat2_direct.3',
39+
'io_uring_prep_openat.3',
40+
'io_uring_prep_openat_direct.3',
41+
'io_uring_prep_poll_add.3',
42+
'io_uring_prep_poll_multishot.3',
43+
'io_uring_prep_poll_remove.3',
44+
'io_uring_prep_poll_update.3',
45+
'io_uring_prep_provide_buffers.3',
46+
'io_uring_prep_read.3',
47+
'io_uring_prep_read_fixed.3',
48+
'io_uring_prep_readv2.3',
49+
'io_uring_prep_readv.3',
50+
'io_uring_prep_recv.3',
51+
'io_uring_prep_recvmsg.3',
52+
'io_uring_prep_remove_buffers.3',
53+
'io_uring_prep_rename.3',
54+
'io_uring_prep_renameat.3',
55+
'io_uring_prep_send.3',
56+
'io_uring_prep_sendmsg.3',
57+
'io_uring_prep_shutdown.3',
58+
'io_uring_prep_socket.3',
59+
'io_uring_prep_socket_direct.3',
60+
'io_uring_prep_splice.3',
61+
'io_uring_prep_statx.3',
62+
'io_uring_prep_symlink.3',
63+
'io_uring_prep_symlinkat.3',
64+
'io_uring_prep_sync_file_range.3',
65+
'io_uring_prep_tee.3',
66+
'io_uring_prep_timeout.3',
67+
'io_uring_prep_timeout_remove.3',
68+
'io_uring_prep_timeout_update.3',
69+
'io_uring_prep_unlink.3',
70+
'io_uring_prep_unlinkat.3',
71+
'io_uring_prep_write.3',
72+
'io_uring_prep_write_fixed.3',
73+
'io_uring_prep_writev2.3',
74+
'io_uring_prep_writev.3',
75+
'io_uring_queue_exit.3',
76+
'io_uring_queue_init.3',
77+
'io_uring_queue_init_params.3',
78+
'io_uring_register.2',
79+
'io_uring_register_buffers.3',
80+
'io_uring_register_buf_ring.3',
81+
'io_uring_register_eventfd.3',
82+
'io_uring_register_eventfd_async.3',
83+
'io_uring_register_files.3',
84+
'io_uring_register_iowq_aff.3',
85+
'io_uring_register_iowq_max_workers.3',
86+
'io_uring_register_ring_fd.3',
87+
'io_uring_setup.2',
88+
'io_uring_sqe_set_data.3',
89+
'io_uring_sqe_set_data64.3',
90+
'io_uring_sqe_set_flags.3',
91+
'io_uring_sq_ready.3',
92+
'io_uring_sqring_wait.3',
93+
'io_uring_sq_space_left.3',
94+
'io_uring_submit.3',
95+
'io_uring_submit_and_wait.3',
96+
'io_uring_submit_and_wait_timeout.3',
97+
'io_uring_unregister_buffers.3',
98+
'io_uring_unregister_buf_ring.3',
99+
'io_uring_unregister_eventfd.3',
100+
'io_uring_unregister_files.3',
101+
'io_uring_unregister_iowq_aff.3',
102+
'io_uring_unregister_ring_fd.3',
103+
'io_uring_wait_cqe.3',
104+
'io_uring_wait_cqe_nr.3',
105+
'io_uring_wait_cqes.3',
106+
'io_uring_wait_cqe_timeout.3',
107+
)

subprojects/packagefiles/liburing/meson.build

Lines changed: 23 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
project('liburing', ['c','cpp'],
2-
version: '2.1',
2+
version: '2.2',
33
license: ['MIT', 'LGPL-2.1-only', 'GPL-2.0-only WITH Linux-syscall-note'],
4-
meson_version: '>=0.53.0',
4+
meson_version: '>=0.54.0',
55
default_options: ['default_library=both',
66
'buildtype=debugoptimized',
77
'c_std=c11',
@@ -31,9 +31,9 @@ has__kernel_timespec = cc.has_members('struct __kernel_timespec',
3131
prefix: '#include <linux/time.h>')
3232

3333
code = '''#include <sys/types.h>
34-
#include <sys/stat.h>
3534
#include <fcntl.h>
3635
#include <string.h>
36+
#include <linux/openat2.h>
3737
int main(int argc, char **argv)
3838
{
3939
struct open_how how;
@@ -60,6 +60,20 @@ int main(int argc, char **argv)
6060
'''
6161
has_statx = cc.compiles(code, name: 'statx')
6262

63+
code= '''#include <sys/types.h>
64+
#include <unistd.h>
65+
#include <fcntl.h>
66+
#include <string.h>
67+
#include <linux/stat.h>
68+
main(int argc, char **argv)
69+
{
70+
struct statx x;
71+
72+
return memset(&x, 0, sizeof(x)) != NULL;
73+
}
74+
'''
75+
glibc_statx = cc.compiles(code, name: 'glibc_statx')
76+
6377
cpp = meson.get_compiler('cpp')
6478

6579
code = '''#include <iostream>
@@ -74,13 +88,19 @@ has_cxx = cpp.compiles(code, name: 'C++')
7488
has_ucontext = (cc.has_type('ucontext_t', prefix: '#include <ucontext.h>')
7589
and cc.has_function('makecontext', prefix: '#include <ucontext.h>'))
7690

91+
has_memfd_create = cc.has_function('memfd_create',
92+
args: ['-D_GNU_SOURCE'],
93+
prefix: '#include <sys/mman.h>')
94+
7795
conf_data = configuration_data()
7896
conf_data.set('CONFIG_HAVE_KERNEL_RWF_T', has__kernel_rwf_t)
7997
conf_data.set('CONFIG_HAVE_KERNEL_TIMESPEC', has__kernel_timespec)
8098
conf_data.set('CONFIG_HAVE_OPEN_HOW', has_open_how)
8199
conf_data.set('CONFIG_HAVE_STATX', has_statx)
100+
conf_data.set('CONFIG_HAVE_GLIBC_STATX', glibc_statx)
82101
conf_data.set('CONFIG_HAVE_CXX', has_cxx)
83102
conf_data.set('CONFIG_HAVE_UCONTEXT', has_ucontext)
103+
conf_data.set('CONFIG_HAVE_MEMFD_CREATE', has_memfd_create)
84104
configure_file(output: 'config-host.h',
85105
configuration: conf_data)
86106

subprojects/packagefiles/liburing/src/include/liburing/meson.build

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ struct __kernel_timespec {
1919
endif
2020

2121
if has_open_how
22-
open_how_compat = ''
22+
open_how_compat = '#include <linux/openat2.h>'
2323
else
2424
open_how_compat = '''#include <inttypes.h>
2525
@@ -35,6 +35,11 @@ conf_data = configuration_data()
3535
conf_data.set('__kernel_rwf_t_compat', __kernel_rwf_t_compat)
3636
conf_data.set('__kernel_timespec_compat', __kernel_timespec_compat)
3737
conf_data.set('open_how_compat', open_how_compat)
38+
39+
if not glibc_statx and has_statx
40+
conf_data.set('no_glibc_statx', '#include <stat/stat.h>')
41+
endif
42+
3843
configure_file(input: 'compat.h.meson',
3944
output: 'compat.h',
4045
configuration: conf_data,

subprojects/packagefiles/liburing/src/meson.build

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ liburing = library('uring',
88
'setup.c',
99
'syscall.c',
1010
include_directories: inc,
11+
c_args: '-DLIBURING_INTERNAL',
1112
link_args: '-Wl,--version-script=' + meson.current_source_dir() + '/liburing.map',
1213
link_depends: 'liburing.map',
1314
install: true)

0 commit comments

Comments
 (0)