mirror of
https://gitlab.com/embeddable-common-lisp/ecl.git
synced 2025-12-05 18:30:24 -08:00
Compare commits
4 commits
1b93843a9a
...
eee3007827
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
eee3007827 | ||
|
|
34afd9a6d3 | ||
|
|
e09f0d9742 | ||
|
|
bb3f48af4e |
3 changed files with 21 additions and 14 deletions
|
|
@ -38,12 +38,20 @@
|
|||
(defun host-type-record (host-type)
|
||||
(ext:if-let ((record (gethash host-type (machine-host-type-hash *machine*))))
|
||||
record
|
||||
(cmperr "Not a valid C type name ~A" host-type)))
|
||||
(if ffi::*ffi-types*
|
||||
(let ((ffi-type (gethash host-type ffi::*ffi-types*)))
|
||||
(if ffi-type
|
||||
(host-type-record ffi-type)
|
||||
(cmperr "Not a valid FFI type name ~A" host-type)))
|
||||
(cmperr "Not a valid C type name ~A" host-type))))
|
||||
|
||||
|
||||
(defun host-type->lisp-type (name)
|
||||
(let ((output (host-type-record-unsafe name)))
|
||||
(cond (output
|
||||
(host-type-lisp-type output))
|
||||
(let ((output (host-type-record-unsafe name))
|
||||
(ffi-type (when ffi::*ffi-types*
|
||||
(gethash name ffi::*ffi-types*))))
|
||||
(cond (output (host-type-lisp-type output))
|
||||
(ffi-type (host-type->lisp-type ffi-type))
|
||||
((lisp-type-p name) name)
|
||||
(t (error "Unknown representation type ~S" name)))))
|
||||
|
||||
|
|
|
|||
|
|
@ -52,20 +52,19 @@ coprocessor).")
|
|||
#+msvc "~A -Fe~S~* ~{~S ~} ~@[~S~]~{ '~A'~} ~A")
|
||||
|
||||
(defconfig *cc-format* (cond ((member :msvc *features*)
|
||||
"~A -I. \"-I~A\" ~A ~:[~*~;~A~] -w -c \"~A\" -o \"~A\"~{ '~A'~}")
|
||||
((member :nacl *features*) ;; pnacl-clang doesn't support -w
|
||||
"~A -I. \"-I~A\" ~A ~:[~*~;~A~] -c \"~A\" -o \"~A\"~{ '~A'~}")
|
||||
(t
|
||||
"~A -I. \"-I~A\" ~A ~:[~*~;~A~] -w -c \"~A\" -o \"~A\"~{ '~A'~}")))
|
||||
"~A -I. \"-I~A\" ~A ~:[~*~;~A~] -w -c \"~A\" -o \"~A\"~{ '~A'~}")
|
||||
((member :nacl *features*) ;; pnacl-clang doesn't support -w
|
||||
"~A -I. \"-I~A\" ~A ~:[~*~;~A~] -c \"~A\" -o \"~A\"~{ '~A'~}")
|
||||
(t
|
||||
"~A -I. \"-I~A\" ~A ~:[~*~;~A~] -w -c \"~A\" -o \"~A\"~{ '~A'~}")))
|
||||
|
||||
(defconfig *ld-flags* "@LDFLAGS@")
|
||||
#-dlopen
|
||||
(defconfig *ld-libs* "-lecl @CORE_LIBS@ @FASL_LIBS@ @LIBS@")
|
||||
#+dlopen
|
||||
(defconfig *ld-libs* #-msvc "-lecl @FASL_LIBS@ @LIBS@"
|
||||
#+msvc "ecl.lib @CLIBS@")
|
||||
(defconfig *ld-shared-flags* #+dlopen "@SHARED_LDFLAGS@ @LDFLAGS@")
|
||||
(defconfig *ld-bundle-flags* #+dlopen "@BUNDLE_LDFLAGS@ @LDFLAGS@")
|
||||
(defconfig *ld-libs* #-msvc "-lecl @FASL_LIBS@ @LIBS@" #+msvc "ecl.lib @CLIBS@")
|
||||
(defconfig *ld-shared-flags* #+dlopen "@SHARED_LDFLAGS@ @LDFLAGS@" #-dlopen "")
|
||||
(defconfig *ld-bundle-flags* #+dlopen "@BUNDLE_LDFLAGS@ @LDFLAGS@" #-dlopen "")
|
||||
(defconfig *ld-program-flags* "@PROGRAM_LDFLAGS@ @LDFLAGS@")
|
||||
|
||||
(defconfig +shared-library-prefix+ "@SHAREDPREFIX@")
|
||||
|
|
|
|||
|
|
@ -101,7 +101,7 @@ compiled successfully, returns the pathname of the compiled file."
|
|||
(setq *compile-file-pathname* (make-pathname :type ext :defaults input-pathname))
|
||||
(when (probe-file *compile-file-pathname*)
|
||||
(return)))))
|
||||
(when (and system-p load)
|
||||
(when (and system-p load (not *cross-compiling*))
|
||||
(error "Cannot load system files."))
|
||||
(cmpprogress "~&;;;~%;;; Compiling ~a~:[~; for target ~a~]."
|
||||
(namestring input-pathname)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue