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
racket 8.12 segfaults immediately on Fedora #4981
Comments
Thanks for the report. Does something in the build process change the The symptom suggests that the boot file meant to be in the executable isn't being found, maybe because the relevant ELF section was removed. At the same time, it seems that |
Of course we strip and I suspect more these days. :-) Unfortunately the rpm .spec file is not directly visible there (it is in the .src.rpm files of course), but I can attach that too. I also did a Rawhide (devel version) aarch64 build. (Note these scratch build logs will disappear after 2 weeks) |
A more useful question from me would have been: is a |
I remembered you had found a solution in #3726 (comment):
|
This is the most relevant parts of the current .spec I am using: %prep
%autosetup -p1
# Remove bundled libffi
rm -r src/bc/foreign/libffi
%build
cd src
%configure \
--enable-pthread \
--enable-shared \
--enable-libffi \
--disable-libs \
--enable-lt="%{_bindir}/libtool" \
--disable-strip
%make_build
%install
%make_install -C src
# Delete mred binaries and replace them with links.
rm %{buildroot}%{_bindir}/mred
rm %{buildroot}%{_bindir}/mred-text
ln -s gracket %{buildroot}%{_bindir}/mred
ln -s gracket-text %{buildroot}%{_bindir}/mred-text
# Fix the rpath error.
chrpath --delete %{buildroot}%{_bindir}/racket
chrpath --delete %{buildroot}%{_libdir}/racket/gracket
# Fix paths in the desktop files.
sed -i "s#%{buildroot}##g" %{buildroot}/%{_datadir}/applications/*.desktop
# Validate desktop files
desktop-file-validate %{buildroot}/%{_datadir}/applications/*.desktop
# Remove the executable bit on legacy template file
chmod -x %{buildroot}%{_libdir}/racket/starter-sh
# disable check-buildroot for
# (see https://github.com/racket/racket/issues/3878 discussion)
%undefine __arch_install_post
%ldconfig_scriptlets See the above linked build.log's to see what the macros actually expand to and run. Do you have any pointers to linux build scripts to compare? |
The issue is specifically that the tool which strips the debug info from ELF files to form separate %global _find_debuginfo_opts --keep-section .rackboot There's a little more info on what happens by default here, under "Post-build ELF object processing" (the anchor within the page isn't working for me). There are other things that maybe should be tweaked, but probably better to get a working package before worrying about them. |
Thanks @LiberalArtist - that worked great! I wonder if there are any build-time tests I should run or at least way to verify the executable works. I would also be very grateful for any other suggestions on how to improve the fedora .spec file. |
Good news is Racket now builds on Fedora without any obvious problems -
the bad news is it segfaults immediately at startup
What version of Racket are you using?
8.12
What program did you run?
racket
What should have happened?
UI should start
If you got an error message, please include it here.
Please include any other relevant details
Happens for both Fedora Linux 39 and 40
What other information can I provide?
The text was updated successfully, but these errors were encountered: