Building bioinformatics tools in Ubuntu 17.10
3
0
Entering edit mode
6.6 years ago

Dear all,

I am re-building bioinformatics software in a newly acquired machine; I am using tools that I have compiled on Ubuntu 14 and 16, but the new machine has Ubuntu 17 and I am getting strange warnings and poor failure in compilation, For instance I have been using Bowtie2 in the old machine; in the new I have installed tbb with sudo apt-get install libtbb-dev then downloaded the latest Bowtie2 source and built it with make as suggested in the manual. I got, just for an example, the following errors:

diff_sample.h:180:6: warning: this ‘if’ clause does not guard... [-Wmisleading-indentation]
      if(!diffs[d1]) diffCnt++; diffs[d1] = true;
      ^~
diff_sample.h:180:32: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the ‘if’
      if(!diffs[d1]) diffCnt++; diffs[d1] = true;
                                ^~~~~
diff_sample.h:181:6: warning: this ‘if’ clause does not guard... [-Wmisleading-indentation]
      if(!diffs[d2]) diffCnt++; diffs[d2] = true;
      ^~
diff_sample.h:181:32: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the ‘if’
      if(!diffs[d2]) diffCnt++; diffs[d2] = true;
                                ^~~~~

that I did not obtain previously. In the old computer, for instance, bowtie2-align-l is given as 'executable shared library (application/x-executable)' with the classic purple icon; in the new computer the file compiled is listed as 'shared library (application/x-sharedlib)'. Similarly with other tools such as blast. I installed 'make' with sudo apt-get install make.

The tools are contained in the directory ~/src and then their location is exported to PATH.

Is there something funny with Ubuntu 17 or I forgot to install in the new machine some fundamental library required for the compilation?

Assembly software error • 3.2k views
ADD COMMENT
1
Entering edit mode

Why are you building things from source? Ubuntu comes with plenty of tools available via apt, including blast and bowtie.

ADD REPLY
1
Entering edit mode

Compiling from source is often the only way to get the latest version, which is desirable especially if it has bug fixes and/or new features.

ADD REPLY
0
Entering edit mode

in the case of bowtie itself, i had a previous error with apt-get bowtie2, compiling from source was the solution.

ADD REPLY
2
Entering edit mode

This should be apt install bowtie2. Packages normally install without problem with apt so I wonder what kind of error you got.

ADD REPLY
0
Entering edit mode

probably it was apt install bowtie2 but I forgot the issue...

ADD REPLY
0
Entering edit mode

This is probably due to using a newer compiler. Newer versions of GCC tend to produce errors where previous versions only issued warnings. It also depends on which compiler options are used. These warnings are an indication that not all is well with the code and I would report them to the developers so that the issues could be fixed before the software becomes impossible to compile with new compilers.

ADD REPLY
0
Entering edit mode

if u17 comes with a newer compiler than u16, would be possible to downgrade the compiler? i had not these issues with u16.

ADD REPLY
0
Entering edit mode

I got gcc 7.2.0 pm both machines. The difference is that I installed with success Bowtie2 on ubuntu16 and I am now getting errors while compiling on ubuntu17.

ADD REPLY
0
Entering edit mode

Same kind of error with BWA, the file produced by the compilation is a shared library rather than an executable. It is not just an issue of Bowtie.

ADD REPLY
0
Entering edit mode

What exactly the compilation produced? Did you try:

./bwa
ADD REPLY
0
Entering edit mode

actually now it works like an executable...

ADD REPLY
0
Entering edit mode

HISAT2 is also built as shared library instead of executable, even if in this case I could not locate the libraries MSYS and zlib, also the pre-compiled binaries for linux are not available.

ADD REPLY
0
Entering edit mode

What do you mean by "is built as a shared library". Did you try:

./hisat2 --help
ADD REPLY
0
Entering edit mode

since I am getting the issue that -- even if the compilation succeed -- the executables are listed as shared libraries, can I compile the tools on the old Ubuntu 16 machine and the copy them in the new Ubuntu 17 machine?

ADD REPLY
0
Entering edit mode

Did you try to run these "shared objects"? See this:

Executables vs Shared objects

ADD REPLY
3
Entering edit mode
6.6 years ago
h.mon 35k

Why compile if there is an official Bowtie2 binary download:

https://sourceforge.net/projects/bowtie-bio/files/bowtie2/2.3.4.1/bowtie2-2.3.4.1-linux-x86_64.zip

Also, I don't know how conda hasn't been mentioned so far - and I only mentioning it for the sake of completeness, as I appreciate its usefulness but don't like it for every case, and only use it sparingly.

ADD COMMENT
0
Entering edit mode

I installed the folder you suggested on ~/src but all the executables are not executable, for instance -rwxr-xr-x bowtie2, -rw-r--r-- bowtie2-build and -rw-r--r-- bowtie2-align-l (the latter is executable because I changed it manually). This is something that does not occur while compiling from source. Also, I like to know where the files are installed so I am not quite happy to use conda or apt.

ADD REPLY
0
Entering edit mode

I never had this problem with bowtie or bowtie2. Do you have some special file system configuration?

I like to know where the files are installed so I am not quite happy to use conda or apt.

It is just a matter of reading documentation. I know where all my conda packages are installed, and I can check all files installed with apt-get install from any package.

ADD REPLY
2
Entering edit mode
6.6 years ago
Charles Plessy ★ 2.9k

Ubuntu Bionic already comes with a bowtie 2.3.4.1 package. It was compiled with GCC7 as you can see from the build logs. The package was made after correcting the sources with the following patch (plus others). Maybe you can try applying it if you still want to compile Bowtie from source. But as written in the other comments, apt install bowtie2 is your friend!

ADD COMMENT
0
Entering edit mode
6.6 years ago
jomo018 ▴ 730

It is just a new warning in compiler GCC 6. Intended for programmers, probably those writing in both C++ and Python, where command indentation has different meaning. I would guess program behaviour (or misbehaviour...) would be exactly same as before.

ADD COMMENT
0
Entering edit mode

well, actually the executables are not being built, as the case of bowtie shows. the compilation runs but fails. i believe most of the problems are due to floating point handling.

ADD REPLY

Login before adding your answer.

Traffic: 813 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6