[LTP] [PATCH] configure.ac: Fix redefinition of mount_attr by checking sys/mount.h

Petr Vorel petr.vorel@gmail.com
Tue Sep 27 22:08:38 CEST 2022


Hi Marcos,

>
> My bad. I had this repository for some months already, I might have
> forgotten to
> run "make autotools"... it now build as expected. Thanks and sorry about
> the
> noise.
>
> No problem. But Buildroot CI reports similar problem, I wonder if I find
some time in my after work time to look into it
http://autobuild.buildroot.net/results/ef429f764d7b017b37e4a1216a2b7b325bc1ea73/build-end.log

Petr

In file included from
/home/buildroot/autobuild/instance-0/output-1/host/aarch64-buildroot-linux-gnu/sysroot/usr/include/linux/fs.h:19,
                 from ../../../../include/lapi/fs.h:10,
                 from statx09.c:24:
/home/buildroot/autobuild/instance-0/output-1/host/aarch64-buildroot-linux-gnu/sysroot/usr/include/linux/mount.h:95:6:
error: redeclaration of 'enum fsconfig_command'
   95 | enum fsconfig_command {
      |      ^~~~~~~~~~~~~~~~
In file included from statx09.c:21:
/home/buildroot/autobuild/instance-0/output-1/host/lib/gcc/aarch64-buildroot-linux-gnu/11.3.0/include-fixed/sys/mount.h:249:6:
note: originally defined here
  249 | enum fsconfig_command
      |      ^~~~~~~~~~~~~~~~
/home/buildroot/autobuild/instance-0/output-1/host/aarch64-buildroot-linux-gnu/sysroot/usr/include/linux/mount.h:96:9:
error: redeclaration of enumerator 'FSCONFIG_SET_FLAG'
   96 |         FSCONFIG_SET_FLAG       = 0,    /* Set parameter, supplying
no value */
      |         ^~~~~~~~~~~~~~~~~
/home/buildroot/autobuild/instance-0/output-1/host/lib/gcc/aarch64-buildroot-linux-gnu/11.3.0/include-fixed/sys/mount.h:251:3:
note: previous definition of 'FSCONFIG_SET_FLAG' with type 'enum
fsconfig_command'
  251 |   FSCONFIG_SET_FLAG       = 0,    /* Set parameter, supplying no
value */
      |   ^~~~~~~~~~~~~~~~~
/home/buildroot/autobuild/instance-0/output-1/host/aarch64-buildroot-linux-gnu/sysroot/usr/include/linux/mount.h:97:9:
error: redeclaration of enumerator 'FSCONFIG_SET_STRING'
   97 |         FSCONFIG_SET_STRING     = 1,    /* Set parameter, supplying
a string value */
      |         ^~~~~~~~~~~~~~~~~~~
/home/buildroot/autobuild/instance-0/output-1/host/lib/gcc/aarch64-buildroot-linux-gnu/11.3.0/include-fixed/sys/mount.h:253:3:
note: previous definition of 'FSCONFIG_SET_STRING' with type 'enum
fsconfig_command'
  253 |   FSCONFIG_SET_STRING     = 1,    /* Set parameter, supplying a
string value */
      |   ^~~~~~~~~~~~~~~~~~~
/home/buildroot/autobuild/instance-0/output-1/host/aarch64-buildroot-linux-gnu/sysroot/usr/include/linux/mount.h:98:9:
error: redeclaration of enumerator 'FSCONFIG_SET_BINARY'
   98 |         FSCONFIG_SET_BINARY     = 2,    /* Set parameter, supplying
a binary blob value */
      |         ^~~~~~~~~~~~~~~~~~~
/home/buildroot/autobuild/instance-0/output-1/host/lib/gcc/aarch64-buildroot-linux-gnu/11.3.0/include-fixed/sys/mount.h:255:3:
note: previous definition of 'FSCONFIG_SET_BINARY' with type 'enum
fsconfig_command'
  255 |   FSCONFIG_SET_BINARY     = 2,    /* Set parameter, supplying a
binary blob value */
      |   ^~~~~~~~~~~~~~~~~~~
/home/buildroot/autobuild/instance-0/output-1/host/aarch64-buildroot-linux-gnu/sysroot/usr/include/linux/mount.h:99:9:
error: redeclaration of enumerator 'FSCONFIG_SET_PATH'
   99 |         FSCONFIG_SET_PATH       = 3,    /* Set parameter, supplying
an object by path */
      |         ^~~~~~~~~~~~~~~~~
/home/buildroot/autobuild/instance-0/output-1/host/lib/gcc/aarch64-buildroot-linux-gnu/11.3.0/include-fixed/sys/mount.h:257:3:
note: previous definition of 'FSCONFIG_SET_PATH' with type 'enum
fsconfig_command'
  257 |   FSCONFIG_SET_PATH       = 3,    /* Set parameter, supplying an
object by path */
      |   ^~~~~~~~~~~~~~~~~
/home/buildroot/autobuild/instance-0/output-1/host/aarch64-buildroot-linux-gnu/sysroot/usr/include/linux/mount.h:100:9:
error: redeclaration of enumerator 'FSCONFIG_SET_PATH_EMPTY'
  100 |         FSCONFIG_SET_PATH_EMPTY = 4,    /* Set parameter, supplying
an object by (empty) path */
      |         ^~~~~~~~~~~~~~~~~~~~~~~
/home/buildroot/autobuild/instance-0/output-1/host/lib/gcc/aarch64-buildroot-linux-gnu/11.3.0/include-fixed/sys/mount.h:259:3:
note: previous definition of 'FSCONFIG_SET_PATH_EMPTY' with type 'enum
fsconfig_command'
  259 |   FSCONFIG_SET_PATH_EMPTY = 4,    /* Set parameter, supplying an
object by (empty) path */
      |   ^~~~~~~~~~~~~~~~~~~~~~~
/home/buildroot/autobuild/instance-0/output-1/host/aarch64-buildroot-linux-gnu/sysroot/usr/include/linux/mount.h:101:9:
error: redeclaration of enumerator 'FSCONFIG_SET_FD'
  101 |         FSCONFIG_SET_FD         = 5,    /* Set parameter, supplying
an object by fd */
      |         ^~~~~~~~~~~~~~~
/home/buildroot/autobuild/instance-0/output-1/host/lib/gcc/aarch64-buildroot-linux-gnu/11.3.0/include-fixed/sys/mount.h:261:3:
note: previous definition of 'FSCONFIG_SET_FD' with type 'enum
fsconfig_command'
  261 |   FSCONFIG_SET_FD         = 5,    /* Set parameter, supplying an
object by fd */
      |   ^~~~~~~~~~~~~~~
/home/buildroot/autobuild/instance-0/output-1/host/aarch64-buildroot-linux-gnu/sysroot/usr/include/linux/mount.h:102:9:
error: redeclaration of enumerator 'FSCONFIG_CMD_CREATE'
  102 |         FSCONFIG_CMD_CREATE     = 6,    /* Invoke superblock
creation */
      |         ^~~~~~~~~~~~~~~~~~~
/home/buildroot/autobuild/instance-0/output-1/host/lib/gcc/aarch64-buildroot-linux-gnu/11.3.0/include-fixed/sys/mount.h:263:3:
note: previous definition of 'FSCONFIG_CMD_CREATE' with type 'enum
fsconfig_command'
  263 |   FSCONFIG_CMD_CREATE     = 6,    /* Invoke superblock creation */
      |   ^~~~~~~~~~~~~~~~~~~
/home/buildroot/autobuild/instance-0/output-1/host/aarch64-buildroot-linux-gnu/sysroot/usr/include/linux/mount.h:103:9:
error: redeclaration of enumerator 'FSCONFIG_CMD_RECONFIGURE'
  103 |         FSCONFIG_CMD_RECONFIGURE = 7,   /* Invoke superblock
reconfiguration */
      |         ^~~~~~~~~~~~~~~~~~~~~~~~
/home/buildroot/autobuild/instance-0/output-1/host/lib/gcc/aarch64-buildroot-linux-gnu/11.3.0/include-fixed/sys/mount.h:265:3:
note: previous definition of 'FSCONFIG_CMD_RECONFIGURE' with type 'enum
fsconfig_command'
  265 |   FSCONFIG_CMD_RECONFIGURE = 7,   /* Invoke superblock
reconfiguration */
      |   ^~~~~~~~~~~~~~~~~~~~~~~~
In file included from
/home/buildroot/autobuild/instance-0/output-1/host/aarch64-buildroot-linux-gnu/sysroot/usr/include/linux/fs.h:19,
                 from ../../../../include/lapi/fs.h:10,
                 from statx09.c:24:
/home/buildroot/autobuild/instance-0/output-1/host/aarch64-buildroot-linux-gnu/sysroot/usr/include/linux/mount.h:129:8:
error: redefinition of 'struct mount_attr'
  129 | struct mount_attr {
      |        ^~~~~~~~~~
In file included from statx09.c:21:
/home/buildroot/autobuild/instance-0/output-1/host/lib/gcc/aarch64-buildroot-linux-gnu/11.3.0/include-fixed/sys/mount.h:219:8:
note: originally defined here
  219 | struct mount_attr
      |        ^~~~~~~~~~
../../../../include/mk/rules.mk:45: recipe for target 'statx09' failed
make[5]: *** [statx09] Error 1
../../../include/mk/generic_trunk_target.inc:108: recipe for target 'all'
failed
make[4]: *** [all] Error 2
../../include/mk/generic_trunk_target.inc:108: recipe for target 'all'
failed
make[3]: *** [all] Error 2
../include/mk/generic_trunk_target.inc:108: recipe for target 'all' failed
make[2]: *** [all] Error 2
make[2]: Leaving directory
'/home/buildroot/autobuild/instance-0/output-1/build/ltp-testsuite-20220527/testcases'
Makefile:106: recipe for target 'testcases-all' failed
make[1]: *** [testcases-all] Error 2
make[1]: Leaving directory
'/home/buildroot/autobuild/instance-0/output-1/build/ltp-testsuite-20220527'
package/pkg-generic.mk:290: recipe for target
'/home/buildroot/autobuild/instance-0/output-1/build/ltp-testsuite-20220527/.stamp_built'
failed
make: ***
[/home/buildroot/autobuild/instance-0/output-1/build/ltp-testsuite-20220527/.stamp_built]
Error 2
make: Leaving directory '/home/buildroot/autobuild/instance-0/buildroot'
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.linux.it/pipermail/ltp/attachments/20220927/78b50050/attachment.htm>


More information about the ltp mailing list