Improve the translation of notequal
[maxima.git] / lisp-utils / convert-fortran.lisp
blob52eff76580a7c664ca721e412dad5dd6bfd3131a
1 ;; Simple script to convert all of the Fortran sources to lisp.
2 ;;
3 ;; This should be run from the root of the maxima source tree. We go
4 ;; one by one and load the appropriate defsystem file and run mk:oos
5 ;; to convert the Fortran sources to Lisp. These are not done in any
6 ;; particular order.
7 ;;
8 ;; Note that the current conversion was done using CMUCL. It's
9 ;; probably best to continue to use CMUCL to do the conversion. Why?
10 ;; So that the diffs between conversions are minimized. Other than
11 ;; this, any Lisp that can run f2cl can be used to do the conversion.
13 ;; This can be done from a running maxima-local:
15 ;; :lisp (load "lisp-utils/convert-fortran")
17 ;; For this to work, you must have f2cl available. If REQUIRE doesn't
18 ;; work, you'll have to load f2cl yourself.
19 (require :f2cl)
21 (defun convert-system (system-name system-file &optional (clear-info t))
22 (when clear-info
23 ;; Clear the function info in case the various packages have
24 ;; functions with the same name but different parameters or return
25 ;; type.
26 (f2cl::clear-f2cl-finfo))
27 (load system-file)
28 (mk:oos system-name :compile :force t))
30 (convert-system "slatec" "src/numerical/slatec/slatec.system")
31 (convert-system "lbfgs-lisp" "share/lbfgs/lbfgs-lisp.system")
32 (convert-system "minpack-lisp" "share/minpack/minpack-lisp.system")
34 ;; BLAS and LAPACK should be compiled in this order. And we probably
35 ;; don't want to clear out the f2cl function info when compiling
36 ;; LAPACK since LAPACK calls some BLAS routines.
37 (convert-system "blas-lisp" "share/lapack/blas/blas-lisp.system")
38 (convert-system "lapack-lisp" "share/lapack/lapack/lapack-lisp.system" nil)
40 (convert-system "colnew-lisp" "share/colnew/colnew-lisp.system")