You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The use of cpio in bakeware is pretty simplistic and shelling out was done for expediency during the competition. Several people have reported issues with shelling out and it seems simpler just to avoid the issue.
Here's how we use cpio:
For each file and directory in the release do the following:
Run stat to get the file/directory's type, permissions, etc.
Write the CPIO header
If a file, write its contents
When done, write the CPIO trailer
The CPIO header is a fixed length text string. You can see it at https://github.com/bake-bake-bake/bakeware/blob/main/src/cpio.c#L74. The hardest part, I think, is getting the padding correct. Many of the fields are ignored. Forcing those to 0 seems better than trying to get them right for deterministic builds and better compression.
The text was updated successfully, but these errors were encountered:
The use of
cpio
inbakeware
is pretty simplistic and shelling out was done for expediency during the competition. Several people have reported issues with shelling out and it seems simpler just to avoid the issue.Here's how we use
cpio
:The CPIO header is a fixed length text string. You can see it at https://github.com/bake-bake-bake/bakeware/blob/main/src/cpio.c#L74. The hardest part, I think, is getting the padding correct. Many of the fields are ignored. Forcing those to
0
seems better than trying to get them right for deterministic builds and better compression.The text was updated successfully, but these errors were encountered: