148    wxString eol = aHtml ? 
"<br>" : 
"\n";
 
  151    wxString indent4 = aHtml ? 
"    " : 
"\t";
 
  153#define ON "ON" << eol 
  154#define OFF "OFF" << eol 
  166    aMsg << 
"Application: " << aTitle;
 
  167    aMsg << 
" " << wxGetCpuArchitectureName() << 
" on " << wxGetNativeCpuArchitectureName();
 
  172    aMsg << 
"Version: " << version << eol << eol;
 
  173    aMsg << 
"Libraries:" << eol;
 
  175    aMsg << indent4 << wxGetLibraryVersionInfo().GetVersionString() << eol;
 
  186    wxString osDescription;
 
  189    osDescription = wxGetLinuxDistributionInfo().Description;
 
  195    if( osDescription.empty() )
 
  196        osDescription = wxGetOsDescription();
 
  203            << osDescription << 
", " 
  205            << wxPlatformInfo().GetEndiannessName() << 
", " 
  206            << wxPlatformInfo().GetPortIdName();
 
  210    if( wxTheApp && wxTheApp->IsGUI() )
 
  214        switch( wxGetDisplayInfo().type )
 
  216        case wxDisplayX11:     aMsg << 
"X11"; 
break;
 
  217        case wxDisplayWayland: aMsg << 
"Wayland"; 
break;
 
  218        case wxDisplayNone:    aMsg << 
"None"; 
break;
 
  219        default:               aMsg << 
"Unknown";
 
  223    aMsg << 
", " << wxGetenv( 
"XDG_SESSION_DESKTOP" )
 
  224         << 
", " << wxGetenv( 
"XDG_SESSION_TYPE" );
 
  237        aMsg << 
"Build Info:" << eol;
 
  241    aMsg << indent4 << 
"wxWidgets: " << wxVERSION_NUM_DOT_STRING << 
" (";
 
  242    aMsg << __WX_BO_UNICODE __WX_BO_STL;
 
  245#if wxCHECK_VERSION( 3, 3, 0 ) 
  246    aMsg << __WX_BO_WXWIN_COMPAT_3_0 
")";
 
  248    aMsg << __WX_BO_WXWIN_COMPAT_2_8 
")";
 
  258        major = wxPlatformInfo().GetToolkitMajorVersion();
 
  259        minor = wxPlatformInfo().GetToolkitMinorVersion();
 
  260        aMsg << 
" GTK+ " << major << 
"." << minor;
 
  266    aMsg << indent4 << 
"Boost: " << ( BOOST_VERSION / 100000 ) << wxT( 
"." )
 
  267         << ( BOOST_VERSION / 100 % 1000 ) << wxT( 
"." )
 
  268         << ( BOOST_VERSION % 100 ) << eol;
 
  270    aMsg << indent4 << 
"OCC: " << OCC_VERSION_COMPLETE << eol;
 
  273#if defined( NGSPICE_BUILD_VERSION ) 
  274    aMsg << indent4 << 
"ngspice: " << NGSPICE_BUILD_VERSION << eol;
 
  275#elif defined( NGSPICE_HAVE_CONFIG_H ) 
  276    #undef HAVE_STRNCASECMP      
  277    #include <ngspice/config.h> 
  279#elif defined( NGSPICE_PACKAGE_VERSION ) 
  280    aMsg << indent4 << 
"ngspice: " << NGSPICE_PACKAGE_VERSION << eol;
 
  282    aMsg << indent4 << 
"ngspice: " << 
"unknown" << eol;
 
  285    aMsg << indent4 << 
"Compiler: ";
 
  286#if defined(__clang__) 
  287    aMsg << 
"Clang " << __clang_major__ << 
"." << __clang_minor__ << 
"." << __clang_patchlevel__;
 
  288#elif defined(__GNUG__) 
  289    aMsg << 
"GCC " << __GNUC__ << 
"." << __GNUC_MINOR__ << 
"." << __GNUC_PATCHLEVEL__;
 
  290#elif defined(_MSC_VER) 
  291    aMsg << 
"Visual C++ " << _MSC_VER;
 
  292#elif defined(__INTEL_COMPILER) 
  293    aMsg << 
"Intel C++ " << __INTEL_COMPILER;
 
  295    aMsg << 
"Other Compiler ";
 
  298#if defined(__GXX_ABI_VERSION) 
  299    aMsg << 
" with C++ ABI " << __GXX_ABI_VERSION << eol;
 
  301    aMsg << 
" without C++ ABI" << eol;
 
  305#if defined( KICAD_USE_EGL ) || ! defined( NDEBUG ) 
  307    aMsg << 
"Build settings:" << eol;
 
  311    aMsg << indent4 << 
"KICAD_USE_EGL=" << 
ON;
 
  315    aMsg << indent4 << 
"KICAD_IPC_API=" << 
ON;
 
  317    aMsg << indent4 << 
"KICAD_IPC_API=" << 
OFF;
 
  320    aMsg << indent4 << 
"KICAD_USE_PCH=";
 
  328    aMsg << indent4 << 
"KICAD_STDLIB_DEBUG=";
 
  329#ifdef KICAD_STDLIB_DEBUG 
  333    aMsg << indent4 << 
"KICAD_STDLIB_LIGHT_DEBUG=";
 
  334#ifdef KICAD_STDLIB_LIGHT_DEBUG 
  341    aMsg << indent4 << 
"KICAD_SANITIZE_ADDRESS=";
 
  342#ifdef KICAD_SANITIZE_ADDRESS 
  348    aMsg << indent4 << 
"KICAD_SANITIZE_THREADS=";
 
  349#ifdef KICAD_SANITIZE_THREADS 
  356    wxLocale* locale = wxGetLocale();
 
  361        aMsg << 
"Locale: " << eol;
 
  362        aMsg << indent4 << 
"Lang: " << locale->GetCanonicalName() << eol;
 
  363        aMsg << indent4 << 
"Enc: " << locale->GetSystemEncodingName() << eol;
 
  364        aMsg << indent4 << 
"Num: " 
  365             << wxString::Format( 
"%d%s%.1f", 1,
 
  366                                  locale->GetInfo( wxLocaleInfo::wxLOCALE_THOUSANDS_SEP ), 234.5 )
 
  369        wxString testStr( wxS( 
"кΩ丈" ) );
 
  370        wxString expectedUtf8Hex( wxS( 
"D0BACEA9E4B888" ) );
 
  371        wxString sysHex, utf8Hex;
 
  373            const char* asChar = testStr.c_str().AsChar();
 
  374            size_t      length = strlen( asChar );
 
  376            for( 
size_t i = 0; i < length; i++ )
 
  377                sysHex << wxString::Format( 
"%02X", (
unsigned int) (uint8_t) asChar[i] );
 
  380            const char* asChar = testStr.utf8_str().data();
 
  381            size_t      length = strlen( asChar );
 
  383            for( 
size_t i = 0; i < length; i++ )
 
  384                utf8Hex << wxString::Format( 
"%02X", (
unsigned int) (uint8_t) asChar[i] );
 
  387        aMsg << indent4 << 
"Encoded " << testStr << 
": " << sysHex << 
" (sys), " << utf8Hex
 
  390        wxASSERT_MSG( utf8Hex == expectedUtf8Hex,
 
  391                      wxString::Format( 
"utf8_str string %s encoding bad result: %s, expected " 
  392                                        "%s, system enc %s, lang %s",
 
  393                                        testStr, utf8Hex, expectedUtf8Hex,
 
  394                                        locale->GetSystemEncodingName(),
 
  395                                        locale->GetCanonicalName() ) );