1.23.0 FreeBSD build fails: 1 showstopper mempcpy(), 1 sendfile() incompat.

Bartosz Gołaszewski bartekgola at gmail.com
Wed Jan 7 09:11:20 UTC 2015


2015-01-06 21:55 GMT+01:00 Matthias Andree <mandree at freebsd.org>:
> Happy new year!
>
> I just tried to upgrade the busybox-unstable port on FreeBSD to 1.23.0,
> but one issue of the two given below is a showstopper.
>
>
> The first one pertains to an incompatibility around sendfile. Easily
> sidestepped by deconfiguring it.
>
>> libbb/copyfd.c:12:27: error: sys/sendfile.h: No such file or directory
>> libbb/copyfd.c: In function 'bb_full_fd_action':
>> libbb/copyfd.c:65: warning: passing argument 3 of 'sendfile' makes integer from pointer without a cast
>> libbb/copyfd.c:65: error: too few arguments to function 'sendfile'
>
> FreeBSD's sendfile() is documented here:
> <https://www.freebsd.org/cgi/man.cgi?query=sendfile&apropos=0&sektion=2&manpath=FreeBSD+10.1-RELEASE&arch=default&format=html>
>

The problem with FreeBSD's sendfile() is that it's more limited than
the one in Linux. It requires the destination descriptor to be
associated with a socket (like in Linux before 2.6.33). It's useless
in case of bb_full_fd_action(). This is why commit 202d9a64 was
merged.

Bart


More information about the busybox mailing list