From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 22396 invoked by alias); 12 Nov 2007 09:22:53 -0000 Received: (qmail 22359 invoked by uid 22791); 12 Nov 2007 09:22:53 -0000 X-Spam-Check-By: sourceware.org Received: from province.act-europe.fr (HELO province.act-europe.fr) (212.157.227.214) by sourceware.org (qpsmtpd/0.31) with ESMTP; Mon, 12 Nov 2007 09:22:50 +0000 Received: from localhost (localhost [127.0.0.1]) by filtered-province.act-europe.fr (Postfix) with ESMTP id 8F80A166278; Mon, 12 Nov 2007 10:22:48 +0100 (CET) Received: from province.act-europe.fr ([127.0.0.1]) by localhost (province.act-europe.fr [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id tAa9vUpZKeZW; Mon, 12 Nov 2007 10:22:48 +0100 (CET) Received: from [10.10.127.242] (dhcp-guest-242.act-europe.fr [10.10.127.242]) (using TLSv1 with cipher AES128-SHA (128/128 bits)) (No client certificate requested) by province.act-europe.fr (Postfix) with ESMTP id 59E9216515B; Mon, 12 Nov 2007 10:22:48 +0100 (CET) In-Reply-To: <4738109C.3090008@jermar.eu> References: <4738109C.3090008@jermar.eu> Mime-Version: 1.0 (Apple Message framework v752.3) Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed Message-Id: Cc: binutils@sourceware.org Content-Transfer-Encoding: 7bit From: Tristan Gingold Subject: Re: [ia64] objcopy and constant-gp Date: Mon, 12 Nov 2007 09:22:00 -0000 To: Jakub Jermar X-Mailer: Apple Mail (2.752.3) X-IsSubscribed: yes Mailing-List: contact binutils-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: binutils-owner@sourceware.org X-SW-Source: 2007-11/txt/msg00111.txt.bz2 On Nov 12, 2007, at 9:36 AM, Jakub Jermar wrote: > the following stopped working for me in ia64 binutils 2.18: > > 1. I have a binary file and want to objcopy it from the binary > format to elf64-ia64-little, creating one ELF section in it, the > result is called empty.o > 2. I want to link empty.o with other .o files that were compiled > with -mconstant-gp > 3. ld returns an error complaining about linking constant-gp and > non-constant-gp object files > > So I would like to know if you consider this a regression or if it > is actually a feature or a fix introduced in the newest version. > > Anyway, what I am now most concerned about is if there is a > straightforward way to specify that empty.o should be constructed > with the constant-gp flag. (There is an easy workaround for this: > after objcopy, patch the ELF file manually and set the constant-gp > bit using some hex editor). This behaviour sounds reasonable. You'd better to create empty.s which .incbin (see gas manual) the binary file. Then you assemble empty.s using the right options (--mconstant-gp). The link should be successful. Tristan.