Re: [OMPI users] where is mpif.h ?
On Sep 24, 2008, at 10:47 AM, Shafagh Jafer wrote: Yes, I am using the wrapper compilers. But in my simulator Makefile.common I am including the files from gcc and g++. Please see my attached makefile. I am also attaching my previouse Makefile.common which I was MPICH instead of openmpi. Please see both of them and see the defferences, you will see that in the new makefile, I am only commenting the MPICH related stuff and replacing gcc and g++ with mpicc and mpic++. Is there anything else I am doing wrong or I am not supposed not have in my new Make file?? You did a few other things, too. ;-) (do a diff -u between the two files and you'll see the differences) The OMPI Makefile.common looks ok (you don't need the -L for OMPI's libs, but it's not harmful). I don't know exactly how it's used, but from the context in that file, I guess it's ok. FWIW, I'd guess that you should be able to use MPICH's wrapper compilers in the same way that you use OMPI's wrapper compilers. I don't know this for sure, but I do know that MPICH has wrapper compilers and I was under the impression that they worked pretty much like ours. As for why you're getting those STL errors, are you able to compile any C++ STL codes on your machine at all? I.e., do you know that the C ++ compiler and STL are installed and functioning properly? The OMPI v1.2 C++ bindings use the STL in a few places; it looks like that is failing to compile with some nebulous errors on your machine. (FWIW, in the upcoming Open MPI v1.3, we have removed all uses of the STL from our C++ bindings, at least partly due to the fact that we have seen multiple users that have functional C++ compilers but broken have STL installations) -- Jeff Squyres Cisco Systems
Re: [OMPI users] where is mpif.h ?
Yes, I am using the wrapper compilers. But in my simulator Makefile.common I am including the files from gcc and g++. Please see my attached makefile. I am also attaching my previouse Makefile.common which I was MPICH instead of openmpi. Please see both of them and see the defferences, you will see that in the new makefile, I am only commenting the MPICH related stuff and replacing gcc and g++ with mpicc and mpic++. Is there anything else I am doing wrong or I am not supposed not have in my new Make file?? --- On Wed, 9/24/08, Jeff Squyres <jsquy...@cisco.com> wrote: From: Jeff Squyres <jsquy...@cisco.com> Subject: Re: [OMPI users] where is mpif.h ? To: "Open MPI Users" <us...@open-mpi.org> List-Post: users@lists.open-mpi.org Date: Wednesday, September 24, 2008, 5:14 AM On Sep 24, 2008, at 12:15 AM, Shafagh Jafer wrote: > Ok now after i have made sure that my code acutally goes and > includes the mpi.h from openmpi and not mpich, now I get really > wierd errors. Below I will paste my mpic++ configurations from -- > showme and the errors i gert from running my code. > > [sjafer@DeepThought latest_cd++_timewarp]$ /opt/openmpi/1.2.7/bin/ > mpic++ --showme:compile > -I/opt/openmpi/1.2.7/include -pthread > > [sjafer@DeepThought latest_cd++_timewarp]$ /opt/openmpi/1.2.7/bin/ > mpic++ --showme:link > -pthread -L/opt/openmpi/1.2.7/lib -lmpi_cxx -lmpi -lopen-rte -lopen- > pal -ldl -Wl,--export-dynamic -lnsl -lutil -lm -ldl > The above looks about right. > =ERRORS=== > In file included from /usr/local/include/g++-3/stl_tree.h:57, > from /usr/local/include/g++-3/map:31, > from /opt/openmpi/1.2.7/include/openmpi/ompi/mpi/ > cxx/mpicxx.h:35, > from /opt/openmpi/1.2.7/include/mpi.h:1795, > from CommPhyMPI.cc:36: > /usr/local/include/g++-3/stl_alloc.h: At top level: > /usr/local/include/g++-3/stl_alloc.h:142: template with C linkage Are you compiling your application with the same C++ compiler that you compiled Open MPI with? If you use the --showme:compile|link flags to put OMPI's required flags into a building process (i.e., if you're not using OMPI's wrapper compilers), it is still strongly recommended that you use the same compilers that you used to compile and build Open MPI. Is there a reason you stopped using the wrapper compilers? Although some users have reported successes with mixing-n-matching compilers, it is untested by the Open MPI team and unsupported. -- Jeff Squyres Cisco Systems ___ users mailing list us...@open-mpi.org http://www.open-mpi.org/mailman/listinfo.cgi/users OMPIMakefile.common Description: Binary data MPICHMakefile.common Description: Binary data
Re: [OMPI users] where is mpif.h ?
On Sep 24, 2008, at 12:15 AM, Shafagh Jafer wrote: Ok now after i have made sure that my code acutally goes and includes the mpi.h from openmpi and not mpich, now I get really wierd errors. Below I will paste my mpic++ configurations from -- showme and the errors i gert from running my code. [sjafer@DeepThought latest_cd++_timewarp]$ /opt/openmpi/1.2.7/bin/ mpic++ --showme:compile -I/opt/openmpi/1.2.7/include -pthread [sjafer@DeepThought latest_cd++_timewarp]$ /opt/openmpi/1.2.7/bin/ mpic++ --showme:link -pthread -L/opt/openmpi/1.2.7/lib -lmpi_cxx -lmpi -lopen-rte -lopen- pal -ldl -Wl,--export-dynamic -lnsl -lutil -lm -ldl The above looks about right. =ERRORS=== In file included from /usr/local/include/g++-3/stl_tree.h:57, from /usr/local/include/g++-3/map:31, from /opt/openmpi/1.2.7/include/openmpi/ompi/mpi/ cxx/mpicxx.h:35, from /opt/openmpi/1.2.7/include/mpi.h:1795, from CommPhyMPI.cc:36: /usr/local/include/g++-3/stl_alloc.h: At top level: /usr/local/include/g++-3/stl_alloc.h:142: template with C linkage Are you compiling your application with the same C++ compiler that you compiled Open MPI with? If you use the --showme:compile|link flags to put OMPI's required flags into a building process (i.e., if you're not using OMPI's wrapper compilers), it is still strongly recommended that you use the same compilers that you used to compile and build Open MPI. Is there a reason you stopped using the wrapper compilers? Although some users have reported successes with mixing-n-matching compilers, it is untested by the Open MPI team and unsupported. -- Jeff Squyres Cisco Systems
Re: [OMPI users] where is mpif.h ?
Ok now after i have made sure that my code acutally goes and includes the mpi.h from openmpi and not mpich, now I get really wierd errors. Below I will paste my mpic++ configurations from --showme and the errors i gert from running my code. [sjafer@DeepThought latest_cd++_timewarp]$ /opt/openmpi/1.2.7/bin/mpic++ --showme:compile -I/opt/openmpi/1.2.7/include -pthread [sjafer@DeepThought latest_cd++_timewarp]$ /opt/openmpi/1.2.7/bin/mpic++ --showme:link -pthread -L/opt/openmpi/1.2.7/lib -lmpi_cxx -lmpi -lopen-rte -lopen-pal -ldl -Wl,--export-dynamic -lnsl -lutil -lm -ldl =ERRORS=== In file included from /usr/local/include/g++-3/stl_tree.h:57, from /usr/local/include/g++-3/map:31, from /opt/openmpi/1.2.7/include/openmpi/ompi/mpi/cxx/mpicxx.h:35, from /opt/openmpi/1.2.7/include/mpi.h:1795, from CommPhyMPI.cc:36: /usr/local/include/g++-3/stl_alloc.h: At top level: /usr/local/include/g++-3/stl_alloc.h:142: template with C linkage /usr/local/include/g++-3/stl_alloc.h:224: template with C linkage /usr/local/include/g++-3/stl_alloc.h:243: template with C linkage /usr/local/include/g++-3/stl_alloc.h:320: template with C linkage /usr/local/include/g++-3/stl_alloc.h:729: template with C linkage /usr/local/include/g++-3/stl_alloc.h:740: template with C linkage /usr/local/include/g++-3/stl_alloc.h:746: template with C linkage /usr/local/include/g++-3/stl_alloc.h: In method `allocator<_Tp>::allocator(const allocator<_Tp1> &)': /usr/local/include/g++-3/stl_alloc.h:746: template with C linkage /usr/local/include/g++-3/stl_alloc.h: At top level: /usr/local/include/g++-3/stl_alloc.h:778: template with C linkage /usr/local/include/g++-3/stl_alloc.h: In function `bool operator ==(const allocator<_Tp1> &, const allocator<_T2> &)': /usr/local/include/g++-3/stl_alloc.h:786: template with C linkage /usr/local/include/g++-3/stl_alloc.h: In function `bool operator !=(const allocator<_Tp1> &, const allocator<_T2> &)': /usr/local/include/g++-3/stl_alloc.h:792: template with C linkage /usr/local/include/g++-3/stl_alloc.h: At top level: /usr/local/include/g++-3/stl_alloc.h:804: template with C linkage /usr/local/include/g++-3/stl_alloc.h:815: template with C linkage /usr/local/include/g++-3/stl_alloc.h:824: template with C linkage /usr/local/include/g++-3/stl_alloc.h: In method `__allocator<_Tp,_Alloc>::__allocator(const __allocator<_Tp1,_Alloc> &)': /usr/local/include/g++-3/stl_alloc.h:824: template with C linkage /usr/local/include/g++-3/stl_alloc.h: At top level: ... === --- On Tue, 9/23/08, Jeff Squyres <jsquy...@cisco.com> wrote: From: Jeff Squyres <jsquy...@cisco.com> Subject: Re: [OMPI users] where is mpif.h ? To: "Open MPI Users" <us...@open-mpi.org> List-Post: users@lists.open-mpi.org Date: Tuesday, September 23, 2008, 2:13 PM See that FAQ entry I pointed to. ${includedir} is the default "include" directory that came in from running OMPI's configure (defaults to $prefix/include). Likewise for $ {libdir}; it's the "library" directory that came in from running OMPI's configure (defaults to $prefix/lib). On Sep 23, 2008, at 4:41 PM, Shafagh Jafer wrote: > In mpic++_wrapper-data.txt what do the following statments mean and > where do they exactly point to?? > > -- > includedir=${includedir} > libdir=${libdir} > -- > > --- On Tue, 9/23/08, Jeff Squyres <jsquy...@cisco.com> wrote: > From: Jeff Squyres <jsquy...@cisco.com> > Subject: Re: [OMPI users] where is mpif.h ? > To: "Open MPI Users" <us...@open-mpi.org> > Date: Tuesday, September 23, 2008, 5:11 AM > > It actually is expected behavior. Open MPI's wrappers do not > automatically add -I for /usr/include or -L for /usr/lib because these > directories are typically in the compiler's/linker's default search > path, and having the wrapper compilers manually add them tends to > screw up search ordering. > > You can change the default behavior of the wrapper compilers, though > -- see this FAQ entry for details: > > > http://www.open-mpi.org/faq/?category=mpi-apps#override-wrappers-after-v1.0 > > > On Sep 23, 2008, at 6:40 AM, Jed Brown wrote: > > > On Tue 2008-09-23 08:50, Simon Hammond wrote: > >> Yes, it should be there. > > > > Shouldn't the path be automatically included by the mpif77 > wrapper? I > > ran into this problem when building BLACS (my default OpenMPI 1.2.7 > > lives in /usr, MPICH2 is at /opt/mpich2). The build tries > > > > $ /usr/bin/mpif90 -c -I. -fPIC -Wno-unused-variable -g > > bi_f77_mpi_attr_get.f > > Error: Can't open included file 'mpif.h'
Re: [OMPI users] where is mpif.h ?
See that FAQ entry I pointed to. ${includedir} is the default "include" directory that came in from running OMPI's configure (defaults to $prefix/include). Likewise for $ {libdir}; it's the "library" directory that came in from running OMPI's configure (defaults to $prefix/lib). On Sep 23, 2008, at 4:41 PM, Shafagh Jafer wrote: In mpic++_wrapper-data.txt what do the following statments mean and where do they exactly point to?? -- includedir=${includedir} libdir=${libdir} -- --- On Tue, 9/23/08, Jeff Squyres <jsquy...@cisco.com> wrote: From: Jeff Squyres <jsquy...@cisco.com> Subject: Re: [OMPI users] where is mpif.h ? To: "Open MPI Users" <us...@open-mpi.org> Date: Tuesday, September 23, 2008, 5:11 AM It actually is expected behavior. Open MPI's wrappers do not automatically add -I for /usr/include or -L for /usr/lib because these directories are typically in the compiler's/linker's default search path, and having the wrapper compilers manually add them tends to screw up search ordering. You can change the default behavior of the wrapper compilers, though -- see this FAQ entry for details: http://www.open-mpi.org/faq/?category=mpi-apps#override-wrappers-after-v1.0 On Sep 23, 2008, at 6:40 AM, Jed Brown wrote: > On Tue 2008-09-23 08:50, Simon Hammond wrote: >> Yes, it should be there. > > Shouldn't the path be automatically included by the mpif77 wrapper? I > ran into this problem when building BLACS (my default OpenMPI 1.2.7 > lives in /usr, MPICH2 is at /opt/mpich2). The build tries > > $ /usr/bin/mpif90 -c -I. -fPIC -Wno-unused-variable -g > bi_f77_mpi_attr_get.f > Error: Can't open included file 'mpif.h' > > but this succeeds > > $ /usr/bin/mpif90 -c -I. -I/usr/include -fPIC -Wno-unused-variable > -g bi_f77_mpi_attr_get.f > > and this works fine as well > > $ /opt/mpich2/mpif90 -c -I. -fPIC -Wno-unused-variable -g > bi_f77_mpi_attr_get.f > > Is this the expected behavior? > > Jed > ___ > users mailing list > us...@open-mpi.org > http://www.open-mpi.org/mailman/listinfo.cgi/users -- Jeff Squyres Cisco Systems ___ users mailing list us...@open-mpi.org http://www.open-mpi.org/mailman/listinfo.cgi/users ___ users mailing list us...@open-mpi.org http://www.open-mpi.org/mailman/listinfo.cgi/users -- Jeff Squyres Cisco Systems
Re: [OMPI users] where is mpif.h ?
In mpic++_wrapper-data.txt what do the following statments mean and where do they exactly point to?? -- includedir=${includedir} libdir=${libdir} -- --- On Tue, 9/23/08, Jeff Squyres <jsquy...@cisco.com> wrote: From: Jeff Squyres <jsquy...@cisco.com> Subject: Re: [OMPI users] where is mpif.h ? To: "Open MPI Users" <us...@open-mpi.org> List-Post: users@lists.open-mpi.org Date: Tuesday, September 23, 2008, 5:11 AM It actually is expected behavior. Open MPI's wrappers do not automatically add -I for /usr/include or -L for /usr/lib because these directories are typically in the compiler's/linker's default search path, and having the wrapper compilers manually add them tends to screw up search ordering. You can change the default behavior of the wrapper compilers, though -- see this FAQ entry for details: http://www.open-mpi.org/faq/?category=mpi-apps#override-wrappers-after-v1.0 On Sep 23, 2008, at 6:40 AM, Jed Brown wrote: > On Tue 2008-09-23 08:50, Simon Hammond wrote: >> Yes, it should be there. > > Shouldn't the path be automatically included by the mpif77 wrapper? I > ran into this problem when building BLACS (my default OpenMPI 1.2.7 > lives in /usr, MPICH2 is at /opt/mpich2). The build tries > > $ /usr/bin/mpif90 -c -I. -fPIC -Wno-unused-variable -g > bi_f77_mpi_attr_get.f > Error: Can't open included file 'mpif.h' > > but this succeeds > > $ /usr/bin/mpif90 -c -I. -I/usr/include -fPIC -Wno-unused-variable > -g bi_f77_mpi_attr_get.f > > and this works fine as well > > $ /opt/mpich2/mpif90 -c -I. -fPIC -Wno-unused-variable -g > bi_f77_mpi_attr_get.f > > Is this the expected behavior? > > Jed > ___ > users mailing list > us...@open-mpi.org > http://www.open-mpi.org/mailman/listinfo.cgi/users -- Jeff Squyres Cisco Systems ___ users mailing list us...@open-mpi.org http://www.open-mpi.org/mailman/listinfo.cgi/users
Re: [OMPI users] where is mpif.h ?
On Tue 2008-09-23 08:50, Simon Hammond wrote: > Yes, it should be there. Shouldn't the path be automatically included by the mpif77 wrapper? I ran into this problem when building BLACS (my default OpenMPI 1.2.7 lives in /usr, MPICH2 is at /opt/mpich2). The build tries $ /usr/bin/mpif90 -c -I. -fPIC -Wno-unused-variable -g bi_f77_mpi_attr_get.f Error: Can't open included file 'mpif.h' but this succeeds $ /usr/bin/mpif90 -c -I. -I/usr/include -fPIC -Wno-unused-variable -g bi_f77_mpi_attr_get.f and this works fine as well $ /opt/mpich2/mpif90 -c -I. -fPIC -Wno-unused-variable -g bi_f77_mpi_attr_get.f Is this the expected behavior? Jed pgp66MlGd2epW.pgp Description: PGP signature
Re: [OMPI users] where is mpif.h ?
Yes, it should be there. Have you configured OpenMPI with Fortran during the build? Si Hammond High Performance Systems Group University of Warwick Coventry, UK 2008/9/23 Shafagh Jafer: > Does openmpi have any "mpif.h" ?? if yes, where? in openmpi_dir/include ??!! > > ___ > users mailing list > us...@open-mpi.org > http://www.open-mpi.org/mailman/listinfo.cgi/users >
[OMPI users] where is mpif.h ?
Does openmpi have any "mpif.h" ?? if yes, where? in openmpi_dir/include ??!!