winegcc library creation/import broken

Peter Dons Tychsen donpedro.list at gmail.com
Sun Mar 14 12:09:46 CDT 2021


Hej again AJ,

OK. I have made an example that shows the problem here:
https://drive.google.com/file/d/1R4iIUkOTEP9dczwpUjqgApHE2W51gLwK/view?usp=sharing

https://drive.google.com/file/d/1B-EgplAnMhx_31y5j4Q2Aa6SAx2VW3oe/view?usp=sharing

Its a very simple app and lib. Just run "./build.sh" to build both and
see the problem.

It includes your suggestion with LoadLibrary(), which seems to make no
difference.

The make-files are based off winemaker, and are very simple.

Any tips on getting this working would be great.

Thanks,

Den søn. 14. mar. 2021 kl. 10.33 skrev Peter Dons Tychsen
<donpedro.list at gmail.com>:
>
> Hi Again,
>
> Den søn. 14. mar. 2021 kl. 10.26 skrev Peter Dons Tychsen
> <donpedro.list at gmail.com>:
> >
> > Hi AJ,
> >
> > > Because of the loader changes needed to support PE builtins, importing a
> > > Winelib library directly at the Unix level is currently broken. It may
> > > be reimplemented at some point, but that's not trivial.
> >
> > > You can still link to a library at the Unix level (as opposed to
> > > building an import library and linking to that), but you have to tell
> > > Wine explicitly about the loaded library. This can be done by adding a
> > > LoadLibraryA("libtest.so") at the start of your app.
> >
> > Has anyone tried this recently? Are there any examples of this still working?
> >
> > I tried to insert LoadLibraryA("libtest.so") with success, but this did not change anything. Still the same crash.
>
> And i am not using an import library, just linking directly with the
> library, and then confirming it with LoadLibrary() as you suggested
> (which is successfully loaded).
>
> Could i be using the wrong compiler flags or something? My example is
> fairly trivial.
>
> Thanks,
>
> /pedro



More information about the wine-devel mailing list