Created attachment 573366 [details] build.log 'MAKEOPTS=-j1 emerge -v1 valgrind' fails with: ... make[2]: Entering directory '/var/tmp/portage/dev-util/valgrind-3.15.0/work/valgrind-3.15.0/mpi' /usr/bin/mpicc -I../include -g -O -fno-omit-frame-pointer -Wall -fpic -m64 -Wno-deprecated-declarations -march=broadwell -O2 -pipe -c -o libmpiwrap_amd64_linux_so-libmpiwrap.o `test -f 'libmpiwrap.c' || echo './'`libmpiwrap.c In file included from /usr/include/mpi.h:10, from libmpiwrap.c:116: libmpiwrap.c: In function ‘showTy’: libmpiwrap.c:281:19: error: expected expression before ‘_Static_assert’ else if (ty == MPI_UB) fprintf(f,"UB"); ^~~~~~ libmpiwrap.c:282:19: error: expected expression before ‘_Static_assert’ else if (ty == MPI_LB) fprintf(f,"LB"); ^~~~~~ libmpiwrap.c: In function ‘extentOfTy’: libmpiwrap.c:462:8: warning: implicit declaration of function ‘PMPI_Type_extent’; did you mean ‘MPI_Type_extent’? [-Wimplicit-function-declaration] r = PMPI_Type_extent(ty, &n); ^~~~~~~~~~~~~~~~ MPI_Type_extent In file included from /usr/include/mpi.h:10, from libmpiwrap.c:116: libmpiwrap.c: In function ‘walk_type’: libmpiwrap.c:736:17: error: expected expression before ‘_Static_assert’ if (ty == MPI_LB || ty == MPI_UB) ^~~~~~ make[2]: *** [Makefile:657: libmpiwrap_amd64_linux_so-libmpiwrap.o] Error 1 root@lynx:/root(39)# emerge -pqv '=dev-util/valgrind-3.15.0::gentoo' [ebuild U ] dev-util/valgrind-3.15.0 [3.14.0] USE="mpi"
Created attachment 573368 [details] emerge --info '=dev-util/valgrind-3.15.0::gentoo'
'USE=-mpi emerge -v1 valgrind' works.
root@lynx:/root(41)# qlist -Iv mpi ... dev-perl/XML-Compile-WSDL11-3.60.0 dev-python/mpi4py-3.0.0 sci-libs/mpir-3.0.0 sys-cluster/openmpi-4.0.1 sys-libs/compiler-rt-8.0.0 sys-libs/compiler-rt-sanitizers-8.0.0 virtual/mpi-2.0-r5
*** Bug 685064 has been marked as a duplicate of this bug. ***
It still fails.
I'm running into the same issue: ``` In file included from /usr/include/mpi.h:10, from libmpiwrap.c:116: libmpiwrap.c: In function ‘showTy’: libmpiwrap.c:281:19: error: expected expression before ‘_Static_assert’ 281 | else if (ty == MPI_UB) fprintf(f,"UB"); | ^~~~~~ libmpiwrap.c:282:19: error: expected expression before ‘_Static_assert’ 282 | else if (ty == MPI_LB) fprintf(f,"LB"); | ^~~~~~ libmpiwrap.c: In function ‘extentOfTy’: 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 /usr/include/mpi.h:10, from libmpiwrap.c:116: libmpiwrap.c: In function ‘walk_type’: libmpiwrap.c:736:17: error: expected expression before ‘_Static_assert’ 736 | if (ty == MPI_LB || ty == MPI_UB) | ^~~~~~ make[2]: *** [Makefile:657: libmpiwrap_amd64_linux_so-libmpiwrap.o] Error 1 make[2]: Leaving directory '/var/tmp/portage/dev-util/valgrind-3.15.0/work/valgrind-3.15.0/mpi' make[1]: *** [Makefile:841: all-recursive] Error 1 make[1]: Leaving directory '/var/tmp/portage/dev-util/valgrind-3.15.0/work/valgrind-3.15.0' make: *** [Makefile:710: all] Error 2 ```
sys-cluster/openmpi-4.x has to be configured with --enable-mpi1-compatibility so valgrind can keep using these deprecated facilities. However, until valgrind catches up, a USE flag for that option in OpenMPI, which is the requested by Valgrind might do the trick.
A patch is attached in upstream bug (https://bugs.kde.org/show_bug.cgi?id=401416#c3). Maybe that patch could be conditionally applied?: if has_version ">=sys-cluster/openmpi-4"; then eapply ... fi
(In reply to Arfrever Frehtes Taifersar Arahesis from comment #8) > A patch is attached in upstream bug > (https://bugs.kde.org/show_bug.cgi?id=401416#c3). > > Maybe that patch could be conditionally applied?: > > if has_version ">=sys-cluster/openmpi-4"; then > eapply ... > fi That patch works like a charm!