This project is a port of HMMER source code to the MInGW compiler.
With the exception of hmmpgmd
and hmmpgmd_shard
the Windows native executables pass all tests.
If prefer not to do your own build the resulting executables are in the binaries directory.
The source code in this project was created from hmmer and easel forks of the develop branches of HMMER.
The following recipe describes how to build native executables for windows using
MSYS2 and MInGW. At the time
of writing the compiler was gcc version 11.2.0 (Rev1, Built by MSYS2 project)
Prerequisites
Prior to building install MSYS2, For example use chocolately
(choco.exe install msys2
), or an
installer
In the MSYS2 shell install these packages (picking all groups)
pacman -S base-devel gcc vim cmake
pacman -S mingw-w64-x86_64-toolchain
pacman -S diffutils
pacman -S git
There is no mman library for windows, but a wrapper is available for MinGW.
Download it from github and build
in MSYS2 (here installing it to c:\local).
./configure --prefix=c:/local
mingw32-make.exe
mingw32-make.exe install
Download code
git clone https://github.com/jones-gareth/hmmer
cd hmmer
git clone https://github.com/jones-gareth/easel
Configure HMMER
If configure
is not present it will need to be generated on a LINUX system using autoconf
.
Run configure (here installing to c:\local and looking for mman header files and library in c:\local):
CPPFLAGS="-Ic:/local/include" LDFLAGS=" -static -Lc:/local/lib" CFLAGS="-g -O0" ./configure --prefix=c:/local
Check that configure has picked up the mman library.
HMMER configuration:
compiler: gcc -g -O0 -pthread
host: x86_64-w64-mingw32
linker: -static -Lc:/local/lib
libraries: -lmman -lpthread
DP implementation: sse
Make, test and install
mingw32-make.exe clean
mingw32-make.exe dev # build everything- there should be no warnings
rm -r src/impl
cp -r src/impl_sse src/impl # No symlinks on windows, so this needs to be copied
mingw32-make.exe check # Run the tests. 2 will fail
mingw32-make.exe install # install if you're happy with test results
The presence of carriage returns (\r
) in config.sub
or config.guess
will cause autoconf
to fail.
Git operations may result in the insertion of \r
depending on the core.autocrlf
setting.
Windows (and MinGW) do not support POSIX signals or sockets. Lack of socket support
mean that the client server daemon
commands hmmpgmd
and hmmpgmd_shard
do not function (the executables are compiled, but they
won't work.)
Use of shell commands in C system calls is not properly supported. For example, code like
popen("cat esltmpfile 2>/dev/null");
system("gzip -c eslfile 2>/dev/null > eslfile.gz");
Will compile but not generally run (at least not in any portable fashion). I disabled unit tests that use this type of code.
- Case 5 in esl_buffer_utest::main
- esl_buffer_utest::utestOpenPipe
- The gzip output case in esl_buffer_utest::utestSetOffset
- esl_buffer_utest::utest_halfnewline (requires signals)
The temporary files created by esl_tmpfile
will persist on the filesystem in TEMP.
In Windows it is not possible to delete a file that is in use.
All tests except hmmpgmd_ga
and hmmpgmd_shard_ga
should pass.
Since the hmmpgmd
and hmmpgmd_shard
commands are broken that is expected.
exercise 297 [ hmmpgmd_ga] ... FAILED [command failed]
exercise 299 [ hmmpgmd_shard_ga] ... FAILED [command failed]
2 of 307 exercises at level <= 2 FAILED.
The tests use the perl and python executables installed in the MSYS2 shell.
Test code at a level > 2 has not been ported and may not run correctly (because of windows text mode, the test scripts frequently need changes even when the commands function correctly).
HMMER searches biological sequence databases for homologous sequences, using either single sequences or multiple sequence alignments as queries. HMMER implements a technology called "profile hidden Markov models" (profile HMMs). HMMER is used by many protein family domain databases and large-scale annotation pipelines, including Pfam and other members of the InterPro Consortium.
To obtain HMMER releases, please visit hmmer.org.
To participate in HMMER development, visit us at github. HMMER development depends on the Easel library, also at github.
% wget http://eddylab.org/software/hmmer/hmmer.tar.gz
% tar zxf hmmer.tar.gz
% cd hmmer-3.3.2
% ./configure --prefix /your/install/path
% make
% make check # optional: run automated tests
% make install # optional: install HMMER programs, man pages
% (cd easel; make install) # optional: install Easel tools
Executable programs will be installed in /your/install/path/bin
. If
you leave this optional ./configure
argument off, the default prefix
is /usr/local
.
Files to read in the source directory:
- INSTALL - brief installation instructions.
- Userguide.pdf - the HMMER User's Guide.
To get started after installation, see the Tutorial section in the HMMER User's Guide (Userguide.pdf).
The tarball way, above, is a better way to install HMMER (it includes a precompiled Userguide.pdf, for example), but you can also clone our github repo. You need to clone both the HMMER and Easel repositories, as follows:
% git clone https://github.com/EddyRivasLab/hmmer
% cd hmmer
% git clone https://github.com/EddyRivasLab/easel
% autoconf
and to build:
% ./configure
% make
Our git workflow includes three main branches:
- master is the stable branch for HMMER3 releases (including when H3 is released as a library inside Infernal)
- develop is the HMMER3 development branch
- h4-develop is the HMMER4 development branch.
To build the most recent official release, leave both HMMER and Easel on their default master branch. To contribute to HMMER3 development, you want to be on the develop branches. If you want to send us a pull request on GitHub, please base your changes on our develop branches.
Visit our issues tracking page at github.