_Static_assert is C11. Are you using a compiler that supports C11 and are you using the correct flags to activate that support?
Jeff On Sun, Mar 1, 2020 at 1:35 PM Derrick McKee <derrick.mc...@gmail.com> wrote: > I am having a problem compiling Valgrind using OpenMPI 4.0.2. The > error is listed below. It seems it is the same bug logged in [1]. > Has there been any patch made that resolves the issue? Thanks. > > - Derrick > > [1]: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=946329 > > Error > ----------------------------------------------------------------------- > mkdir -p ../.in_place; \ > for f in ; do \ > rm -f ../.in_place/$f.dSYM; \ > ln -f -s ../mpi/$f.dSYM ../.in_place; \ > done > In file included from ../../mpi/libmpiwrap.c:116: > ../../mpi/libmpiwrap.c: In function ‘showTy’: > ../../mpi/libmpiwrap.c:281:19: error: expected expression before > ‘_Static_assert’ > 281 | else if (ty == MPI_UB) fprintf(f,"UB"); > | ^~~~~~ > ../../mpi/libmpiwrap.c:282:19: error: expected expression before > ‘_Static_assert’ > 282 | else if (ty == MPI_LB) fprintf(f,"LB"); > | ^~~~~~ > ../../mpi/libmpiwrap.c: In function ‘showCombiner’: > ../../mpi/libmpiwrap.c:354:12: error: expected expression before > ‘_Static_assert’ > 354 | case MPI_COMBINER_HVECTOR_INTEGER: fprintf(f, > "HVECTOR_INTEGER"); break; > | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ > ../../mpi/libmpiwrap.c:354:12: error: expected expression before > ‘_Static_assert’ > ../../mpi/libmpiwrap.c:354:40: error: expected expression before ‘:’ token > 354 | case MPI_COMBINER_HVECTOR_INTEGER: fprintf(f, > "HVECTOR_INTEGER"); break; > | ^ > In file included from ../../mpi/libmpiwrap.c:116: > ../../mpi/libmpiwrap.c:359:12: error: expected expression before > ‘_Static_assert’ > 359 | case MPI_COMBINER_HINDEXED_INTEGER: fprintf(f, > "HINDEXED_INTEGER"); break; > | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~ > ../../mpi/libmpiwrap.c:359:12: error: expected expression before > ‘_Static_assert’ > ../../mpi/libmpiwrap.c:359:41: error: expected expression before ‘:’ token > 359 | case MPI_COMBINER_HINDEXED_INTEGER: fprintf(f, > "HINDEXED_INTEGER"); break; > | ^ > In file included from ../../mpi/libmpiwrap.c:116: > ../../mpi/libmpiwrap.c:366:12: error: expected expression before > ‘_Static_assert’ > 366 | case MPI_COMBINER_STRUCT_INTEGER: fprintf(f, > "STRUCT_INTEGER"); break; > | ^~~~~~~~~~~~~~~~~~~~~~~~~~~ > ../../mpi/libmpiwrap.c:366:12: error: expected expression before > ‘_Static_assert’ > ../../mpi/libmpiwrap.c:366:39: error: expected expression before ‘:’ token > 366 | case MPI_COMBINER_STRUCT_INTEGER: fprintf(f, > "STRUCT_INTEGER"); break; > | ^ > ../../mpi/libmpiwrap.c: In function ‘extentOfTy’: > ../../mpi/libmpiwrap.c:462:8: warning: implicit declaration of > function ‘PMPI_Type_extent’; did you mean ‘MPI_Type_extent’? > [-Wimplicit-function-declaration] > 462 | r = PMPI_Type_extent(ty, &n); > | ^~~~~~~~~~~~~~~~ > | MPI_Type_extent > In file included from ../../mpi/libmpiwrap.c:116: > ../../mpi/libmpiwrap.c: In function ‘walk_type’: > ../../mpi/libmpiwrap.c:736:17: error: expected expression before > ‘_Static_assert’ > 736 | if (ty == MPI_LB || ty == MPI_UB) > > -- > Derrick McKee > Phone: (703) 957-9362 > Email: derrick.mc...@gmail.com > > > _______________________________________________ > Valgrind-users mailing list > Valgrind-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/valgrind-users > -- Jeff Hammond jeff.scie...@gmail.com http://jeffhammond.github.io/
_______________________________________________ Valgrind-users mailing list Valgrind-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/valgrind-users