• Problems building on Debian 10 ("Buster") -- mozjs and data types

    From =?UTF-8?Q?Bj=C3=B6rn_Wiberg?=@VERT to alt.bbs.synchronet on Monday, July 29, 2019 03:02:49
    @MSGID: <82625e1c-161a-430a-91cb-17fbad7155b1@googlegroups.com>
    @TZ: fe5c
    From Newsgroup: alt.bbs.synchronet

    Hello,
    First of all, thanks for all the work on Synchronet! I'm a former SysOp (I used to run a BBS during the 1990s), and with a Linux machine at hand, I'm slowly beginning to set up my BBS "again".
    (I have also begun writing a bash script modem frontend which -- with the help of stty and socat -- hopefully should be able to transfer incoming modem connections to the Telnet parts of Synchronet, which I believe is a missing "part of the puzzle" at the moment?)
    Now on to my problem:
    I'm trying to build Synchronet 3.17b on a Debian 10 ("Buster") machine:
    mkdir -p ~/src/sbbs317b
    cd ~/src/sbbs317b
    wget 'http://cvs.synchro.net/cgi-bin/viewcvs.cgi/*checkout*/install/GNUmakefile'
    make install CVSTAG=sbbs317b NO_GTK=1 NO_X=1
    ...but I get compile errors regarding missing datatypes:
    c++ -o jsanalyze.o -c -fvisibility=hidden -DOSTYPE=\"Linux4.19\" -DOSARCH=Linux -DEXPORT_JS_API -D__STDC_LIMIT_MACROS -I. -I. -I./dist/include -I./dist/include/nsprpub -I/usr/include/nspr -I. -I./assembler -I./yarr -fPIC -fno-rtti -fno-exceptions -Wall -Wpointer-arith -Woverloaded-virtual -Wsynth -Wno-ctor-dtor-privacy -Wno-non-virtual-dtor -Wcast-align -Wno-invalid-offsetof -Wno-variadic-macros -Werror=return-type -pedantic -Wno-long-long -std=gnu++98 -fno-strict-aliasing -pthread -pipe -DNDEBUG -DTRIMMED -O3 -DUSE_SYSTEM_MALLOC=1 -DENABLE_ASSEMBLER=1 -DENABLE_JIT=1 -DMOZILLA_CLIENT -include ./js-confdefs.h -MD -MF .deps/jsanalyze.pp jsanalyze.cpp
    In file included from jstypes.h:58,
    from jsarena.h:50,
    from jsanalyze.h:44,
    from jsanalyze.cpp:40:
    js-config.h:85:27: error: ‘WORD’ does not name a type
    /* #undef JS_BYTES_PER_ */WORD
    ^~~~
    In file included from jstypes.h:338,
    from jsarena.h:50,
    from jsanalyze.h:44,
    from jsanalyze.cpp:40:
    jsinttypes.h:85:9: error: ‘uint8_t’ does not name a type; did you mean ‘u_int8_t’?
    typedef uint8_t JSUint8;
    ^~~~~~~
    u_int8_t
    In file included from jsarena.h:50,
    from jsanalyze.h:44,
    from jsanalyze.cpp:40:
    jstypes.h:408:9: error: ‘JSUint8’ does not name a type; did you mean ‘JSUintn’?
    typedef JSUint8 JSPackedBool;
    ^~~~~~~
    JSUintn
    In file included from jstypes.h:416,
    from jsarena.h:50,
    from jsanalyze.h:44,
    from jsanalyze.cpp:40:
    jsotypes.h:80:9: error: ‘JSUint8’ does not name a type; did you mean ‘JSUintn’?
    typedef JSUint8 uint8;
    ^~~~~~~
    JSUintn
    ...and so on. Checking ~/src/sbbs317b/3rdp/src/mozjs/js-1.8.5/js/src/config.status shows that the define "-DJS_HAVE_STDINT_H=1" is set, so it appears that it has found <stdint.h>, however this does not seem to help.
    Any ideas?
    I tried replacing the bundled mozjs library by installing the libmozjs-60-0 and libmozjs-60-dev packages, and specifying JSINCLUDE=/usr/include/mozjs-60/js JSLIB=libmozjs-60, but that made things worse in other aspects (smblib couldn't find the headers from "encode" and "hash", so it appears that this caused some other include path problems).
    I have checked the prerequisites and I think I've got the ones required. Perhaps mozjs 1.8.5 is simply "too old" for the up-to-date software in Debian 10?
    I'm using gcc/g++ 8.3.0 (8.3.0-6), pkgconf 1.6.0 (1.6.0-1), make 4.2.1 (4.2.1-1.2), libc6-dev 2.28 (2.28-10).
    Many thanks in advance!
    Best regards,
    Björn
    --- Synchronet 3.17c-Win32 NewsLink 1.110
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net