GNOME Bugzilla – Bug 742980
cannot start broadway on FreeBSD
Last modified: 2015-01-18 20:25:49 UTC
Created attachment 294605 [details] [review] suppress posix_fallocate() on FreeBSD Starting broadwayd on FreeBSD 10.1 fails with the output "Abstract unix domain socket addresses not supported on this system". Broadway uses either TCP or abstract Unix domain sockets dependent upon definition the macro G_OS_UNIX. Abstract domain sockets are supported only on Linux but G_OS_UNIX is defined on a number of other platforms. The attached patch against 3.14.7 (current version in FreeBSD ports) changes G_OS_UNIX to __linux__ for cases when testing for functionality specific to linux. An alternative approach could be implemented using g_unix_socket_address_abstract_names_supported(). Additionally the posix_fallocate() check added in commit 8084e6e4 fails on FreeBSD fails with ENODEV as the passed file descriptor must be a regular file. Attached patch disables this check when the macro __FreeBSD__ is defined.
Created attachment 294606 [details] [review] use abstract sockets only on linux
I've fixed the posix_fallocate issue with a different patch, checking for ENOSPC instead.
Fixed the abstract socket issue by using g_unix_socket_address_abstract_names_supported