Opened 10 months ago

Closed 10 months ago

Last modified 10 months ago

#67905 closed defect (fixed)

p5-mozilla-ca @20230801 does not extract using system tar on 10.11.6 and 10.10

Reported by: snowflake (Dave Evans) Owned by: ryandesign (Ryan Carsten Schmidt)
Priority: Normal Milestone:
Component: ports Version: 2.8.99
Keywords: Cc: pcafstockf (Frank Stock)
Port: p5-mozilla-ca

Description

Running the system tar for macOS 10.11.6 on the distfile gives these errors:

tar: Ignoring malformed pax extended attribute
tar: Error exit delayed from previous errors.

and the exit status is 1.

Running Macports gnutar works with a couple of PAX warnings.

Change History (10)

comment:1 Changed 10 months ago by ryandesign (Ryan Carsten Schmidt)

We show the same failure on the 10.10 buildbot worker:

https://build.macports.org/builders/ports-10.10_x86_64-builder/builds/234067/steps/install-port/logs/stdio

The port is classified as not differing by OS version or architecture, so it only needs to be built by one of our buildbot workers and that archive is then made available to all OS versions. But that doesn't help you if your MacPorts installation is such that you cannot use our archives.

The port has no maintainer. Could you report the broken tarball issue to the developers of this module? Maybe they can release a new version with a more compatibly-packaged tarball.

comment:2 Changed 10 months ago by snowflake (Dave Evans)

I fixed it by installing from the Macports' archive.

comment:3 Changed 10 months ago by pcafstockf (Frank Stock)

The problem is that in the tarball, 'xattr.com.apple.provenance' gets attached to the 'Mozilla-CA-20230801/README' file and the 'Mozilla-CA-20230801/lib/Mozilla' directory.
System tar on older macOS do not know how to process these attributes. Indeed it seems that thanks to SIP, they can only be removed with great difficulty (https://eclecticlight.co/2023/03/13/ventura-has-changed-app-quarantine-with-a-new-xattr/).

Unfortunately I need a to create a binary package that depends on p5-mozilla-ca which must be installable on a machine that may or may not have macports installed (e.g. Xcode may not be allowed), and so I have to set up a custom MacPorts install (https://guide.macports.org/#installing.macports.source.multiple).
This in turn makes the solution suggested by @snowflake a non-starter for me.

I'm a long time MacPorts user and open source contributor, but a noob wrt creating / modifying ports, and have not yet figured out how the tarball itself gets created.
If by "report the broken tarball issue to the developers", you mean file a GitHub issue, then I have now done that (https://github.com/libwww-perl/Mozilla-CA/issues/21).
If you meant something else, could you please elaborate?

If all else fails, some guidance on how I can fix this would be much appreciated. I see from the original posting that I could create a local Portfile, override and modify it to use gnutar, but that really doesn't fix the problem for other users.

comment:4 Changed 10 months ago by snowflake (Dave Evans)

As the original poster, just to clarify, I did not do anything to the port file. I just did an update without the -s option, so as to fetch the Macports binary archive. This worked, so I assumed the buildbots were using a different version of tar to extract the tar.gz file.

comment:5 in reply to:  3 Changed 10 months ago by ryandesign (Ryan Carsten Schmidt)

Replying to pcafstockf:

The problem is that in the tarball, 'xattr.com.apple.provenance' gets attached to the 'Mozilla-CA-20230801/README' file and the 'Mozilla-CA-20230801/lib/Mozilla' directory.
System tar on older macOS do not know how to process these attributes.

How did you determine that this was the problem? I haven't investigated it but it doesn't seem likely to me. You're talking about extended filesystem attributes—additional metadata that can be attached to any file or directory. Significantly, they are not part of the file data. However tar here is complaining about extended pax attributes, which are a completely different thing and are part of the file data (they are part of how tar files work).

If by "report the broken tarball issue to the developers", you mean file a GitHub issue, then I have now done that (https://github.com/libwww-perl/Mozilla-CA/issues/21).

Yes, that's what I meant. They created the tarball that has the problem; I'm hoping they will create a new tarball that doesn't have the problem. We can work around it by having the portfile use gnutar instead but we'd rather not have to do that.

comment:6 Changed 10 months ago by ryandesign (Ryan Carsten Schmidt)

Cc: pcafstockf added

Frank, Ccing you so you get notifications. Please see my comment above in the ticket.

comment:7 Changed 10 months ago by pcafstockf (Frank Stock)

Thanks everyone.

I think I understand a little more now, enough to recognize that this discussion is probably best continued on (​https://github.com/libwww-perl/Mozilla-CA/issues/21).

I will describe the problem I see a little more clearly there, and report back to this thread if need be.

comment:8 Changed 10 months ago by ryandesign (Ryan Carsten Schmidt)

Owner: set to ryandesign
Status: newaccepted

The developers state version 20230807 should fix this. I was going to update the port shortly.

comment:9 Changed 10 months ago by ryandesign (Ryan Carsten Schmidt)

Resolution: fixed
Status: acceptedclosed

In c09edf4e40bcf52127208f1f21e3ab84addf0e38/macports-ports (master):

p5-mozilla-ca: Update to 20230807

Closes: #67905

comment:10 Changed 10 months ago by pcafstockf (Frank Stock)

At the risk of a little extra spam...

I can confirm this works for a custom/multiple MacPorts install, creating a binary package on macOS High Sierra.

Thank you to all of you who not only helped fill in my knowledge gaps, but also ultimately provided the fix!

Note: See TracTickets for help on using tickets.