On Tue, Sep 07, 2021 at 06:13:32PM +0200, Ondrej Mosnacek wrote:
On Tue, Sep 7, 2021 at 5:45 PM Zebediah Figura
> On 9/7/21 2:12 AM, Richard W.M. Jones wrote:
> > On Mon, Sep 06, 2021 at 05:59:41PM -0500, Zebediah Figura wrote:
> >> Thanks everyone for their input.
> >> There seems to be a consensus that Fedora would prefer that we use
> >> their MinGW dynamic libraries. However, this leaves a couple of
> >> questions:
> >> * As I described in , we *may* be able to hack things in the Wine
> >> loader such that we can use unmodified dynamic libraries. However,
> >> it's not fully clear yet that it's feasible. If it turns out to be
> >> infeasible, what preferences does Fedora have? (Renamed dynamic
> >> libraries shipped separately, shipped as part of Wine, static
> >> libraries, etc...)
> > Adding -static subpackages is the easiest option from our point of
> > view. As I mentioned in the previous email this would mean adjusting
> > an existing spec such as:
> > so that it builds the static library. It's a simple and obvious
> > change.
> > But can Wine use the static library built this way unmodified?
> > And are there any other implications versus using a DLL?
> I believe we should be able to use unmodified static libraries, yes.
> There are the usual implications—more space on disk and in memory; in
> Wine's case it doesn't really matter a lot, but we do still have cases
> of multiple DLLs that use the same library. It may be possible to use
> helper DLLs to avoid that in most cases.
> And, of course, I hate developing with static libraries :-(
Could you perhaps just build a new dynamic library (with the adjusted
name) by linking an empty/dummy object with the Fedora-provided static
library? (Not sure if that's possible, but it's what came to my mind
when reading this thread.)
I doubt this is going to be possible. Windows PE DLLs have some
complicated machinery for declaring exported symbols. Plus (like ELF)
I imagine the compiler needs to generate quite different code for
static vs dynamic.
Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones
Read my programming and virtualization blog: http://rwmj.wordpress.com
virt-p2v converts physical machines to virtual machines. Boot with a
live CD or over the network (PXE) and turn machines into KVM guests.