\f
;;;; Legacy packages
-(define legacy-libraries)
-
(define (initialize-legacy-libraries! package-file)
- (set! legacy-libraries
- (filter-map (lambda (pd)
- (and (let ((name (package-description/name pd)))
- (and (pair? name)
- (eq? (car name) 'runtime)))
- (create-legacy-library pd)))
- (vector->list (package-file/descriptions package-file))))
- (register-libraries! legacy-libraries host-library-db))
-
-(define (create-legacy-library pd)
- (make-library (cons* 'mit 'legacy (package-description/name pd))
- 'parsed-imports '()
- 'exports (package-exports pd)
- 'parsed-contents '()
- 'filename #f
- 'environment system-global-environment))
+ (register-library! (make-library '(mit legacy runtime)
+ 'parsed-imports '()
+ 'exports (runtime-exports package-file)
+ 'parsed-contents '()
+ 'filename #f
+ 'environment system-global-environment)
+ host-library-db))
+
+(define (runtime-exports package-file)
+ (append-map package-exports
+ (filter (lambda (pd)
+ (let ((name (package-description/name pd)))
+ (and (pair? name)
+ (eq? (car name) 'runtime))))
+ (vector->list (package-file/descriptions package-file)))))
(define (package-exports pd)
(filter-map (lambda (link)
(and (null? (link-description/package link))
+ (not (link-description/status link))
(make-library-export (link-description/outer-name link))))
(vector->list (package-description/exports pd))))
\ No newline at end of file
'(link-description/inner-name
link-description/outer-name
link-description/package
+ link-description/status
package-description/exports
package-description/name
package-file/descriptions)))
;; cold load sequence in "make.scm".
(files "packag")
(parent ())
+ ;; All these exports must match those in "make.scm".
(export ()
*allow-package-redefinition?*
construct-packages-from-file
package?
all-packages)
(export (runtime library standard)
- link-description/inner-name
link-description/outer-name
link-description/package
+ link-description/status
package-description/exports
package-description/name
package-file/descriptions)