weston/shared
Daniel Stone 11f91bbd36 helpers: Move static_assert definition to shared
Collect the fallback definitions of static_assert() from desktop-shell
and the test shell, and move them to helpers.h. This allows code
throughout the tree to use static_assert() for build-time assertions,
where it is supported by the compiler.

As GCC goes out of its way to only add static_assert() when C11 has been
explicitly requested - which we don't do - make sure to use the more
widely available _Static_assert() if that is provided.

This will be used in future patches to ensure two array lengths don't go
out of sync.

Signed-off-by: Daniel Stone <daniels@collabora.com>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
2018-07-09 15:39:20 +01:00
..
cairo-util.c xwm: Use Pango to draw title string if available 2017-12-05 14:09:31 +00:00
cairo-util.h xwm: Fix icon surface ownership 2018-02-09 17:01:09 +00:00
config-parser.c shared: remove weston_config_get_libexec_dir() 2018-06-20 16:01:03 +03:00
config-parser.h shared: remove weston_config_get_libexec_dir() 2018-06-20 16:01:03 +03:00
file-util.c file-util: allow specifying path separately in file_create_dated() 2018-02-09 15:16:07 +00:00
file-util.h file-util: allow specifying path separately in file_create_dated() 2018-02-09 15:16:07 +00:00
frame.c xwm: Fix icon surface ownership 2018-02-09 17:01:09 +00:00
helpers.h helpers: Move static_assert definition to shared 2018-07-09 15:39:20 +01:00
image-loader.c shared/image: Silence maybe-uninitialized warning 2016-08-15 16:31:00 +02:00
image-loader.h shared: Update boilerplate from MIT X11 license to MIT Expat license 2015-06-15 13:04:18 -07:00
matrix.c shared: Update boilerplate from MIT X11 license to MIT Expat license 2015-06-15 13:04:18 -07:00
matrix.h shared: Update boilerplate from MIT X11 license to MIT Expat license 2015-06-15 13:04:18 -07:00
option-parser.c option-parser: replace int/0/1 with bool/false/true 2017-12-04 19:37:33 +00:00
os-compatibility.c os: Check for EINTR on ftruncate() 2017-03-24 21:02:30 +01:00
os-compatibility.h log: Open log file CLOEXEC so child processes don't get the fd 2015-07-16 19:28:36 -07:00
platform.h shared/platform.h: introduce weston_platform_destroy_egl_surface() 2016-11-21 16:07:05 +00:00
string-helpers.h string-helpers.h: Fix usage on musl libc 2016-09-24 11:55:58 +02:00
timespec-util.h shared: Add timespec_eq helper function 2018-02-20 10:20:29 +02:00
weston-egl-ext.h gl-renderer: Emit GPU rendering begin and end timeline timepoints 2017-09-29 10:20:54 +03:00
xalloc.c include stdint.h for int32_t/uint32_t 2016-07-26 16:26:08 -07:00
xalloc.h include stdint.h for int32_t/uint32_t 2016-07-26 16:26:08 -07:00
zalloc.h shared: Update boilerplate from MIT X11 license to MIT Expat license 2015-06-15 13:04:18 -07:00