Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Problem compilation #1

Open
ebioman opened this issue Dec 4, 2014 · 5 comments
Open

Problem compilation #1

ebioman opened this issue Dec 4, 2014 · 5 comments

Comments

@ebioman
Copy link

ebioman commented Dec 4, 2014

Hi
I got some compiling problems with this version which I did not experience earlier. I am on a CentOS based system and with Hdf >= 1.8 , g++ (GCC) 4.9.1.
There quite a few warnings regarding some pointers in hdf libraries but which causes then exit errors is:

g++ -g -O3  -Wno-div-by-zero -I ../common -I /software/include/  -fpermissive -static  -I ../common -I /software/include/  bin/GuidedAlign.o  -o bin/guidedalign -L/software/lib64/ -lhdf5_cpp -lhdf5 -lz -lpthread
/software/lib64//libhdf5.a(H5PL.o): In function `H5PL__open':
(.text+0xb08): undefined reference to `dlopen'
/software/lib64//libhdf5.a(H5PL.o): In function `H5PL__open':
(.text+0xb1a): undefined reference to `dlerror'
/software/lib64//libhdf5.a(H5PL.o): In function `H5PL__open':
(.text+0xb3a): undefined reference to `dlsym'
/software/lib64//libhdf5.a(H5PL.o): In function `H5PL__search_table':
(.text+0xeef): undefined reference to `dlsym'
/software/lib64//libhdf5.a(H5PL.o): In function `H5PL__close':
(.text+0x1004): undefined reference to `dlclose'
collect2: error: ld returned 1 exit status

Any idea how I can fix that ?

@mchaisso
Copy link
Owner

mchaisso commented Dec 4, 2014

I pushed a fix that explicitly loads dl for hdf linked code, and actually just removed the program that was causing this particular error. I don't have access to a CentOS box to test on, but let me know if this works.

-mark

@ebioman
Copy link
Author

ebioman commented Dec 5, 2014

Thanks for this quick reply!
It does indeed fix many of these errors but for 2 they are still left:

Still, it compiled blasr and I gave it a try but obviously it did not compile correctly and I got errors:

*** Error in `../../../blasr-master/alignment/bin/blasr': double free or corruption (!prev):     0x0000000003b52fb0 ***
======= Backtrace: =========
[0x85a513]
[0x861aa8]
[0x866687]
[0x495d5b]
[0x497d50]
[0x40ceb6]
[0x83eb13]
[0x4118ac]
======= Memory map: ========
00400000-00bcf000 r-xp 00000000 00:1d 2905236918                             /scratch/ul/monthly/eschmid/blasr-master/alignment/bin/blasr
00dcf000-00ddc000 rw-p 007cf000 00:1d 2905236918                             /scratch/ul/monthly/eschmid/blasr-master/alignment/bin/blasr
00ddc000-00df9000 rw-p 00000000 00:00 0 
0109c000-03fbe000 rw-p 00000000 00:00 0                                  [heap]
7fddc8000000-7fddc8021000 rw-p 00000000 00:00 0 
7fddc8021000-7fddcc000000 ---p 00000000 00:00 0 
7fddcc000000-7fddcc021000 rw-p 00000000 00:00 0 

and so on....

Here are some of the compilation warnings and errors:

In file included from ../common/data/hdf/HDFGroup.h:8:0,
             from ../common/data/hdf/DatasetCollection.h:8,
             from ../common/data/hdf/HDFBasReader.h:8,
             from FilterBySubreadAgreement.cpp:1:
../common/data/hdf/HDFAttributable.h: In member function ‘void     HDFAttributable::StoreAttributeNames(H5::H5Object&, std::vector<std::basic_string<char> >&)’:
../common/data/hdf/HDFAttributable.h:26:46: warning: invalid conversion from ‘void (*)    (H5::H5Object&, std::string, void*) {aka void (*)(H5::H5Object&, std::basic_string<char>, void*)}’ to     ‘H5::attr_operator_t {aka void (*)(H5::H5Location&, std::basic_string<char>, void*)}’ [-fpermissive]
               bounds, (void*) &attributeNames);
                                          ^
In file included from /software/include/H5Cpp.h:25:0,
             from ../common/data/hdf/HDFGroup.h:7,
             from ../common/data/hdf/DatasetCollection.h:8,
             from ../common/data/hdf/HDFBasReader.h:8,
             from FilterBySubreadAgreement.cpp:1:
/software/include/H5Location.h:85:6: note: initializing argument 1 of ‘int     H5::H5Location::iterateAttrs(H5::attr_operator_t, unsigned int*, void*)’
  int iterateAttrs(attr_operator_t user_op, unsigned* idx = NULL, void* op_data = NULL);
  ^
/software/lib64//libhdf5.a(H5PL.o): In function `H5PL__open':
(.text+0xb08): undefined reference to `dlopen'
/software/lib64//libhdf5.a(H5PL.o): In function `H5PL__open':
(.text+0xb1a): undefined reference to `dlerror'
/software/lib64//libhdf5.a(H5PL.o): In function `H5PL__open':
(.text+0xb3a): undefined reference to `dlsym'
/software/lib64//libhdf5.a(H5PL.o): In function `H5PL__search_table':
(.text+0xeef): undefined reference to `dlsym'
/software/lib64//libhdf5.a(H5PL.o): In function `H5PL__close':
(.text+0x1004): undefined reference to `dlclose'
collect2: error: ld returned 1 exit status
make[1]: *** [bin/filterBySubreadAgreement] Error 1
Makefile:148: warning: overriding commands for target `clean'
../make.rules:25: warning: ignoring old commands for target `clean'
In file included from ../common/data/hdf/HDFGroup.h:8:0,
             from ../common/data/hdf/HDFAtom.h:12,
             from ../common/data/hdf/HDFCmpFile.h:15,
             from LoadPulses.cpp:3:
../common/data/hdf/HDFAttributable.h: In member function ‘void     HDFAttributable::StoreAttributeNames(H5::H5Object&, std::vector<std::basic_string<char> >&)’:
../common/data/hdf/HDFAttributable.h:26:46: warning: invalid conversion from ‘void (*)    (H5::H5Object&, std::string, void*) {aka void (*)(H5::H5Object&, std::basic_string<char>, void*)}’ to     ‘H5::attr_operator_t {aka void (*)(H5::H5Location&, std::basic_string<char>, void*)}’ [-fpermissive]
               bounds, (void*) &attributeNames);


In file included from /software/include/H5Cpp.h:25:0,
             from ../common/data/hdf/HDFGroup.h:7,
             from ../common/data/hdf/DatasetCollection.h:8,
             from ../common/data/hdf/HDFBasReader.h:8,
             from ../common/files/ReaderAgglomerate.h:13,
             from StoreQualityByContext.cpp:1:
/software/include/H5Location.h:85:6: note: initializing argument 1 of ‘int     H5::H5Location::iterateAttrs(H5::attr_operator_t, unsigned int*, void*)’
  int iterateAttrs(attr_operator_t user_op, unsigned* idx = NULL, void* op_data = NULL);
      ^
/software/lib64//libhdf5.a(H5PL.o): In function `H5PL__open':
(.text+0xb08): undefined reference to `dlopen'
/software/lib64//libhdf5.a(H5PL.o): In function `H5PL__open':
(.text+0xb1a): undefined reference to `dlerror'
/software/lib64//libhdf5.a(H5PL.o): In function `H5PL__open':
(.text+0xb3a): undefined reference to `dlsym'
/software/lib64//libhdf5.a(H5PL.o): In function `H5PL__search_table':
(.text+0xeef): undefined reference to `dlsym'
/software/lib64//libhdf5.a(H5PL.o): In function `H5PL__close':
(.text+0x1004): undefined reference to `dlclose'
collect2: error: ld returned 1 exit status
make[1]: *** [bin/storeQualityByContext] Error 1
Makefile:80: warning: overriding commands for target `clean'

@mchaisso
Copy link
Owner

mchaisso commented Dec 5, 2014

Ok, the compilation should be fixed for the whole tree. The memory problem above is a bigger issue that I do not see on my test data. Do you have a small input fastq and the reference to share? We can take this offline at mchaisso@uw.edu to set up data transfer.

@ebioman
Copy link
Author

ebioman commented Dec 12, 2014

Hi
Sorry for the late reply, I was busy. Indeed the previous errors are fixed now - thanks!
Now only warnings are left and it compiles otherwise.
I still receive though sudden crashes and segmentation faults. I believe that the problem stems from
the compilation with the new g++ (GCC) 4.9.1. It is much more greedy concerning variables which are not well defined. This was e.g. as well the case for the tools from Gene Meyers (DAZZLER) prior he cleaned it. Essentially if a variable is not correctly defined it will pick up a random one from the memory which leads randomly to segmentation faults. Old compilers are more forgiving since they assign 0 by default.
Therefore I receive many warnings that variables are not correctly defined and there are many voids.
Please correct me if this is all bullshit ;)
Cheers

@mchaisso
Copy link
Owner

Thanks for the update. I'll see if I can upgrade gcc here and test this out to fix this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants