-
Notifications
You must be signed in to change notification settings - Fork 77
Files unpacked from tarballs bear the archived mtime (SBCL, Allegro) #154
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
This is the default behaviour of GNU tar and useful in cases where the archives of a dist are downloaded, but not yet unpacked. Implementations other than Allegro and SBCL retain the current behaviour: the modification time of the file is the time when the archive was unpacked.
A case where this functionality is handy is a Docker image, where the QL dist archives are downloaded, but not unpacked: |
Can you tell me more about why this matters? What happens if it is not done? |
The rationale for that Docker image is to have a specific distribution of QL at hand, even in environments where no internet connectivity is available (or allowed out of security considerations). The referenced Docker image downloads all archives of a specific QL dist by using ensure-local-archive-file at build time but doesn't unpack the archives to keep the image size as small as possible:
Due to the design of Docker, the storage of a running container is ephemeral. To quote the current documentation:
This means that everytime the running image is stopped, the unpacked But it is possible to use a 'bind mount' to mount a directory of the Docker host into the running Docker instance. When using the image during development, it would be very convenient to mount ~/.cache/common-lisp into the container ( Without this patch, the unpacked lisp files have a current mtime. This mtime is compared to the mtime of the fasl files in the With this patch, the unpacked lisp file has the same mtime it has in the tarball. Because the mtime of the fasls in Sorry for the lengthy explanation and I hope it is clear enough. |
Apply the patch which was submitted as quicklisp/quicklisp-client#154 to have the lisp files be unpacked with the timestamp which they have inside the tar archive.
Apply the patch which was submitted as quicklisp/quicklisp-client#154 to have the lisp files be unpacked with the timestamp which they have inside the tar archive.
Apply the patch which was submitted as quicklisp/quicklisp-client#154 to have the lisp files be unpacked with the timestamp which they have inside the tar archive.
Apply the patch which was submitted as quicklisp/quicklisp-client#154 to have the lisp files be unpacked with the timestamp which they have inside the tar archive.
Thanks for the explanation. This makes sense. I'd need support for all Lisps that Quicklisp supports to accept this change. |
Can't you just do a bind mount of the places the sources get unpacked as well? Then you need to rebuild once, when the Docker image gets booted the first time on a given host, which you need to do anyway, and you'd avoid a complicated mass of implementation-specific code. |
This is the default behaviour of GNU tar and useful in cases where the
archives of a dist are downloaded, but not yet unpacked.
Implementations other than Allegro and SBCL retain the current
behaviour: the modification time of the file is the time when the
archive was unpacked.