about summary refs log tree commit diff
diff options
context:
space:
mode:
authorsterni <sternenseemann@systemli.org>2024-12-02T22·28+0100
committerclbot <clbot@tvl.fyi>2024-12-02T23·09+0000
commit604296bb7c2743be60e66e8390498580b2402997 (patch)
tree484eb3d5af557faee298bb882ec4b7b4d338b3a1
parent302297cfe3f475a826a020433c3243ae82b1070a (diff)
feat(3p/lisp/mime4cl): enable compilation with CCL r/8979
Only significant implementation specific code at the moment is FILE-SIZE
which isn't very important. We can also easily implement it for CCL.

Additionally, we clean up an unused lexical variable warning and remove
a duplicate definiton of MIME-TYPE-STRING fro MIME-UNKNOWN-PART that CCL
doesn't like.

Change-Id: I7c960e50dcdc1d3e46cb4945f36ea315a3c9838d
Reviewed-on: https://cl.tvl.fyi/c/depot/+/12862
Autosubmit: sterni <sternenseemann@systemli.org>
Reviewed-by: sterni <sternenseemann@systemli.org>
Tested-by: BuildkiteCI
-rw-r--r--third_party/lisp/mime4cl/default.nix1
-rw-r--r--third_party/lisp/mime4cl/ex-sclf.lisp3
-rw-r--r--third_party/lisp/mime4cl/mime.lisp4
-rw-r--r--users/sterni/mblog/default.nix2
4 files changed, 3 insertions, 7 deletions
diff --git a/third_party/lisp/mime4cl/default.nix b/third_party/lisp/mime4cl/default.nix
index af015a257bf2..c83d5e4ffce1 100644
--- a/third_party/lisp/mime4cl/default.nix
+++ b/third_party/lisp/mime4cl/default.nix
@@ -45,7 +45,6 @@ depot.nix.buildLisp.library {
 
   # limited by sclf
   brokenOn = [
-    "ccl"
     "ecl"
   ];
 }
diff --git a/third_party/lisp/mime4cl/ex-sclf.lisp b/third_party/lisp/mime4cl/ex-sclf.lisp
index bf5b157d167d..8b71a2f2c6c9 100644
--- a/third_party/lisp/mime4cl/ex-sclf.lisp
+++ b/third_party/lisp/mime4cl/ex-sclf.lisp
@@ -274,7 +274,8 @@ ELEMENT-TYPE."
 ;; file; just ask politely.
 (defun file-size (pathname)
   #+sbcl (sb-posix:stat-size (sb-posix:stat pathname))
-  #-sbcl (error "nyi"))
+  #+ccl (ccl:file-data-size pathname)
+  #-(or sbcl ccl) (error "nyi"))
 
 ;; LAZY
 
diff --git a/third_party/lisp/mime4cl/mime.lisp b/third_party/lisp/mime4cl/mime.lisp
index eeddea970603..18c9e7bbb029 100644
--- a/third_party/lisp/mime4cl/mime.lisp
+++ b/third_party/lisp/mime4cl/mime.lisp
@@ -500,6 +500,7 @@ separated by PART-BOUNDARY."
   (encode-mime-part (mime-body part) stream))
 
 (defmethod encode-mime-part ((part mime-multipart) stream)
+  (declare (ignore stream)) ; call-next-method
   ;; choose a boundary if not already set
   (let* ((original-boundary (get-mime-type-parameter part :boundary))
          (boundary (choose-boundary (mime-parts part) original-boundary)))
@@ -998,9 +999,6 @@ is a string."))
   (:documentation
    "Return the string describing the MIME part."))
 
-(defmethod mime-type-string ((part mime-unknown-part))
-  (mime-type part))
-
 (defmethod mime-type-string ((part mime-text))
   (format nil "text/~A" (mime-subtype part)))
 
diff --git a/users/sterni/mblog/default.nix b/users/sterni/mblog/default.nix
index 6ad8a10ce378..e9a1d304fdfb 100644
--- a/users/sterni/mblog/default.nix
+++ b/users/sterni/mblog/default.nix
@@ -31,9 +31,7 @@
 
   main = "cli:main";
 
-  # due to sclf
   brokenOn = [
-    "ccl"
     "ecl"
   ];
 }).overrideAttrs (super: {