X-Git-Url: https://review.fuel-infra.org/gitweb?a=blobdiff_plain;f=cirros-testvm%2Fsrc-cirros%2Fbuildroot-2015.05%2Fpackage%2Flttng-babeltrace%2F0001-no-posix-fallocate-in-uclibc.patch;fp=cirros-testvm%2Fsrc-cirros%2Fbuildroot-2015.05%2Fpackage%2Flttng-babeltrace%2F0001-no-posix-fallocate-in-uclibc.patch;h=d77825fab65408ffa805a13c3eba670b0f102040;hb=b0a0f15dfaa205161a7fcb20cf1b8cd4948c2ef3;hp=0000000000000000000000000000000000000000;hpb=c6ac3cd55ee2da956195eee393b0882105dfad4e;p=packages%2Ftrusty%2Fcirros-testvm.git diff --git a/cirros-testvm/src-cirros/buildroot-2015.05/package/lttng-babeltrace/0001-no-posix-fallocate-in-uclibc.patch b/cirros-testvm/src-cirros/buildroot-2015.05/package/lttng-babeltrace/0001-no-posix-fallocate-in-uclibc.patch new file mode 100644 index 0000000..d77825f --- /dev/null +++ b/cirros-testvm/src-cirros/buildroot-2015.05/package/lttng-babeltrace/0001-no-posix-fallocate-in-uclibc.patch @@ -0,0 +1,37 @@ +Do not call posix_fallocate() on uClibc + +uClibc does not implement posix_fallocate(), and posix_fallocate() is +mostly only an hint to the kernel that we will need such or such +amount of space inside a file. So we just don't call posix_fallocate() +when building against uClibc. + +Signed-off-by: Thomas Petazzoni +[Peter: add #include +--- + formats/ctf/ctf.c | 3 +++ + 1 file changed, 3 insertions(+) + +Index: lttng-babeltrace-0.8/formats/ctf/ctf.c +=================================================================== +--- lttng-babeltrace-0.8.orig/formats/ctf/ctf.c ++++ lttng-babeltrace-0.8/formats/ctf/ctf.c +@@ -32,6 +32,7 @@ + #include + #include + #include ++#include + #include + #include + #include +@@ -384,9 +385,11 @@ + } + pos->content_size = -1U; /* Unknown at this point */ + pos->packet_size = WRITE_PACKET_LEN; ++#ifndef __UCLIBC__ + off = posix_fallocate(pos->fd, pos->mmap_offset, + pos->packet_size / CHAR_BIT); + assert(off >= 0); ++#endif + pos->offset = 0; + } else { + read_next_packet: