polyphony 0.85 → 0.86

Sign up to get free protection for your applications and to get access to all the features.
Files changed (230) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +4 -0
  3. data/Gemfile.lock +1 -1
  4. data/ext/polyphony/io_extensions.c +2 -3
  5. data/lib/polyphony/version.rb +1 -1
  6. data/polyphony.gemspec +1 -1
  7. data/test/test_backend.rb +1 -1
  8. data/test/test_signal.rb +3 -3
  9. data/vendor/liburing/.github/pull_request_template.md +86 -0
  10. data/vendor/liburing/.github/workflows/build.yml +85 -0
  11. data/vendor/liburing/.github/workflows/shellcheck.yml +20 -0
  12. data/vendor/liburing/.gitignore +149 -0
  13. data/vendor/liburing/COPYING +502 -0
  14. data/vendor/liburing/COPYING.GPL +339 -0
  15. data/vendor/liburing/LICENSE +7 -0
  16. data/vendor/liburing/Makefile +82 -0
  17. data/vendor/liburing/Makefile.common +5 -0
  18. data/vendor/liburing/Makefile.quiet +11 -0
  19. data/vendor/liburing/README +46 -0
  20. data/vendor/liburing/configure +486 -0
  21. data/vendor/liburing/debian/README.Debian +7 -0
  22. data/vendor/liburing/debian/changelog +27 -0
  23. data/vendor/liburing/debian/compat +1 -0
  24. data/vendor/liburing/debian/control +48 -0
  25. data/vendor/liburing/debian/copyright +49 -0
  26. data/vendor/liburing/debian/liburing-dev.install +4 -0
  27. data/vendor/liburing/debian/liburing-dev.manpages +6 -0
  28. data/vendor/liburing/debian/liburing1-udeb.install +1 -0
  29. data/vendor/liburing/debian/liburing1.install +1 -0
  30. data/vendor/liburing/debian/liburing1.symbols +32 -0
  31. data/vendor/liburing/debian/patches/series +1 -0
  32. data/vendor/liburing/debian/rules +81 -0
  33. data/vendor/liburing/debian/source/format +1 -0
  34. data/vendor/liburing/debian/source/local-options +2 -0
  35. data/vendor/liburing/debian/source/options +1 -0
  36. data/vendor/liburing/debian/watch +3 -0
  37. data/vendor/liburing/examples/Makefile +38 -0
  38. data/vendor/liburing/examples/io_uring-cp.c +282 -0
  39. data/vendor/liburing/examples/io_uring-test.c +112 -0
  40. data/vendor/liburing/examples/link-cp.c +193 -0
  41. data/vendor/liburing/examples/ucontext-cp.c +273 -0
  42. data/vendor/liburing/liburing.pc.in +12 -0
  43. data/vendor/liburing/liburing.spec +66 -0
  44. data/vendor/liburing/make-debs.sh +53 -0
  45. data/vendor/liburing/man/io_uring.7 +754 -0
  46. data/vendor/liburing/man/io_uring_cq_advance.3 +35 -0
  47. data/vendor/liburing/man/io_uring_cq_ready.3 +25 -0
  48. data/vendor/liburing/man/io_uring_cqe_get_data.3 +34 -0
  49. data/vendor/liburing/man/io_uring_cqe_seen.3 +32 -0
  50. data/vendor/liburing/man/io_uring_enter.2 +1483 -0
  51. data/vendor/liburing/man/io_uring_free_probe.3 +24 -0
  52. data/vendor/liburing/man/io_uring_get_probe.3 +29 -0
  53. data/vendor/liburing/man/io_uring_get_sqe.3 +38 -0
  54. data/vendor/liburing/man/io_uring_opcode_supported.3 +29 -0
  55. data/vendor/liburing/man/io_uring_prep_msg_ring.3 +58 -0
  56. data/vendor/liburing/man/io_uring_prep_read.3 +50 -0
  57. data/vendor/liburing/man/io_uring_prep_read_fixed.3 +54 -0
  58. data/vendor/liburing/man/io_uring_prep_readv.3 +51 -0
  59. data/vendor/liburing/man/io_uring_prep_readv2.3 +79 -0
  60. data/vendor/liburing/man/io_uring_prep_write.3 +50 -0
  61. data/vendor/liburing/man/io_uring_prep_write_fixed.3 +54 -0
  62. data/vendor/liburing/man/io_uring_prep_writev.3 +51 -0
  63. data/vendor/liburing/man/io_uring_prep_writev2.3 +78 -0
  64. data/vendor/liburing/man/io_uring_queue_exit.3 +27 -0
  65. data/vendor/liburing/man/io_uring_queue_init.3 +44 -0
  66. data/vendor/liburing/man/io_uring_register.2 +688 -0
  67. data/vendor/liburing/man/io_uring_register_buffers.3 +41 -0
  68. data/vendor/liburing/man/io_uring_register_files.3 +35 -0
  69. data/vendor/liburing/man/io_uring_setup.2 +534 -0
  70. data/vendor/liburing/man/io_uring_sq_ready.3 +25 -0
  71. data/vendor/liburing/man/io_uring_sq_space_left.3 +25 -0
  72. data/vendor/liburing/man/io_uring_sqe_set_data.3 +30 -0
  73. data/vendor/liburing/man/io_uring_sqe_set_flags.3 +60 -0
  74. data/vendor/liburing/man/io_uring_sqring_wait.3 +30 -0
  75. data/vendor/liburing/man/io_uring_submit.3 +29 -0
  76. data/vendor/liburing/man/io_uring_submit_and_wait.3 +34 -0
  77. data/vendor/liburing/man/io_uring_submit_and_wait_timeout.3 +49 -0
  78. data/vendor/liburing/man/io_uring_unregister_buffers.3 +26 -0
  79. data/vendor/liburing/man/io_uring_unregister_files.3 +26 -0
  80. data/vendor/liburing/man/io_uring_wait_cqe.3 +33 -0
  81. data/vendor/liburing/man/io_uring_wait_cqe_nr.3 +36 -0
  82. data/vendor/liburing/man/io_uring_wait_cqe_timeout.3 +39 -0
  83. data/vendor/liburing/man/io_uring_wait_cqes.3 +46 -0
  84. data/vendor/liburing/src/Makefile +89 -0
  85. data/vendor/liburing/src/arch/aarch64/syscall.h +95 -0
  86. data/vendor/liburing/src/arch/generic/lib.h +21 -0
  87. data/vendor/liburing/src/arch/generic/syscall.h +87 -0
  88. data/vendor/liburing/src/arch/syscall-defs.h +67 -0
  89. data/vendor/liburing/src/arch/x86/lib.h +32 -0
  90. data/vendor/liburing/src/arch/x86/syscall.h +160 -0
  91. data/vendor/liburing/src/include/liburing/barrier.h +81 -0
  92. data/vendor/liburing/src/include/liburing/io_uring.h +442 -0
  93. data/vendor/liburing/src/include/liburing.h +921 -0
  94. data/vendor/liburing/src/int_flags.h +8 -0
  95. data/vendor/liburing/src/lib.h +57 -0
  96. data/vendor/liburing/src/liburing.map +53 -0
  97. data/vendor/liburing/src/nolibc.c +48 -0
  98. data/vendor/liburing/src/queue.c +403 -0
  99. data/vendor/liburing/src/register.c +293 -0
  100. data/vendor/liburing/src/setup.c +332 -0
  101. data/vendor/liburing/src/syscall.c +47 -0
  102. data/vendor/liburing/src/syscall.h +103 -0
  103. data/vendor/liburing/test/232c93d07b74-test.c +306 -0
  104. data/vendor/liburing/test/35fa71a030ca-test.c +329 -0
  105. data/vendor/liburing/test/500f9fbadef8-test.c +89 -0
  106. data/vendor/liburing/test/7ad0e4b2f83c-test.c +93 -0
  107. data/vendor/liburing/test/8a9973408177-test.c +106 -0
  108. data/vendor/liburing/test/917257daa0fe-test.c +53 -0
  109. data/vendor/liburing/test/Makefile +244 -0
  110. data/vendor/liburing/test/a0908ae19763-test.c +58 -0
  111. data/vendor/liburing/test/a4c0b3decb33-test.c +180 -0
  112. data/vendor/liburing/test/accept-link.c +254 -0
  113. data/vendor/liburing/test/accept-reuse.c +164 -0
  114. data/vendor/liburing/test/accept-test.c +79 -0
  115. data/vendor/liburing/test/accept.c +477 -0
  116. data/vendor/liburing/test/across-fork.c +283 -0
  117. data/vendor/liburing/test/b19062a56726-test.c +53 -0
  118. data/vendor/liburing/test/b5837bd5311d-test.c +77 -0
  119. data/vendor/liburing/test/ce593a6c480a-test.c +136 -0
  120. data/vendor/liburing/test/close-opath.c +122 -0
  121. data/vendor/liburing/test/config +10 -0
  122. data/vendor/liburing/test/connect.c +398 -0
  123. data/vendor/liburing/test/cq-full.c +96 -0
  124. data/vendor/liburing/test/cq-overflow.c +294 -0
  125. data/vendor/liburing/test/cq-peek-batch.c +102 -0
  126. data/vendor/liburing/test/cq-ready.c +94 -0
  127. data/vendor/liburing/test/cq-size.c +64 -0
  128. data/vendor/liburing/test/d4ae271dfaae-test.c +96 -0
  129. data/vendor/liburing/test/d77a67ed5f27-test.c +65 -0
  130. data/vendor/liburing/test/defer.c +307 -0
  131. data/vendor/liburing/test/double-poll-crash.c +185 -0
  132. data/vendor/liburing/test/drop-submit.c +92 -0
  133. data/vendor/liburing/test/eeed8b54e0df-test.c +114 -0
  134. data/vendor/liburing/test/empty-eownerdead.c +45 -0
  135. data/vendor/liburing/test/eventfd-disable.c +151 -0
  136. data/vendor/liburing/test/eventfd-reg.c +76 -0
  137. data/vendor/liburing/test/eventfd-ring.c +97 -0
  138. data/vendor/liburing/test/eventfd.c +112 -0
  139. data/vendor/liburing/test/exec-target.c +6 -0
  140. data/vendor/liburing/test/exit-no-cleanup.c +117 -0
  141. data/vendor/liburing/test/fadvise.c +202 -0
  142. data/vendor/liburing/test/fallocate.c +249 -0
  143. data/vendor/liburing/test/fc2a85cb02ef-test.c +131 -0
  144. data/vendor/liburing/test/file-register.c +858 -0
  145. data/vendor/liburing/test/file-update.c +173 -0
  146. data/vendor/liburing/test/file-verify.c +629 -0
  147. data/vendor/liburing/test/files-exit-hang-poll.c +128 -0
  148. data/vendor/liburing/test/files-exit-hang-timeout.c +134 -0
  149. data/vendor/liburing/test/fixed-link.c +90 -0
  150. data/vendor/liburing/test/fpos.c +252 -0
  151. data/vendor/liburing/test/fsync.c +224 -0
  152. data/vendor/liburing/test/hardlink.c +136 -0
  153. data/vendor/liburing/test/helpers.c +135 -0
  154. data/vendor/liburing/test/helpers.h +67 -0
  155. data/vendor/liburing/test/io-cancel.c +550 -0
  156. data/vendor/liburing/test/io_uring_enter.c +296 -0
  157. data/vendor/liburing/test/io_uring_register.c +676 -0
  158. data/vendor/liburing/test/io_uring_setup.c +192 -0
  159. data/vendor/liburing/test/iopoll.c +372 -0
  160. data/vendor/liburing/test/lfs-openat-write.c +119 -0
  161. data/vendor/liburing/test/lfs-openat.c +275 -0
  162. data/vendor/liburing/test/link-timeout.c +1107 -0
  163. data/vendor/liburing/test/link.c +496 -0
  164. data/vendor/liburing/test/link_drain.c +229 -0
  165. data/vendor/liburing/test/madvise.c +195 -0
  166. data/vendor/liburing/test/mkdir.c +108 -0
  167. data/vendor/liburing/test/msg-ring.c +234 -0
  168. data/vendor/liburing/test/multicqes_drain.c +387 -0
  169. data/vendor/liburing/test/nop-all-sizes.c +99 -0
  170. data/vendor/liburing/test/nop.c +115 -0
  171. data/vendor/liburing/test/open-close.c +261 -0
  172. data/vendor/liburing/test/openat2.c +308 -0
  173. data/vendor/liburing/test/personality.c +204 -0
  174. data/vendor/liburing/test/pipe-eof.c +83 -0
  175. data/vendor/liburing/test/pipe-reuse.c +105 -0
  176. data/vendor/liburing/test/poll-cancel-ton.c +135 -0
  177. data/vendor/liburing/test/poll-cancel.c +228 -0
  178. data/vendor/liburing/test/poll-link.c +230 -0
  179. data/vendor/liburing/test/poll-many.c +208 -0
  180. data/vendor/liburing/test/poll-mshot-update.c +273 -0
  181. data/vendor/liburing/test/poll-ring.c +48 -0
  182. data/vendor/liburing/test/poll-v-poll.c +353 -0
  183. data/vendor/liburing/test/poll.c +109 -0
  184. data/vendor/liburing/test/pollfree.c +426 -0
  185. data/vendor/liburing/test/probe.c +135 -0
  186. data/vendor/liburing/test/read-write.c +876 -0
  187. data/vendor/liburing/test/register-restrictions.c +633 -0
  188. data/vendor/liburing/test/rename.c +135 -0
  189. data/vendor/liburing/test/ring-leak.c +173 -0
  190. data/vendor/liburing/test/ring-leak2.c +249 -0
  191. data/vendor/liburing/test/rsrc_tags.c +449 -0
  192. data/vendor/liburing/test/runtests-loop.sh +16 -0
  193. data/vendor/liburing/test/runtests.sh +170 -0
  194. data/vendor/liburing/test/rw_merge_test.c +97 -0
  195. data/vendor/liburing/test/self.c +91 -0
  196. data/vendor/liburing/test/send_recv.c +286 -0
  197. data/vendor/liburing/test/send_recvmsg.c +345 -0
  198. data/vendor/liburing/test/sendmsg_fs_cve.c +200 -0
  199. data/vendor/liburing/test/shared-wq.c +84 -0
  200. data/vendor/liburing/test/short-read.c +75 -0
  201. data/vendor/liburing/test/shutdown.c +165 -0
  202. data/vendor/liburing/test/sigfd-deadlock.c +74 -0
  203. data/vendor/liburing/test/skip-cqe.c +429 -0
  204. data/vendor/liburing/test/socket-rw-eagain.c +158 -0
  205. data/vendor/liburing/test/socket-rw-offset.c +157 -0
  206. data/vendor/liburing/test/socket-rw.c +145 -0
  207. data/vendor/liburing/test/splice.c +512 -0
  208. data/vendor/liburing/test/sq-full-cpp.cc +45 -0
  209. data/vendor/liburing/test/sq-full.c +45 -0
  210. data/vendor/liburing/test/sq-poll-dup.c +204 -0
  211. data/vendor/liburing/test/sq-poll-kthread.c +169 -0
  212. data/vendor/liburing/test/sq-poll-share.c +137 -0
  213. data/vendor/liburing/test/sq-space_left.c +159 -0
  214. data/vendor/liburing/test/sqpoll-cancel-hang.c +157 -0
  215. data/vendor/liburing/test/sqpoll-disable-exit.c +196 -0
  216. data/vendor/liburing/test/sqpoll-exit-hang.c +78 -0
  217. data/vendor/liburing/test/sqpoll-sleep.c +69 -0
  218. data/vendor/liburing/test/statx.c +172 -0
  219. data/vendor/liburing/test/stdout.c +232 -0
  220. data/vendor/liburing/test/submit-link-fail.c +154 -0
  221. data/vendor/liburing/test/submit-reuse.c +239 -0
  222. data/vendor/liburing/test/symlink.c +116 -0
  223. data/vendor/liburing/test/teardowns.c +58 -0
  224. data/vendor/liburing/test/thread-exit.c +143 -0
  225. data/vendor/liburing/test/timeout-new.c +252 -0
  226. data/vendor/liburing/test/timeout-overflow.c +204 -0
  227. data/vendor/liburing/test/timeout.c +1523 -0
  228. data/vendor/liburing/test/unlink.c +112 -0
  229. data/vendor/liburing/test/wakeup-hang.c +162 -0
  230. metadata +223 -2
@@ -0,0 +1,486 @@
1
+ #!/bin/sh
2
+
3
+ cc=${CC:-gcc}
4
+ cxx=${CXX:-g++}
5
+
6
+ for opt do
7
+ optarg=$(expr "x$opt" : 'x[^=]*=\(.*\)')
8
+ case "$opt" in
9
+ --help|-h) show_help=yes
10
+ ;;
11
+ --prefix=*) prefix="$optarg"
12
+ ;;
13
+ --includedir=*) includedir="$optarg"
14
+ ;;
15
+ --libdir=*) libdir="$optarg"
16
+ ;;
17
+ --libdevdir=*) libdevdir="$optarg"
18
+ ;;
19
+ --mandir=*) mandir="$optarg"
20
+ ;;
21
+ --datadir=*) datadir="$optarg"
22
+ ;;
23
+ --cc=*) cc="$optarg"
24
+ ;;
25
+ --cxx=*) cxx="$optarg"
26
+ ;;
27
+ --nolibc) liburing_nolibc="yes"
28
+ ;;
29
+ *)
30
+ echo "ERROR: unknown option $opt"
31
+ echo "Try '$0 --help' for more information"
32
+ exit 1
33
+ ;;
34
+ esac
35
+ done
36
+
37
+ if test -z "$prefix"; then
38
+ prefix=/usr
39
+ fi
40
+ if test -z "$includedir"; then
41
+ includedir="$prefix/include"
42
+ fi
43
+ if test -z "$libdir"; then
44
+ libdir="$prefix/lib"
45
+ fi
46
+ if test -z "$libdevdir"; then
47
+ libdevdir="$prefix/lib"
48
+ fi
49
+ if test -z "$mandir"; then
50
+ mandir="$prefix/man"
51
+ fi
52
+ if test -z "$datadir"; then
53
+ datadir="$prefix/share"
54
+ fi
55
+
56
+ if test x"$libdir" = x"$libdevdir"; then
57
+ relativelibdir=""
58
+ else
59
+ relativelibdir="$libdir/"
60
+ fi
61
+
62
+ if test "$show_help" = "yes"; then
63
+ cat <<EOF
64
+
65
+ Usage: configure [options]
66
+ Options: [defaults in brackets after descriptions]
67
+ --help print this message
68
+ --prefix=PATH install in PATH [$prefix]
69
+ --includedir=PATH install headers in PATH [$includedir]
70
+ --libdir=PATH install runtime libraries in PATH [$libdir]
71
+ --libdevdir=PATH install development libraries in PATH [$libdevdir]
72
+ --mandir=PATH install man pages in PATH [$mandir]
73
+ --datadir=PATH install shared data in PATH [$datadir]
74
+ --cc=CMD use CMD as the C compiler
75
+ --cxx=CMD use CMD as the C++ compiler
76
+ --nolibc build liburing without libc
77
+ EOF
78
+ exit 0
79
+ fi
80
+
81
+ TMP_DIRECTORY="$(mktemp -d)"
82
+ TMPC="$TMP_DIRECTORY/liburing-conf.c"
83
+ TMPC2="$TMP_DIRECTORY/liburing-conf-2.c"
84
+ TMPCXX="$TMP_DIRECTORY/liburing-conf-2.cpp"
85
+ TMPO="$TMP_DIRECTORY/liburing-conf.o"
86
+ TMPE="$TMP_DIRECTORY/liburing-conf.exe"
87
+
88
+ touch $TMPC $TMPC2 $TMPCXX $TMPO $TMPE
89
+
90
+ # NB: do not call "exit" in the trap handler; this is buggy with some shells;
91
+ # see <1285349658-3122-1-git-send-email-loic.minier@linaro.org>
92
+ trap "rm -rf $TMP_DIRECTORY" EXIT INT QUIT TERM
93
+
94
+ rm -rf config.log
95
+
96
+ config_host_mak="config-host.mak"
97
+ config_host_h="config-host.h"
98
+
99
+ rm -rf $config_host_mak
100
+ rm -rf $config_host_h
101
+
102
+ fatal() {
103
+ echo $@
104
+ echo "Configure failed, check config.log and/or the above output"
105
+ rm -rf $config_host_mak
106
+ rm -rf $config_host_h
107
+ exit 1
108
+ }
109
+
110
+ # Print result for each configuration test
111
+ print_config() {
112
+ printf "%-30s%s\n" "$1" "$2"
113
+ }
114
+
115
+ # Default CFLAGS
116
+ CFLAGS="-D_GNU_SOURCE -include config-host.h"
117
+ BUILD_CFLAGS=""
118
+
119
+ # Print configure header at the top of $config_host_h
120
+ echo "/*" > $config_host_h
121
+ echo " * Automatically generated by configure - do not modify" >> $config_host_h
122
+ printf " * Configured with:" >> $config_host_h
123
+ printf " * '%s'" "$0" "$@" >> $config_host_h
124
+ echo "" >> $config_host_h
125
+ echo " */" >> $config_host_h
126
+
127
+ echo "# Automatically generated by configure - do not modify" > $config_host_mak
128
+ printf "# Configured with:" >> $config_host_mak
129
+ printf " '%s'" "$0" "$@" >> $config_host_mak
130
+ echo >> $config_host_mak
131
+
132
+ do_cxx() {
133
+ # Run the compiler, capturing its output to the log.
134
+ echo $cxx "$@" >> config.log
135
+ $cxx "$@" >> config.log 2>&1 || return $?
136
+ return 0
137
+ }
138
+
139
+ do_cc() {
140
+ # Run the compiler, capturing its output to the log.
141
+ echo $cc "$@" >> config.log
142
+ $cc "$@" >> config.log 2>&1 || return $?
143
+ # Test passed. If this is an --enable-werror build, rerun
144
+ # the test with -Werror and bail out if it fails. This
145
+ # makes warning-generating-errors in configure test code
146
+ # obvious to developers.
147
+ if test "$werror" != "yes"; then
148
+ return 0
149
+ fi
150
+ # Don't bother rerunning the compile if we were already using -Werror
151
+ case "$*" in
152
+ *-Werror*)
153
+ return 0
154
+ ;;
155
+ esac
156
+ echo $cc -Werror "$@" >> config.log
157
+ $cc -Werror "$@" >> config.log 2>&1 && return $?
158
+ echo "ERROR: configure test passed without -Werror but failed with -Werror."
159
+ echo "This is probably a bug in the configure script. The failing command"
160
+ echo "will be at the bottom of config.log."
161
+ fatal "You can run configure with --disable-werror to bypass this check."
162
+ }
163
+
164
+ compile_prog() {
165
+ local_cflags="$1"
166
+ local_ldflags="$2 $LIBS"
167
+ echo "Compiling test case $3" >> config.log
168
+ do_cc $CFLAGS $local_cflags -o $TMPE $TMPC $LDFLAGS $local_ldflags
169
+ }
170
+
171
+ compile_prog_cxx() {
172
+ local_cflags="$1"
173
+ local_ldflags="$2 $LIBS"
174
+ echo "Compiling test case $3" >> config.log
175
+ do_cxx $CFLAGS $local_cflags -o $TMPE $TMPCXX $LDFLAGS $local_ldflags
176
+ }
177
+
178
+ has() {
179
+ type "$1" >/dev/null 2>&1
180
+ }
181
+
182
+ output_mak() {
183
+ echo "$1=$2" >> $config_host_mak
184
+ }
185
+
186
+ output_sym() {
187
+ output_mak "$1" "y"
188
+ echo "#define $1" >> $config_host_h
189
+ }
190
+
191
+ print_and_output_mak() {
192
+ print_config "$1" "$2"
193
+ output_mak "$1" "$2"
194
+ }
195
+ print_and_output_mak "prefix" "$prefix"
196
+ print_and_output_mak "includedir" "$includedir"
197
+ print_and_output_mak "libdir" "$libdir"
198
+ print_and_output_mak "libdevdir" "$libdevdir"
199
+ print_and_output_mak "relativelibdir" "$relativelibdir"
200
+ print_and_output_mak "mandir" "$mandir"
201
+ print_and_output_mak "datadir" "$datadir"
202
+
203
+ ##########################################
204
+ # check for compiler -Wstringop-overflow
205
+ stringop_overflow="no"
206
+ cat > $TMPC << EOF
207
+ #include <linux/fs.h>
208
+ int main(int argc, char **argv)
209
+ {
210
+ return 0;
211
+ }
212
+ EOF
213
+ if compile_prog "-Werror -Wstringop-overflow=0" "" "stringop_overflow"; then
214
+ stringop_overflow="yes"
215
+ fi
216
+ print_config "stringop_overflow" "$stringop_overflow"
217
+
218
+ ##########################################
219
+ # check for compiler -Warryr-bounds
220
+ array_bounds="no"
221
+ cat > $TMPC << EOF
222
+ #include <linux/fs.h>
223
+ int main(int argc, char **argv)
224
+ {
225
+ return 0;
226
+ }
227
+ EOF
228
+ if compile_prog "-Werror -Warray-bounds=0" "" "array_bounds"; then
229
+ array_bounds="yes"
230
+ fi
231
+ print_config "array_bounds" "$array_bounds"
232
+
233
+
234
+ ##########################################
235
+ # check for __kernel_rwf_t
236
+ __kernel_rwf_t="no"
237
+ cat > $TMPC << EOF
238
+ #include <linux/fs.h>
239
+ int main(int argc, char **argv)
240
+ {
241
+ __kernel_rwf_t x;
242
+ x = 0;
243
+ return x;
244
+ }
245
+ EOF
246
+ if compile_prog "" "" "__kernel_rwf_t"; then
247
+ __kernel_rwf_t="yes"
248
+ fi
249
+ print_config "__kernel_rwf_t" "$__kernel_rwf_t"
250
+
251
+ ##########################################
252
+ # check for __kernel_timespec
253
+ __kernel_timespec="no"
254
+ cat > $TMPC << EOF
255
+ #include <linux/time.h>
256
+ #include <linux/time_types.h>
257
+ int main(int argc, char **argv)
258
+ {
259
+ struct __kernel_timespec ts;
260
+ ts.tv_sec = 0;
261
+ ts.tv_nsec = 1;
262
+ return 0;
263
+ }
264
+ EOF
265
+ if compile_prog "" "" "__kernel_timespec"; then
266
+ __kernel_timespec="yes"
267
+ fi
268
+ print_config "__kernel_timespec" "$__kernel_timespec"
269
+
270
+ ##########################################
271
+ # check for open_how
272
+ open_how="no"
273
+ cat > $TMPC << EOF
274
+ #include <sys/types.h>
275
+ #include <fcntl.h>
276
+ #include <string.h>
277
+ #include <linux/openat2.h>
278
+ int main(int argc, char **argv)
279
+ {
280
+ struct open_how how;
281
+ how.flags = 0;
282
+ how.mode = 0;
283
+ how.resolve = 0;
284
+ return 0;
285
+ }
286
+ EOF
287
+ if compile_prog "" "" "open_how"; then
288
+ open_how="yes"
289
+ fi
290
+ print_config "open_how" "$open_how"
291
+
292
+ ##########################################
293
+ # check for statx
294
+ statx="no"
295
+ cat > $TMPC << EOF
296
+ #include <sys/types.h>
297
+ #include <sys/stat.h>
298
+ #include <unistd.h>
299
+ #include <fcntl.h>
300
+ #include <string.h>
301
+ #include <linux/stat.h>
302
+ int main(int argc, char **argv)
303
+ {
304
+ struct statx x;
305
+
306
+ return memset(&x, 0, sizeof(x)) != NULL;
307
+ }
308
+ EOF
309
+ if compile_prog "" "" "statx"; then
310
+ statx="yes"
311
+ fi
312
+ print_config "statx" "$statx"
313
+
314
+ ##########################################
315
+ # check for glibc statx
316
+ glibc_statx="no"
317
+ cat > $TMPC << EOF
318
+ #include <sys/types.h>
319
+ #include <unistd.h>
320
+ #include <fcntl.h>
321
+ #include <string.h>
322
+ #include <linux/stat.h>
323
+ int main(int argc, char **argv)
324
+ {
325
+ struct statx x;
326
+
327
+ return memset(&x, 0, sizeof(x)) != NULL;
328
+ }
329
+ EOF
330
+ if compile_prog "" "" "glibc_statx"; then
331
+ glibc_statx="yes"
332
+ fi
333
+ print_config "glibc_statx" "$glibc_statx"
334
+
335
+ ##########################################
336
+ # check for C++
337
+ has_cxx="no"
338
+ cat > $TMPCXX << EOF
339
+ #include <iostream>
340
+ int main(int argc, char **argv)
341
+ {
342
+ std::cout << "Test";
343
+ return 0;
344
+ }
345
+ EOF
346
+ if compile_prog_cxx "" "" "C++"; then
347
+ has_cxx="yes"
348
+ fi
349
+ print_config "C++" "$has_cxx"
350
+
351
+ ##########################################
352
+ # check for ucontext support
353
+ has_ucontext="no"
354
+ cat > $TMPC << EOF
355
+ #include <ucontext.h>
356
+ int main(int argc, char **argv)
357
+ {
358
+ ucontext_t ctx;
359
+ getcontext(&ctx);
360
+ makecontext(&ctx, 0, 0);
361
+ return 0;
362
+ }
363
+ EOF
364
+ if compile_prog "" "" "has_ucontext"; then
365
+ has_ucontext="yes"
366
+ fi
367
+ print_config "has_ucontext" "$has_ucontext"
368
+
369
+ ##########################################
370
+ # check for memfd_create(2)
371
+ has_memfd_create="no"
372
+ cat > $TMPC << EOF
373
+ #include <sys/mman.h>
374
+ int main(int argc, char **argv)
375
+ {
376
+ int memfd = memfd_create("test", 0);
377
+ return 0;
378
+ }
379
+ EOF
380
+ if compile_prog "-Werror=implicit-function-declaration" "" "has_memfd_create"; then
381
+ has_memfd_create="yes"
382
+ fi
383
+ print_config "has_memfd_create" "$has_memfd_create"
384
+
385
+
386
+ #############################################################################
387
+ if test "$liburing_nolibc" = "yes"; then
388
+ output_sym "CONFIG_NOLIBC"
389
+ else
390
+ liburing_nolibc="no"
391
+ fi
392
+ print_config "liburing_nolibc" "$liburing_nolibc"
393
+
394
+ if test "$__kernel_rwf_t" = "yes"; then
395
+ output_sym "CONFIG_HAVE_KERNEL_RWF_T"
396
+ fi
397
+ if test "$__kernel_timespec" = "yes"; then
398
+ output_sym "CONFIG_HAVE_KERNEL_TIMESPEC"
399
+ fi
400
+ if test "$open_how" = "yes"; then
401
+ output_sym "CONFIG_HAVE_OPEN_HOW"
402
+ fi
403
+ if test "$statx" = "yes"; then
404
+ output_sym "CONFIG_HAVE_STATX"
405
+ fi
406
+ if test "$glibc_statx" = "yes"; then
407
+ output_sym "CONFIG_HAVE_GLIBC_STATX"
408
+ fi
409
+ if test "$has_cxx" = "yes"; then
410
+ output_sym "CONFIG_HAVE_CXX"
411
+ fi
412
+ if test "$has_ucontext" = "yes"; then
413
+ output_sym "CONFIG_HAVE_UCONTEXT"
414
+ fi
415
+ if test "$stringop_overflow" = "yes"; then
416
+ output_sym "CONFIG_HAVE_STRINGOP_OVERFLOW"
417
+ fi
418
+ if test "$array_bounds" = "yes"; then
419
+ output_sym "CONFIG_HAVE_ARRAY_BOUNDS"
420
+ fi
421
+ if test "$has_memfd_create" = "yes"; then
422
+ output_sym "CONFIG_HAVE_MEMFD_CREATE"
423
+ fi
424
+
425
+ echo "CC=$cc" >> $config_host_mak
426
+ print_config "CC" "$cc"
427
+ echo "CXX=$cxx" >> $config_host_mak
428
+ print_config "CXX" "$cxx"
429
+
430
+ # generate compat.h
431
+ compat_h="src/include/liburing/compat.h"
432
+ cat > $compat_h << EOF
433
+ /* SPDX-License-Identifier: MIT */
434
+ #ifndef LIBURING_COMPAT_H
435
+ #define LIBURING_COMPAT_H
436
+
437
+ EOF
438
+
439
+ if test "$__kernel_rwf_t" != "yes"; then
440
+ cat >> $compat_h << EOF
441
+ typedef int __kernel_rwf_t;
442
+
443
+ EOF
444
+ fi
445
+ if test "$__kernel_timespec" != "yes"; then
446
+ cat >> $compat_h << EOF
447
+ #include <stdint.h>
448
+
449
+ struct __kernel_timespec {
450
+ int64_t tv_sec;
451
+ long long tv_nsec;
452
+ };
453
+
454
+ EOF
455
+ else
456
+ cat >> $compat_h << EOF
457
+ #include <linux/time_types.h>
458
+
459
+ EOF
460
+ fi
461
+ if test "$open_how" != "yes"; then
462
+ cat >> $compat_h << EOF
463
+ #include <inttypes.h>
464
+
465
+ struct open_how {
466
+ uint64_t flags;
467
+ uint64_t mode;
468
+ uint64_t resolve;
469
+ };
470
+
471
+ EOF
472
+ else cat >> $compat_h << EOF
473
+ #include <linux/openat2.h>
474
+
475
+ EOF
476
+ fi
477
+ if [ "$glibc_statx" = "no" ] && [ "$statx" = "yes" ]; then
478
+ cat >> $compat_h << EOF
479
+ #include <sys/stat.h>
480
+
481
+ EOF
482
+ fi
483
+
484
+ cat >> $compat_h << EOF
485
+ #endif
486
+ EOF
@@ -0,0 +1,7 @@
1
+ liburing for Debian
2
+
3
+ The newest Linux IO interface i.e. io_uring, need
4
+ userspace library to support it. This package
5
+ liburing is the library for io_uring.
6
+
7
+ -- Liu Changcheng <changcheng.liu@aliyun.com> Thu, 14 Nov 2019 21:35:39 +0800
@@ -0,0 +1,27 @@
1
+ liburing (0.7-1) stable; urgency=low
2
+
3
+ * Update to 0.7
4
+ * Fix library symlinks
5
+
6
+ -- Stefan Metzmacher <metze@samba.org> Thu, 23 Jul 2020 00:23:00 +0200
7
+
8
+ liburing (0.4-2) stable; urgency=low
9
+
10
+ * Fix /usr/lib/*/liburing.so symlink to /lib/*/liburing.so.1.0.4
11
+
12
+ -- Stefan Metzmacher <metze@samba.org> Fri, 07 Feb 2020 15:30:00 +0100
13
+
14
+ liburing (0.4-1) stable; urgency=low
15
+
16
+ * Package liburing-0.4 using a packaging layout similar to libaio1
17
+
18
+ -- Stefan Metzmacher <metze@samba.org> Thu, 06 Feb 2020 11:30:00 +0100
19
+
20
+ liburing (0.2-1ubuntu1) stable; urgency=low
21
+
22
+ * Initial release.
23
+ * commit 4bce856d43ab1f9a64477aa5a8f9f02f53e64b74
24
+ * Author: Jens Axboe <axboe@kernel.dk>
25
+ * Date: Mon Nov 11 16:00:58 2019 -0700
26
+
27
+ -- Liu Changcheng <changcheng.liu@aliyun.com> Fri, 15 Nov 2019 00:06:46 +0800
@@ -0,0 +1 @@
1
+ 9
@@ -0,0 +1,48 @@
1
+ Source: liburing
2
+ Section: libs
3
+ Priority: optional
4
+ Maintainer: Liu Changcheng <changcheng.liu@intel.com>
5
+ Build-Depends: debhelper (>=9)
6
+ Standards-Version: 4.1.4
7
+ Homepage: https://git.kernel.dk/cgit/liburing/tree/README
8
+ Vcs-Git: https://git.kernel.dk/liburing
9
+ Vcs-Browser: https://git.kernel.dk/cgit/liburing/
10
+
11
+ Package: liburing1
12
+ Architecture: linux-any
13
+ Multi-Arch: same
14
+ Pre-Depends: ${misc:Pre-Depends}
15
+ Depends: ${misc:Depends}, ${shlibs:Depends}
16
+ Description: userspace library for using io_uring
17
+ io_uring is kernel feature to improve development
18
+ The newese Linux IO interface, io_uring could improve
19
+ system performance a lot. liburing is the userpace
20
+ library to use io_uring feature.
21
+ .
22
+ This package contains the shared library.
23
+
24
+ Package: liburing1-udeb
25
+ Package-Type: udeb
26
+ Section: debian-installer
27
+ Architecture: linux-any
28
+ Depends: ${misc:Depends}, ${shlibs:Depends},
29
+ Description: userspace library for using io_uring
30
+ io_uring is kernel feature to improve development
31
+ The newese Linux IO interface, io_uring could improve
32
+ system performance a lot. liburing is the userpace
33
+ library to use io_uring feature.
34
+ .
35
+ This package contains the udeb shared library.
36
+
37
+ Package: liburing-dev
38
+ Section: libdevel
39
+ Architecture: linux-any
40
+ Multi-Arch: same
41
+ Depends: ${misc:Depends}, liburing1 (= ${binary:Version}),
42
+ Description: userspace library for using io_uring
43
+ io_uring is kernel feature to improve development
44
+ The newese Linux IO interface, io_uring could improve
45
+ system performance a lot. liburing is the userpace
46
+ library to use io_uring feature.
47
+ .
48
+ This package contains the static library and the header files.
@@ -0,0 +1,49 @@
1
+ Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
2
+ Upstream-Name: liburing
3
+ Source: https://git.kernel.dk/cgit/liburing/
4
+
5
+ Files: *
6
+ Copyright: 2019 Jens Axboe <axboe@kernel.dk>
7
+ License: GPL-2+ / MIT
8
+
9
+ Files: debian/*
10
+ Copyright: 2019 Changcheng Liu <changcheng.liu@aliyun.com>
11
+ License: GPL-2+
12
+
13
+ License: GPL-2+
14
+ This package is free software; you can redistribute it and/or modify
15
+ it under the terms of the GNU General Public License as published by
16
+ the Free Software Foundation; either version 2 of the License, or
17
+ (at your option) any later version.
18
+ .
19
+ This package is distributed in the hope that it will be useful,
20
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
21
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
22
+ GNU General Public License for more details.
23
+ .
24
+ You should have received a copy of the GNU General Public License
25
+ along with this program. If not, see <https://www.gnu.org/licenses/>
26
+ .
27
+ On Debian systems, the complete text of the GNU General
28
+ Public License version 2 can be found in "/usr/share/common-licenses/GPL-2".
29
+
30
+ License: MIT
31
+ Copyright 2020 Jens Axboe
32
+
33
+ Permission is hereby granted, free of charge, to any person obtaining a copy
34
+ of this software and associated documentation files (the "Software"), to deal
35
+ in the Software without restriction, including without limitation the rights
36
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
37
+ copies of the Software, and to permit persons to whom the Software is
38
+ furnished to do so, subject to the following conditions:
39
+
40
+ The above copyright notice and this permission notice shall be included in all
41
+ copies or substantial portions of the Software.
42
+
43
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
44
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
45
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
46
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
47
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
48
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
49
+ SOFTWARE.
@@ -0,0 +1,4 @@
1
+ usr/include
2
+ usr/lib/*/lib*.so
3
+ usr/lib/*/lib*.a
4
+ usr/lib/*/pkgconfig
@@ -0,0 +1,6 @@
1
+ man/io_uring_setup.2
2
+ man/io_uring_enter.2
3
+ man/io_uring_register.2
4
+ man/io_uring_queue_exit.3
5
+ man/io_uring_queue_init.3
6
+ man/io_uring_get_sqe.3
@@ -0,0 +1 @@
1
+ lib/*/lib*.so.*
@@ -0,0 +1 @@
1
+ lib/*/lib*.so.*
@@ -0,0 +1,32 @@
1
+ liburing.so.1 liburing1 #MINVER#
2
+ (symver)LIBURING_0.1 0.1-1
3
+ io_uring_get_sqe@LIBURING_0.1 0.1-1
4
+ io_uring_queue_exit@LIBURING_0.1 0.1-1
5
+ io_uring_queue_init@LIBURING_0.1 0.1-1
6
+ io_uring_queue_mmap@LIBURING_0.1 0.1-1
7
+ io_uring_register_buffers@LIBURING_0.1 0.1-1
8
+ io_uring_register_eventfd@LIBURING_0.1 0.1-1
9
+ io_uring_register_eventfd_async@LIBURING_0.6 0.6-1
10
+ io_uring_register_files@LIBURING_0.1 0.1-1
11
+ io_uring_submit@LIBURING_0.1 0.1-1
12
+ io_uring_submit_and_wait@LIBURING_0.1 0.1-1
13
+ io_uring_unregister_buffers@LIBURING_0.1 0.1-1
14
+ io_uring_unregister_files@LIBURING_0.1 0.1-1
15
+ (symver)LIBURING_0.2 0.2-1
16
+ __io_uring_get_cqe@LIBURING_0.2 0.2-1
17
+ io_uring_queue_init_params@LIBURING_0.2 0.2-1
18
+ io_uring_register_files_update@LIBURING_0.2 0.2-1
19
+ io_uring_peek_batch_cqe@LIBURING_0.2 0.2-1
20
+ io_uring_wait_cqe_timeout@LIBURING_0.2 0.2-1
21
+ io_uring_wait_cqes@LIBURING_0.2 0.2-1
22
+ (symver)LIBURING_0.3 0.3-1
23
+ (symver)LIBURING_0.4 0.4-1
24
+ (symver)LIBURING_0.5 0.5-1
25
+ (symver)LIBURING_0.6 0.6-1
26
+ (symver)LIBURING_0.7 0.7-1
27
+ io_uring_get_probe@LIBURING_0.4 0.4-1
28
+ io_uring_get_probe_ring@LIBURING_0.4 0.4-1
29
+ io_uring_register_personality@LIBURING_0.4 0.4-1
30
+ io_uring_register_probe@LIBURING_0.4 0.4-1
31
+ io_uring_ring_dontfork@LIBURING_0.4 0.4-1
32
+ io_uring_unregister_personality@LIBURING_0.4 0.4-1
@@ -0,0 +1 @@
1
+ # You must remove unused comment lines for the released package.