ComparativeGenomicsToolkit / hal

Hierarchical Alignment Format
Other
159 stars 40 forks source link

make[1]: *** [../objs/phyloP/impl/halPhyloPMain.o] Error 1 #83

Closed shameem356 closed 5 years ago

shameem356 commented 5 years ago

Hello Team,

I am getting the following error while installing hal.

make[1]: Entering directory `/data/labs/genomics_lab/shared/apps/HAL/hal/phyloP' h5c++ -prefix=/data/labs/genomics_lab/shared/apps/hdf5-1.10.1/hdf5/ -MM -MT ../objs/phyloP/impl/halPhyloPMain.o -O3 -g -Wall -funroll-loops -DNDEBUG -I../../sonLib/lib -fPIC -D_GLIBCXX_USE_CXX11_ABI=1 -std=c++11 -Wno-sign-compare -DENABLE_PHYLOP -I../../phast/include -I../../phast/src/lib/pcre -I../../clapack/INCLUDE -I../../clapack/F2CLIBS -I../api/inc -Iimpl -Iinc -I../liftover/inc/ -I../liftover/inc -c impl/halPhyloPMain.cpp >impl/halPhyloPMain.depend In file included from ../liftover/inc/halBedScanner.h:14:0, from inc/halPhyloPBed.h:11, from impl/halPhyloPMain.cpp:10: /usr/include/c++/4.8.2/fstream:43:17: error: operator '>=' has no left operand

if __cplusplus >= 201103L

             ^

/usr/include/c++/4.8.2/fstream:272:17: error: operator '>=' has no left operand

if __cplusplus >= 201103L

             ^

/usr/include/c++/4.8.2/fstream:474:17: error: operator '>=' has no left operand

if __cplusplus >= 201103L

             ^

/usr/include/c++/4.8.2/fstream:548:17: error: operator '>=' has no left operand

if __cplusplus >= 201103L

             ^

/usr/include/c++/4.8.2/fstream:648:17: error: operator '>=' has no left operand

if __cplusplus >= 201103L

             ^

/usr/include/c++/4.8.2/fstream:724:17: error: operator '>=' has no left operand

if __cplusplus >= 201103L

             ^

/usr/include/c++/4.8.2/fstream:824:17: error: operator '>=' has no left operand

if __cplusplus >= 201103L

             ^

/usr/include/c++/4.8.2/fstream:897:17: error: operator '>=' has no left operand

if __cplusplus >= 201103L

             ^

make[1]: [../objs/phyloP/impl/halPhyloPMain.o] Error 1 make[1]: Leaving directory `/data/labs/genomics_lab/shared/apps/HAL/hal/phyloP' make: [phyloP.progs] Error 2

diekhans commented 5 years ago

This looks like a broken C++ install. Note that the error is in a C++ header.

Mark

BioRyder notifications@github.com writes:

Hello Team,

I am getting the following error while installing hal.

make[1]: Entering directory `/data/labs/genomics_lab/shared/apps/HAL/hal/phyloP' h5c++ -prefix=/data/labs/genomics_lab/shared/apps/hdf5-1.10.1/hdf5/ -MM -MT ../objs/phyloP/impl/halPhyloPMain.o -O3 -g -Wall -funroll-loops -DNDEBUG -I../../sonLib/lib -fPIC -D_GLIBCXX_USE_CXX11_ABI=1 -std=c++11 -Wno-sign-compare -DENABLE_PHYLOP -I../../phast/include -I../../phast/src/lib/pcre -I../../clapack/INCLUDE -I../../clapack/F2CLIBS -I../api/inc -Iimpl -Iinc -I../liftover/inc/ -I../liftover/inc -c impl/halPhyloPMain.cpp >impl/halPhyloPMain.depend In file included from ../liftover/inc/halBedScanner.h:14:0, from inc/halPhyloPBed.h:11, from impl/halPhyloPMain.cpp:10: /usr/include/c++/4.8.2/fstream:43:17: error: operator '>=' has no left operand

if __cplusplus >= 201103L

             ^

/usr/include/c++/4.8.2/fstream:272:17: error: operator '>=' has no left operand

if __cplusplus >= 201103L

             ^

/usr/include/c++/4.8.2/fstream:474:17: error: operator '>=' has no left operand

if __cplusplus >= 201103L

             ^

/usr/include/c++/4.8.2/fstream:548:17: error: operator '>=' has no left operand

if __cplusplus >= 201103L

             ^

/usr/include/c++/4.8.2/fstream:648:17: error: operator '>=' has no left operand

if __cplusplus >= 201103L

             ^

/usr/include/c++/4.8.2/fstream:724:17: error: operator '>=' has no left operand

if __cplusplus >= 201103L

             ^

/usr/include/c++/4.8.2/fstream:824:17: error: operator '>=' has no left operand

if __cplusplus >= 201103L

             ^

/usr/include/c++/4.8.2/fstream:897:17: error: operator '>=' has no left operand

if __cplusplus >= 201103L

             ^

make[1]: [../objs/phyloP/impl/halPhyloPMain.o] Error 1 make[1]: Leaving directory `/data/labs/genomics_lab/shared/apps/HAL/hal/phyloP' make: [phyloP.progs] Error 2

-- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/ComparativeGenomicsToolkit/hal/issues/83 Hello Team,

I am getting the following error while installing hal.

make[1]: Entering directory /data/labs/genomics_lab/shared/apps/HAL/hal/phyloP' h5c++ -prefix=/data/labs/genomics_lab/shared/apps/hdf5-1.10.1/hdf5/ -MM -MT ../ objs/phyloP/impl/halPhyloPMain.o -O3 -g -Wall -funroll-loops -DNDEBUG -I../../ sonLib/lib -fPIC -D_GLIBCXX_USE_CXX11_ABI=1 -std=c++11 -Wno-sign-compare -DENABLE_PHYLOP -I../../phast/include -I../../phast/src/lib/pcre -I../../ clapack/INCLUDE -I../../clapack/F2CLIBS -I../api/inc -Iimpl -Iinc -I../liftover /inc/ -I../liftover/inc -c impl/halPhyloPMain.cpp >impl/halPhyloPMain.depend In file included from ../liftover/inc/halBedScanner.h:14:0, from inc/ halPhyloPBed.h:11, from impl/halPhyloPMain.cpp:10: /usr/include/c++/4.8.2/ fstream:43:17: error: operator '>=' has no left operand #if cplusplus >= 201103L ^ /usr/include/c++/4.8.2/fstream:272:17: error: operator '>=' has no left operand #if cplusplus >= 201103L ^ /usr/include/c++/4.8.2/ fstream:474:17: error: operator '>=' has no left operand #if cplusplus >= 201103L ^ /usr/include/c++/4.8.2/fstream:548:17: error: operator '>=' has no left operand #if cplusplus >= 201103L ^ /usr/include/c++/4.8.2/ fstream:648:17: error: operator '>=' has no left operand #if cplusplus >= 201103L ^ /usr/include/c++/4.8.2/fstream:724:17: error: operator '>=' has no left operand #if cplusplus >= 201103L ^ /usr/include/c++/4.8.2/ fstream:824:17: error: operator '>=' has no left operand #if cplusplus >= 201103L ^ /usr/include/c++/4.8.2/fstream:897:17: error: operator '>=' has no left operand #if cplusplus >= 201103L ^ make[1]: [../objs/phyloP/impl/ halPhyloPMain.o] Error 1 make[1]: Leaving directory /data/labs/genomics_lab/ shared/apps/HAL/hal/phyloP' make: [phyloP.progs] Error 2

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub, or mute the thread.*

joelarmstrong commented 5 years ago

This is my fault, probably: I put in an ungodly hack here which was necessary to work around some issues with a PHAST dependency assuming that a C++ compiler was active if __cplusplus was defined. Which it is even in extern "C" environments, sadly, so the compilation totally broke if we didn't undef it.

I think the way to fix this (while retaining the ugly hack) is to save the value of __cplusplus and restore it, rather than just defining it.

EDIT: though that's actually not possible... hmm. We could try using push/pop_macro.

diekhans commented 5 years ago

Added different workarounds for PHAST vs C++ issues.

Miguel-BSoares commented 3 years ago

Hi everyone,

Just trying to install hal on my University HPC cluster and got stuck right at the phyloP stage:

cd phyloP && make progs
make[1]: Entering directory `/users/baltazar/software/hal/phyloP'
h5c++ -prefix=/users/baltazar/software/hdf5/hdf5-1.10.1/ -MM -MT ../objs/phyloP/impl/halPhyloPMain.o -fPIC -D_GLIBCXX_USE_CXX11_ABI=1 -O3 -g -Wall -funroll-loops -DNDEBUG -I../../sonLib/lib -D_GLIBCXX_USE_CXX11_ABI=1 -std=c++11 -Wno-sign-compare -DENABLE_PHYLOP -I../../phast/include -I../../phast/src/lib/pcre -I/users/baltazar/software/clapack/INCLUDE -I/users/baltazar/software/clapack/F2CLIBS -I../api/inc -Iimpl -Iinc -I../liftover/inc -I../liftover/inc -c impl/halPhyloPMain.cpp >impl/halPhyloPMain.depend
In file included from impl/halPhyloPMain.cpp(9):
inc/halPhyloP.h(19): catastrophic error: cannot open source file "fit_column.h"
  #include "fit_column.h"
                         ^
make[1]: *** [../objs/phyloP/impl/halPhyloPMain.o] Error 4
make[1]: Leaving directory `/users/baltazar/software/hal/phyloP'
make: *** [phyloP.progs] Error 2

Followed the instructions on installation to the letter and all other steps went smoothly.

best,

Miguel

joanam commented 3 years ago

Hi everyone,

I have the same problem. Everything worked well so far with the dependencies but when I try to install hal, it cannot find fit_column.h.

make[1]: Entering directory '/rds/project/cj107/rds-cj107-jiggins-rds/projects/Mechanitis/referenceGenome/hal/phyloP'
h5c++ -prefix=/rds/project/cj107/rds-cj107-jiggins-rds/projects/Mechanitis/referenceGenome/hdf5 -MM -MT ../objs/phyloP/impl/halPhyloPMain.o -fvisibility-inlines-hidden -std=c++17 -fmessage-length=0 -march=nocona -mtune=haswell -ftree-vectorize -fPIC -fstack-protector-strong -fno-plt -O2 -ffunction-sections -pipe -isystem /home/jm2276/miniconda3/envs/btk_env/include -fPIC -D_GLIBCXX_USE_CXX11_ABI=1 -O3 -g -Wall -funroll-loops -DNDEBUG -I./../sonLib/lib -D_GLIBCXX_USE_CXX11_ABI=1 -std=c++11 -Wno-sign-compare -DENABLE_PHYLOP -I./../phast/include -I./../phast/src/lib/pcre -I/rds/project/cj107/rds-cj107-jiggins-rds/projects/Mechanitis/referenceGenome/clapack/INCLUDE -I/rds/project/cj107/rds-cj107-jiggins-rds/projects/Mechanitis/referenceGenome/clapack/F2CLIBS -DENABLE_UDC -I/rds/project/cj107/rds-cj107-jiggins-rds/projects/Mechanitis/referenceGenome/kent/src//inc -I/rds/project/cj107/rds-cj107-jiggins-rds/projects/Mechanitis/referenceGenome/kent/src//htslib -pthread -fPIC -D_GLIBCXX_USE_CXX11_ABI=1 -O3 -g -Wall -funroll-loops -DNDEBUG -I../../sonLib/lib -D_GLIBCXX_USE_CXX11_ABI=1 -std=c++11 -Wno-sign-compare -DENABLE_PHYLOP -I../../phast/include -I../../phast/src/lib/pcre -I/rds/project/cj107/rds-cj107-jiggins-rds/projects/Mechanitis/referenceGenome/clapack/INCLUDE -I/rds/project/cj107/rds-cj107-jiggins-rds/projects/Mechanitis/referenceGenome/clapack/F2CLIBS -DENABLE_UDC -I/rds/project/cj107/rds-cj107-jiggins-rds/projects/Mechanitis/referenceGenome/kent/src//inc -I/rds/project/cj107/rds-cj107-jiggins-rds/projects/Mechanitis/referenceGenome/kent/src//htslib -pthread -I../api/inc -Iimpl -Iinc -I../liftover/inc -I../liftover/inc -c impl/halPhyloPMain.cpp >impl/halPhyloPMain.depend
In file included from impl/halPhyloPMain.cpp:9:
inc/halPhyloP.h:18:10: fatal error: fit_column.h: No such file or directory
   18 | #include "fit_column.h"
      |          ^~~~~~~~~~~~~~
compilation terminated.
make[1]: *** [../rules.mk:18: ../objs/phyloP/impl/halPhyloPMain.o] Error 1
make[1]: Leaving directory '/rds/project/cj107/rds-cj107-jiggins-rds/projects/Mechanitis/referenceGenome/hal/phyloP'
make: *** [Makefile:17: phyloP.progs] Error 2

Running make in the phyloP directory in hal leads to the same error.

Any help solving this issue would be greatly appreciated.

Best wishes, Joana

Miguel-BSoares commented 3 years ago

Hello Joana,

Have you tried Joel´s "ungodly hack" on the halPhyloP.h file? I have solved my installation issue but honestly I cannot fully remember if it was that way. If it does not work still, let me know so I dig deeper on my notes.

best,

Miguel

On Tue, May 25, 2021 at 2:13 PM Joana @.***> wrote:

Hi everyone,

I have the same problem. Everything worked well so far with the dependencies but when I try to install hal, it cannot find fit_column.h.

make[1]: Entering directory '/rds/project/cj107/rds-cj107-jiggins-rds/projects/Mechanitis/referenceGenome/hal/phyloP' h5c++ -prefix=/rds/project/cj107/rds-cj107-jiggins-rds/projects/Mechanitis/referenceGenome/hdf5 -MM -MT ../objs/phyloP/impl/halPhyloPMain.o -fvisibility-inlines-hidden -std=c++17 -fmessage-length=0 -march=nocona -mtune=haswell -ftree-vectorize -fPIC -fstack-protector-strong -fno-plt -O2 -ffunction-sections -pipe -isystem /home/jm2276/miniconda3/envs/btk_env/include -fPIC -D_GLIBCXX_USE_CXX11_ABI=1 -O3 -g -Wall -funroll-loops -DNDEBUG -I./../sonLib/lib -D_GLIBCXX_USE_CXX11_ABI=1 -std=c++11 -Wno-sign-compare -DENABLE_PHYLOP -I./../phast/include -I./../phast/src/lib/pcre -I/rds/project/cj107/rds-cj107-jiggins-rds/projects/Mechanitis/referenceGenome/clapack/INCLUDE -I/rds/project/cj107/rds-cj107-jiggins-rds/projects/Mechanitis/referenceGenome/clapack/F2CLIBS -DENABLE_UDC -I/rds/project/cj107/rds-cj107-jiggins-rds/projects/Mechanitis/referenceGenome/kent/src//inc -I/rds/project/cj107/rds-cj107-jiggins-rds/projects/Mechanitis/referenceGenome/kent/src//htslib -pthread -fPIC -D_GLIBCXX_USE_CXX11_ABI=1 -O3 -g -Wall -funroll-loops -DNDEBUG -I../../sonLib/lib -D_GLIBCXX_USE_CXX11_ABI=1 -std=c++11 -Wno-sign-compare -DENABLE_PHYLOP -I../../phast/include -I../../phast/src/lib/pcre -I/rds/project/cj107/rds-cj107-jiggins-rds/projects/Mechanitis/referenceGenome/clapack/INCLUDE -I/rds/project/cj107/rds-cj107-jiggins-rds/projects/Mechanitis/referenceGenome/clapack/F2CLIBS -DENABLE_UDC -I/rds/project/cj107/rds-cj107-jiggins-rds/projects/Mechanitis/referenceGenome/kent/src//inc -I/rds/project/cj107/rds-cj107-jiggins-rds/projects/Mechanitis/referenceGenome/kent/src//htslib -pthread -I../api/inc -Iimpl -Iinc -I../liftover/inc -I../liftover/inc -c impl/halPhyloPMain.cpp >impl/halPhyloPMain.depend In file included from impl/halPhyloPMain.cpp:9: inc/halPhyloP.h:18:10: fatal error: fit_column.h: No such file or directory 18 | #include "fit_column.h" | ^~~~~~ compilation terminated. make[1]: [../rules.mk:18: ../objs/phyloP/impl/halPhyloPMain.o] Error 1 make[1]: Leaving directory '/rds/project/cj107/rds-cj107-jiggins-rds/projects/Mechanitis/referenceGenome/hal/phyloP' make: [Makefile:17: phyloP.progs] Error 2

Running make in the phyloP directory in hal leads to the same error.

Any help solving this issue would be greatly appreciated.

Best wishes, Joana

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/ComparativeGenomicsToolkit/hal/issues/83#issuecomment-847779837, or unsubscribe https://github.com/notifications/unsubscribe-auth/AOAPJUSY4V2C2C66WGMIEGDTPOA6ZANCNFSM4HYYMAAQ .

-- "And those who were seen dancing were thought to be insane by those who couldn't hear the music

" Postdoctoral researcher

*Google Scholar:https://scholar.google.hu/citations?user=U4X7rRYAAAAJ&hl=en https://scholar.google.hu/citations?user=U4X7rRYAAAAJ&hl=enRG:https://www.researchgate.net/profile/Miguel_Baltazar-Soares @.**_soaresReviewing Editor for Journal of Evolutionary Biology

diekhans commented 3 years ago

The phast package has renamed their header files, go back to an earlier version and it will work.

glennhickey commented 3 years ago

A couple things:

joanam commented 3 years ago

Many thanks for your fast replies! I have now tried the Phast installation with the new hal README instructions. Now I get a new error message when running make in the hal directory.

../../phast/include/msa.h:425:38: error: 'GFF_Set' has not been declared
  425 | void msa_reverse_compl_gff(MSA *msa, GFF_Set *gff, int *aux_data);
      |                                      ^~~~~~~
../../phast/include/msa.h:443:40: error: 'GFF_Set' has not been declared
  443 | void msa_reverse_compl_feats(MSA *msa, GFF_Set *feats, int *aux_data);
      |                                        ^~~~~~~
../../phast/include/msa.h:515:1: error: 'GFF_Set' does not name a type; did you mean 'GFF_H'?
  515 | GFF_Set *msa_get_informative_feats(MSA *msa, int min_informative,
      | ^~~~~~~
      | GFF_H
make[1]: *** [../rules.mk:19: ../objs/phyloP/impl/halPhyloPMain.o] Error 1
make[1]: Leaving directory '/rds/project/cj107/rds-cj107-jiggins-rds/projects/Mechanitis/referenceGenome/hal/phyloP'
make: *** [Makefile:17: phyloP.progs] Error 2

Next, I installed Phast again without git checkout and generated symlinks for all files in phast/include/ like this:

cd phast/include
for i in phast*
do
 ln -s $i ${i#phast_}
done

I did not get the error message about the missing fit_column.h anymore, but now I get this error:

/rds/project/cj107/rds-cj107-jiggins-rds/projects/Mechanitis/referenceGenome/kent/src/htslib/libhts.a(files.o): In function `file_exists':
/rds/project/cj107/rds-cj107-jiggins-rds/projects/Mechanitis/referenceGenome/kent/src/htslib/cram/files.c:63: multiple definition of `file_exists'
../../phast/lib/libphast.a(phast_misc.o):phast_misc.c:(.text+0x3ac0): first defined here
collect2: error: ld returned 1 exit status
make[1]: *** [../rules.mk:32: ../bin/halPhyloP] Error 1
make[1]: Leaving directory '/rds/project/cj107/rds-cj107-jiggins-rds/projects/Mechanitis/referenceGenome/hal/phyloP'
make: *** [Makefile:17: phyloP.progs] Error 2

Great that halPhyloP will be included in the next Cactus release! If we cannot figure these errors out, I will just wait for the next Cactus release.

Best wishes, Joana

diekhans commented 3 years ago

I am able to compile with the phast-1.5 release. It has the old include names and also has CLAPACK-3.2.1 provided, which is not in the source tree.

I believe the "multiple definition of `file_exists'" is because you are also linking with the UCSC browser (kent) tree. It appears that htslib and phast both define a function 'file_exists'.

Try disabling using the kent tree in HAL and see how it works?

diekhans commented 3 years ago

Actually,, I was wrong, CLAPACK isn't actually in the release, but the instructions have you download and compile it, so that should work with 1.5 too.

diekhans commented 3 years ago

If you go into:

src/lib/base/phast_misc.c

and delete the function file_exist and recompile phast, HAL should like.

The conflicting functions isn't used.

joanam commented 3 years ago

Hi everyone,

Thanks so much, diekhans for your help. It worked now! I have used the new phast version but had to also change the names of the files in src/lib/base/ and deleted the file_exist function. I also reinstalled clapack following the instructions on the phast website.

In the end, I am not quite sure what solved it but it worked.

Many thanks, everyone for your rapid replies!

Best wishes, Joana