mirror of
https://github.com/justinethier/cyclone.git
synced 2025-07-13 07:47:39 +02:00
Issue #354 - Cleanup
This commit is contained in:
parent
bc3ab62439
commit
77a02fe26d
1 changed files with 6 additions and 17 deletions
21
cyclone.scm
21
cyclone.scm
|
@ -56,25 +56,16 @@
|
||||||
includes))
|
includes))
|
||||||
(base (basename sld-file))
|
(base (basename sld-file))
|
||||||
(obj-file (string-append base ".o"))
|
(obj-file (string-append base ".o"))
|
||||||
(sys-dir (Cyc-installation-dir 'sld))
|
(sys-dir (Cyc-installation-dir 'sld)) )
|
||||||
)
|
|
||||||
; DEBUG:
|
|
||||||
;(display (list lib-dep "includes" included-files) (current-error-port))
|
|
||||||
;(newline (current-error-port))
|
|
||||||
(and
|
(and
|
||||||
(not (in-subdir? sys-dir sld-file)) ;; Never try to recompile installed libraries
|
(not (in-subdir? sys-dir sld-file)) ;; Never try to recompile installed libraries
|
||||||
(or
|
(or
|
||||||
(not (file-exists? obj-file)) ;; No obj file, must rebuild
|
(not (file-exists? obj-file)) ;; No obj file, must rebuild
|
||||||
(any (lambda (src-file)
|
(any
|
||||||
(let ((result (> (file-mtime src-file)
|
(lambda (src-file)
|
||||||
|
(> (file-mtime src-file)
|
||||||
(file-mtime obj-file))) ;; obj file out of date
|
(file-mtime obj-file))) ;; obj file out of date
|
||||||
)
|
(cons sld-file included-files))))))
|
||||||
; (when result
|
|
||||||
;(display (list "DEBUG src file newer than obj" src-file obj-file) (current-error-port))
|
|
||||||
;(newline (current-error-port)))
|
|
||||||
result))
|
|
||||||
(cons sld-file included-files))
|
|
||||||
))))
|
|
||||||
|
|
||||||
;; Is "path" under given subdirectory "dir"?
|
;; Is "path" under given subdirectory "dir"?
|
||||||
(define (in-subdir? dir path)
|
(define (in-subdir? dir path)
|
||||||
|
@ -288,8 +279,6 @@
|
||||||
(for-each
|
(for-each
|
||||||
(lambda (lib-dep)
|
(lambda (lib-dep)
|
||||||
(when (recompile? lib-dep append-dirs prepend-dirs)
|
(when (recompile? lib-dep append-dirs prepend-dirs)
|
||||||
;(write `(DEBUG auto compile ,lib-dep) (current-error-port))
|
|
||||||
;(newline (current-error-port))
|
|
||||||
(system (string-append "cyclone "
|
(system (string-append "cyclone "
|
||||||
(lib:import->filename lib-dep ".sld" append-dirs prepend-dirs)))))
|
(lib:import->filename lib-dep ".sld" append-dirs prepend-dirs)))))
|
||||||
lib-deps))
|
lib-deps))
|
||||||
|
|
Loading…
Add table
Reference in a new issue