lustre/tests/statx.c does not compile is SELINUX support
is not installed.
So add some #ifdefs to fix it.
Test-Parameters: trivial
Fixes:
3f7853b31ef6 ("LU-10934 llite: integrate statx() API with Lustre")
Signed-off-by: Mr NeilBrown <neilb@suse.de>
Change-Id: Ia0f285e1bb04270aff753bea71ffbe15a911db5f
Reviewed-on: https://review.whamcloud.com/38973
Tested-by: jenkins <devops@whamcloud.com>
Reviewed-by: Yingjin Qian <qian@ddn.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-by: James Simmons <jsimmons@infradead.org>
static char const fmt_terse_fs[] = "%n %i %l %t %s %S %b %f %a %c %d\n";
static char const fmt_terse_regular[] = "%n %s %b %f %u %g %D %i %h %t %T"
" %X %Y %Z %W %o\n";
static char const fmt_terse_fs[] = "%n %i %l %t %s %S %b %f %a %c %d\n";
static char const fmt_terse_regular[] = "%n %s %b %f %u %g %D %i %h %t %T"
" %X %Y %Z %W %o\n";
static char const fmt_terse_selinux[] = "%n %s %b %f %u %g %D %i %h %t %T"
" %X %Y %Z %W %o %C\n";
static char const fmt_terse_selinux[] = "%n %s %b %f %u %g %D %i %h %t %T"
" %X %Y %Z %W %o %C\n";
static char *format;
/* Whether to follow symbolic links; True for --dereference (-L). */
static char *format;
/* Whether to follow symbolic links; True for --dereference (-L). */
strcpy(pformat + prefix_len, "s");
printf(pformat, (scontext ? scontext : "?"));
strcpy(pformat + prefix_len, "s");
printf(pformat, (scontext ? scontext : "?"));
if (scontext)
freecon(scontext);
if (scontext)
freecon(scontext);
if (is_selinux_enabled() > 0) {
temp = format;
/* TRANSLATORS: This string uses format
if (is_selinux_enabled() > 0) {
temp = format;
/* TRANSLATORS: This string uses format
"Context: %C\n");
free(temp);
}
"Context: %C\n");
free(temp);
}
temp = format;
/* TRANSLATORS: This string uses format specifiers from
* 'stat --help' without --file-system, and NOT from
temp = format;
/* TRANSLATORS: This string uses format specifiers from
* 'stat --help' without --file-system, and NOT from