From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Ken Brown Newsgroups: gmane.emacs.bugs Subject: bug#17176: 24.3.50; Problem with manifests on cygw32 build with new binutils Date: Wed, 02 Apr 2014 15:07:23 -0400 Message-ID: <533C5FEB.7090408@cornell.edu> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1396522444 30387 80.91.229.3 (3 Apr 2014 10:54:04 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 3 Apr 2014 10:54:04 +0000 (UTC) To: 17176@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Thu Apr 03 12:53:58 2014 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1WVeJa-00075K-DX for geb-bug-gnu-emacs@m.gmane.org; Thu, 03 Apr 2014 11:52:06 +0200 Original-Received: from localhost ([::1]:40227 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WVQWO-0008St-RU for geb-bug-gnu-emacs@m.gmane.org; Wed, 02 Apr 2014 15:08:24 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:39415) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WVQWD-0008Sk-MG for bug-gnu-emacs@gnu.org; Wed, 02 Apr 2014 15:08:19 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WVQW2-0006QF-Ts for bug-gnu-emacs@gnu.org; Wed, 02 Apr 2014 15:08:13 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:60325) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WVQW2-0006Q9-R1 for bug-gnu-emacs@gnu.org; Wed, 02 Apr 2014 15:08:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.80) (envelope-from ) id 1WVQW2-0003IR-Ag for bug-gnu-emacs@gnu.org; Wed, 02 Apr 2014 15:08:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Ken Brown Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 02 Apr 2014 19:08:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 17176 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Original-Received: via spool by submit@debbugs.gnu.org id=B.139646565612631 (code B ref -1); Wed, 02 Apr 2014 19:08:01 +0000 Original-Received: (at submit) by debbugs.gnu.org; 2 Apr 2014 19:07:36 +0000 Original-Received: from localhost ([127.0.0.1]:33274 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1WVQVb-0003Hf-B4 for submit@debbugs.gnu.org; Wed, 02 Apr 2014 15:07:35 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:37595) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1WVQVX-0003HS-PC for submit@debbugs.gnu.org; Wed, 02 Apr 2014 15:07:33 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WVQVR-0006JL-Dq for submit@debbugs.gnu.org; Wed, 02 Apr 2014 15:07:31 -0400 Original-Received: from lists.gnu.org ([2001:4830:134:3::11]:47600) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WVQVR-0006JD-Bk for submit@debbugs.gnu.org; Wed, 02 Apr 2014 15:07:25 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:39289) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WVQVM-0008FK-0P for bug-gnu-emacs@gnu.org; Wed, 02 Apr 2014 15:07:25 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WVQVG-0005z0-BZ for bug-gnu-emacs@gnu.org; Wed, 02 Apr 2014 15:07:19 -0400 Original-Received: from limerock02.mail.cornell.edu ([128.84.12.100]:51255) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WVQVG-0005xU-76 for bug-gnu-emacs@gnu.org; Wed, 02 Apr 2014 15:07:14 -0400 X-CornellRouted: This message has been Routed already. Original-Received: from authusersmtp.mail.cornell.edu (granite3.serverfarm.cornell.edu [10.16.197.8]) by limerock02.mail.cornell.edu (8.14.4/8.14.4_cu) with ESMTP id s32J75Ob022739 for ; Wed, 2 Apr 2014 15:07:05 -0400 Original-Received: from [192.168.1.4] (cpe-67-249-194-47.twcny.res.rr.com [67.249.194.47]) (authenticated bits=0) by authusersmtp.mail.cornell.edu (8.14.4/8.12.10) with ESMTP id s32J74x4020137 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES128-SHA bits=128 verify=NOT) for ; Wed, 2 Apr 2014 15:07:05 -0400 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:24.0) Gecko/20100101 Thunderbird/24.4.0 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 140.186.70.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:87644 Archived-At: binutils has changed so that, on Cygwin, executables have a manifest built in by default. A consequence is that the cygw32 build of emacs produces an emacs.exe which, after it is stripped, won't run: $ ./emacs-stripped.exe -bash: ./emacs-stripped.exe: cannot execute binary file This is presumably caused by the fact that the cygw32 build already incorporates a manifest via nt/emacs.res. The following patch fixes this and does some related manifest-related cleanup: === modified file 'configure.ac' --- configure.ac 2014-03-27 21:29:32 +0000 +++ configure.ac 2014-04-02 17:47:41 +0000 @@ -1834,11 +1834,6 @@ W32_OBJ="w32fns.o w32menu.o w32reg.o w32font.o w32term.o" W32_OBJ="$W32_OBJ w32xfns.o w32select.o w32uniscribe.o" EMACSRES="emacs.res" - case "$canonical" in - x86_64-*-*) EMACS_MANIFEST="emacs-x64.manifest" ;; - *) EMACS_MANIFEST="emacs-x86.manifest" ;; - esac - UPDATE_MANIFEST=update-game-score.exe.manifest if test "${opsys}" = "cygwin"; then W32_LIBS="$W32_LIBS -lkernel32 -luser32 -lgdi32 -lole32 -lcomdlg32" W32_LIBS="$W32_LIBS -lusp10 -lcomctl32 -lwinspool" @@ -1846,6 +1841,11 @@ # the rc file), not a linker script. W32_RES_LINK="-Wl,emacs.res" else + case "$canonical" in + x86_64-*-*) EMACS_MANIFEST="emacs-x64.manifest" ;; + *) EMACS_MANIFEST="emacs-x86.manifest" ;; + esac + UPDATE_MANIFEST=update-game-score.exe.manifest W32_OBJ="$W32_OBJ w32.o w32console.o w32heap.o w32inevt.o w32proc.o" W32_LIBS="$W32_LIBS -lwinmm -lgdi32 -lcomdlg32" W32_LIBS="$W32_LIBS -lmpr -lwinspool -lole32 -lcomctl32 -lusp10" === modified file 'nt/emacs.rc' --- nt/emacs.rc 2014-03-21 10:12:53 +0000 +++ nt/emacs.rc 2014-04-02 18:30:53 +0000 @@ -1,10 +1,12 @@ Emacs ICON icons/emacs.ico 32649 CURSOR icons/hand.cur -#if defined (WIN64) || defined (__x86_64__) +#ifndef __CYGWIN__ +#ifdef WIN64 1 24 "emacs-x64.manifest" #else 1 24 "emacs-x86.manifest" #endif +#endif #ifndef VS_VERSION_INFO #define VS_VERSION_INFO 1 === modified file 'src/Makefile.in' --- src/Makefile.in 2014-01-12 17:27:17 +0000 +++ src/Makefile.in 2014-04-02 18:29:50 +0000 @@ -259,7 +259,7 @@ ## emacs.res if HAVE_W32 EMACSRES = @EMACSRES@ -## emacs-*.manifest if HAVE_W32 +## emacs-*.manifest if WINDOWSNT EMACS_MANIFEST = @EMACS_MANIFEST@ ## If HAVE_W32, compiler arguments for including ## the resource file in the binary. OK to apply to the emacs-24 branch? Ken