Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 609680 - app-editors/emacs-24.5-r3 build fails with temacs segmentation fault
Summary: app-editors/emacs-24.5-r3 build fails with temacs segmentation fault
Status: RESOLVED WORKSFORME
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: GNU Emacs project
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-02-17 23:46 UTC by Ulrich Müller
Modified: 2018-03-07 00:10 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
build.log (build.log,142.39 KB, text/plain)
2017-02-17 23:50 UTC, Ulrich Müller
Details
emerge --info (emerge.info,6.73 KB, text/plain)
2017-02-17 23:51 UTC, Ulrich Müller
Details
build.log (build.log,151.48 KB, text/x-log)
2017-06-26 08:04 UTC, Aurélien Francillon
Details
emerge --info (gentoo-info,5.88 KB, text/plain)
2017-06-26 08:06 UTC, Aurélien Francillon
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Ulrich Müller gentoo-dev 2017-02-17 23:46:59 UTC
Build fails in src_compile with a segmentation fault when first executing temacs:

if test "no" = "yes"; then \
  rm -f bootstrap-emacs; \
  ln temacs bootstrap-emacs; \
else \
  ./temacs --batch --load loadup bootstrap || exit 1; \
  test "X" = X ||  -zex emacs; \
  mv -f emacs bootstrap-emacs; \
fi
/bin/sh: line 7: 30823 Segmentation fault      ./temacs --batch --load loadup bootstrap
make[1]: *** [Makefile:816: bootstrap-emacs] Error 1
make[1]: Leaving directory '/var/tmp/portage/app-editors/emacs-24.5-r3/work/emacs-24.5/src'
make: *** [Makefile:387: src] Error 2
 * ERROR: app-editors/emacs-24.5-r3::gentoo failed (compile phase):
 *   emake failed

(gdb) run
Starting program: /var/tmp/portage/app-editors/emacs-24.5-r3/work/emacs-24.5/src/temacs 
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib64/libthread_db.so.1".

Program received signal SIGSEGV, Segmentation fault.
0x00000000005ce6e5 in calloc (
    nmemb=<error reading variable: DWARF-2 expression error: Loop detected (257).>, size=size@entry=1) at gmalloc.c:1529
1529      result = malloc (bytes);


Not sure what has triggered this. Possibly due to glibc update from 2.23 to 2.24.
Comment 1 Ulrich Müller gentoo-dev 2017-02-17 23:50:40 UTC
Created attachment 464170 [details]
build.log
Comment 2 Ulrich Müller gentoo-dev 2017-02-17 23:51:38 UTC
Created attachment 464172 [details]
emerge --info
Comment 3 Aurélien Francillon 2017-06-26 08:04:21 UTC
Same problem here (on hardened) with sys-libs/glibc-2.23-r4
Comment 4 Aurélien Francillon 2017-06-26 08:04:52 UTC
Created attachment 478020 [details]
build.log
Comment 5 Aurélien Francillon 2017-06-26 08:06:29 UTC
Created attachment 478022 [details]
emerge --info
Comment 6 Aurélien Francillon 2017-06-26 08:32:02 UTC
Looks like duplicate of #622146 

and caused by improper pax flags :
paxctl-ng -v temacs 
temacs:
        PT_PAX    : -e---
        XATTR_PAX : -e-r-

temacs does not segfault after resetting pax flags using:
paxctl-ng -z temacs
Comment 7 Ulrich Müller gentoo-dev 2017-06-26 11:58:56 UTC
(In reply to Aurélien Francillon from comment #3)

Please don't re-use an existing bug report for an unrelated issue. *This* bug is about a build failure of emacs-24.5-r3 on non-hardened amd64.

Your emacs-25.2 issue is most likely the same problem as bug 607990 (in particular, see bug 607990 comment 8).
Comment 8 Aurélien Francillon 2017-06-26 12:20:36 UTC
OK sorry to disturb here, crash was on the same step of compilation and this was unclear initially if that was hardened related or not (or if original post was hardened too...). 

Thanks for the pointers though.
Comment 9 Ulrich Müller gentoo-dev 2018-03-07 00:10:56 UTC
I cannot reproduce this any more. Closing.