Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 885835

Summary: dev-libs/gmp-6.2.1-r5 - ar: error: script line 1: unknown command: OPEN
Product: Gentoo Linux Reporter: topological-automata <safeguard_502>
Component: Current packagesAssignee: Gentoo Toolchain Maintainers <toolchain>
Status: UNCONFIRMED ---    
Severity: normal    
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Attachments: emerge-info
build.log
build.log.xz
Replace MRI OPEN script with ar qL invocation

Description topological-automata 2022-12-14 08:31:31 UTC
I'm trying to build gmp with slibtool, but I get the this error:

attached to this thread are emerge --info, and /var/tmp/portage/dev-libs/gmp-6.2.1/temp/build.log

p.s. I have many other with this error; what would be the best way to report them? a for loop and pybugz?
Comment 1 topological-automata 2022-12-14 08:32:17 UTC
Created attachment 842525 [details]
emerge-info

here is emerge --info
Comment 2 topological-automata 2022-12-14 08:36:45 UTC
Created attachment 842529 [details]
build.log

here is tail --lines 50 of build.log; the full build.log does not fit; if it's needed please let me know.
Comment 3 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2022-12-14 08:37:45 UTC
(In reply to safeguard_502 from comment #2)
> Created attachment 842529 [details]
> build.log
> 
> here is tail --lines 50 of build.log; the full build.log does not fit; if
> it's needed please let me know.

Can you get the full thing please (compress it with xz -9 or so)?
Comment 4 topological-automata 2022-12-14 09:49:31 UTC
Created attachment 842537 [details]
build.log.xz

here is the build.log.xz compressed via xz -9, as requested
Comment 5 Carlos 2022-12-18 17:51:54 UTC
Created attachment 843485 [details, diff]
Replace MRI OPEN script with ar qL invocation

I looked into this issue and it doesn't seem to be related to slibtool or gmp, but to llvm-ar. It doesn't support scripts with OPEN [1].

[1] https://llvm.org/docs/CommandGuide/llvm-ar.html#mri-scripts

This patch is unfortunately only usable for LLVM ar, as GNU ar and FreeBSD ar both seem to require OPEN + ADDLIB for this functionality. I'm leaving it here for the benefit of LLVM profile users like me, but making it conditional on ar supporting the L modifier is required before sending the patch upstream.