Age | Commit message (Collapse) | Author |
|
This is related to the the issue reported here:
https://github.com/axboe/liburing/issues/578
A fix for the reported issue changed ``linux/stat.h`` to ``sys/stat.h``
in ``test/statx.c``, however, it did not change the compile-check in
``configure``.
This change is needed on Alpine Linux / muslc, where 'statx' is detected
by ``configure/compile-check`` but ``sys/stat.h`` does not provide what
is needed by ``test/statx.c``. Resulting in a build-error.
This changes the compiler-check to match the usage in `tests/statx.c`,
thereby fixing the build-error on Alpine Linux / muslc.
Signed-off-by: Simon A. F. Lund <os@safl.dk>
|
|
For poorly configured environments, configure may fail but will still
exit with code 0. This, in turn, causes cryptic build errors later.
Fix this by adding "set -e". Also, append "|| true" to prevent the
`expr` command breaks because it will return a non-zero exit code if
the regex doesn't match.
Closes: https://github.com/axboe/liburing/pull/553
Co-authored-by: Roman Gershman <romange@gmail.com>
Signed-off-by: Roman Gershman <romange@gmail.com>
Signed-off-by: Ammar Faizi <ammarfaizi2@gnuweeb.org>
|
|
```
clang-12: warning: treating 'c' input as 'c++' when in C++ mode, this \
behvior is deprecated [-Wdeprecated]
```
The target compile is C++ but the file extension is ".c". Got the
above warning from clang. Fix it by creating a temporary file with
".cpp" extension and use it.
Introduced by commit d9f953770708ad ("configure: test for presence of
C++ compiler").
Fixes: d9f953770708ad6893140dc2d11258223ba7abfd ("configure: test for presence of C++ compiler")
Cc: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Alviro Iskandar Setiawan <alviro.iskandar@gnuweeb.org>
Signed-off-by: Ammar Faizi <ammarfaizi2@gnuweeb.org>
|
|
```
gcc -D_GNU_SOURCE -include config-host.h -Werror=implicit-function-declaration \
-o /tmp/tmp.UrAfu1BQqA/liburing-conf.exe /tmp/tmp.UrAfu1BQqA/liburing-conf.c
/tmp/tmp.UrAfu1BQqA/liburing-conf.c:1: warning: "_GNU_SOURCE" redefined
1 | #define _GNU_SOURCE
|
<command-line>: note: this is the location of the previous definition
```
Introduced by commit 17d25f4c73b89 ("test/io_uring_register: fix
-Wimplicit-function-declaration of memfd_create").
Fixes: 17d25f4c73b89dfc722a367914776577e266638c ("test/io_uring_register: fix -Wimplicit-function-declaration of memfd_create")
Signed-off-by: Alviro Iskandar Setiawan <alviro.iskandar@gnuweeb.org>
Signed-off-by: Ammar Faizi <ammarfaizi2@gnuweeb.org>
|
|
Busybox mktemp does not support `--tmpdir`, it says:
mktemp: unrecognized option: tmpdir
It can be fixed with:
1. Create a temporary directory.
2. Use touch to create the temporary files inside the directory.
3. Clean up by deleting the temporary directory.
[ammarfaizi2: s/fio/liburing/]
Signed-off-by: Nugra <richiisei@gmail.com>
Link: https://t.me/GNUWeeb/530154
[ammarfaizi2: Rephrase the commit message and add touch command]
Co-authored-by: Ammar Faizi <ammarfaizi2@gnuweeb.org>
Signed-off-by: Ammar Faizi <ammarfaizi2@gnuweeb.org>
Link: https://lore.kernel.org/r/20220215153651.181319-2-ammarfaizi2@gnuweeb.org
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Update configure and test/Makefile, such that if !CONFIG_HAVE_STATX will
not generate statx.c test. Without this patch, liburing fails to compile
on an older toolchain that does not have statx available.
Fixes: #516
Signed-off-by: Jon Kohler <jon@nutanix.com>
|
|
glibc >= 2.28 supports `statx` out of the box. This means we get an
error when attempting to build `liburing` when glibc is >= 2.28, for
e.g. in my glibc version 2.33 I get the following errors
```
:26:8: error: redefinition of ‘struct statx_timestamp’
26 | struct statx_timestamp
| ^~~~~~~~~~~~~~~
In file included from statx.c:14:
```
or
```
error: redefinition of ‘struct statx’
30 | struct statx
| ^~~~~
In file included from statx.c:14:
```
This commit fixes 'make' error by choosing to use the glibc version
of `statx` if available.
glibc 2.28 release notes:
https://sourceware.org/git/?p=glibc.git;a=blob;f=NEWS;h=154ab22d7ca065af5233406927302bb7f6a66890;hb=3c03baca37fdcb52c3881e653ca392bba7a99c2b#l84
Signed-off-by: Bikal Lem <gbikal+git@gmail.com>
|
|
It's for conditonal variable and macro to enable nolibc build.
Also add `--nolibc` option to `configure` to enable it.
Link: https://github.com/axboe/liburing/issues/443
Reviewed-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Ammar Faizi <ammar.faizi@students.amikom.ac.id>
Link: https://lore.kernel.org/r/20211010135338.397115-4-ammar.faizi@students.amikom.ac.id
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
struct open_how and friends reside in the openat2.h header, so include
that for the test case.
Fixes: https://github.com/axboe/liburing/issues/360
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
On some systems, there is no `memfd_create` function. This commit
fixes this:
```
CC io_uring_register
io_uring_register.c: In function 'test_shmem':
io_uring_register.c:514:10: warning: implicit declaration of function 'memfd_create' [-Wimplicit-function-declaration]
memfd = memfd_create("uring-shmem-test", 0);
^
```
Fix for this is based on an answer on Stack Overflow [1].
On Jun 16 '19 at 5:12, mosvy wrote:
> On older systems, you'll have to include linux/memfd.h for the MFD_
> defines, and call memfd_create() via the the syscall(2) wrapper
> (and include unistd.h and sys/syscall.h for it work).
>
Link: https://stackoverflow.com/a/56616264/7275114 [1]
Reported-by: Louvian Lyndal <louvianlyndal@gmail.com>
Tested-by: Louvian Lyndal <louvianlyndal@gmail.com>
Signed-off-by: Ammar Faizi <ammarfaizi2@gmail.com>
|
|
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Elbrus 2000 (aka e2k) is a 64-bit little-endian architecture.
For several reasons it use makecontext_e2k(ctx, ...)
with different semantic instead of makecontext(ctx, ...).
Signed-off-by: Nikita Pechenkin <n.pechenkin@relex.ru>
|
|
These are false positives, and they are annoying when trying to see
if new warnings have been added. Silence them.
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
The header file `ucontext.h` is not available on musl based distros. The
example `ucontext-cp` is not built if `configure` fails to locate the
header.
Signed-off-by: Simon Zeni <simon@bl4ckb0ne.ca>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
The RANDOM variable is a bashism, but we are using a /bin/sh as a
shebang, which means the temporary files created when /bin/sh is not
bash will be using unsafe and predictable names.
Switch to use mktemp(1) and its built-in temporary directory handling
instead of open-coding it.
|
|
Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
This change causes .travis.yml to use the compilers configured in the $CC
and $CXX variables. Additionally, make the configure script show the
compiler names.
Signed-off-by: Bart Van Assche <bvanassche@acm.org>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Trying to build liburing on musl yields an error:
make[1]: Entering directory '/work/devel/liburing/src'
CC setup.ol
CC queue.ol
CC syscall.ol
In file included from syscall.c:9:
include/liburing/compat.h:6:2: error: unknown type name 'int64_t'
6 | int64_t tv_sec;
| ^~~~~~~
make[1]: *** [Makefile:43: syscall.ol] Error 1
make[1]: Leaving directory '/work/devel/liburing/src'
make: *** [Makefile:12: all] Error 2
Ensure that compat.h includes stdint.h.
Signed-off-by: Milan P. Stanić <mps@arvanta.net>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
If not there, don't build the test program test/statx
Fixes: https://github.com/axboe/liburing/issues/101
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
This got changed and I missed it, now corrected...
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
The previous fix for __kernel_timespec only works within the liburing
repo, as that's the only place we have the defines we need. Instead of
relying on that, auto-generate compat.h so it suits the given build
environment.
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
This makes it possible to install runtime libraries to
/lib/* and developement libraries to /usr/lib/*
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Use ./configure --cc=whatever to set the compiler.
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Create an installation target for liburing's regression test suite.
Signed-off-by: Johannes Thumshirn <jthumshirn@suse.de>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
We made a kernel change to support timeouts properly on 32-bit
archs, update liburing to use __kernel_timespec instead of the
differently sized timespec.
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
The configure script used the default value of the prefix variable
(/usr) to determine the includedir etc. *before* parsing the command
line to determine if the user specified a prefix. This made configure
--prefix ineffective.
Fix.
Tested with configure --help, configure --prefix, configure --prefix
--includedir
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
libdir is hardcoded to ${prefix}/lib in Makefile. Fedora x86_64 uses
/usr/lib64 and this means libaries will be installed in the wrong place.
This patch moves prefix, includedir, libdir, and mandir into ./configure
for easier customization. To build and install on Fedora x86_64:
# ./configure --libdir=/usr/lib64
# make && make install
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Some older installs don't have __kernel_rwf_t in linux/fs.h, so
add a check for that.
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|