Jean-Marc Lasgouttes <[EMAIL PROTECTED]> writes: >>>>>> "Jean-Marc" == Jean-Marc Lasgouttes <[EMAIL PROTECTED]> writes: > | Jean-Marc> I can run both lyx-qt and lyx-xforms, but as soon as I | Jean-Marc> create a new file, I get: > | OK, here is more information on the problem: it seems that | lyxerr::rdbuf is set to 0: | (gdb) p lyxerr.rdbuf() | $7 = (struct basic_streambuf<char,_STL::char_traits<char> > *) 0x0 > | This is probably due to this line in debug.C: | LyXErr lyxerr(std::cerr.rdbuf()); | and to the fact that cerr is defined by STLport as | // Definitions of the eight global I/O objects that are declared in | // <iostream>. For VC++ we use the init_seg pragma to put the global I/O | // objects into an intitialization segement that will not | // be executed. We then explicitly invoke the constructors | // with placement new in ios_base::_S_initialize() | [...] | _STLP_DECLSPEC ostream cerr(0); > | The streambuf is set later in some mysterious ios_base::_S_initialize. > | I am not sure where this last method is invoked, but this smells like | faulty ordering of constructors.
Hmm... it seems that STLport is broken. Ok, try this: remove the rdbuf initialization from debug.C and put it in main.C instead: debug.C LyXErr lyxerr; // or perhaps lyxerr(0); main.c #inlucde "debug.h" lyxerr.rdbuf(std::cerr.rdbuf()); -- Lgb