delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/1999/03/07/12:26:44

Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm
Sender: cygwin-owner AT sourceware DOT cygnus DOT com
Delivered-To: mailing list cygwin AT sourceware DOT cygnus DOT com
X-Lotus-FromDomain: ARS GMBH
From: "Kai-Uwe Rommel" <rommel AT ars DOT de>
To: cygwin AT sourceware DOT cygnus DOT com
Message-ID: <C125672D.005EA124.00@abraham.ars.de>
Date: Sun, 7 Mar 1999 18:09:51 +0100
Subject: B20.1: small change for dlltool to enhance portability
Mime-Version: 1.0

--0__=XktfdZ6hCqLu8kKJYeL8XXWzErZnuPGQWLwPD5ATi6pz9J7aEfY6jjRQ
Content-type: text/plain; charset=us-ascii
Content-Disposition: inline


I maintain several packages that are compiled with GNU gcc compilers
for the OS/2 and Win32 platforms. I use emx+gcc for OS/2 and CygWin
and MinGW32 for Win32. One example is the official RCS 5.7 release
for the PC that I maintain.

Some of these packages also contain DLLs (such as RCS, in which I
put the shared code into a rcslib.dll). With the current tools, I
can maintain a maximum of portability of the code between Win32
and OS/2 with only a different header file and Makefiles.

However, I need to use differen .DEF files for building DLLs
because I need to use additional statements in .DEF files for OS/2.
These are part of the Microsoft/IBM defined syntax of .DEF files
but are only meaningful for some linkers (on OS/2, mostly) and
are silently ignored by other linkers.

However, the GNU binary utilities do NOT silently ignore these
additional keywords which forces me to maintain different .DEF
files just because of one single line in them (I do not want
to use sed commands in Makefiles in order to keep build procedures
as simple as possible).

So what I did was adding support for these keywords to the
dlltool's scanner and parser grammars. Since they have no meaning
to CygWin and MinGW32, no other functionality has to be added.
The dlltool utility, with this patch, now silently ignores
the following additional keywords:

a) The DATA statement now can contain the attributes NONSHARED,
   SINGLE and MULTIPLE.

b) The LIBRARY statement now can contain the attributes
   INITINSTANCE, INITGLOBAL, TERMINSTANCE and TERMGLOBAL.

As I said above, they have no meaning and are silently ignored,
just for portability reasons.

I append the small context diff to this message as an attachment.
It is relative to the source code in the B20.1 source code package.
Please add it to future releases.

Kai Uwe Rommel

--
/* Kai Uwe Rommel                   ARS Computer & Consulting GmbH *
 * rommel AT ars DOT de (http://www.ars.de)             Muenchen, Germany *
 * rommel AT leo DOT org (http://www.leo.org/pub/comp/os/os2 maintenance) */


(See attached file: dlltool.dif)

--0__=XktfdZ6hCqLu8kKJYeL8XXWzErZnuPGQWLwPD5ATi6pz9J7aEfY6jjRQ
Content-type: application/octet-stream; 
	name="dlltool.dif"
Content-Disposition: attachment; filename="dlltool.dif"
Content-transfer-encoding: base64

KioqIGRlZnBhcnNlLnl+CVR1ZSBPY3QgMjcgMDI6MDQ6MTAgMTk5OA0KLS0tIGRlZnBhcnNlLnkJ
U3VuIE1hciAwNyAxNjowNzo1MCAxOTk5DQoqKioqKioqKioqKioqKioNCioqKiAzMCwzNiAqKioq
DQogIA0KICAldG9rZW4gTkFNRSwgTElCUkFSWSwgREVTQ1JJUFRJT04sIFNUQUNLU0laRSwgSEVB
UFNJWkUsIENPREUsIERBVEENCiAgJXRva2VuIFNFQ1RJT05TLCBFWFBPUlRTLCBJTVBPUlRTLCBW
RVJTSU9OSywgQkFTRSwgQ09OU1RBTlQNCiEgJXRva2VuIFJFQUQgV1JJVEUgRVhFQ1VURSBTSEFS
RUQgTk9OQU1FDQogICV0b2tlbiA8aWQ+IElEDQogICV0b2tlbiA8bnVtYmVyPiBOVU1CRVINCiAg
JXR5cGUgIDxudW1iZXI+IG9wdF9iYXNlIG9wdF9vcmRpbmFsIG9wdF9OT05BTUUgb3B0X0NPTlNU
QU5UIG9wdF9EQVRBDQotLS0gMzAsMzcgLS0tLQ0KICANCiAgJXRva2VuIE5BTUUsIExJQlJBUlks
IERFU0NSSVBUSU9OLCBTVEFDS1NJWkUsIEhFQVBTSVpFLCBDT0RFLCBEQVRBDQogICV0b2tlbiBT
RUNUSU9OUywgRVhQT1JUUywgSU1QT1JUUywgVkVSU0lPTkssIEJBU0UsIENPTlNUQU5UDQohICV0
b2tlbiBSRU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JTlNUQU5DRSIJeyByZXR1cm4gSU5JVElOU1RBTkNFO30NCisgIklOSVRHTE9CQUwi
CXsgcmV0dXJuIElOSVRHTE9CQUw7fQ0KKyAiVEVSTUlOU1RBTkNFIgl7IHJldHVybiBURVJNSU5T
VEFOQ0U7fQ0KKyAiVEVSTUdMT0JBTCIJeyByZXR1cm4gVEVSTUdMT0JBTDt9DQorIA0KICANCiAg
WzAtOV1beDAtOUEtRmEtZl0qIHsgeXlsdmFsLm51bWJlciA9IHN0cnRvbCAoeXl0ZXh0LDAsMCk7
IA0KICAJCXJldHVybiBOVU1CRVI7IH0NCg==

--0__=XktfdZ6hCqLu8kKJYeL8XXWzErZnuPGQWLwPD5ATi6pz9J7aEfY6jjRQ--



--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe AT sourceware DOT cygnus DOT com

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019