GROMACS 4.5.5, OpenMPI 1.6, And FFTW 3.3.2 Compilation Under Mountain Lion (OSX 10.8) With XCode (And A Little Help From Homebrew)

Minus a few glitches easily fixed with the right software, this build wasn’t bad at all (and thanks to Adam Lindsay for the title catch).

Now sitting in front of a new Core i7 MacBook Pro, one of the first compilations I wanted to have finished for new projects was GROMACS 4.5.5. As my procedure for compiling GROMACS 3.3.3 had been a highly-traveled page, I wanted to provide a brief summary of my successful 4.5.5 compilation.

A Few Piece Of Info

1. XCode

This used to be disc-download and install, now it’s available as a free download from the App Store (1.57 GB download, so plan to do something else while you wait for the download).

2. Homebrew

Having Homebrew installed in Mountain Lion made the installation of FFTW easy and OpenMPI trivial once gfortran was equally trivially installed. Therefore, to make your life easier, I can’t recommend a Homebrew installation enough. For additional install tweaks, I followed the following page: gist.github.com/1860902

Installation Procedure

1. Download gromacs 4.5.5

…and place it in your home folder (will go to Downloads most likely, drag it to your home folder for ease of building).

2. Extract into your home holder

…with a double-click, making ~/gromacs-4.5.5.

3. brew install fftw

With the install of Homebrew, you’ll simply run the following from a terminal window and produce the following output:

brew install fftw

==> Downloading http://www.fftw.org/fftw-3.3.2.tar.gz
######################################################################## 100.0%
==> ./configure --enable-single --enable-sse --enable-shared --disable-debug 
--prefix=/usr/local/Cellar/fftw/3.3.2 --enable-threads --disable-fortran
==> make install
==> make clean
==> ./configure --enable-sse2 --enable-shared --disable-debug 
--prefix=/usr/local/Cellar/fftw/3.3.2 --enable-threads --disable-fortran
==> make install
==> make clean
==> ./configure --enable-long-double --enable-shared --disable-debug 
--prefix=/usr/local/Cellar/fftw/3.3.2 --enable-threads --disable-fortran
==> make install
/usr/local/Cellar/fftw/3.3.2: 34 files, 13M, built in 2.7 minutes

4. brew install gfortran

If you don’t install gfortran FIRST and try to install OpenMPI, you’ll get the following error in Homebrew:

==> Downloading http://www.open-mpi.org/software/ompi/v1.6/downloads/openmpi-1.6.tar.bz2
######################################################################## 100.0%
Error: This formula requires a fortran compiler, but we could not find one by
looking at the FC environment variable or searching your PATH for `gfortran`.
Please take one of the following actions:

  - Decide to use the build of gfortran 4.2.x provided by Homebrew using
        `brew install gfortran`

  - Choose another Fortran compiler by setting the FC environment variable:
        export FC=/path/to/some/fortran/compiler
    Using an alternative compiler may produce more efficient code, but we will
    not be able to provide support for build errors.

So don’t. Installing gfortran will produce the following:

brew install gfortran

==> Downloading http://r.research.att.com/tools/gcc-42-5666.3-darwin11.pkg
######################################################################## 100.0%
==> Installing gfortran 4.2.4 for XCode 4.2 (build 5666) or higher
==> Caveats
Brews that require a Fortran compiler should not use:
  depends_on 'gfortran'

The preferred method of declaring Fortran support is to use:
  def install
    ...
    ENV.fortran
    ...
  end

==> Summary
/usr/local/Cellar/gfortran/4.2.4-5666.3: 86 files, 72M, built in 39 seconds

5. brew install openmpi

This is what allows you to use all cores on your machine and is not in the default XCode install.

brew install openmpi

==> Downloading http://www.open-mpi.org/software/ompi/v1.6/downloads/openmpi-1.6.tar.bz2
Already downloaded: /Library/Caches/Homebrew/open-mpi-1.6.tar.bz2
==> Using Homebrew-provided fortran compiler.
This may be changed by setting the FC environment variable.

==> ./configure --prefix=/usr/local/Cellar/open-mpi/1.6 --enable-ipv6
==> make all
==> make install
/usr/local/Cellar/open-mpi/1.6: 674 files, 21M, built in 5.9 minutes

6. cd gromacs-4.5.5

7. ./configure –enable-float –enable-mpi

You’ll produce output such as found in: 2012august29_gromacs455_configure.txt

You’ll also get two odd errors at the end of the ./configure run that do not affect the rest of the procedure:

./configure --enable-float --enable-mpi

...
./configure: line 29242: sort: No such file or directory
./configure: line 29239: sed: No such file or directory

So ignore them.

NOTE: If you’ve been going by my 3.3.3 procedure and used…

./configure --enable-mpi --enable-double

You’ll get the following error when you try to run make:

Making all in include
Making all in .
make[2]: Nothing to be done for `all-am'.
Making all in types
make[2]: Nothing to be done for `all'.

...

/bin/sh http://www.somewhereville.com/libtool --tag=CC   --mode=compile mpicc -DHAVE_CONFIG_H -I. -Ihttp://www.somewhereville.com/src -I/usr/include/libxml2 -Ihttp://www.somewhereville.com/include -DGMXLIBDIR=\"/usr/local/gromacs/share/top\"   -O3 -fomit-frame-pointer -finline-functions -Wall -Wno-unused -msse2 -funroll-all-loops -std=gnu99 -MT genborn_sse2_double.lo -MD -MP -MF .deps/genborn_sse2_double.Tpo -c -o genborn_sse2_double.lo genborn_sse2_double.c
 mpicc -DHAVE_CONFIG_H -I. -Ihttp://www.somewhereville.com/src -I/usr/include/libxml2 -Ihttp://www.somewhereville.com/include -DGMXLIBDIR=\"/usr/local/gromacs/share/top\" -O3 -fomit-frame-pointer -finline-functions -Wall -Wno-unused -msse2 -funroll-all-loops -std=gnu99 -MT genborn_sse2_double.lo -MD -MP -MF .deps/genborn_sse2_double.Tpo -c genborn_sse2_double.c  -fno-common -DPIC -o .libs/genborn_sse2_double.o
genborn_sse2_double.c:931: internal compiler error: Segmentation fault: 11
Please submit a full bug report,
with preprocessed source if appropriate.
See  for instructions.
make[3]: *** [genborn_sse2_double.lo] Error 1
make[2]: *** [all-recursive] Error 1
make[1]: *** [all] Error 2
make: *** [all-recursive] Error 1

So don’t do that, either. The proper flag is the enable-float.

8. make

This will produce the output available for download at: 2012august29_gromacs455_make.txt

9. make install

This will produce the output available for download at: 2012august29_gromacs455_make_install.txt

10. make links

This will produce the short piece of output reproduced below.

cd /usr/local/gromacs/bin && programs=`ls` && cd /usr/local/bin && \
	for i in $programs; do \
	   (test ! -f $i && ln -s /usr/local/gromacs/bin/$i . ; exit 0); \
	done

And with that, you should be able to run all programs from a terminal window.

Examining The Effects Of Vitamin B12 Conjugation On The Biological Activity Of Insulin: A Molecular Dynamic And In Vivo Oral Uptake Investigation

Published in MedChemComm (direct link: xlink.rsc.org/?doi=C2MD20040F). And Happy Belated New Year. After the methodological work that went into the Molecular Biosystems paper, this was a remarkably simple molecular dynamics study of the changes to vitamin B12 binding in transcobalamin II (TCII) with the B12 conjugated to the first amino acid side chain in the B-Chain of insulin. The structure of the B12-insulin conjugate is shown below in a molecular dynamics snapshot, which reveals that the binding of B12 to its TCII transport protein is negligibly affected.

And apparently the experiments went well, too. Cover hopefully to follow.

Susan Clardy-James, Damian G. Allis, Timothy J. Fairchild and Robert P. Doyle

Abstract: The practical use of the vitamin B12 uptake pathway to orally deliver peptides and proteins is much debated. To understand the full potential of the pathway however, a deeper understanding of the impact B12 conjugation has on peptides and proteins is needed. We previously reported an orally active B12 based insulin conjugate attached at LysB29 with hypoglycaemic properties in STZ diabetic rats. We are exploring an alternative attachment for B12 on insulin in an attempt to determine the effect B12 has on the protein biological activity. We describe herein the synthesis, characterization, and purification of a new B12-insulin conjugate, which is attached between the B12 ribose hydroxyl group and insulin PheB1. The hypoglycemic properties resulting from oral administration (gavage) of such a conjugate in STZ diabetic rats was similar to that noted in a conjugate covalently linked at insulin LysB2911, demonstrating the availability of both position on insulin for B12 attachment. A possible rationale for this result is put forward from MD simulations. We also conclude that there is a dose dependent response that can be observed for B12-insulin conjugates, with doses of conjugate greater than 10-9 M necessary to observe even low levels of glucose drop.

Vitamin B12 In Drug Delivery: Breaking Through The Barriers To A B12 Bioconjugate Pharmaceutical

In press in Expert Opinion On Drug Delivery (DOI:10.1517/17425247.2011.539200). The theory section (the only part I can properly speak to) builds on the discussion section of the full theory paper in Molecular Biosystems from earlier this year, providing an outlet for some of the more speculative design possibilities for trinary B12 bioconjugate design. Given that (1) there are mechanisms for cleavage at both of the proposed positions and (2) the molecular dynamics work indicates that, at least, TCII (transcobalamin II) can easily accommodate a bi-functionalized cobalamin, the A-B12-C design possibility is probably the most interesting long-term idea to come out of the computational side of the B12-insulin bioconjugate study (or so I argue).

Having “B12” and “cobalamin” in a blog post guarantees a bunch of useless moderation-necessary comments from vita-spam sites.

Susan M. Clardy, Damian G. Allis, Timothy J. Fairchild & Robert P. Doyle

Syracuse University, Syracuse, Department of Chemistry, NY 13244-4100, USA

Importance of the field: Vitamin B12 (B12) is a rare and vital micronutrient for which mammals have developed a complex and highly efficient dietary uptake system. This uptake pathway consists of a series of proteins and receptors, and has been utilized to deliver several bioactive and/or imaging molecules from 99mTc to insulin.

Areas covered in this review: The current field of B12-based drug delivery is reviewed, including recent highlights surrounding the very pathway itself.

What the reader will gain: Despite over 30 years of work, no B12-based drug delivery conjugate has reached the market-place, hampered by issues such as limited uptake capacity, gastrointestinal degradation of the conjugate or high background uptake by healthy tissues. Variability in dose response among individuals, especially across ageing populations and slow oral uptake (several hours), has also slowed development and interest.

Take home message: This review is intended to stress again the great potential, as yet not fully realized, for B12-based therapeutics, tumor imaging and oral drug delivery. This review discusses recent reports that demonstrate that the issues noted above can be overcome and need not be seen as negating the great potential of B12 in the drug delivery field.