Bug 63360

Summary: wayland: fail to build on centos 5.5 without signalfd support
Product: Wayland Reporter: chnarius <chnarius>
Component: waylandAssignee: Wayland bug list <wayland-bugs>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: medium CC: pochu27
Version: 1.0.x   
Hardware: x86 (IA32)   
OS: Linux (All)   
Whiteboard:
i915 platform: i915 features:

Description chnarius 2013-04-10 07:38:27 UTC
-bash-3.2$ lsb_release -ri
Distributor ID:	CentOS
Release:	5.5
-bash-3.2$ uname -r
2.6.18-194.el5PAE
-bash-3.2$ /lib/libc.so.6 
GNU C Library stable release version 2.5, by Roland McGrath et al.

Log:
| wayland-1.0.6/src/wayland-shm.c: In function 'shm_pool_create_buffer':
| wayland-1.0.6/src/wayland-shm.c:134: warning: dereferencing type-punned pointer will break strict-aliasing rules
| wayland-1.0.6/src/wayland-server.c: In function 'get_socket_lock':
| wayland-1.0.6/src/wayland-server.c:1245: error: 'O_CLOEXEC' undeclared (first use in this function)
| wayland-1.0.6/src/wayland-server.c:1245: error: (Each undeclared identifier is reported only oncewayland-1.0.6/src/event-loop.c:33:26: error: sys/signalfd.h: No such file or directory
| wayland-1.0.6/src/event-loop.c:34:25: error: sys/timerfd.h: No such file or directory
| wayland-1.0.6/src/wayland-shm.c: In function 'shm_create_pool':
| wayland-1.0.6/src/wayland-shm.c:217: warning: dereferencing type-punned pointer will break strict-aliasing rules
| 
| wayland-1.0.6/src/wayland-server.c:1245: error: for each function it appears in.)
| wayland-1.0.6/src/wayland-shm.c: In function 'wl_shm_buffer_create':
| wayland-1.0.6/src/wayland-shm.c:289: warning: dereferencing type-punned pointer will break strict-aliasing rules
| wayland-1.0.6/src/wayland-shm.c: In function 'wl_buffer_is_shm':
| wayland-1.0.6/src/wayland-shm.c:304: warning: dereferencing type-punned pointer will break strict-aliasing rules
| wayland-1.0.6/src/data-device.c: In function 'wl_data_source_send_offer':
| wayland-1.0.6/src/data-device.c:105: warning: dereferencing type-punned pointer will break strict-aliasing rules
| wayland-1.0.6/src/data-device.c: In function 'create_data_source':
| wayland-1.0.6/src/data-device.c:466: warning: dereferencing type-punned pointer will break strict-aliasing rules
| make[3]: *** [wayland-server.lo] Error 1
| make[3]: *** Waiting for unfinished jobs....
| wayland-1.0.6/src/wayland-client.c: In function 'wl_display_connect_to_fd':
| wayland-1.0.6/src/wayland-client.c:529: warning: dereferencing type-punned pointer will break strict-aliasing rules
| wayland-1.0.6/src/event-loop.c: In function 'wl_event_loop_add_timer':
| wayland-1.0.6/src/event-loop.c:199: warning: implicit declaration of function 'timerfd_create'
| wayland-1.0.6/src/event-loop.c:199: error: 'CLOCK_MONOTONIC' undeclared (first use in this function)
| wayland-1.0.6/src/event-loop.c:199: error: (Each undeclared identifier is reported only once
| wayland-1.0.6/src/event-loop.c:199: error: for each function it appears in.)
| wayland-1.0.6/src/event-loop.c:199: error: 'TFD_CLOEXEC' undeclared (first use in this function)
| wayland-1.0.6/src/event-loop.c: In function 'wl_event_source_timer_update':
| wayland-1.0.6/src/event-loop.c:208: error: storage size of 'its' isn't known
| wayland-1.0.6/src/event-loop.c:214: warning: implicit declaration of function 'timerfd_settime'
| wayland-1.0.6/src/event-loop.c:208: warning: unused variable 'its'
| wayland-1.0.6/src/event-loop.c: In function 'wl_event_source_signal_dispatch':
| wayland-1.0.6/src/event-loop.c:234: error: storage size of 'signal_info' isn't known
| wayland-1.0.6/src/event-loop.c:234: warning: unused variable 'signal_info'
| wayland-1.0.6/src/event-loop.c: In function 'wl_event_loop_add_signal':
| wayland-1.0.6/src/event-loop.c:268: warning: implicit declaration of function 'signalfd'
| wayland-1.0.6/src/event-loop.c:268: error: 'SFD_CLOEXEC' undeclared (first use in this function)
| make[3]: *** [event-loop.lo] Error 1
Comment 1 Emilio Pozuelo Monfort 2013-04-11 15:47:08 UTC
We could add a configure check for sys/timerfd.h.
Comment 2 Rob Bradford 2013-06-12 17:19:17 UTC
A patch to make configure check and abort if the required syscall includes are not available has been pushed to master:

commit bc3e020475e0fc29f265c4f8029f03584bee086e
Author: Rob Bradford <rob@linux.intel.com>
Date:   Tue Jun 4 13:27:49 2013 +0100

    build: Add declaration checks to check for required syscall flags
    
    The required flags are relatively new and some older enterprise distributions
    do not feature them.
    
    https://bugs.freedesktop.org/show_bug.cgi?id=63360

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.