From: John Levon Subject: Re: Solaris build fix breaks Solaris Date: Tue, 13 Nov 2007 17:32:43 +0000 Message-ID: <20071113173243.GA27927@totally.trollied.org.uk> References: <20071112220639.GA2329@totally.trollied.org.uk> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Content-Disposition: inline In-Reply-To: List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: Keir Fraser Cc: xen-devel@lists.xensource.com List-Id: xen-devel@lists.xenproject.org On Tue, Nov 13, 2007 at 05:00:03AM +0000, Keir Fraser wrote: > > gld -melf_i386 -nostdlib -N -Ttext 0x100000 -o hvmloader.tmp hvmloader.o > > mp_tables.o util.o smbios.o 32bitbios_support.o acpi/acpi.a > > > > Specifying a linker script and asking for -nostdlib is obviously > > contradictory. Removing $(LDFLAGS_DIRECT) fixes the problem. > > That command line doesn't specify a linker script. And even if it did, how > would that contradict -nostdlib? Also the -nostdlib is not in > LDFLAGS_DIRECT: -melf_i386 is. -melf_i386 translates to using an internal script, specifically /usr/sfw/i386-pc-solaris2.11/lib/ldscripts/elf_i386.xc on Solaris. Clearly -nostdlib means it can't be used, so it cannot find the relevant script and gives up: hatchback:~ $ gld -nostdlib -melf_i386 a.o gld: cannot open linker script file ldscripts/elf_i386.xc: No such file or directory Since the -nostdlib is presumably there for a reason, the correct fix seems to be to remove $(LDFLAGS_DIRECT), right? regards john