Mailing-List: contact cygwin-help@sourceware.cygnus.com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe@sources.redhat.com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin@sources.redhat.com>
List-Help: <mailto:cygwin-help@sources.redhat.com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner@sources.redhat.com
Delivered-To: mailing list cygwin@sources.redhat.com
X-Authentication-Warning: mail.webfountain.com: Host gate.webfountain.com [63.161.54.3] claimed to be electra
From: "Serban Simu" <serban@digitalfountain.com>
To: <cygwin@sourceware.cygnus.com>
Subject:  ld COFF processing
Date: Fri, 1 Sep 2000 17:36:05 -0700
Message-ID: <NEBBJJDHNMBJBKMAFPPOIEDMCAAA.serban@digitalfountain.com>
MIME-Version: 1.0
Content-Type: text/plain;
	charset="iso-8859-1"
Content-Transfer-Encoding: 7bit
X-Priority: 3 (Normal)
X-MSMail-Priority: Normal
X-Mailer: Microsoft Outlook IMO, Build 9.0.2416 (9.0.2910.0)
X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2314.1300
Importance: Normal

I'm trying to use ld on a Windows NT object file produced with cl. The
problems that I have are related to the fact that ld removes some of the
sections from the output file, which causes further link to fail.

Here is a simple example:

$ cl /c s.cpp		(produces s.obj)
$ ld -o s.a -r s.obj	(produces s.a)

Linking against s.a, using Microsoft's 'cl' works in most of the simple
cases, although the ld operation removed some of the sections. I have also
tried the --oformat pe-i386 and -m i386pe with the same effect. In case
s.cpp uses exceptions, 'cl' creates a special section .xdata$x and a .text$x
which are not put in the output file.

My question is, to what extent is the pe-i386 format compatible with the
Microsoft format?

Thank you for your help with that!

Serban


-----------
Versions used:

cl:
Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 12.00.8168 for 80x86
Copyright (C) Microsoft Corp 1984-1998. All rights reserved.

ld:
GNU ld version 19990818 (with BFD 19990818)


--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com

