snowtar C5 patch added by dieggsy on Mon Sep 16 19:53:30 2019

diff -u 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 -u 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 -u 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")
 
--- 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 -u 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 -u 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")