28 #include <boost/version.hpp> 39 #if defined( KICAD_USE_OCC ) 40 #include <Standard_Version.hxx> 43 #if defined( KICAD_SPICE ) 44 #include <ngspice/sharedspice.h> 50 #include <kicad_build_version.h> 55 wxPlatformInfo platform;
57 #if 0 && wxCHECK_VERSION( 3, 1, 5 ) 58 return platform.GetBitnessName();
60 return platform.GetArchName();
74 wxString msg =
wxString::Format( wxT(
"%s %s" ), wxT( __DATE__ ), wxT( __TIME__ ) );
81 wxString msg =
wxString::Format( wxT(
"%s" ), wxT( KICAD_SEMANTIC_VERSION ) );
88 wxString msg =
wxString::Format( wxT(
"%s" ), wxT( KICAD_MAJOR_MINOR_VERSION ) );
98 wxString eol = aHtml ? wxT(
"<br>" ) : wxT(
"\n" );
101 wxString indent4 = aHtml ? wxT(
" " ) : wxT(
"\t" );
103 #define ON wxT( "ON" ) << eol 104 #define OFF wxT( "OFF" ) << eol 112 << wxT(
", release" )
116 wxPlatformInfo platform;
117 aMsg << wxT(
"Application: " ) << aTitle;
119 #if defined( KICAD_BUILD_ARCH_X64 ) 120 aMsg << wxT(
" (64-bit)" );
121 #elif defined( KICAD_BUILD_ARCH_X86 ) 122 aMsg << wxT(
" (32-bit)" );
123 #elif defined( KICAD_BUILD_ARCH_ARM ) 124 aMsg << wxT(
" (ARM 32-bit)" );
125 #elif defined( KICAD_BUILD_ARCH_ARM64 ) 126 aMsg << wxT(
" (ARM 64-bit)" );
132 aMsg << wxT(
"Version: " ) << version << eol << eol;
133 aMsg << wxT(
"Libraries:" ) << eol;
135 aMsg << indent4 << wxGetLibraryVersionInfo().GetVersionString() << eol;
142 aMsg << wxT(
"Platform: " ) << wxGetOsDescription() << wxT(
", " )
144 << platform.GetEndiannessName() << wxT(
", " )
145 << platform.GetPortIdName();
148 aMsg << wxT(
", " ) << wxGetenv( wxT(
"XDG_SESSION_DESKTOP" ) )
149 << wxT(
", " ) << wxGetenv( wxT(
"XDG_SESSION_TYPE" ) );
156 aMsg << wxT(
"Build Info:" ) << eol;
157 aMsg << indent4 << wxT(
"Date: " ) <<
GetBuildDate() << eol;
160 aMsg << indent4 << wxT(
"wxWidgets: " ) << wxVERSION_NUM_DOT_STRING << wxT(
" (" );
161 aMsg << __WX_BO_UNICODE __WX_BO_STL __WX_BO_WXWIN_COMPAT_2_8 wxT(
")" );
167 major = wxPlatformInfo().Get().GetToolkitMajorVersion();
168 minor = wxPlatformInfo().Get().GetToolkitMinorVersion();
169 aMsg << wxT(
" GTK+ " ) << major << wxT(
"." ) << minor;
174 aMsg << indent4 << wxT(
"Boost: " ) << ( BOOST_VERSION / 100000 ) << wxT(
"." )
175 << ( BOOST_VERSION / 100 % 1000 ) << wxT(
"." )
176 << ( BOOST_VERSION % 100 ) << eol;
179 aMsg << indent4 << wxT(
"OCC: " ) << OCC_VERSION_COMPLETE << eol;
184 #if defined( KICAD_SPICE ) 185 #if defined( NGSPICE_BUILD_VERSION ) 186 aMsg << indent4 << wxT(
"ngspice: " ) << NGSPICE_BUILD_VERSION << eol;
187 #elif defined( NGSPICE_HAVE_CONFIG_H ) 188 #undef HAVE_STRNCASECMP 189 #include <ngspice/config.h> 191 #elif defined( NGSPICE_PACKAGE_VERSION ) 192 aMsg << indent4 << wxT(
"ngspice: " ) << NGSPICE_PACKAGE_VERSION << eol;
194 aMsg << indent4 << wxT(
"ngspice: " ) << wxT(
"unknown" ) << eol;
198 aMsg << indent4 << wxT(
"Compiler: " );
199 #if defined(__clang__) 200 aMsg << wxT(
"Clang " ) << __clang_major__ << wxT(
"." ) << __clang_minor__ << wxT(
"." ) << __clang_patchlevel__;
201 #elif defined(__GNUG__) 202 aMsg << wxT(
"GCC " ) << __GNUC__ << wxT(
"." ) << __GNUC_MINOR__ << wxT(
"." ) << __GNUC_PATCHLEVEL__;
203 #elif defined(_MSC_VER) 204 aMsg << wxT(
"Visual C++ " ) << _MSC_VER;
205 #elif defined(__INTEL_COMPILER) 206 aMsg << wxT(
"Intel C++ " ) << __INTEL_COMPILER;
208 aMsg << wxT(
"Other Compiler " );
211 #if defined(__GXX_ABI_VERSION) 212 aMsg << wxT(
" with C++ ABI " ) << __GXX_ABI_VERSION << eol;
214 aMsg << wxT(
" without C++ ABI" ) << eol;
220 aMsg << wxT(
"Build settings:" ) << eol;
223 aMsg << indent4 << wxT(
"KICAD_USE_OCC=" ) <<
ON;
227 aMsg << indent4 << wxT(
"KICAD_USE_EGL=" ) <<
ON;
230 aMsg << indent4 << wxT(
"KICAD_SPICE=" );
238 aMsg << indent4 << wxT(
"KICAD_STDLIB_DEBUG=" );
239 #ifdef KICAD_STDLIB_DEBUG 243 aMsg << indent4 << wxT(
"KICAD_STDLIB_LIGHT_DEBUG=" );
244 #ifdef KICAD_STDLIB_LIGHT_DEBUG 251 aMsg << indent4 << wxT(
"KICAD_SANITIZE_ADDRESS=" );
252 #ifdef KICAD_SANITIZE_ADDRESS 258 aMsg << indent4 << wxT(
"KICAD_SANITIZE_THREADS=" );
259 #ifdef KICAD_SANITIZE_THREADS
< Package version metadata Package metadata
wxString GetVersionInfoData(const wxString &aTitle, bool aHtml, bool aBrief)
Create a version info string for bug reports and the about dialog.
wxString GetMajorMinorVersion()
Get only the major and minor version in a string major.minor.
std::string GetCurlLibVersion()
wxString GetBuildVersion()
Get the full KiCad version string.
wxString GetPlatformGetBitnessName()
void Format(OUTPUTFORMATTER *out, int aNestLevel, int aCtl, const CPTREE &aTree)
Output a PTREE into s-expression format via an OUTPUTFORMATTER derivative.
wxString GetBuildDate()
Get the build date as a string.
std::string GetKicadCurlVersion()
wxString GetSemanticVersion()
Get the semantic version string for KiCad defined inside the KiCadVersion.cmake file in the variable ...