85ec9f9
%ifnarch s390 s390x
85ec9f9
%global with_openmpi 1
85ec9f9
%else
85ec9f9
%global with_openmpi 0
85ec9f9
%endif
85ec9f9
6e06a80
Name:		gromacs
2b17eb0
Version:	4.5.4
2b17eb0
Release:	1%{?dist}
4fd2f7f
Summary:	Fast, Free and Flexible Molecular Dynamics
6e06a80
Group:		Applications/Engineering
6e06a80
License:	GPLv2+
6e06a80
URL:		http://www.gromacs.org
4fd2f7f
BuildRoot:	%{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
6e06a80
Source0:	ftp://ftp.gromacs.org/pub/gromacs/gromacs-%{version}.tar.gz
2b17eb0
# File gotten from 
2b17eb0
# http://www.gromacs.org/@api/deki/files/152/=manual-4.5.4.pdf
2b17eb0
Source1:	manual-4.5.4.pdf
6e06a80
Source2:	gromacs-template-makefile-single
6e06a80
Source3:	gromacs-template-makefile-double
6e06a80
Source4:	gromacs-template-makefile-mpi-single
6e06a80
Source5:	gromacs-template-makefile-mpi-double
6e06a80
Source6:	gromacs-README.fedora
6e06a80
6e06a80
# Add shebangs to scripts
6e06a80
Patch0:		gromacs-GMXRC.patch
2d0f49e
# Patch gmxdemo for new filenames
2d0f49e
Patch1:		gromacs-gmxdemo.patch
6e06a80
b9e9c1f
BuildRequires:	cmake
b9e9c1f
BuildRequires:	atlas-devel
6e06a80
BuildRequires:	fftw-devel
6e06a80
BuildRequires:	gsl-devel
1b055a1
BuildRequires:	libxml2-devel
6e06a80
BuildRequires:	libX11-devel
85ec9f9
# To get rid of executable stacks
85ec9f9
BuildRequires:	prelink
6e06a80
1b055a1
Requires:	gromacs-common = %{version}-%{release}
6e06a80
e1bf06f
# Libs were branched from gromacs, so there are 64-bit installs that have 32-bit packages installed
e1bf06f
Obsoletes:	gromacs < 4.5.2-1 
e1bf06f
e1bf06f
6e06a80
%description
4fd2f7f
GROMACS is a versatile and extremely well optimized package to perform
4fd2f7f
molecular dynamics computer simulations and subsequent trajectory analysis.
4fd2f7f
It is developed for biomolecules like proteins, but the extremely high
4fd2f7f
performance means it is used also in several other field like polymer chemistry
4fd2f7f
and solid state physics.
6e06a80
6e06a80
This package provides single and double precision binaries.
6e06a80
The documentation is in the package gromacs-common.
6e06a80
b9e9c1f
mdrun has been compiled with thread parallellization, so it runs in parallel
b9e9c1f
on shared memory systems. If you want to run on a cluster, you probably want
b9e9c1f
to install one of the MPI parallellized packages.
b9e9c1f
4fd2f7f
N.B. All binaries have names starting with g_, for example mdrun has been
4fd2f7f
renamed to g_mdrun.
4fd2f7f
4fd2f7f
6e06a80
%package common
6e06a80
Summary:	GROMACS shared data and documentation
6e06a80
Group:		Applications/Engineering
1b055a1
BuildArch:	noarch
1b055a1
# Due to switch to noarch package
dc6f6f6
Obsoletes:	gromacs-common < 4.0.7-1
6e06a80
6e06a80
%description common
4fd2f7f
GROMACS is a versatile and extremely well optimized package to perform
4fd2f7f
molecular dynamics computer simulations and subsequent trajectory analysis.
4fd2f7f
It is developed for biomolecules like proteins, but the extremely high
4fd2f7f
performance means it is used also in several other field like polymer chemistry
4fd2f7f
and solid state physics.
6e06a80
4fd2f7f
This package includes architecture independent data and documentation.
6e06a80
6e06a80
6e06a80
%package devel
6e06a80
Summary:	GROMACS header files and development libraries
6e06a80
Group:		Applications/Engineering
1b055a1
Requires:	gromacs = %{version}-%{release}
6e06a80
6e06a80
%description devel
4fd2f7f
GROMACS is a versatile and extremely well optimized package to perform
4fd2f7f
molecular dynamics computer simulations and subsequent trajectory analysis.
4fd2f7f
It is developed for biomolecules like proteins, but the extremely high
4fd2f7f
performance means it is used also in several other field like polymer chemistry
4fd2f7f
and solid state physics.
4fd2f7f
4fd2f7f
This package contains header files and development libraries for the GROMACS
4fd2f7f
molecular dynamics software. You need it if you want to write your own analysis
4fd2f7f
programs.
4fd2f7f
4fd2f7f
dc6f6f6
%package libs
dc6f6f6
Summary:	GROMACS shared libraries
dc6f6f6
Group:		System Environment/Libraries
dc6f6f6
dc6f6f6
%description libs
dc6f6f6
GROMACS is a versatile and extremely well optimized package to perform
dc6f6f6
molecular dynamics computer simulations and subsequent trajectory analysis.
dc6f6f6
It is developed for biomolecules like proteins, but the extremely high
dc6f6f6
performance means it is used also in several other field like polymer chemistry
dc6f6f6
and solid state physics.
dc6f6f6
dc6f6f6
This package contains libraries needed for operation of GROMACS.
dc6f6f6
dc6f6f6
85ec9f9
%if %{with_openmpi}
1b055a1
%package openmpi
1b055a1
Summary:	GROMACS Open MPI binaries and libraries
4fd2f7f
Group:		Applications/Engineering
1b055a1
Obsoletes:	gromacs-mpi < %{version}-%{release}
4fd2f7f
Requires:	gromacs-common = %{version}-%{release}
1b055a1
BuildRequires:	openmpi-devel
a90b748
Requires:	openmpi
fae6a03
# Libs were branched from gromacs, so there are 64-bit installs that have 32-bit packages installed
fae6a03
Obsoletes:	gromacs-openmpi < 4.5.3-2
6e06a80
1b055a1
%description openmpi
4fd2f7f
GROMACS is a versatile and extremely well optimized package to perform
4fd2f7f
molecular dynamics computer simulations and subsequent trajectory analysis.
4fd2f7f
It is developed for biomolecules like proteins, but the extremely high
4fd2f7f
performance means it is used also in several other field like polymer chemistry
4fd2f7f
and solid state physics.
6e06a80
b9e9c1f
mdrun has been compiled with thread parallellization (for running on
b9e9c1f
a single node) and with Open MPI (for running on multiple nodes).
b9e9c1f
This package single and double precision binaries and libraries.
6e06a80
6e06a80
dc6f6f6
%package openmpi-libs
dc6f6f6
Summary:	GROMACS Open MPI shared libraries
dc6f6f6
Group:		System Environment/Libraries
dc6f6f6
Obsoletes:	gromacs-mpi-libs < %{version}-%{release}
dc6f6f6
Requires:	openmpi
dc6f6f6
dc6f6f6
%description openmpi-libs
dc6f6f6
GROMACS is a versatile and extremely well optimized package to perform
dc6f6f6
molecular dynamics computer simulations and subsequent trajectory analysis.
dc6f6f6
It is developed for biomolecules like proteins, but the extremely high
dc6f6f6
performance means it is used also in several other field like polymer chemistry
dc6f6f6
and solid state physics.
dc6f6f6
dc6f6f6
This package contains libraries needed for operation of GROMACS Open MPI.
dc6f6f6
dc6f6f6
1b055a1
%package openmpi-devel
1b055a1
Summary:	GROMACS Open MPI development libraries
4fd2f7f
Group:		Applications/Engineering
1b055a1
Obsoletes:	gromacs-mpi-devel < %{version}-%{release}
1b055a1
Requires:	gromacs-devel = %{version}-%{release}
031fcad
Requires:	gromacs-openmpi = %{version}-%{release}
1b055a1
Requires:	openmpi-devel
4fd2f7f
6e06a80
1b055a1
%description openmpi-devel
4fd2f7f
GROMACS is a versatile and extremely well optimized package to perform
4fd2f7f
molecular dynamics computer simulations and subsequent trajectory analysis.
4fd2f7f
It is developed for biomolecules like proteins, but the extremely high
4fd2f7f
performance means it is used also in several other field like polymer chemistry
4fd2f7f
and solid state physics.
4fd2f7f
1b055a1
This package contains development libraries for GROMACS Open MPI.
b9e9c1f
You may need it if you want to write your own analysis programs.
85ec9f9
%endif
4fd2f7f
4fd2f7f
e3131b9
%package mpich2
e3131b9
Summary:	GROMACS MPICH2 binaries and libraries
e3131b9
Group:		Applications/Engineering
e3131b9
Requires:	gromacs-common = %{version}-%{release}
e3131b9
Requires:	mpich2
fae6a03
# Libs were branched from gromacs, so there are 64-bit installs that have 32-bit packages installed
fae6a03
Obsoletes:	gromacs-mpich2 < 4.5.3-2
e3131b9
e3131b9
%description mpich2
e3131b9
GROMACS is a versatile and extremely well optimized package to perform
e3131b9
molecular dynamics computer simulations and subsequent trajectory analysis.
e3131b9
It is developed for biomolecules like proteins, but the extremely high
e3131b9
performance means it is used also in several other field like polymer chemistry
e3131b9
and solid state physics.
e3131b9
b9e9c1f
mdrun has been compiled with thread parallellization (for running on
b9e9c1f
a single node) and with MPICH2 (for running on multiple nodes).
b9e9c1f
This package single and double precision binaries and libraries.
e3131b9
dc6f6f6
%package mpich2-libs
dc6f6f6
Summary:	GROMACS MPICH2 shared libraries
dc6f6f6
Group:		System Environment/Libraries
dc6f6f6
Requires:	mpich2
dc6f6f6
dc6f6f6
%description mpich2-libs
dc6f6f6
GROMACS is a versatile and extremely well optimized package to perform
dc6f6f6
molecular dynamics computer simulations and subsequent trajectory analysis.
dc6f6f6
It is developed for biomolecules like proteins, but the extremely high
dc6f6f6
performance means it is used also in several other field like polymer chemistry
dc6f6f6
and solid state physics.
dc6f6f6
dc6f6f6
This package contains libraries needed for operation of GROMACS MPICH2.
dc6f6f6
dc6f6f6
e3131b9
%package mpich2-devel
e3131b9
Summary:	GROMACS MPICH2 development libraries
e3131b9
Group:		Applications/Engineering
e3131b9
Requires:	gromacs-devel = %{version}-%{release}
031fcad
Requires:	gromacs-mpich2 = %{version}-%{release}
e3131b9
BuildRequires:	mpich2-devel
e3131b9
Requires:	mpich2-devel
e3131b9
e3131b9
%description mpich2-devel
e3131b9
GROMACS is a versatile and extremely well optimized package to perform
e3131b9
molecular dynamics computer simulations and subsequent trajectory analysis.
e3131b9
It is developed for biomolecules like proteins, but the extremely high
e3131b9
performance means it is used also in several other field like polymer chemistry
e3131b9
and solid state physics.
e3131b9
e3131b9
This package contains development libraries for GROMACS MPICH2.
b9e9c1f
You may need it if you want to write your own analysis programs.
4fd2f7f
6e06a80
6e06a80
6e06a80
%package bash
6e06a80
Summary:	GROMACS bash completion
6e06a80
Group:		Applications/Engineering
6e06a80
Requires:	bash-completion
1b055a1
BuildArch:	noarch
1b055a1
# Due to switch to noarch package
dc6f6f6
Obsoletes:	gromacs-bash < 4.0.7-1 
1b055a1
6e06a80
6e06a80
%description bash
4fd2f7f
GROMACS is a versatile and extremely well optimized package to perform
4fd2f7f
molecular dynamics computer simulations and subsequent trajectory analysis.
4fd2f7f
It is developed for biomolecules like proteins, but the extremely high
4fd2f7f
performance means it is used also in several other field like polymer chemistry
4fd2f7f
and solid state physics.
6e06a80
4fd2f7f
This package provides bash completion for GROMACS.
6e06a80
6e06a80
6e06a80
%package zsh
6e06a80
Summary:	GROMACS zsh support
6e06a80
Group:		Applications/Engineering
6e06a80
Requires:	zsh
1b055a1
BuildArch:	noarch
1b055a1
# Due to switch to noarch package
dc6f6f6
Obsoletes:	gromacs-zsh < 4.0.7-1
1b055a1
6e06a80
6e06a80
%description zsh
4fd2f7f
GROMACS is a versatile and extremely well optimized package to perform
4fd2f7f
molecular dynamics computer simulations and subsequent trajectory analysis.
4fd2f7f
It is developed for biomolecules like proteins, but the extremely high
4fd2f7f
performance means it is used also in several other field like polymer chemistry
4fd2f7f
and solid state physics.
6e06a80
4fd2f7f
This package provides scripts needed to run GROMACS with zsh and zsh
4fd2f7f
completion.
6e06a80
6e06a80
6e06a80
%package csh
6e06a80
Summary:	GROMACS csh support
6e06a80
Group:		Applications/Engineering
6e06a80
Requires:	csh
1b055a1
BuildArch:	noarch
1b055a1
# Due to switch to noarch package
dc6f6f6
Obsoletes:	gromacs-csh < 4.0.7-1 
1b055a1
6e06a80
6e06a80
%description csh
4fd2f7f
GROMACS is a versatile and extremely well optimized package to perform
4fd2f7f
molecular dynamics computer simulations and subsequent trajectory analysis.
4fd2f7f
It is developed for biomolecules like proteins, but the extremely high
4fd2f7f
performance means it is used also in several other field like polymer chemistry
4fd2f7f
and solid state physics.
6e06a80
4fd2f7f
This package provides scripts needed to run GROMACS with csh and a completion
4fd2f7f
script.
6e06a80
6e06a80
%package tutor
6e06a80
Summary:	GROMACS tutorial files
6e06a80
Group:		Applications/Engineering
6e06a80
Requires:	gromacs-common = %{version}-%{release}
1b055a1
BuildArch:	noarch
1b055a1
# Due to switch to noarch package
dc6f6f6
Obsoletes:	gromacs-tutor < 4.0.7-1 
6e06a80
6e06a80
%description tutor
4fd2f7f
GROMACS is a versatile and extremely well optimized package to perform
4fd2f7f
molecular dynamics computer simulations and subsequent trajectory analysis.
4fd2f7f
It is developed for biomolecules like proteins, but the extremely high
4fd2f7f
performance means it is used also in several other field like polymer chemistry
4fd2f7f
and solid state physics.
6e06a80
6e06a80
This package provides tutorials for the use of GROMACS.
6e06a80
6e06a80
%prep
b9e9c1f
%setup -q 
4fd2f7f
%patch0 -p1 -b .gmxrc
4fd2f7f
%patch1 -p1 -b .gmxdemo
6e06a80
6e06a80
# Fix incorrect permission
4fd2f7f
#chmod a-x src/tools/gmx_xpm2ps.c
6e06a80
6e06a80
6e06a80
6e06a80
%build
b9e9c1f
# First, override bug in MPICH2 packaging.
b9e9c1f
%{_mpich2_unload}
b9e9c1f
6e06a80
# Assembly kernels haven't got .note.GNU-stack sections
6e06a80
# because of incompatibilies with Microsoft Assembler.
6e06a80
# Add noexecstack to compiler flags
6e06a80
a90b748
export CFLAGS="%optflags -Wa,--noexecstack -fPIC"
b9e9c1f
export LIBS="-L%{_libdir}/atlas -lblas -llapack"
6e06a80
4fd2f7f
# Default options, used for all compilations
85ec9f9
export DEFOPTS="-D BUILD_SHARED_LIBS=ON -DCMAKE_SKIP_RPATH:BOOL=ON -DCMAKE_SKIP_BUILD_RPATH:BOOL=ON -DLIB=%{_lib}"
b9e9c1f
export SINGLE="-D GMX_DOUBLE=OFF" # Single precision
b9e9c1f
export DOUBLE="-D GMX_DOUBLE=ON" # Double precision
b9e9c1f
export MPI="-D GMX_MPI=ON"
1b055a1
1b055a1
# Add this to the configure options if you want to build a debug version
b9e9c1f
export NOASM="-D GMX_ACCELERATION=OFF"
4fd2f7f
6e06a80
# Single precision
6e06a80
mkdir single
6e06a80
cd single
b9e9c1f
%cmake $DEFOPTS $SINGLE ..
b9e9c1f
make VERBOSE=1 %{?_smp_mflags}
6e06a80
cd ..
6e06a80
6e06a80
# Double precision
6e06a80
mkdir double
6e06a80
cd double
b9e9c1f
%cmake $DEFOPTS $DOUBLE ..
b9e9c1f
make VERBOSE=1 %{?_smp_mflags}
6e06a80
cd ..
6e06a80
6e06a80
1b055a1
### MPI versions
1b055a1
export CC=mpicc
1b055a1
export CXX=mpicxx
1b055a1
export F77=mpif77
1b055a1
export F90=mpif90
1b055a1
export FC=mpif90
6e06a80
1b055a1
## Open MPI
85ec9f9
%if %{with_openmpi}
1b055a1
%{_openmpi_load}
b9e9c1f
# Suffix to be used for single precision is
b9e9c1f
SUFFIXCONF="-D GMX_DEFAULT_SUFFIX=OFF -D GMX_BINARY_SUFFIX=$SUFFIX -D GMX_LIBS_SUFFIX=${MPI_SUFFIX}"
1b055a1
# single precision
1b055a1
mkdir openmpi-single
1b055a1
cd openmpi-single
b9e9c1f
%cmake $DEFOPTS $SINGLE $MPI $SUFFIXCONF ..
b9e9c1f
make VERBOSE=1 %{?_smp_mflags} mdrun
4fd2f7f
cd ..
b9e9c1f
1b055a1
# double precision
b9e9c1f
# Suffix to be used for double precision is
b9e9c1f
SUFFIXCONF="-D GMX_DEFAULT_SUFFIX=OFF -D GMX_BINARY_SUFFIX=$SUFFIX -D GMX_LIBS_SUFFIX=${MPI_SUFFIX}_d"
1b055a1
mkdir openmpi-double
1b055a1
cd openmpi-double
b9e9c1f
%cmake $DEFOPTS $DOUBLE $MPI $SUFFIXCONF ..
b9e9c1f
make VERBOSE=1 %{?_smp_mflags} mdrun
6e06a80
cd ..
1b055a1
# unload
1b055a1
%{_openmpi_unload}
85ec9f9
%endif
1b055a1
b9e9c1f
1b055a1
## MPICH2
e3131b9
%{_mpich2_load}
b9e9c1f
# Suffix to be used for single precision is
b9e9c1f
SUFFIXCONF="-D GMX_DEFAULT_SUFFIX=OFF -D GMX_BINARY_SUFFIX=$SUFFIX -D GMX_LIBS_SUFFIX=${MPI_SUFFIX}"
b9e9c1f
# MPICH 2 is broken, so need to modify linker command
b9e9c1f
export CC="mpicc -lstdc++"
1b055a1
# single precision
e3131b9
mkdir mpich2-single
e3131b9
cd mpich2-single
b9e9c1f
%cmake $DEFOPTS $SINGLE $MPI $SUFFIXCONF ..
b9e9c1f
make VERBOSE=1 %{?_smp_mflags} mdrun
e3131b9
cd ..
1b055a1
# double precision
b9e9c1f
# Suffix to be used for double precision is
b9e9c1f
SUFFIXCONF="-D GMX_DEFAULT_SUFFIX=OFF -D GMX_BINARY_SUFFIX=$SUFFIX -D GMX_LIBS_SUFFIX=${MPI_SUFFIX}_d"
e3131b9
mkdir mpich2-double
e3131b9
cd mpich2-double
b9e9c1f
%cmake $DEFOPTS $DOUBLE $MPI $SUFFIXCONF ..
b9e9c1f
make VERBOSE=1 %{?_smp_mflags} mdrun
e3131b9
cd ..
e3131b9
%{_mpich2_unload}
6e06a80
4fd2f7f
1b055a1
%install
1b055a1
rm -rf %{buildroot}
4fd2f7f
4fd2f7f
1b055a1
## Open MPI
85ec9f9
%if %{with_openmpi}
1b055a1
%{_openmpi_load}
b9e9c1f
# Make install-mdrun target is broken, do install manually
b9e9c1f
mkdir -p %{buildroot}%{_libdir}/openmpi/{bin,lib}
1b055a1
# single precision
1b055a1
cd openmpi-single
b9e9c1f
install -p -m 755 src/kernel/mdrun %{buildroot}%{_libdir}/openmpi/bin/g_mdrun_openmpi
b9e9c1f
cp -a src/*/*.so* %{buildroot}%{_libdir}/openmpi/lib/
4fd2f7f
cd ..
1b055a1
# double precision
1b055a1
cd openmpi-double
b9e9c1f
install -p -m 755 src/kernel/mdrun %{buildroot}%{_libdir}/openmpi/bin/g_mdrun_openmpi_d
b9e9c1f
cp -a src/*/*.so* %{buildroot}%{_libdir}/openmpi/lib/
6e06a80
cd ..
1b055a1
%{_openmpi_unload}
85ec9f9
%endif
6e06a80
1b055a1
## MPICH 2
e3131b9
%{_mpich2_load}
b9e9c1f
# Make install-mdrun target is broken, do install manually
b9e9c1f
mkdir -p %{buildroot}%{_libdir}/mpich2/{bin,lib}
1b055a1
# single precision
e3131b9
cd mpich2-single
b9e9c1f
install -p -m 755 src/kernel/mdrun %{buildroot}%{_libdir}/mpich2/bin/g_mdrun_mpich2
b9e9c1f
cp -a src/*/*.so* %{buildroot}%{_libdir}/mpich2/lib/
e3131b9
cd ..
1b055a1
# double precision
e3131b9
cd mpich2-double
b9e9c1f
install -p -m 755 src/kernel/mdrun %{buildroot}%{_libdir}/mpich2/bin/g_mdrun_mpich2_d
b9e9c1f
cp -a src/*/*.so* %{buildroot}%{_libdir}/mpich2/lib/
e3131b9
cd ..
e3131b9
%{_mpich2_unload}
6e06a80
26363c1
1b055a1
## Serial versions
26363c1
6e06a80
# Single precision
6e06a80
cd single
6e06a80
make DESTDIR=%{buildroot} INSTALL="install -p" install
6e06a80
cd ..
6e06a80
# Double precision
6e06a80
cd double
6e06a80
make DESTDIR=%{buildroot} INSTALL="install -p" install
6e06a80
cd ..
6e06a80
b9e9c1f
## Now, the rest of the necessary stuff
b9e9c1f
6e06a80
# Install manual & packager's note
6e06a80
install -cpm 644 %{SOURCE1} .
6e06a80
install -cpm 644 %{SOURCE6} README.fedora
6e06a80
6e06a80
# Remove broken makefiles generated by build process
6e06a80
rm -rf %{buildroot}%{_datadir}/%{name}/template/Makefil*
6e06a80
# Install template makefiles
6e06a80
install -cpm 644 %{SOURCE2} %{buildroot}%{_datadir}/%{name}/template/Makefile.single
6e06a80
install -cpm 644 %{SOURCE3} %{buildroot}%{_datadir}/%{name}/template/Makefile.double
6e06a80
install -cpm 644 %{SOURCE4} %{buildroot}%{_datadir}/%{name}/template/Makefile.mpi.single
6e06a80
install -cpm 644 %{SOURCE5} %{buildroot}%{_datadir}/%{name}/template/Makefile.mpi.double
6e06a80
6e06a80
# Fix GMXRC file permissions
6e06a80
chmod a+x %{buildroot}%{_bindir}/GMXRC %{buildroot}%{_bindir}/GMXRC.*
6e06a80
6e06a80
# Rename binaries and man pages to prevent clashes
6e06a80
# (This is done here so that we don't need to mess with machine generated makefiles.
b9e9c1f
#for bin in anadock do_dssp editconf eneconv genbox genconf genion genrestr gmxcheck gmxdump grompp highway luck make_edi make_ndx mdrun mk_angndx ngmx pdb2gmx protonate sigeps tpbconv trjcat trjconv trjorder wheel x2top xpm2ps xrama ; do 
b9e9c1f
for bin in do_dssp editconf eneconv genbox genconf genion genrestr gmxcheck gmxdump grompp make_edi make_ndx mdrun mk_angndx pdb2gmx tpbconv trjcat trjconv trjorder xpm2ps; do
6e06a80
mv %{buildroot}%{_bindir}/${bin} %{buildroot}%{_bindir}/g_${bin}
6e06a80
mv %{buildroot}%{_bindir}/${bin}_d %{buildroot}%{_bindir}/g_${bin}_d
6e06a80
done
6e06a80
6e06a80
for bin in demux.pl xplor2gmx.pl; do
6e06a80
mv %{buildroot}%{_bindir}/$bin %{buildroot}%{_bindir}/g_${bin}
6e06a80
done
6e06a80
6e06a80
# Man pages
b9e9c1f
#for bin in anadock do_dssp editconf eneconv genbox genconf genion genrestr gmxcheck gmxdump grompp highway make_edi make_ndx mdrun mk_angndx ngmx pdb2gmx protonate sigeps tpbconv trjcat trjconv trjorder wheel x2top xpm2ps xrama ; do 
b9e9c1f
for bin in do_dssp editconf eneconv genbox genconf genion genrestr gmxcheck gmxdump grompp make_edi make_ndx mdrun mk_angndx pdb2gmx tpbconv trjcat trjconv trjorder xpm2ps; do
6e06a80
mv %{buildroot}%{_mandir}/man1/${bin}.1 %{buildroot}%{_mandir}/man1/g_${bin}.1
b9e9c1f
#mv %{buildroot}%{_mandir}/man1/${bin}_d.1 %{buildroot}%{_mandir}/man1/g_${bin}_d.1
6e06a80
done
6e06a80
6e06a80
# Move completion files around
6e06a80
chmod a-x %{buildroot}%{_bindir}/completion.*
6e06a80
# Zsh
6e06a80
mkdir -p %{buildroot}%{_datadir}/zsh/site-functions
6e06a80
mv %{buildroot}%{_bindir}/completion.zsh %{buildroot}%{_datadir}/zsh/site-functions/gromacs
6e06a80
# Bash
6e06a80
mkdir -p %{buildroot}%{_sysconfdir}/bash_completion.d
6e06a80
mv %{buildroot}%{_bindir}/completion.bash %{buildroot}/etc/bash_completion.d/gromacs
6e06a80
# Tcsh
6e06a80
mv %{buildroot}%{_bindir}/completion.csh . 
6e06a80
6e06a80
# Remove .la files
1b055a1
find %{buildroot} -name *.la -exec rm -rf {} \;
4fd2f7f
85ec9f9
# Get rid of executable stacks
85ec9f9
find %{buildroot} -name *.so.* -exec execstack -c {} \;
85ec9f9
1b055a1
# Post install for libs. MPI packages don't need this.
88fd785
%post libs -p /sbin/ldconfig
4fd2f7f
88fd785
%postun libs -p /sbin/ldconfig
6e06a80
6e06a80
%clean
6e06a80
rm -rf %{buildroot}
6e06a80
6e06a80
6e06a80
# Files section
6e06a80
6e06a80
%files
6e06a80
%defattr(-,root,root,-)
8cb2189
%{_bindir}/g_*
6e06a80
6e06a80
%files common
6e06a80
%defattr(-,root,root,-)
2b17eb0
%doc AUTHORS COPYING README manual-4.5.4.pdf README.fedora
6e06a80
%{_bindir}/GMXRC
6e06a80
%{_bindir}/GMXRC.bash
6e06a80
%{_mandir}/man1/*
b9e9c1f
%{_mandir}/man7/gromacs.*
8b25f67
%{_datadir}/%{name}/
8b25f67
%exclude %{_datadir}/%{name}/template/
8b25f67
%exclude %{_datadir}/%{name}/tutor/
6e06a80
dc6f6f6
%files libs
dc6f6f6
%defattr(-,root,root,-)
dc6f6f6
%{_libdir}/libgmx.so.*
dc6f6f6
%{_libdir}/libgmx_d.so.*
dc6f6f6
%{_libdir}/libgmxana.so.*
dc6f6f6
%{_libdir}/libgmxana_d.so.*
dc6f6f6
%{_libdir}/libgmxpreprocess.so.*
dc6f6f6
%{_libdir}/libgmxpreprocess_d.so.*
dc6f6f6
%{_libdir}/libmd.so.*
dc6f6f6
%{_libdir}/libmd_d.so.*
dc6f6f6
6e06a80
%files devel
6e06a80
%defattr(-,root,root,-)
6e06a80
%{_includedir}/%{name}
6e06a80
%{_libdir}/libgmx.so
6e06a80
%{_libdir}/libgmx_d.so
6e06a80
%{_libdir}/libgmxana.so
6e06a80
%{_libdir}/libgmxana_d.so
b9e9c1f
%{_libdir}/libgmxpreprocess.so
b9e9c1f
%{_libdir}/libgmxpreprocess_d.so
6e06a80
%{_libdir}/libmd.so
6e06a80
%{_libdir}/libmd_d.so
b9e9c1f
%{_libdir}/pkgconfig/*.pc
8b25f67
%{_datadir}/%{name}/template/
6e06a80
%exclude %{_datadir}/%{name}/template/Makefile.mpi.*
6e06a80
85ec9f9
%if %{with_openmpi}
1b055a1
%files openmpi
6e06a80
%defattr(-,root,root,-)
1b055a1
%{_libdir}/openmpi/bin/g_mdrun*
dc6f6f6
dc6f6f6
%files openmpi-libs
dc6f6f6
%defattr(-,root,root,-)
1b055a1
%{_libdir}/openmpi/lib/lib*.so.*
6e06a80
1b055a1
%files openmpi-devel
4fd2f7f
%defattr(-,root,root,-)
1b055a1
%{_libdir}/openmpi/lib/lib*.so
85ec9f9
%endif
4fd2f7f
e3131b9
%files mpich2
e3131b9
%defattr(-,root,root,-)
e3131b9
%{_libdir}/mpich2/bin/g_mdrun*
dc6f6f6
dc6f6f6
%files mpich2-libs
dc6f6f6
%defattr(-,root,root,-)
e3131b9
%{_libdir}/mpich2/lib/lib*.so.*
1b055a1
e3131b9
%files mpich2-devel
e3131b9
%defattr(-,root,root,-)
e3131b9
%{_libdir}/mpich2/lib/lib*.so
6e06a80
6e06a80
%files zsh
6e06a80
%defattr(-,root,root,-)
6e06a80
%{_datadir}/zsh/site-functions/gromacs
6e06a80
%{_bindir}/GMXRC.zsh
6e06a80
6e06a80
%files bash
6e06a80
%defattr(-,root,root,-)
6e06a80
%config(noreplace) %{_sysconfdir}/bash_completion.d/gromacs
6e06a80
6e06a80
%files csh
6e06a80
%defattr(-,root,root,-)
6e06a80
%doc completion.csh
6e06a80
%{_bindir}/GMXRC.csh
6e06a80
6e06a80
%files tutor
6e06a80
%defattr(-,root,root,-)
8b25f67
%{_datadir}/%{name}/tutor/
6e06a80
6e06a80
6e06a80
%changelog
2b17eb0
* Wed Mar 23 2011 Jussi Lehtola <jussilehtola@fedoraproject.org> - 4.5.4-1
2b17eb0
- Update to 4.5.4.
2b17eb0
85ec9f9
* Sun Feb 13 2011 Jussi Lehtola <jussilehtola@fedoraproject.org> - 4.5.3-4
85ec9f9
- Get rid of executable stacks.
85ec9f9
85ec9f9
* Mon Feb 07 2011 Dan HorĂ¡k <dan[at]danny.cz> - 4.5.3-3
85ec9f9
- conditionalize OpenMPI support
85ec9f9
- fix build on 64-bit platforms
85ec9f9
fae6a03
* Mon Dec 20 2010 Jussi Lehtola <jussilehtola@fedoraproject.org> - 4.5.3-2
fae6a03
- Fix rest of BZ #649338.
fae6a03
66d38f5
* Thu Nov 18 2010 Jussi Lehtola <jussilehtola@fedoraproject.org> - 4.5.3-1
66d38f5
- Update to 4.5.3.
66d38f5
66d38f5
* Fri Nov 05 2010 Jussi Lehtola <jussilehtola@fedoraproject.org> - 4.5.2-3
66d38f5
- Rebuild due to libxml2 soname bump.
66d38f5
e1bf06f
* Wed Nov 03 2010 Jussi Lehtola <jussilehtola@fedoraproject.org> - 4.5.2-2
e1bf06f
- Make gromacs package obsolete older versions of gromacs package due to the
e1bf06f
  branching of libraries.
e1bf06f
88fd785
* Mon Nov 01 2010 Jussi Lehtola <jussilehtola@fedoraproject.org> - 4.5.2-1
88fd785
- Update to 4.5.2.
88fd785
dc6f6f6
* Wed Oct 27 2010 Jussi Lehtola <jussilehtola@fedoraproject.org> - 4.5.1-2
dc6f6f6
- Patch around #644950.
dc6f6f6
- Split libraries in own packages to avoid multilib problems.
dc6f6f6
b9e9c1f
* Sat Oct 09 2010 Jussi Lehtola <jussilehtola@fedoraproject.org> - 4.5.1-1
b9e9c1f
- Update to 4.5.1.
b9e9c1f
3c91c48
* Sun Dec 06 2009 Jussi Lehtola <jussilehtola@fedoraproject.org> - 4.0.7-1
3c91c48
- Update to 4.0.7.
3c91c48
cc7c0b6
* Sun Dec 06 2009 Jussi Lehtola <jussilehtola@fedoraproject.org> - 4.0.6-1
cc7c0b6
- Update to 4.0.6.
cc7c0b6
8cb2189
* Fri Dec 04 2009 Jussi Lehtola <jussilehtola@fedoraproject.org> - 4.0.5-6
8cb2189
- Fix file conflict.
8cb2189
031fcad
* Tue Dec 01 2009 Jussi Lehtola <jussilehtola@fedoraproject.org> - 4.0.5-5
031fcad
- Put correct MPI devel package requires in place.
031fcad
c315d54
* Tue Dec 01 2009 Jussi Lehtola <jussilehtola@fedoraproject.org> - 4.0.5-4
c315d54
- Fix obsoletes.
c315d54
1b055a1
* Mon Nov 30 2009 Jussi Lehtola <jussilehtola@fedoraproject.org> - 4.0.5-3
1b055a1
- Combine libs with binaries and drop debug packages to avoid explosion of
1b055a1
  number of packages.
e3131b9
- Adopt use of MPI guidelines.
1b055a1
0b7b88a
* Fri Jul 24 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 4.0.5-2
0b7b88a
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
0b7b88a
4fd2f7f
* Fri May 22 2009 Jussi Lehtola <jussi.lehtola@iki.fi> - 4.0.5-1
4fd2f7f
- Update to 4.0.5.
4fd2f7f
- Change spec %%defines to %%globals.
4fd2f7f
- Add debug subpackages to make debugging of GROMACS possible.
35dce57
ed60a6b
* Tue Feb 17 2009 Jussi Lehtola <jussi.lehtola@iki.fi> - 4.0.4-1
ed60a6b
- Update to 4.0.4.
ed60a6b
0ff216d
* Mon Jan 19 2009 Jussi Lehtola <jussi.lehtola@iki.fi> - 4.0.3-4
0ff216d
- Retry fixing gmxdemo.
0ff216d
2d0f49e
* Mon Jan 19 2009 Jussi Lehtola <jussi.lehtola@iki.fi> - 4.0.3-3
2d0f49e
- Fixed gmxdemo.
2d0f49e
26363c1
* Mon Jan 19 2009 Jussi Lehtola <jussi.lehtola@iki.fi> - 4.0.3-2
26363c1
- Fix EPEL 4 build.
26363c1
7b3f14a
* Mon Jan 19 2009 Jussi Lehtola <jussi.lehtola@iki.fi> - 4.0.3-1
7b3f14a
- Update to 4.0.3.
7b3f14a
ad6f154
* Wed Jan 14 2009 Jussi Lehtola <jussi.lehtola@iki.fi> - 4.0.2-7
ad6f154
- Update manual to latest version.
ad6f154
- Removed Requires: blas and lapack.
ad6f154
ad6f154
* Mon Nov 10 2008 Jussi Lehtola <jussi.lehtola@iki.fi> - 4.0.2-6
bb4bd8c
- Update to 4.0.2.
bb4bd8c
ad6f154
* Sun Nov 09 2008 Jussi Lehtola <jussi.lehtola@iki.fi> - 4.0.1-5
3f6f449
- Add Requires: blas too.
3f6f449
ad6f154
* Sun Nov 09 2008 Jussi Lehtola <jussi.lehtola@iki.fi> - 4.0.1-4
a90b748
- Update to 4.0.1.
a90b748
- Add Requires: lapack and openmpi to prevent yum from pulling atlas and lam
a90b748
instead.
a90b748
ad6f154
* Wed Oct 15 2008 Jussi Lehtola <jussi.lehtola@iki.fi> - 4.0-3
6e06a80
- Rename also man pages.
6e06a80
ad6f154
* Mon Oct 13 2008 Jussi Lehtola <jussi.lehtola@iki.fi> - 4.0-2
6e06a80
- Added noreplace to bash completion file.
6e06a80
- Changed double precision mpi binary suffix to _mpi_d.
6e06a80
ad6f154
* Sun Oct 12 2008 Jussi Lehtola <jussi.lehtola@iki.fi> - 4.0-1
6e06a80
- Update to Gromacs 4.0.
6e06a80
- Remove module system and patch file names to begin with g_.
6e06a80
ad6f154
* Wed Oct 08 2008 Jussi Lehtola <jussi.lehtola@iki.fi> - 4.0-0.15.rc3
6e06a80
- Changed location of binaries.
6e06a80
- Removed conflict of module file, as the program is binary compatible with older versions.
6e06a80
ad6f154
* Wed Oct 08 2008 Jussi Lehtola <jussi.lehtola@iki.fi> - 4.0-0.14.rc3
6e06a80
- The gromacs module is loaded automatically and it conflicts with gromacs3.
6e06a80
ad6f154
* Tue Oct 07 2008 Jussi Lehtola <jussi.lehtola@iki.fi> - 4.0-0.13.rc3
6e06a80
- Renamed module files from %%{name}-%%{version} to %%{name}.
6e06a80
ad6f154
* Mon Oct 06 2008 Jussi Lehtola <jussi.lehtola@iki.fi> - 4.0-0.12.rc3
6e06a80
- Fix BR to get GROMACS to build in mock for epel-4.
6e06a80
ad6f154
* Sat Oct 04 2008 Jussi Lehtola <jussi.lehtola@iki.fi> - 4.0-0.11.rc3
6e06a80
- Fix to get GROMACS to build in mock for epel-5.
6e06a80
ad6f154
* Sat Oct 04 2008 Jussi Lehtola <jussi.lehtola@iki.fi> - 4.0-0.10.rc3
6e06a80
- Implement module system & remove binary renaming.
6e06a80
- No need for autoreconf anymore.
6e06a80
- Update to rc3.
6e06a80
ad6f154
* Sat Oct 04 2008 Jussi Lehtola <jussi.lehtola@iki.fi> - 4.0-0.9.rc2
6e06a80
- Fall back to autoreconf due to binary renaming.
6e06a80
ad6f154
* Fri Oct 03 2008 Jussi Lehtola <jussi.lehtola@iki.fi> - 4.0-0.8.rc2
6e06a80
- Modified install commands to preserve timestamps.
6e06a80
ad6f154
* Fri Oct 03 2008 Jussi Lehtola <jussi.lehtola@iki.fi> - 4.0-0.7.rc2
6e06a80
- Even more review fixes.
6e06a80
- Binaries renamed:
6e06a80
	highway	->	g_highway
6e06a80
	luck	->	g_luck
6e06a80
	sigeps	->	g_sigeps
6e06a80
	wheel	->	g_wheel
6e06a80
ad6f154
* Thu Oct 02 2008 Jussi Lehtola <jussi.lehtola@iki.fi> - 4.0-0.6.rc2
6e06a80
- Final review fixes.
6e06a80
ad6f154
* Wed Oct 01 2008 Jussi Lehtola <jussi.lehtola@iki.fi> - 4.0-0.5.rc2
6e06a80
- Strip down requires by branching tutor to its own package.
6e06a80
ad6f154
* Tue Sep 30 2008 Jussi Lehtola <jussi.lehtola@iki.fi> - 4.0-0.4.rc2
6e06a80
- Extensive package review fixes.
6e06a80
- Unclear licenses on some files, filed upstream bug 217.
6e06a80
  http://bugzilla.gromacs.org/show_bug.cgi?id=217
6e06a80
ad6f154
* Mon Sep 29 2008 Jussi Lehtola <jussi.lehtola@iki.fi> - 4.0-0.3.rc2
6e06a80
- Move .so files to -devel package.
6e06a80
- Remove .la files.
6e06a80
ad6f154
* Mon Sep 29 2008 Jussi Lehtola <jussi.lehtola@iki.fi> - 4.0-0.2.rc2
6e06a80
- Implement out-of-tree-builds.
6e06a80
- Add --noexecstack to CFLAGS.
6e06a80
- Remove execstack procedure and prelink from buildreqs.
6e06a80
- Filed upstream bug 215 to add .note.GNU-stack .
6e06a80
- Fix incorrect file permission on src/tools/gmx_xpm2ps.c .
6e06a80
ad6f154
* Mon Sep 29 2008 Jussi Lehtola <jussi.lehtola@iki.fi> - 4.0-0.1.rc2
6e06a80
- Alphabetized buildrequires.
6e06a80
- Changed gromacs-share to gromacs-common.
6e06a80
ad6f154
* Fri Sep 26 2008 Jussi Lehtola <jussi.lehtola@iki.fi> - 4.0-0.0.rc2
6e06a80
- Initial build.