~ chicken-core (chicken-5) f53a6342800eb225b16e0783e49c7f5f3b4db929
commit f53a6342800eb225b16e0783e49c7f5f3b4db929
Author: felix <felix@call-with-current-continuation.org>
AuthorDate: Wed Mar 1 21:09:30 2017 +0100
Commit: felix <felix@call-with-current-continuation.org>
CommitDate: Wed Mar 1 21:09:30 2017 +0100
split paths consistently; added -no-install-deps
diff --git a/batch-driver.scm b/batch-driver.scm
index 8f6000e2..f6eb5b9c 100644
--- a/batch-driver.scm
+++ b/batch-driver.scm
@@ -195,9 +195,9 @@
((memq 'to-stdout options) #f)
(else (make-pathname #f (if filename (pathname-file filename) "out") "c")) ) )
(ipath (map chop-separator
- (string-split
- (or (get-environment-variable "CHICKEN_INCLUDE_PATH") "")
- ";")))
+ (##sys#split-path
+ (or (get-environment-variable "CHICKEN_INCLUDE_PATH") ""))))
+
(opasses (default-optimization-passes))
(time0 #f)
(time-breakdown #f)
diff --git a/chicken-install.mdoc b/chicken-install.mdoc
index d83f5dbb..1366a941 100644
--- a/chicken-install.mdoc
+++ b/chicken-install.mdoc
@@ -74,6 +74,8 @@ when cross-compiling, compile extension only for host
when cross-compiling, compile extension only for target
.It Fl test
run included test-cases, if available
+.It Fl no-install-deps
+Do not retrieve or install dependencies.
.It Fl u Ns , Fl update-db
update export database
.It Fl repository
diff --git a/chicken-install.scm b/chicken-install.scm
index d21478c0..38b533ee 100644
--- a/chicken-install.scm
+++ b/chicken-install.scm
@@ -1,6 +1,6 @@
;;;; chicken-install.scm
;
-; Copyright (c) 2008-2016, The CHICKEN Team
+; Copyright (c) 2008-2017, The CHICKEN Team
; All rights reserved.
;
; Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following
@@ -89,6 +89,7 @@
(define purge-mode #f)
(define keepfiles #f)
(define print-repository #f)
+(define no-deps #f)
(define platform
(if (eq? 'mingw (build-platform))
@@ -610,19 +611,21 @@
canonical-eggs)))
(define (outdated-dependencies egg info)
- (let ((ds (get-egg-dependencies info)))
- (for-each
- (lambda (h) (set! ds (h egg ds)))
- hacks)
- (let loop ((deps ds) (missing '()) (upgrade '()))
- (if (null? deps)
- (values (reverse missing) (reverse upgrade))
- (let ((dep (car deps))
- (rest (cdr deps)))
- (let-values (((m u) (check-dependency dep)))
- (loop rest
- (if m (cons m missing) missing)
- (if u (cons u upgrade) upgrade))))))))
+ (if no-deps
+ (values '() '())
+ (let ((ds (get-egg-dependencies info)))
+ (for-each
+ (lambda (h) (set! ds (h egg ds)))
+ hacks)
+ (let loop ((deps ds) (missing '()) (upgrade '()))
+ (if (null? deps)
+ (values (reverse missing) (reverse upgrade))
+ (let ((dep (car deps))
+ (rest (cdr deps)))
+ (let-values (((m u) (check-dependency dep)))
+ (loop rest
+ (if m (cons m missing) missing)
+ (if u (cons u upgrade) upgrade)))))))))
(define (get-egg-dependencies info)
(append (get-egg-property* info 'dependencies '())
@@ -986,6 +989,7 @@ usage: chicken-install [OPTION | EXTENSION[:VERSION]] ...
-force don't ask, install even if versions don't match
-k -keep keep temporary files
-s -sudo use external command to elevate privileges for filesystem operations
+ -no-install-deps do not install dependencies
-r -retrieve only retrieve egg into current directory, don't install (giving -r
more than once implies `-recursive')
-recursive if `-retrieve' is given, retrieve also dependencies
@@ -1055,6 +1059,9 @@ EOF
((equal? arg "-update-db")
(set! update-module-db #t)
(loop (cdr args)))
+ ((equal? arg "-no-install-deps")
+ (set! no-deps #t)
+ (loop (cdr args)))
((equal? arg "-dry-run")
(set! do-not-build #t)
(loop (cdr args)))
diff --git a/csi.scm b/csi.scm
index 3b0cf813..20f81917 100644
--- a/csi.scm
+++ b/csi.scm
@@ -189,7 +189,7 @@ EOF
[(addext name)]
[else
(let ([name2 (string-append "/" name)])
- (let loop ([ps (string-split path ";")])
+ (let loop ((ps (##sys#split-path path)))
(and (pair? ps)
(let ([name2 (string-append (chop-separator (##sys#slot ps 0)) name2)])
(or (addext name2)
@@ -990,9 +990,8 @@ EOF
[quietflag (member* '("-q" "-quiet") args)]
[quiet (or script quietflag eval?)]
[ipath (map chop-separator
- (string-split
- (or (get-environment-variable "CHICKEN_INCLUDE_PATH") "")
- ";"))] )
+ (##sys#split-path
+ (or (get-environment-variable "CHICKEN_INCLUDE_PATH") "")))])
(define (collect-options opt)
(let loop ([opts args])
(cond [(member opt opts)
diff --git a/manual/Using the compiler b/manual/Using the compiler
index bed6f13f..6f952f5e 100644
--- a/manual/Using the compiler
+++ b/manual/Using the compiler
@@ -77,7 +77,7 @@ the source text should be read from standard input.
; -ignore-repository : Do not load any extensions from the repository (treat repository as empty). Also do not consult compiled (only interpreted) import libraries in {{import}} forms.
-; -include-path PATHNAME : Specifies an additional search path for files included via the {{include}} special form. This option may be given multiple times. If the environment variable {{CHICKEN_INCLUDE_PATH}} is set, it should contain a list of alternative include pathnames separated by {{;}}.
+; -include-path PATHNAME : Specifies an additional search path for files included via the {{include}} special form. This option may be given multiple times. If the environment variable {{CHICKEN_INCLUDE_PATH}} is set, it should contain a list of alternative include pathnames separated by {{:}} (unix) or {{;}} (windows).
; -inline : Enable procedure inlining for known procedures of a size below the threshold (which can be set through the {{-inline-limit}} option).
Trap