bcumming / summer-school

9 stars 9 forks source link

MPI program fails to link on my desktop #13

Open jfavre opened 9 years ago

jfavre commented 9 years ago

mpic++ _.o main.cpp -o main main.cpp: In function ‘void writebinary(std::string, data::Field&, data::SubDomain&, data::Discretization&)’: main.cpp:60:95: warning: deprecated conversion from string constant to ‘char’ [-Wwrite-strings] result = MPI_File_set_view(filehandle, disp, MPI_DOUBLE, filetype, "native", MPI_INFO_NULL); ^ data.o: In function data::SubDomain::print()': data.cpp:(.text+0x3f6): undefined reference toomp_get_wtime' data.cpp:(.text+0x409): undefined reference to omp_get_wtime' /tmp/ccjgrECG.o: In functionmain': main.cpp:(.text+0xad5): undefined reference to omp_get_wtime' main.cpp:(.text+0xd04): undefined reference toomp_get_wtime' collect2: error: ld returned 1 exit status make: *\ [main] Error 1