From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Marcus Brinkmann Newsgroups: gmane.emacs.bugs Subject: DOUG_LEA_MALLOC + REL_ALLOC leads to binary incompatibility across libc updates Date: Mon, 29 Apr 2002 16:01:37 -0400 Sender: bug-gnu-emacs-admin@gnu.org Message-ID: <20020429200137.GF10812@gnu.org> NNTP-Posting-Host: localhost.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: main.gmane.org 1020110616 14755 127.0.0.1 (29 Apr 2002 20:03:36 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Mon, 29 Apr 2002 20:03:36 +0000 (UTC) Return-path: Original-Received: from fencepost.gnu.org ([199.232.76.164]) by main.gmane.org with esmtp (Exim 3.33 #1 (Debian)) id 172HN1-0003ps-00 for ; Mon, 29 Apr 2002 22:03:36 +0200 Original-Received: from localhost ([127.0.0.1] helo=fencepost.gnu.org) by fencepost.gnu.org with esmtp (Exim 3.34 #1 (Debian)) id 172HMr-0000WB-00; Mon, 29 Apr 2002 16:03:25 -0400 Original-Received: from marcus by fencepost.gnu.org with local (Exim 3.34 #1 (Debian)) id 172HL8-0000PG-00 for ; Mon, 29 Apr 2002 16:01:38 -0400 Original-To: bug-gnu-emacs@gnu.org Content-Disposition: inline User-Agent: Mutt/1.3.25i Errors-To: bug-gnu-emacs-admin@gnu.org X-BeenThere: bug-gnu-emacs@gnu.org X-Mailman-Version: 2.0.9 Precedence: bulk List-Help: List-Post: List-Subscribe: , List-Id: Bug reports for GNU Emacs, the Swiss army knife of text editors List-Unsubscribe: , List-Archive: Xref: main.gmane.org gmane.emacs.bugs:1034 X-Report-Spam: http://spam.gmane.org/gmane.emacs.bugs:1034 Hi, when compiling emacs21 on the GNU/Hurd system, it will be compiled with DOUG_LEA_MALLOC and REL_ALLOC (because the src/s/gnu.h file does not undefine it like it is done on src/s/gnu-linux.h for the GNU/Linux platform). This leads to a binary incompatibility across libc updates, because the symbol real_morecore will have the address of __default_morecore compiled into the binary with a fixed value, and it will not be relocated. I was able to reproduce this on GNU/Linux by removing the #undef REL_ALLOC in src/s/gnu-linux.h: marcus@fencepost:~/emacs-test/emacs-21.1.95/src$ LD_LIBRARY_PATH=~marcus/emacs-test/usr/lib/debug ./emacs-21.1.95.1 Fatal error (11).Segmentation fault (Feel free to play with the files on fencepost if you have an account). So, maybe adding the same #undef REL_ALLOC in src/s/gnu.h is a good work around, I don't know. Maybe this should really work and we want REL_ALLOC, I don't know either. However, I positively tested that #undef REL_ALLOC in src/s/gnu.h fixes this incompatibility, so at least I could verify that the behaviour is the same on both GNU systems. Thanks, Marcus