--- a/src/maxima.system	2021-12-02 00:26:23.955984864 -0300
+++ b/src/maxima.system	2021-12-02 00:31:22.299541969 -0300
@@ -87,13 +87,15 @@
       (let ((obj (mapcar #'(lambda (p)
 			     ;; Convert dir/foo.fas to dir/foo.o
 			     (make-pathname :type "o" :defaults p))
-			 files)))
-	(c::build-fasl "binary-ecl/maxima" :lisp-files obj
+			 files))
+			(lib '("binary-ecl/libmaxima-ecl.so")))
+	(c::build-shared-library "binary-ecl/maxima-ecl" :lisp-files obj)
+	(c::build-fasl "binary-ecl/maxima" :lisp-files lib
 			  :ld-flags
 			  (let ((x (symbol-value (find-symbol "*AUTOCONF-LD-FLAGS*"
 							      (find-package "MAXIMA")))))
 			    (if (and x (not (string= x ""))) (split-string x))))
-	(c::build-program "binary-ecl/maxima" :lisp-files obj
+	(c::build-program "binary-ecl/maxima" :lisp-files lib
 			  :ld-flags
 			  (let ((x (symbol-value (find-symbol "*AUTOCONF-LD-FLAGS*"
 							      (find-package "MAXIMA")))))
