Re: Two (possibly related) issue w/ 4.18.x rpmbuild

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 3/17/23 00:08, Michael Peters wrote:
Hi. I suspect these issues are with MY system and not RPM itself.
First observed with 4.18.0 but also present with 4.18.1

No earlier version was tried.

Linux From Scratch (LFS) 11.3 system I built at beginning of march and am RPM bootstrapping. It's currently a very minimal system with just the LFS stuff plus cURL and it's dependencies (using GnuTLS) and RPM and it's dependencies.

x86_64 system but it's not multiarch (so I am setting %_lib to lib and %_libdir to /usr/lib)

Big issue: RPM removes the execution bit on shared object files. First package I built was glibc and of course installing the resulting RPM broke the system because the shared libraries were not executable.

I noticed when I add /bin/false at the end of the %install section - the installed library and object files have the execution bit - it's one of the post scriptlets leaving them non-exucatable.

Workaround is to explicitly set %attr(0755,root,root) on shared object files in the %files section but obviously I want to fix why this happens.

Interestingly it does NOT remove the execution bit from executable binaries, only shared objects (shared libraries and plugins)

Most shared libraries are NOT executable, and should not be packaged as such. Which is why rpm automatically strips the executable flags from those deemed only shared libraries via brp-elfperms script after the install stage. glibc (ld*.so rather) being the special case of course.

Rpm is supposed to leave those *actually* executable libraries alone, but this isn't working as intended, I can reproduce it here. A bit surprising it hasn't been reported on any of the major distros, but perhaps they do have those explicit permissions set.

I'd actually recommend just setting those explicit permissions with %attr(), that makes the critically important special case stand out and serves as a protection against other mishaps too.

That said, those brp scripts can be disabled as well, for this particular, put this in the spec needing override:

%define brp_elfdeps %{nil}


Second issue - everything I build gives a warning of missing build-id.

So I suspect either there is an undocumented dependency I am missing, or a tool-chain compile-time option that wasn't used when compiling the toolchain.

Any ideas as to what is causing that?

AIUI it means that the compiler/linker didn't generate a proper build-id for binaries. I suppose this would be a configure option to gcc or such, at least in Fedora gcc adds build-ids automatically to all builds. Being early in bootstrapping you might just want to disable as Scott suggested.

	- Panu -


elfutils is installed (0.188) with eu- prefix on the elfutils binaries.

Thank you for any suggestions.

_______________________________________________
Rpm-list mailing list
Rpm-list@xxxxxxxxxxxxx
http://lists.rpm.org/mailman/listinfo/rpm-list

_______________________________________________
Rpm-list mailing list
Rpm-list@xxxxxxxxxxxxx
http://lists.rpm.org/mailman/listinfo/rpm-list



[Index of Archives]     [RPM Ecosystem]     [Linux Kernel]     [Red Hat Install]     [PAM]     [Red Hat Watch]     [Red Hat Development]     [Red Hat]     [Gimp]     [Yosemite News]     [IETF Discussion]

  Powered by Linux