The Author Online Book Forums are Moving

The Author Online Book Forums will soon redirect to Manning's liveBook and liveVideo. All book forum content will migrate to liveBook's discussion forum and all video forum content will migrate to liveVideo. Log in to liveBook or liveVideo with your Manning credentials to join the discussion!

Thank you for your engagement in the AoF over the years! We look forward to offering you a more enhanced forum experience.

sebastian_sohr (3) [Avatar] Offline


Listing A.1. Building OpenCoarrays from source.

cd OpenCoarrays
mkdir build
FC=gfortran CC=gcc cmake ..
make install

the line

cd build

seems to be missing.

By the way : It compiles only with gcc 5 .
Milan Curcic (43) [Avatar] Offline
Yes, it is, thank you! This will be fixed in the next MEAP update.
arclight (10) [Avatar] Offline
I just ran across this; easy enough to fix with:

git clone --branch 1.9.3
mkdir build
cd build
FC=gfortran CC=gcc cmake ../OpenCoarrays
make test # optional
make install

The main difference is the location of the build directory.
arclight (10) [Avatar] Offline
arclight wrote:
make install

should probably be

sudo make install
337172 (2) [Avatar] Offline
Some other of your readers may be running into a gfortran internal compiler error as follows:

[ 12%] Generating coarray_distributed_transpose

do i = 2, num_nodes; variable[i] = variable; end do

internal compiler error: in gfc_dep_resolver, at fortran/dependency.c:2258
Please submit a full bug report,
with preprocessed source if appropriate.
See <> for instructions.
Error: comand:
`/usr/bin/gfortran -I/home/cropnumeric/OpenCoarrays/build/include/OpenCoarrays-1.9.3_GNU-8.1.1 -fcoarray=lib -pthread -Wl,-rpath -Wl,/opt/lib -Wl,--enable-new-dtags -pthread -I /opt/include -I /opt/lib -DPREFIX_NAME=_gfortran_caf_ -DGCC_GE_7 -DGCC_GE_8 -DMPI_WORKING_MODULE -O2 -DNDEBUG -O2 -o /home/cropnumeric/OpenCoarrays/build/bin/OpenCoarrays-1.9.3-tests/coarray_distributed_transpose /home/cropnumeric/OpenCoarrays/src/tests/integration/dist_transpose/coarray_distributed_transpose.F90 /home/cropnumeric/OpenCoarrays/build/lib64/libcaf_mpi.a /opt/lib/ /opt/lib/ /opt/lib/ /opt/lib/`
failed to compile.
make[2]: *** [src/tests/integration/dist_transpose/CMakeFiles/build_coarray_distributed_transpose.dir/build.make:62: src/tests/integration/dist_transpose/coarray_distributed_transpose] Error 12
make[1]: *** [CMakeFiles/Makefile2:445: src/tests/integration/dist_transpose/CMakeFiles/build_coarray_distributed_transpose.dir/all] Error 2
make: *** [Makefile:141: all] Error 2

This appears to be related to recent versions of gfortran.
Milan Curcic (43) [Avatar] Offline
I can reproduce this. The issue is a compiler bug introduced going from gcc-7 to gcc-8. Full thread here:

Temporary solution is to use gcc-7, or to apply a patch to gcc-8 when building it.

gcc-8.2 should come with the patch applied.