Subject: bug#40462: 28.0.50; Building nativecomp branch segfaulting on FreeBSD

From: Ashish SHUKLA <[email-masked]>
Date: Mon, 06 Apr 2020 14:30:42 +0530

While building emacs (git commit 00ee320) with following configure
flags:

--disable-build-details --localstatedir=/var --with-x --enable-acl
  --with-cairo --with-dbus --with-nativecomp --with-gconf --with-gif
  --with-gnutls --with-gsettings --with-x-toolkit=gtk3 --with-harfbuzz
  --with-jpeg --with-json --with-file-notification=kqueue --with-lcms2
  --with-m17n-flt --without-imagemagick --with-mailutils --with-modules
  --with-sound=oss --with-libotf --with-png --with-toolkit-scroll-bars
  --with-rsvg --with-threads --with-tiff --with-xft --with-xim
  --with-xml2 --with-xpm --without-xwidgets --x-libraries=/usr/local/lib
  --x-includes=/usr/local/include --prefix=/usr/local

It crashes:

=================================================================================
Dumping under the name bootstrap-emacs.pdmp
dumping fingerprint:
9a2ee446c34e7076160c294f92952a1b63dc99c0b318f12a09f5e0cfbd921c35
Dump complete
Byte counts: header=96 hot=13959104 discardable=137904 cold=9581848
Reloc counts: hot=965456 discardable=4905
gmake -C ../lisp compile-first EMACS="../src/bootstrap-emacs"
gmake[4]: Entering directory 'work-full/emacs-00ee320/lisp'
EMACSLOADPATH= '../src/bootstrap-emacs' -batch --no-site-file
--no-site-lisp --eval '(setq load-prefer-newer t)'  \
-l comp -f batch-byte-native-compile-for-bootstrap emacs-lisp/macroexp.el
EMACSLOADPATH= '../src/bootstrap-emacs' -batch --no-site-file
--no-site-lisp --eval '(setq load-prefer-newer t)'  \
-l comp -f batch-byte-native-compile-for-bootstrap emacs-lisp/cconv.el
EMACSLOADPATH= '../src/bootstrap-emacs' -batch --no-site-file
--no-site-lisp --eval '(setq load-prefer-newer t)'  \
-l comp -f batch-byte-native-compile-for-bootstrap emacs-lisp/byte-opt.el
EMACSLOADPATH= '../src/bootstrap-emacs' -batch --no-site-file
--no-site-lisp --eval '(setq load-prefer-newer t)'  \
-l comp -f batch-byte-native-compile-for-bootstrap emacs-lisp/bytecomp.el
EMACSLOADPATH= '../src/bootstrap-emacs' -batch --no-site-file
--no-site-lisp --eval '(setq load-prefer-newer t)'  \
-l comp -f batch-byte-native-compile-for-bootstrap emacs-lisp/comp.el
EMACSLOADPATH= '../src/bootstrap-emacs' -batch --no-site-file
--no-site-lisp --eval '(setq load-prefer-newer t)'  \
-l comp -f batch-byte-native-compile-for-bootstrap emacs-lisp/autoload.el
gmake[4]: Leaving directory 'work-full/emacs-00ee320/lisp'
gmake -C ../lisp autoloads EMACS="../src/bootstrap-emacs"
gmake[4]: Entering directory 'work-full/emacs-00ee320/lisp'
EMACSLOADPATH= '../src/bootstrap-emacs' -batch --no-site-file
--no-site-lisp --eval '(setq load-prefer-newer t)'  \
-l comp -f batch-byte-native-compile-for-bootstrap
international/titdic-cnv.el
gmake -C ../leim all EMACS="../src/bootstrap-emacs"
gmake[5]: Entering directory 'work-full/emacs-00ee320/leim'
EMACSLOADPATH= '../src/bootstrap-emacs' -batch --no-site-file
--no-site-lisp -l titdic-cnv \
  -f batch-titdic-convert -dir ./../lisp/leim/quail CXTERM-DIC/CCDOSPY.tit
Fatal error 11: Segmentation fault
Backtrace:
0x4a1b10 <emacs_backtrace+0xe0> at
work-full/emacs-00ee320/src/bootstrap-emacs
0x46918b <terminate_due_to_signal+0xab> at
work-full/emacs-00ee320/src/bootstrap-emacs
0x4a45d8 <handle_fatal_signal+0x18> at
work-full/emacs-00ee320/src/bootstrap-emacs
0x4a4680 <deliver_thread_signal+0xa0> at
work-full/emacs-00ee320/src/bootstrap-emacs
0x4a15ed <deliver_fatal_thread_signal+0x1d> at
work-full/emacs-00ee320/src/bootstrap-emacs
0x4a4727 <handle_sigsegv+0x87> at
work-full/emacs-00ee320/src/bootstrap-emacs
0x80148b3ce <_pthread_sigmask+0x53e> at /lib/libthr.so.3
gmake[5]: *** [Makefile:107: ../lisp/leim/quail/CCDOSPY.el] Segmentation
fault (core dumped)
gmake[5]: Leaving directory 'work-full/emacs-00ee320/leim'
gmake[4]: *** [Makefile:389: leim] Error 2
gmake[4]: Leaving directory 'work-full/emacs-00ee320/lisp'
gmake[3]: *** [Makefile:802: ../lisp/loaddefs.el] Error 2
gmake[3]: Leaving directory 'work-full/emacs-00ee320/src'
gmake[2]: *** [Makefile:424: src] Error 2
gmake[2]: Leaving directory 'work-full/emacs-00ee320'
=================================================================================

Attached gdb.txt contains the "bt full" output.

-- 
Ashish SHUKLA

Sent via Gnus from GNU Emacs