RHEL7 with LinuxFilePath gives unknown file type #60

Closed
opened 2026-01-29 16:28:22 +00:00 by claunia · 6 comments
Owner

Originally created by @claunia on GitHub (Jun 29, 2019).

Originally assigned to: @qmfrederik on GitHub.

error: unpacking of archive failed on file /usr/share/pixmaps/XXXX.svg:5d1752d7: cpio: Unknown file type
error: xxxx: install failed

from

    <Content Include="Assets/xxxxxxx-logo.svg" CopyToPublishDirectory="PreserveNewest" LinuxFileMode="0644">
      <LinuxPath>/usr/share/pixmaps/xxxxxxxx.svg</LinuxPath>
    </Content>
Originally created by @claunia on GitHub (Jun 29, 2019). Originally assigned to: @qmfrederik on GitHub. ``` error: unpacking of archive failed on file /usr/share/pixmaps/XXXX.svg:5d1752d7: cpio: Unknown file type error: xxxx: install failed ``` from ```xml <Content Include="Assets/xxxxxxx-logo.svg" CopyToPublishDirectory="PreserveNewest" LinuxFileMode="0644"> <LinuxPath>/usr/share/pixmaps/xxxxxxxx.svg</LinuxPath> </Content> ```
Author
Owner

@claunia commented on GitHub (Jun 29, 2019):

Seems to happen even if it's not in LinuxPath mmm.

@claunia commented on GitHub (Jun 29, 2019): Seems to happen even if it's not in LinuxPath mmm.
Author
Owner

@claunia commented on GitHub (Jun 29, 2019):

If I remove LinuxPath it still does not work, if I change Content to None it works but LinuxPath is ignored.
It works if I remove LinuxFileMode.

@claunia commented on GitHub (Jun 29, 2019): If I remove LinuxPath it still does not work, if I change Content to None it works but LinuxPath is ignored. It works if I remove LinuxFileMode.
Author
Owner

@franklupo commented on GitHub (Sep 12, 2019):

Same problem.

News?

Best regards

@franklupo commented on GitHub (Sep 12, 2019): Same problem. News? Best regards
Author
Owner

@clemensv commented on GitHub (Dec 4, 2019):

Having that same issue on Fedora. LinuxFileMode causes that error.

@clemensv commented on GitHub (Dec 4, 2019): Having that same issue on Fedora. LinuxFileMode causes that error.
Author
Owner

@qmfrederik commented on GitHub (Dec 4, 2019):

Thanks. I've been doing some work in this area recently. Let me see if I find some time this week to dive into this.

@qmfrederik commented on GitHub (Dec 4, 2019): Thanks. I've been doing some work in this area recently. Let me see if I find some time this week to dive into this.
Author
Owner

@qmfrederik commented on GitHub (Dec 5, 2019):

The underlying issue was that when you use LinuxFileMode to set the lower values of the file mode (e.g. the permissions, such as 755), the file type (S_IFREG, or 10000 in octal) was not set properly. This caused cpio to rightfully complain on some older versions of RHEL/CentOS.

This has been fixed with #138 and should be on NuGet soon. I'm also fairly sure this fixes the issue with the sticky bits & friends.

@qmfrederik commented on GitHub (Dec 5, 2019): The underlying issue was that when you use `LinuxFileMode` to set the lower values of the file mode (e.g. the permissions, such as `755`), the file type (`S_IFREG`, or `10000` in octal) was not set properly. This caused `cpio` to rightfully complain on some older versions of RHEL/CentOS. This has been fixed with #138 and should be on NuGet soon. I'm also fairly sure this fixes the issue with the sticky bits & friends.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/dotnet-packaging#60