Skip to content
This repository has been archived by the owner on Dec 24, 2022. It is now read-only.

32-bit Sdk extension for builders? #101

Closed
amtlib-dot-dll opened this issue May 3, 2018 · 9 comments
Closed

32-bit Sdk extension for builders? #101

amtlib-dot-dll opened this issue May 3, 2018 · 9 comments

Comments

@amtlib-dot-dll
Copy link

Now we have org.freedesktop.Platform.Compat32 for 32-bit binaries to run alongside with 64-bit ones, but we cannot build 32-bit binaries at the same time with 64-bit ones. Is there anything like org.freedesktop.Sdk.Compat32 or org.freedesktop.Sdk.Extension.Compat32?

@julianrichen
Copy link

I'm also interested in this. I've been working on a platform & SDK for bundling windows applications with Wine via flatpak. Wine really needs WoW64 supports as most 64bit windows application still reference 32bit libraries. So the platform & SDK need to be able to build 32bit wine in a 64bit environment. Adding an SDK version of Compat32 would allow that.

@amtlib-dot-dll
Copy link
Author

amtlib-dot-dll commented May 11, 2018

@julianrichen Do you need to build Wine itself via flatpak-builder?


Ah-ha, I realized that for binary compatibility you need, but do you know that org.freedesktop.Platform.Compat32/x86_64 is just the same as org.freedesktop.Platform/i386? I suggest that we can just use something like --filesystem=/var/lib/flatpak/runtimes/org.freedesktop.Sdk/1.6/active/files.

@julianrichen
Copy link

julianrichen commented May 11, 2018

@julianrichen Do you need to build Wine itself via flatpak-builder?

Ideally yes, at least it would make things easier. I debated trying to find a reliable source with pre-build win64 binaries with WoW64 but that didn't seem good long-term. Would rather have it working nicely in flatpak-builder that can build freshly released wine sources instead of relying on someone else.


I suggest that we can just use something like --filesystem=/var/lib/flatpak/runtimes/org.freedesktop.Sdk/1.6/active/files.

I'm honestly not sure if this would work? Can you set --filesystem in build-args? The docs simply say:

build-args (array of strings)

This is an array containing extra options to pass to flatpak build.

Plus I think you need to symlink ld-linux.so.2 so it would be what? ln -s /var/lib/flatpak/runtimes/org.freedesktop.Sdk/i386/1.6/active/files/usr/lib/32bit/lib/ld-linux.so.2 /usr/lib/ld-linux.so.2.

Concerns:

  • Assumes you install system-wide instead of with --user
  • Feels a bit hack-ish

Edit: Also is the org.freedesktop.Platform.Compat32 manifest located anywhere? I didn't see it on flatpak or flathub. Or is it generated at built time? I don't even see it as an extension point of the freedesktop-sdk-images.

@amtlib-dot-dll
Copy link
Author

Also is the org.freedesktop.Platform.Compat32 manifest located anywhere?

Probably here https://github.com/flatpak/freedesktop-sdk-images/blob/1.6/Makefile#L84

And this should be useful https://github.com/flathub/com.valvesoftware.Steam/blob/master/ld.so.conf

@julianrichen
Copy link

Hmmm, I know this is getting a bit off topic from your idea of providing a *.Sdk.Compat32 but I wonder if shipping my own tld.domain.Platform.Compat32 would work. Technically you don't need to compile Wine with 64bit/32bit together, as long as you ship the required components (dll, binaries, loader) it doesn't matter. Would also save compilation time :) However each app that needs WoW64 would need to extend --extension=tld.domain.Platform.Compat32=directory=lib/32bit & --extension=tld.domain.Platform.Compat32=version=1.6 + ship a ld.so.conf.

Thanks for the idea, might be a good work around atm. Still a proper *.Sdk.Compat32 would be a good idea.

@amtlib-dot-dll
Copy link
Author

Hmmm, sounds like what Steam does. Steam use precompiled binaries and they do as in their recipe file

@nanonyme
Copy link

nanonyme commented Nov 5, 2018

Funny, this sounds exactly like the feature we were requesting for Steam and such for runtime 18.08. Ping @valentindavid

@nanonyme
Copy link

nanonyme commented Nov 5, 2018

I doubt this will ever happen for 1.6. For 18.08 and higher see https://gitlab.com/freedesktop-sdk/freedesktop-sdk/issues/348

@TingPing
Copy link
Member

TingPing commented Nov 7, 2018

Yes I will close this as new improvements will happen in the new runtime.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants