Opened 12 years ago

Closed 12 years ago

#35457 closed enhancement (fixed)

mpich2 variant for hdf5-18

Reported by: numaryu Owned by: eborisch (Eric A. Borisch)
Priority: Normal Milestone:
Component: ports Version: 2.1.2
Keywords: haspatch Cc: mamoll (Mark Moll)
Port: hdf5-18

Description

I'd like to add +mpich2 variant for hdf5-18.

Attachments (3)

Portfile.diff (3.9 KB) - added by numaryu 12 years ago.
Portfile (6.9 KB) - added by eborisch (Eric A. Borisch) 12 years ago.
Portfile.2.diff (8.8 KB) - added by eborisch (Eric A. Borisch) 12 years ago.
The diff for ease of discussion…

Download all attachments as: .zip

Change History (14)

Changed 12 years ago by numaryu

Attachment: Portfile.diff added

comment:1 Changed 12 years ago by ryandesign (Ryan Carsten Schmidt)

Owner: changed from macports-tickets@… to eborisch@…

comment:2 Changed 12 years ago by mamoll (Mark Moll)

Why does the patch change the compiler for the non-Fortran code?

comment:3 Changed 12 years ago by eborisch (Eric A. Borisch)

It is one of the ways to build parallel hdf5; just set the cc and cxx [fc] to the mpi compiler/wrapper scripts.

From http://www.hdfgroup.org/ftp/HDF5/current/src/unpacked/release_docs/INSTALL

A parallel version of HDF5 can be built by specifying `mpicc'
as the C compiler.  (The `--enable-parallel' flag documented
below is optional in this case.)  Using the `mpicc' compiler
will insure that the correct MPI and MPI-IO header files and
libraries are used.

      $ CC=/usr/local/mpi/bin/mpicc ./configure

I'll try to look some night this week...

comment:4 Changed 12 years ago by eborisch (Eric A. Borisch)

I'm not sure if I should be the owner here. If you (mmoll) would like me to, I can take care of it. (Like I just mentioned, will likely be some evening this week.)

comment:5 Changed 12 years ago by mamoll (Mark Moll)

Sorry, I should have been more specific. I am referring to lines like this:

configure.compiler      macports-gcc-4.5 

comment:6 Changed 12 years ago by eborisch (Eric A. Borisch)

Hrmm. I guess that's a choice. It might be worth changing the gccNN variants to build everything with the selected gccNN (cc, cxx) compilers, rather than just using it for Fortran. I know some other ports work that way...

Discussion?

comment:7 Changed 12 years ago by numaryu

I found configure.compiler sets some FLAGS nicely as well. So, I set this to avoid the -arch x86_64 flag, otherwise compilation fails.

comment:8 Changed 12 years ago by mamoll (Mark Moll)

But this means that you *HAVE* to enable a Fortran variant for the mpich2 variant to compile. This is not the right solution. Your patch also enables unsupported combinations of extensions (C++ with parallel HDF5). Have you checked if "make check" still passes?

comment:9 Changed 12 years ago by eborisch (Eric A. Borisch)

Here's a (very modified) Portfile that I worked on this weekend. It supports lots of combinations (including "unsupported" versions - which the user is warned about)

It also takes the approach that a +gccXX variant means "compile C/CXX/Fortran variants (as enabled) with gccNN package compilers." (NOT just Fortran.)

Changed 12 years ago by eborisch (Eric A. Borisch)

Attachment: Portfile added

Changed 12 years ago by eborisch (Eric A. Borisch)

Attachment: Portfile.2.diff added

The diff for ease of discussion...

comment:10 Changed 12 years ago by mamoll (Mark Moll)

This looks good except for a missing conflict between the openmpi and mpich2 variant. You can commit this, if you like.

comment:11 Changed 12 years ago by eborisch (Eric A. Borisch)

Resolution: fixed
Status: newclosed

mpich2 variant (and other changes) available in r97394.

Note: See TracTickets for help on using tickets.