From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Paul Eggert Newsgroups: gmane.emacs.devel Subject: Re: Anyone built Emacs with gcc-3.3? Date: Fri, 11 Jul 2003 15:52:41 -0700 (PDT) Sender: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Message-ID: <200307112252.h6BMqf009206@sic.twinsun.com> References: <200307110955.h6B9tDY06306@sic.twinsun.com> NNTP-Posting-Host: main.gmane.org X-Trace: main.gmane.org 1057964738 21105 80.91.224.249 (11 Jul 2003 23:05:38 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Fri, 11 Jul 2003 23:05:38 +0000 (UTC) Cc: simon.marshall@misys.com, emacs-pretesters@gnu.org, emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Sat Jul 12 01:05:36 2003 Return-path: Original-Received: from quimby.gnus.org ([80.91.224.244]) by main.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 19b6xM-0005UF-00 for ; Sat, 12 Jul 2003 01:05:36 +0200 Original-Received: from monty-python.gnu.org ([199.232.76.173]) by quimby.gnus.org with esmtp (Exim 3.12 #1 (Debian)) id 19b79M-0005u3-00 for ; Sat, 12 Jul 2003 01:18:00 +0200 Original-Received: from localhost ([127.0.0.1] helo=monty-python.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.20) id 19b6y0-000713-1v for emacs-devel@quimby.gnus.org; Fri, 11 Jul 2003 19:06:16 -0400 Original-Received: from list by monty-python.gnu.org with tmda-scanned (Exim 4.20) id 19b6rD-0002sQ-5R for emacs-devel@gnu.org; Fri, 11 Jul 2003 18:59:15 -0400 Original-Received: from mail by monty-python.gnu.org with spam-scanned (Exim 4.20) id 19b6mp-0007ps-7z for emacs-devel@gnu.org; Fri, 11 Jul 2003 18:54:54 -0400 Original-Received: from alcor.twinsun.com ([198.147.65.9]) by monty-python.gnu.org with esmtp (Exim 4.20) id 19b6kt-0006jb-Fr; Fri, 11 Jul 2003 18:52:43 -0400 Original-Received: from green.twinsun.com ([192.54.239.71]) by alcor.twinsun.com (8.12.6/8.12.6) with ESMTP id h6BMqfZ9016804; Fri, 11 Jul 2003 15:52:41 -0700 (PDT) Original-Received: from shade.twinsun.com (shade.twinsun.com [192.54.239.27]) by green.twinsun.com (8.11.7+Sun/8.11.7) with SMTP id h6BMqf016982; Fri, 11 Jul 2003 15:52:41 -0700 (PDT) Original-Received: from sic.twinsun.com ([192.54.239.17]) by shade.twinsun.com (SAVSMTP 3.1.0.29) with SMTP id M2003071115524003862 ; Fri, 11 Jul 2003 15:52:40 -0700 Original-Received: (from eggert@localhost) by sic.twinsun.com (8.11.7+Sun/8.11.7) id h6BMqf009206; Fri, 11 Jul 2003 15:52:41 -0700 (PDT) Original-To: rms@gnu.org In-reply-to: <200307110955.h6B9tDY06306@sic.twinsun.com> (eggert@twinsun.com) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.2 Precedence: list List-Id: Emacs development discussions. List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Xref: main.gmane.org gmane.emacs.devel:15551 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:15551 I found the other bug that was preventing Emacs 21.3 from building with GCC 3.3 on Solaris 8 (sparc). Here is a patch. When I installed this patch, together with the patch I sent earlier today, Emacs built and installed on Solaris 8 with GCC 3.3, and ran OK on some simple tests. 2003-07-11 Paul Eggert * unexelf.c (unexec): Consider a section to precede the .bss section if its addresses overlap that of .bss. This fixes the bug reported by Simon Marshall in , if you also install the patch that I submitted yesterday in . This patch is related to my 1996-06-24 patch to unexelf.c , but it uses a more precise heuristic for deciding when the other section precedes the .bss section. --- emacs-21.3/src/unexelf.c 2002-10-15 07:21:44.000000000 -0700 +++ emacs-21.3-fix/src/unexelf.c 2003-07-11 14:59:48.649294000 -0700 @@ -971,8 +971,13 @@ unexec (new_name, old_name, data_start, } else { - /* Any section that was original placed AFTER the bss - section should now be off by NEW_DATA2_SIZE. */ + /* Any section that was originally placed after the .bss + section should now be off by NEW_DATA2_SIZE. If a + section overlaps the .bss section, consider it to be + placed after the .bss section. Overlap can occur if the + section just before .bss has less-strict alignment; this + was observed between .symtab and .bss on Solaris 2.5.1 + (sparc) with GCC snapshot 960602. */ #ifdef SOLARIS_POWERPC /* On PPC Reference Platform running Solaris 2.5.1 the plt section is also of type NOBI like the bss section. @@ -986,9 +991,8 @@ unexec (new_name, old_name, data_start, >= OLD_SECTION_H (old_bss_index-1).sh_offset) NEW_SECTION_H (nn).sh_offset += new_data2_size; #else - if (round_up (NEW_SECTION_H (nn).sh_offset, - OLD_SECTION_H (old_bss_index).sh_addralign) - >= new_data2_offset) + if (NEW_SECTION_H (nn).sh_offset + NEW_SECTION_H (nn).sh_size + > new_data2_offset) NEW_SECTION_H (nn).sh_offset += new_data2_size; #endif /* Any section that was originally placed after the section