Bug 476502 - binary and libraries are compiled with rpath
Summary: binary and libraries are compiled with rpath
Status: RESOLVED NOT A BUG
Alias: None
Product: KBibTeX
Classification: Applications
Component: Compiling/packaging (show other bugs)
Version: 0.10
Platform: openSUSE Linux
: NOR normal
Target Milestone: ---
Assignee: Thomas Fischer
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-11-03 11:38 UTC by Cor Blom
Modified: 2023-11-22 20:14 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Cor Blom 2023-11-03 11:38:20 UTC
SUMMARY
On openSUSE's OBS when building kbibtex 0.10 I get an error because rpaths are included. This is forbidden in the distro (and other distros).

NOTE: If you are reporting a crash, please try to attach a backtrace with debug symbols.
See https://community.kde.org/Guidelines_and_HOWTOs/Debugging/How_to_create_useful_crash_reports
***


STEPS TO REPRODUCE
1. Build a package of kbibtex on OBS
2. See the rpmlint output
3. Build fails because of presence rpath in binary and libraries

OBSERVED RESULT


EXPECTED RESULT
Either there is an option to disable rpath, or the buildsystem must be updated to make this possible or that rpath is removed.

SOFTWARE/OS VERSIONS
Linux/KDE Plasma: openSUSE
(available in About System)
KDE Plasma Version: 5.27.9
KDE Frameworks Version: 
Qt Version: 

ADDITIONAL INFORMATION
See https://en.opensuse.org/openSUSE:Packaging_checks
and: https://wiki.debian.org/RpathIssue
Comment 1 Thomas Fischer 2023-11-18 21:55:06 UTC
There is no explicit setting of RPATH in KBibTeX's source code. Please provide additional information how/where KBibTeX differs from other KDE applications in respect of its handling of RPATH.
Comment 2 Cor Blom 2023-11-19 13:23:52 UTC
Sorry, cannot help you with that. I maintain kbibtex for openSUSE and with this new version there is a rpmlint check that complains about RPATH. There is a workaround that I use (chrpath). I don't know anything about build systems apart from being able to compile a program.
Comment 3 Thomas Fischer 2023-11-20 21:22:35 UTC
(In reply to Cor Blom from comment #2)
> Sorry, cannot help you with that. I maintain kbibtex for openSUSE and with
> this new version there is a rpmlint check that complains about RPATH. There
> is a workaround that I use (chrpath). I don't know anything about build
> systems apart from being able to compile a program.
Ok. Can you check how other KDE program's packages handle RPATH? For example, passing additional arguments to cmake, patching the build system, or simply ignoring the whole issue? Best check for Extra Gear programs that are not (yet) part of the KDE Applications release.
Comment 4 Cor Blom 2023-11-20 22:57:13 UTC
(In reply to Thomas Fischer from comment #3)
> (In reply to Cor Blom from comment #2)
> > Sorry, cannot help you with that. I maintain kbibtex for openSUSE and with
> > this new version there is a rpmlint check that complains about RPATH. There
> > is a workaround that I use (chrpath). I don't know anything about build
> > systems apart from being able to compile a program.
> Ok. Can you check how other KDE program's packages handle RPATH? For
> example, passing additional arguments to cmake, patching the build system,
> or simply ignoring the whole issue? Best check for Extra Gear programs that
> are not (yet) part of the KDE Applications release.

I don't see anything that can explain this. RPATH is not mentioned. As far as I understand the default cmake behavior is that RPATH is used during build but removed during install, so no special treatment should be necessary.

The only thing I could find is:

https://gitlab.kitware.com/cmake/community/-/wikis/doc/cmake/RPATH-handling#caveats

This is really not my area of expertise. Sorry.
Comment 5 Thomas Fischer 2023-11-22 19:02:18 UTC
> I don't see anything that can explain this. RPATH is not mentioned. As far
> as I understand the default cmake behavior is that RPATH is used during
> build but removed during install, so no special treatment should be
> necessary.
> [...]
> This is really not my area of expertise. Sorry.
Ok, I'll close this bug for now as "not a bug". I am not aware that any other Linux distribution's packager has similar problems, so it could be something specific to openSUSE and/or RPM. Best if you would ask in the openSUSE/KDE community how to proceed.
Feel free to re-open this bug in case new information becomes available.
Comment 6 Cor Blom 2023-11-22 20:14:56 UTC
OK. Is asked on the openSUSE list and the suggestion was to add -DCMAKE_SKIP_RPATH=FALSE and -DCMAKE_SKIP_INSTALL_RPATH=TRUE to cmake, which solves the issue. Still not clear why kbibtex needs this and other apps not. I'll let you know when I hear something about that.