Difference between revisions of "LibStatGen Troubleshooting"

From Genome Analysis Wiki
Jump to navigationJump to search
 
(6 intermediate revisions by the same user not shown)
Line 1: Line 1:
=== Possible Compile Errors ===
+
= Possible Compile Errors =
 +
 
 +
'''If compilation fails due to warnings being treated as errors, please contact us so we can fix the warnings. As a work-around to get it to compile, you can disable the treatment of warnings as errors by editing libStatGen/general/Makefile to remove -Werror.'''
  
 
The following are a list of compile errors that have been encountered with recommendations on what they mean and how to fix them.
 
The following are a list of compile errors that have been encountered with recommendations on what they mean and how to fix them.
  
==== Compile Error on first time building ====
+
== GenomeSequence.cpp:161: error: explicit instantiation... ==
Record the error.
+
If you are compiling on OSX and encounter this error:
 +
;GenomeSequence.cpp<nowiki>:</nowiki> In instantiation of ‘std<nowiki>::</nowiki>basic_ostream<_CharT, _Traits>& std<nowiki>::</nowiki>operator<<(std<nowiki>::</nowiki>basic_ostream<_CharT, _Traits>&, const std<nowiki>::</nowiki>basic_string<_CharT, _Traits, _Alloc>&) [with _CharT = char, _Traits = std<nowiki>::</nowiki>char_traits<char>, _Alloc = std<nowiki>::</nowiki>allocator<char>]’<nowiki>:</nowiki><br />GenomeSequence.cpp<nowiki>:</nowiki>161<nowiki>:</nowiki>  instantiated from here<br />GenomeSequence.cpp<nowiki>:</nowiki>161<nowiki>:</nowiki> error<nowiki>:</nowiki> explicit instantiation of ‘std<nowiki>::</nowiki>basic_ostream<_CharT, _Traits>& std<nowiki>::</nowiki>operator<<(std<nowiki>::</nowiki>basic_ostream<_CharT, _Traits>&, const std<nowiki>::</nowiki>basic_string<_CharT, _Traits, _Alloc>&) [with _CharT = char, _Traits = std<nowiki>::</nowiki>char_traits<char>, _Alloc = std<nowiki>::</nowiki>allocator<char>]’ but no definition available
 +
: Try compiling with:
 +
make USER_COMPILE_VARS=-mmacosx-version-min=10.8
 +
 
  
Try to recompile and see if that fixes the problemIf it does fix the compile error, let me know what the original error was so I can fix the dependency so it compiles in the correct order.
+
== error: Sam[filename].h: No such file or directory or "'Sam[classname]' has not been declared" ==
 +
This error and other, similar errors with "Sam....h: No such file or directory" or "'Sam...' has not been declared" typically means that the library build failedCheck for a previous error in your compile.
  
==== GenomeSequence.h:30:57: error: openssl/md5.h: No such file or directory ====
+
A successful compile of the library will publish SamFile.h and all the other header files from the library into libStatGen/include.  If one of the programs within the statgen repository fails to compile with one of these errors, then the library did not successfully publish the header files and did not successfully build.
  
GenomeSequence requires md5 logic and makes calls to methods defined in md5.h which is found in the openssl library.
 
  
The header files are included in the development version of the package.
+
== InputFile.h (or any other library file): No such file or directory ==
 +
Errors like the following:
 +
<pre>
 +
FastQFile.cpp:20:23: InputFile.h: No such file or directory
 +
In file included from FastQFile.cpp:21:
 +
FastQFile.h:23:26: StringBasics.h: No such file or directory
 +
</pre>
 +
Tend to occur if the library directory containing the file has not yet been compiled.  Try recompiling the entire library by typing make in libStatGen.
  
The package may be called something like: openssl-devel or libssl-dev (on ubuntu).
 
  
==== error: Sam[filename].h: No such file or directory or "'Sam[classname]' has not been declared" ====
+
== Compile Error on first time building ==
This error and other, similar errors with "Sam....h: No such file or directory" or "'Sam...' has not been declared" typically means that the library build failed.  Check for a previous error in your compile.
+
Record the error.
  
A successful compile of the library will publish SamFile.h and all the other header files from the library into samtools/lib/include.  If one of the programs within the statgen repository fails to compile with one of these errors, then the library did not successfully publish the header files and did not successfully byild.
+
Try to recompile and see if that fixes the problem.  If it does fix the compile error, let me know what the original error was so I can fix the dependency so it compiles in the correct order.
  
==== make test produces messages like "ERROR: Missing required tag: LN." and "Can't modify the key tag, ID from pid to pid1" ====
+
'''NOTE: In the latest version, this should be fixed.'''
These messages are currently expected. Some of the tests run by 'make test' test error conditions to make sure they are handled properly.  These error conditions print messages to the screen about the errors.  These messages are expected and are not a failure of 'make test'.
 

Latest revision as of 00:20, 13 November 2017

Possible Compile Errors

If compilation fails due to warnings being treated as errors, please contact us so we can fix the warnings. As a work-around to get it to compile, you can disable the treatment of warnings as errors by editing libStatGen/general/Makefile to remove -Werror.

The following are a list of compile errors that have been encountered with recommendations on what they mean and how to fix them.

GenomeSequence.cpp:161: error: explicit instantiation...

If you are compiling on OSX and encounter this error:

GenomeSequence.cpp: In instantiation of ‘std::basic_ostream<_CharT, _Traits>& std::operator<<(std::basic_ostream<_CharT, _Traits>&, const std::basic_string<_CharT, _Traits, _Alloc>&) [with _CharT = char, _Traits = std::char_traits<char>, _Alloc = std::allocator<char>]’:
GenomeSequence.cpp:161: instantiated from here
GenomeSequence.cpp:161: error: explicit instantiation of ‘std::basic_ostream<_CharT, _Traits>& std::operator<<(std::basic_ostream<_CharT, _Traits>&, const std::basic_string<_CharT, _Traits, _Alloc>&) [with _CharT = char, _Traits = std::char_traits<char>, _Alloc = std::allocator<char>]’ but no definition available
Try compiling with:
make USER_COMPILE_VARS=-mmacosx-version-min=10.8


error: Sam[filename].h: No such file or directory or "'Sam[classname]' has not been declared"

This error and other, similar errors with "Sam....h: No such file or directory" or "'Sam...' has not been declared" typically means that the library build failed. Check for a previous error in your compile.

A successful compile of the library will publish SamFile.h and all the other header files from the library into libStatGen/include. If one of the programs within the statgen repository fails to compile with one of these errors, then the library did not successfully publish the header files and did not successfully build.


InputFile.h (or any other library file): No such file or directory

Errors like the following:

FastQFile.cpp:20:23: InputFile.h: No such file or directory
In file included from FastQFile.cpp:21:
FastQFile.h:23:26: StringBasics.h: No such file or directory

Tend to occur if the library directory containing the file has not yet been compiled. Try recompiling the entire library by typing make in libStatGen.


Compile Error on first time building

Record the error.

Try to recompile and see if that fixes the problem. If it does fix the compile error, let me know what the original error was so I can fix the dependency so it compiles in the correct order.

NOTE: In the latest version, this should be fixed.