Snowtar seems like a useful tool to have. I've made the appropriate C5 
compatibility changes (mostly just an egg file and cond-expands for imports), 
it'd be nice to have this in the C5 repo. I don't think I can actually push 
these changes upstream myself, or change the release-info file either, so I'm 
including a patch with my changes attached to this message. Hopefully someone 
with access can help me out here?

I may also port over snowdigest. Additionally, if anyone knows of a mirror for 
scheme now! packages/code, I'd love to explore these and package some up for C5 
(I'm awaiting on a response from the person who maintained the website, as far 
as I can tell). Looking on web archive, there's some pretty fun and interesting 
sounding stuff in there. Maybe we could create a snow compatibility egg to 
avoid code duplication across snow eggs.

- Diego


diff -uN snowtar-old/snow-compatibility.scm snowtar/snow-compatibility.scm
--- snowtar-old/snow-compatibility.scm	2019-09-16 13:47:22.858957823 -0400
+++ snowtar/snow-compatibility.scm	2019-09-16 13:50:39.929497771 -0400
@@ -1,7 +1,9 @@
 ;;;; snow-compatibility.scm
 
 
-(import (except miscmacros define-macro))
+(cond-expand
+ (chicken-4 (import (except miscmacros define-macro)))
+ (chicken-5 (import miscmacros)))
 
 
 (define-syntax-rule (define-alias-syntax new old)
@@ -93,7 +95,7 @@
   (blob->u8vector/shared (string->blob (get-output-string p))))
 
 (definternal (genport-read-file fname)
-  (blob->u8vector/shared (string->blob (read-all fname))))
+  (blob->u8vector/shared (string->blob (read-string #f fname))))
  
 
 ;;; homovector
diff -uN snowtar-old/snowtar.egg snowtar/snowtar.egg
--- snowtar-old/snowtar.egg	1969-12-31 19:00:00.000000000 -0500
+++ snowtar/snowtar.egg	2019-09-17 01:53:00.038609724 -0400
@@ -0,0 +1,8 @@
+((synopsis "TAR file format packing and unpacking.")
+ (category parsing)
+ (license "LGPL-2.1")
+ (author "Marc Feeley")
+ (maintainer "felix winkelmann")
+ (dependencies miscmacros)
+ (component-options (csc-options "-O3" "-d1"))
+ (components (extension snowtar (source "snowtar-module.scm"))))
diff -uN snowtar-old/snowtar-module.scm snowtar/snowtar-module.scm
--- snowtar-old/snowtar-module.scm	2019-09-16 13:47:23.062294910 -0400
+++ snowtar/snowtar-module.scm	2019-09-16 13:44:44.232858069 -0400
@@ -28,7 +28,11 @@
 		 tar-unpack-u8vector
 		 tar-read-file)
 
-(import scheme chicken)
+(import scheme)
+
+(cond-expand
+  (chicken-4 (import chicken))
+  (chicken-5 (import chicken.base)))
 
 (include "snowtar.scm")
 
diff -uN snowtar-old/snowtar.scm snowtar/snowtar.scm
--- snowtar-old/snowtar.scm	2019-09-16 13:47:23.575637709 -0400
+++ snowtar/snowtar.scm	2019-09-16 13:49:26.181329275 -0400
@@ -1,7 +1,20 @@
 ;;;; snowtar.scm
 
 
-(use srfi-4 numbers lolevel posix utils data-structures)
+(cond-expand
+  (chicken-4 (use srfi-4 numbers lolevel posix utils data-structures))
+  (chicken-5
+   (import srfi-4
+           chicken.condition
+           chicken.fixnum
+           chicken.blob
+           chicken.string
+           chicken.io
+           chicken.memory
+           chicken.syntax
+           chicken.time
+           chicken.file.posix
+           chicken.file)))
 
 (include "snow-compatibility.scm")
 
_______________________________________________
Chicken-users mailing list
[email protected]
https://lists.nongnu.org/mailman/listinfo/chicken-users

Reply via email to