Print system and compile info to a file.
421{
422 if (!fp)
423 return false;
424
425 struct utsname uts;
426 bool tty = isatty(fileno(fp));
427 const char *fmt = "%s\n";
428
429 if (tty)
430 fmt = "\033[1;36m%s\033[0m\n";
431
433 fprintf(fp,
"%s\n",
_(
Notice));
434
435 uname(&uts);
436
437#ifdef SCO
438 fprintf(fp, "System: SCO %s", uts.release);
439#else
440 fprintf(fp, "System: %s %s", uts.sysname, uts.release);
441#endif
442
443 fprintf(fp, " (%s)", uts.machine);
444
445#ifdef NCURSES_VERSION
446 fprintf(fp, "\nncurses: %s (compiled with %s.%d)", curses_version(),
447 NCURSES_VERSION, NCURSES_VERSION_PATCH);
448#else
449 fprintf(fp, "\nncurses: %s", curses_version());
450#endif
451
452#ifdef _LIBICONV_VERSION
453 fprintf(fp, "\nlibiconv: %d.%d", _LIBICONV_VERSION >> 8, _LIBICONV_VERSION & 0xff);
454#endif
455
456#ifdef HAVE_LIBIDN
458#endif
459
460#ifdef CRYPT_BACKEND_GPGME
462#endif
463
464#ifdef USE_SSL_OPENSSL
465#ifdef LIBRESSL_VERSION_TEXT
466 fprintf(fp, "\nLibreSSL: %s", LIBRESSL_VERSION_TEXT);
467#endif
468#ifdef OPENSSL_VERSION_TEXT
469 fprintf(fp, "\nOpenSSL: %s", OPENSSL_VERSION_TEXT);
470#endif
471#endif
472
473#ifdef USE_SSL_GNUTLS
474 fprintf(fp, "\nGnuTLS: %s", GNUTLS_VERSION);
475#endif
476
477#ifdef HAVE_NOTMUCH
478 fprintf(fp, "\nlibnotmuch: %d.%d.%d", LIBNOTMUCH_MAJOR_VERSION,
479 LIBNOTMUCH_MINOR_VERSION, LIBNOTMUCH_MICRO_VERSION);
480#endif
481
482#ifdef HAVE_PCRE2
483 {
484 char version[24] = { 0 };
485 pcre2_config(PCRE2_CONFIG_VERSION, version);
486 fprintf(fp, "\nPCRE2: %s", version);
487 }
488#endif
489
490#ifdef USE_HCACHE
492 fprintf(fp, "\nstorage: %s", backends);
494#ifdef USE_HCACHE_COMPRESSION
496 fprintf(fp, "\ncompression: %s", backends);
498#endif
499#endif
500
503
505 fprintf(fp,
"\nCompilation CFLAGS: %s\n", (
char *)
cc_cflags);
506
507 fprintf(fp,
"\n%s\n",
_(
"Default options:"));
509
510 fprintf(fp,
"\n%s\n",
_(
"Compile options:"));
512
514 {
515 fprintf(fp,
"\n%s\n",
_(
"Devel options:"));
517 }
518
519 fprintf(fp, "\n");
520#ifdef DOMAIN
521 fprintf(fp, "DOMAIN=\"%s\"\n", DOMAIN);
522#endif
523#ifdef ISPELL
524 fprintf(fp,
"ISPELL=\"%s\"\n",
ISPELL);
525#endif
526 fprintf(fp, "MAILPATH=\"%s\"\n", MAILPATH);
527#ifdef MIXMASTER
528 fprintf(fp, "MIXMASTER=\"%s\"\n", MIXMASTER);
529#endif
530 fprintf(fp, "PKGDATADIR=\"%s\"\n", PKGDATADIR);
531 fprintf(fp, "SENDMAIL=\"%s\"\n", SENDMAIL);
532 fprintf(fp, "SYSCONFDIR=\"%s\"\n", SYSCONFDIR);
533
534 fprintf(fp, "\n");
536
537 fflush(fp);
538 return !ferror(fp);
539}
const char * compress_list(void)
Get a list of compression backend names.
const char * mutt_gpgme_print_version(void)
Get version of GPGME.
const char * mutt_idna_print_version(void)
Create an IDN version string.
static void print_compile_options(const struct CompileOptions *co, FILE *fp)
Print a list of enabled/disabled features.
static const char * ReachingUs
CLI Version: How to reach the NeoMutt Team.
const char * mutt_make_version(void)
Generate the NeoMutt version string.
static const struct CompileOptions CompOpts[]
Compile options strings for neomutt -v output.
unsigned char configure_options[]
static const struct CompileOptions DebugOpts[]
Debug options strings for neomutt -v output.
unsigned char cc_cflags[]
static char * rstrip_in_place(char *s)
Strip a trailing carriage return.
static const char * Notice
CLI Version: Warranty notice.
const char * store_backend_list(void)
Get a list of backend names.
static const struct CompileOptions CompOptsDefault[]
Default options strings for neomutt -v output.