Skip to content

Commit

Permalink
...
Browse files Browse the repository at this point in the history
  • Loading branch information
jbigot committed Feb 20, 2024
1 parent 983b70d commit d26738d
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions spack/5a-mpi/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,11 @@ RUN spack -e pdienv fetch \
&& spack clean -a
# install & workaround openmpi issue with mixed compilers where Fortran CHARACTER detection script requires CFLAGS=-fPIE
RUN if ( [ 'xopenmpi' = "x${MPI}" -a 'xoldest' = "x${VERSION}" ] && grep -qs clang compiler.lst ) \
; then ( spack -e pdienv install --only dependencies ${SPACK_INSTALL_ARGS} openmpi \
&& export CFLAGS=-fPIE \
&& spack -e pdienv install ${SPACK_INSTALL_ARGS} --dirty openmpi ) \
; then echo ' ==================== install openmpi dependencies ====================' \
&& spack -e pdienv install --only dependencies ${SPACK_INSTALL_ARGS} openmpi \
&& echo ' ==================== install openmpi with CFLAGS=-fPIE ====================' \
&& ( export CFLAGS=-fPIE; spack -e pdienv install ${SPACK_INSTALL_ARGS} --dirty openmpi ) \
&& echo ' ==================== installed openmpi with CFLAGS=-fPIE ====================' \
; fi \
&& spack -e pdienv install ${SPACK_INSTALL_ARGS} \
&& spack clean -a

0 comments on commit d26738d

Please sign in to comment.