Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for Redhat Linux / Rocky Linux #190

Closed
laurent-martin opened this issue Aug 16, 2024 · 8 comments
Closed

Support for Redhat Linux / Rocky Linux #190

laurent-martin opened this issue Aug 16, 2024 · 8 comments
Assignees
Labels
bug Something isn't working

Comments

@laurent-martin
Copy link

laurent-martin commented Aug 16, 2024

Anyone has successfully used tebako on Rocky Linux 9 ?

I tried on Rocky 9, and got:

$ tebako press --root=$PWD --entry-point=ascli --output=/mnt/w/ascli.exe --Ruby=3.2.4
...
[ 70%] Completed '_zstd'
[ 70%] Built target _zstd
gmake[4]: *** [Makefile:136: all] Error 2
gmake[3]: *** [CMakeFiles/_dwarfs_wr.dir/build.make:86: /home/laurent/.tebako/deps/src/_dwarfs_wr-stamp/_dwarfs_wr-build] Error 2
gmake[2]: *** [CMakeFiles/Makefile2:91: CMakeFiles/_dwarfs_wr.dir/all] Error 2
gmake[1]: *** [CMakeFiles/Makefile2:257: CMakeFiles/tebako.dir/rule] Error 2
gmake: *** [Makefile:202: tebako] Error 2
Tebako script failed: 'tebako press' build step failed [104]

I tried the container:

docker run -it --rm -v $PWD:/mnt/w ghcr.io/tamatebako/tebako-ubuntu-20.04:latest tebako press --root=/mnt/w --entry-point=ascli --output=/mnt/w/ascli.exe --Ruby=3.2.4

But it does not run:

$ ./ascli.exe
./ascli.exe: /lib64/libpthread.so.0: version `GLIBC_PRIVATE' not found (required by ./ascli.exe)
@ronaldtse
Copy link
Contributor

@laurent-martin thanks for the report. No I don't think we've tried Tebako on RHEL or Rocky Linux but it's something we can investigate.

@maxirmx could you please help? I believe at RNP we have CentOS/RHEL GHA builds so we can adopt those workflows over here as well.

@ronaldtse ronaldtse added the bug Something isn't working label Aug 17, 2024
@ronaldtse ronaldtse changed the title Redhat Linux / Rocky Linux ? Support for Redhat Linux / Rocky Linux Aug 17, 2024
@maxirmx
Copy link
Member

maxirmx commented Aug 17, 2024

There are two different topics here

These issues are "orthogonal".
Making Rhel port is possible but it means doing it all the way through - folly with our patches, dwarfs, tebako
I would rather make tebako port to Ubuntu 24, provide container for packaging and the output shall work for Rocky Linux 9. Theoretically ...
It is a matter of week I guess.

@laurent-martin, will it work for you ?

@d4rky-pl
Copy link
Contributor

@maxirmx I found an interesting alternative to what you proposed but it's probably not a viable solution for everyone - I used a modified version of patchelf and ran:

patchelf --remove-needed-version libc.so.6 GLIBC_PRIVATE ht-x86_64-linux
patchelf --remove-needed-version libpthread.so.0 GLIBC_PRIVATE ht-x86_64-linux

So far the binary seems to work on Ubuntu 22 but I didn't stress test it. It could be an option to make things more portable but you're the expert here, feel free to scream at me that this is a horrible hack 😄

@maxirmx
Copy link
Member

maxirmx commented Aug 29, 2024

@maxirmx I found an interesting alternative to what you proposed but it's probably not a viable solution for everyone - I used a modified version of patchelf and ran:

patchelf --remove-needed-version libc.so.6 GLIBC_PRIVATE ht-x86_64-linux
patchelf --remove-needed-version libpthread.so.0 GLIBC_PRIVATE ht-x86_64-linux

So far the binary seems to work on Ubuntu 22 but I didn't stress test it. It could be an option to make things more portable but you're the expert here, feel free to scream at me that this is a horrible hack 😄

I think this is a good idea :)

@ronaldtse
Copy link
Contributor

Will this be an option?

@maxirmx
Copy link
Member

maxirmx commented Aug 30, 2024

Will this be an option?

I think this is a postprocessing option that will make tebako package built with "older" glibc (pre 3.24) to work on newer gnu-linux versions.

For example, make package built on Ubuntu 20 work on Ubuntu 22/24 (or Rocky Linux 9)

I will test it

@maxirmx
Copy link
Member

maxirmx commented Sep 2, 2024

@laurent-martin
The latest Ubuntu container https://github.com/tamatebako/tebako-ci-containers/pkgs/container/tebako-ubuntu-20.04 shall produce correct package that wiill work on Rocky Linux

There are some examples here:
https://github.com/tamatebako/tebako-samples/tree/maxirmx-rocky-linux

@laurent-martin
Copy link
Author

laurent-martin commented Sep 3, 2024

Thanks a lot.
I have tested 0.8.6, and now the generated executable works on Rocky 9.

podman run -it --rm -v $PWD:/mnt/w ghcr.io/tamatebako/tebako-ubuntu-20.04:0.8.6 tebako press --root=/mnt/w --entry-point=ascli --output=/mnt/w/ascli.exe --Ruby=3.2.4 --patchelf

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Status: Done
Development

No branches or pull requests

4 participants