Ticket #4461: disable-ffi.patch

File disable-ffi.patch, 1.8 KB (added by bpage, 13 years ago)

disable FFI in fricas

  • src/interp/util.lisp

    diff -ru fricas.bb2/src/interp/util.lisp fricas/src/interp/util.lisp
    old new  
    13011301                    (sb-alien::load-shared-object spad-lib)
    13021302                    #+:openmcl
    13031303                    (ccl::open-shared-library spad-lib)
    1304                     #+:clisp
     1304                    #+(and :clisp :ffi)
    13051305                    (progn
    13061306                        (eval `(FFI:DEFAULT-FOREIGN-LIBRARY ,spad-lib))
    13071307                        (FRICAS-LISP::clisp-init-foreign-calls)))
    13081308                (setf $openServerIfTrue nil))))
    1309     #+(or :gcl :clisp :sbcl :openmcl :ecl)
     1309    #+(or :gcl (and :clisp :ffi) :sbcl :openmcl :ecl)
    13101310    (if $openServerIfTrue
    13111311        (let ((os (|openServer| $SpadServerName)))
    13121312             (format t "openServer result ~S~%" os)
  • src/lisp/fricas-lisp.lisp

    diff -ru fricas.bb2/src/lisp/fricas-lisp.lisp fricas/src/lisp/fricas-lisp.lisp
    old new  
    240240
    241241)
    242242
    243 #+:clisp
     243#+(and :clisp :ffi)
    244244(eval-when (:compile-toplevel :load-toplevel :execute)
    245245
    246246(setf *c-type-to-ffi* '(
     
    382382
    383383(defmacro foreign-defs (&rest arguments)
    384384    #-:clisp `(progn ,@arguments)
    385     #+:clisp `(defun clisp-init-foreign-calls () ,@arguments)
     385    #+(and :clisp :ffi) `(defun clisp-init-foreign-calls () ,@arguments)
    386386)
    387387
    388388(foreign-defs
     
    453453            buf))
    454454
    455455)
    456 #+:clisp
     456#+(and :clisp :ffi)
    457457(eval '(FFI:DEF-CALL-OUT sock_get_string_buf
    458458    (:NAME "sock_get_string_buf")
    459459    (:arguments (purpose ffi:int)
     
    464464
    465465)
    466466
    467 #+:clisp
     467#+(and :clisp :ffi)
    468468(defun |sockGetStringFrom| (purpose)
    469469    (let ((buf nil))
    470470        (FFI:WITH-C-VAR (tmp-buf '(FFI:C-ARRAY