add CRASHREPORT directly to browser

add CRASHREPORT for Windows
add ^P info to report (via DUMPLOG)

new options: crash_email, crash_name, crash_urlmax
new game command: #bugreport
new config option: CRASHREPORT_EXEC_NOSTDERR
new command line option: --bidshow

deleted helper scripts:
    NetHackCrashReport.Javascript
    nhcrashreport.lua

misc:
    update CRASHREPORTURL (will need to be updated before release)
    update bitrot in winchain
    winchain for Windows
    add missing synch_wait for NetHackW --showpaths
    add PANICTRACE (and CRASHREPORT) in mdlib.c:build_opts

missing:
    packaging (Windows needs the pdb file)
    no testing with MSVC command line build

port status:
    linux: working, but glibc's backtrace doesn't show static functions
    Windows VS: working.  pdb file is large - looking into options
    MacOS: working
    msdos: not supported
    VMS: not supported
    MSVC: planned, but not attempted
    MSYS2: working, but libbacktrace not showing symbols (yet?)
This commit is contained in:
nhkeni
2024-02-06 18:33:59 -05:00
parent cf3cbcf832
commit dbe5c98dca
37 changed files with 1001 additions and 315 deletions

View File

@@ -241,12 +241,33 @@
#ifndef CRASHREPORT
# ifdef MACOS
/* NB: This needs to be a full path unless it's in the playground. */
//#define CRASHREPORT "NetHackCrashReport.JavaScript"
# define CRASHREPORT "/usr/bin/open"
# endif
# ifdef __linux__
/* NB: This expects to find the nhlua binary as "./nhlua" */
//#define CRASHREPORT "nhcrashreport.lua"
# define CRASHREPORT "/usr/bin/xdg-open"
/* Define this if the terminal is filled with useless error messages
* when the browser launches. */
# define CRASHREPORT_EXEC_NOSTDERR
# endif
# ifdef WIN32
# define CRASHREPORT /* builtin helper */
# endif
#endif
#ifdef CRASHREPORT
# ifndef DUMPLOG
# define DUMPLOG // required to get ^P info
# endif
# ifdef MACOS
# define PANICTRACE
# endif
# ifdef __linux__
# define PANICTRACE
# endif
// This test isn't quite right: CNG is only available from Windows 2000 on.
// But we'll check that at runtime.
# ifdef WIN32
# define PANICTRACE
# endif
#endif