delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2021/05/21/01:09:21

X-Recipient: archive-cygwin AT delorie DOT com
X-Original-To: cygwin AT cygwin DOT com
Delivered-To: cygwin AT cygwin DOT com
DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org 4A4D3385742C
Authentication-Results: sourceware.org; dmarc=none (p=none dis=none)
header.from=SystematicSw.ab.ca
Authentication-Results: sourceware.org;
spf=none smtp.mailfrom=brian DOT inglis AT systematicsw DOT ab DOT ca
X-Authority-Analysis: v=2.4 cv=Nv6yz+RJ c=1 sm=1 tr=0 ts=60a74078
a=T+ovY1NZ+FAi/xYICV7Bgg==:117 a=T+ovY1NZ+FAi/xYICV7Bgg==:17
a=IkcTkHD0fZMA:10 a=0UTjuw-4AAAA:20 a=w_pzkKWiAAAA:8 a=Gw2kqpqoAAAA:8
a=94nOnFI1EgyDtX4ev68A:9 a=QEXdDO2ut3YA:10 a=MP2Ns1xdqCcA:10
a=sRI3_1zDfAgwuvI8zelB:22 a=eScz40NEmC3w1fR48gjg:22
To: cygwin AT cygwin DOT com
References: <3ca48702525e10e74147067d20bd4532 AT mail DOT kylheku DOT com>
From: Brian Inglis <Brian DOT Inglis AT SystematicSw DOT ab DOT ca>
Organization: Systematic Software
Subject: Re: Building resource-only DLL under Cygwin.
Message-ID: <91e8ffc7-087d-24f4-67ae-13e0c49fab1d@SystematicSw.ab.ca>
Date: Thu, 20 May 2021 23:09:11 -0600
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:78.0) Gecko/20100101
Thunderbird/78.10.2
MIME-Version: 1.0
In-Reply-To: <3ca48702525e10e74147067d20bd4532@mail.kylheku.com>
X-CMAE-Envelope: MS4xfBT4+MD7nnWTUG0z/6y+c8ZUrpHoxVSpdERwwt7mMZTIYdOoy+bbUFvYwr58CUsWdz1f0ABz4+CtplH9ndlUWWasl5zWZXmOLyZqbXid+W1XTAI+Hg7t
kDGG0V6WLETDe06pebLTLphoEbDBYtHADJHLswCkogwZvgcfRrWyMJxDfK5rEbSPyrvP5ZYn92fo9yGZ5ts4Wtn9tvaWCfvoF50=
X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_00, KAM_DMARC_STATUS,
KAM_LAZY_DOMAIN_SECURITY, NICE_REPLY_A, RCVD_IN_BARRACUDACENTRAL,
RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, SPF_HELO_NONE,
SPF_NONE, TXREP autolearn=no autolearn_force=no version=3.4.2
X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on
server2.sourceware.org
X-BeenThere: cygwin AT cygwin DOT com
X-Mailman-Version: 2.1.29
List-Id: General Cygwin discussions and problem reports <cygwin.cygwin.com>
List-Unsubscribe: <https://cygwin.com/mailman/options/cygwin>,
<mailto:cygwin-request AT cygwin DOT com?subject=unsubscribe>
List-Archive: <https://cygwin.com/pipermail/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-request AT cygwin DOT com?subject=help>
List-Subscribe: <https://cygwin.com/mailman/listinfo/cygwin>,
<mailto:cygwin-request AT cygwin DOT com?subject=subscribe>
Reply-To: cygwin AT cygwin DOT com
Errors-To: cygwin-bounces AT cygwin DOT com
Sender: "Cygwin" <cygwin-bounces AT cygwin DOT com>

On 2021-05-20 18:33, Kaz Kylheku via Cygwin wrote:
> I was just wondering; have any of you ever tried to build a resource-only DLL using the Cygwin toolchain environment?
> 
> I mean, starting with a .rc file, build a .res, and then link it into a working resource-only DLL?
> 
> I know that adding resources to executables is perfectly possible; I'm specifically asking about resource-only DLLs.
> 
> If you use Microsoft's tools, you must specify the /NOENTRY linker option to indicate that the object has no DllMain.
> 
> Can we do the analog of this with the GNU-based toolchain on Cygwin?

Not done it - but should be doable - normal MS approach to L14N.

 From the links near the bottom, it looks like if you want or need a DllMain,
you have to write and build it, as would be expected, so just don't do that!

See what mintty and setup do with their resources in their build processes:

<https://github.com/mintty/mintty/blob/master/src/res.rc>
<https://github.com/mintty/mintty/blob/master/src/Makefile#L159>

<https://cygwin.com/git/?p=cygwin-apps/setup.git;a=blob;f=res.rc>
<https://cygwin.com/git/?p=cygwin-apps/setup.git;a=blob;f=Makefile.am#l275>

See man dlltool(1), windres(1),
<https://cygwin.com/cygwin-ug-net/dll.html#dll-build>
<https://www.transmissionzero.co.uk/computing/building-dlls-with-mingw/>
<https://www.transmissionzero.co.uk/computing/advanced-mingw-dll-topics/>
<https://www.transmissionzero.co.uk/computing/win32-apps-with-mingw/>

-- 
Take care. Thanks, Brian Inglis, Calgary, Alberta, Canada

This email may be disturbing to some readers as it contains
too much technical detail. Reader discretion is advised.
[Data in binary units and prefixes, physical quantities in SI.]

-- 
Problem reports:      https://cygwin.com/problems.html
FAQ:                  https://cygwin.com/faq/
Documentation:        https://cygwin.com/docs.html
Unsubscribe info:     https://cygwin.com/ml/#unsubscribe-simple

- Raw text -


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