tests: Mark tests as used so they don’t get removed at link time

Without this attribute, the test macros were making Weston fail to
build with LTO enabled.

Signed-off-by: Markus Trippelsdorf <markus@trippelsdorf.de>
Signed-off-by: Emmanuel Gil Peyrot <emmanuel.peyrot@collabora.com>
Tested-by: Emmanuel Gil Peyrot <emmanuel.peyrot@collabora.com>
Reviewed-by: Daniel Stone <daniels@collabora.com>
This commit is contained in:
Emmanuel Gil Peyrot
2017-04-14 19:48:07 +01:00
committed by Daniel Stone
parent 0f4dbe72d3
commit 7092090de9
2 changed files with 3 additions and 3 deletions
+2 -2
View File
@@ -268,7 +268,7 @@ zuc_set_output_junit(bool enable);
static void zuctest_##tcase##_##test(void); \
\
const struct zuc_registration zzz_##tcase##_##test \
__attribute__ ((section ("zuc_tsect"))) = \
__attribute__ ((used, section ("zuc_tsect"))) = \
{ \
#tcase, #test, 0, \
zuctest_##tcase##_##test, \
@@ -298,7 +298,7 @@ zuc_set_output_junit(bool enable);
static void zuctest_##tcase##_##test(void *param); \
\
const struct zuc_registration zzz_##tcase##_##test \
__attribute__ ((section ("zuc_tsect"))) = \
__attribute__ ((used, section ("zuc_tsect"))) = \
{ \
#tcase, #test, &tcase, \
0, \