[mvapich-discuss] MVAPICH2, Lustre 2.4, and /usr/include/sys/quota.h lead to _XOPEN_SOURCE and caddr_t problem
Adam T. Moody
moody20 at llnl.gov
Tue Dec 10 15:04:44 EST 2013
Hello MVAPICH team,
I'm trying to build MVAPICH2 on one of our systems that has Lustre 2.4
installed, but I'm hitting the following error during the build:
make[3]: Entering directory
`/usr/global/tools/mpi/sideinstalls/chaos_5_x86_64_ib/mvapich2-2.0b-gnu-cuda/mvapich2-2.0b/src/mpi/romio'
CC adio/ad_lustre/ad_lustre_rwcontig.lo
In file included from /usr/include/linux/lustre_user.h:46,
from /usr/include/lustre/lustre_user.h:54,
from adio/ad_lustre/ad_lustre.h:30,
from adio/ad_lustre/ad_lustre_rwcontig.c:14:
/usr/include/sys/quota.h:221: error: expected declaration specifiers or
'...' before 'caddr_t'
From what I've read
(http://gcc.gnu.org/ml/gcc-patches/2000-09/msg00651.html), defining
_XOPEN_SOURCE hides the definition of caddr_t, which is a BSD feature.
It seems there are two spots where _XOPEN_SOURCE is defined, both in ROMIO.
>>: grep -R -n XOPEN_SOURCE src/mpi/*
src/mpi/romio/adio/ad_xfs/ad_xfs.h:11:#define _XOPEN_SOURCE 500
src/mpi/romio/adio/ad_lustre/ad_lustre_rwcontig.c:11:#define
_XOPEN_SOURCE 600
If I comment the line in ad_lustre_rwcontig.c, the build works.
Are these definitions necessary, or can they be removed?
-Adam
More information about the mvapich-discuss
mailing list