I was able to build Orthanc 0.5.2 using static build..
Unfortunately, I get an exception after the HTTP server starts:
"..terminated after throwing exception of type Orthanc::OrthancException."
How to debug?
The first thing to try is to add the "--verbose" and the "--trace" options at the command line to obtain more information about the problem:
Make sure your configuration file (if any) is well-formatted: Just try to start Orthanc without any configuration file.
Make sure the default TCP ports (8042 and 4242) are not already used by another software:
# netstat -tulpn | grep :8042
# netstat -tulpn | grep :4242
If this does not help, maybe you have moved the Orthanc binary from the build directory to another place in your filesystem (e.g. "/usr/bin"). If this is the case, you have to compile Orthanc with the STANDALONE_BUILD option:
# cmake -DSTATIC_BUILD=ON -DSTANDALONE_BUILD=ON -DCMAKE_BUILD_TYPE=Debug
If it is not sufficient, you will have to use the three most useful Linux debugging tools: gdb, valgrind and possibly strace:
# gdb --args ./Orthanc --verbose
=> enter "catch t", then "run", and finally "bt" when the exception occurs to inspect the stack.
# valgrind ./Orthanc --verbose
# strace ./Orthanc
Make sure that the option "-DCMAKE_BUILD_TYPE=Debug" was used in CMake to obtain detailed debug information. Please send me these reports if cannot figure what happens by yourself.
HTH,
Sébastien-