aboutsummaryrefslogtreecommitdiffhomepage
path: root/configure.ml
diff options
context:
space:
mode:
authorGravatar Hugo Herbelin <Hugo.Herbelin@inria.fr>2016-11-12 11:40:20 +0100
committerGravatar Hugo Herbelin <Hugo.Herbelin@inria.fr>2017-05-29 12:12:57 +0200
commita0cec18b3ac2427aaf15d2808cf021a8931a2516 (patch)
tree750ab6d4e6958c07f8c4b0fab17c70fb50c6eb71 /configure.ml
parent886c222fabd6658d0ef1fe0ed18ff9d5fba9982a (diff)
Configuration with -local definitively seen as an installation layout like others.
Diffstat (limited to 'configure.ml')
-rw-r--r--configure.ml13
1 files changed, 5 insertions, 8 deletions
diff --git a/configure.ml b/configure.ml
index 64165fab0..0d2a9881f 100644
--- a/configure.ml
+++ b/configure.ml
@@ -905,8 +905,10 @@ let find_suffix prefix path = match prefix with
else
Absolute path
-let do_one_instdir (var,msg,uservalue,selfcontainedlayout,unixlayout,_) =
- let dir,suffix = match !uservalue, !Prefs.prefix with
+let do_one_instdir (var,msg,uservalue,selfcontainedlayout,unixlayout,locallayout) =
+ let dir,suffix =
+ if !Prefs.local then (use_suffix coqtop locallayout,locallayout)
+ else match !uservalue, !Prefs.prefix with
| Some d, p -> d,find_suffix p d
| _, Some p ->
let suffix = if arch_is_win32 then selfcontainedlayout else relativize unixlayout in
@@ -920,12 +922,7 @@ let do_one_instdir (var,msg,uservalue,selfcontainedlayout,unixlayout,_) =
if line = "" then (dflt,suffix) else (line,find_suffix p line)
in (var,msg,dir,suffix)
-let do_one_noinst (var,msg,_,_,_,locallayout) =
- (var,msg,use_suffix coqtop locallayout,locallayout)
-
-let install_dirs =
- let f = if !Prefs.local then do_one_noinst else do_one_instdir in
- List.map f install
+let install_dirs = List.map do_one_instdir install
let select var = List.find (fun (v,_,_,_) -> v=var) install_dirs