1
1
(* OASIS_START *)
2
- (* DO NOT EDIT (digest: b9c71e7d1ddd2a4412821af705169ba7 ) *)
2
+ (* DO NOT EDIT (digest: fb39601598e0c8e6f4698a5182f16985 ) *)
3
3
module OASISGettext = struct
4
- # 22 " /home/maurer/Sources/live/oasis/ src/oasis/OASISGettext.ml"
4
+ (* # 22 "src/oasis/OASISGettext.ml" *)
5
5
6
6
7
7
let ns_ str =
@@ -30,7 +30,7 @@ module OASISGettext = struct
30
30
end
31
31
32
32
module OASISExpr = struct
33
- # 22 " /home/maurer/Sources/live/oasis/ src/oasis/OASISExpr.ml"
33
+ (* # 22 "src/oasis/OASISExpr.ml" *)
34
34
35
35
36
36
@@ -39,10 +39,10 @@ module OASISExpr = struct
39
39
open OASISGettext
40
40
41
41
42
- type test = string
42
+ type test = string
43
43
44
44
45
- type flag = string
45
+ type flag = string
46
46
47
47
48
48
type t =
@@ -55,7 +55,7 @@ module OASISExpr = struct
55
55
56
56
57
57
58
- type 'a choices = (t * 'a ) list
58
+ type 'a choices = (t * 'a ) list
59
59
60
60
61
61
let eval var_get t =
131
131
132
132
# 132 " myocamlbuild.ml"
133
133
module BaseEnvLight = struct
134
- # 22 " /home/maurer/Sources/live/oasis/ src/base/BaseEnvLight.ml"
134
+ (* # 22 "src/base/BaseEnvLight.ml" *)
135
135
136
136
137
137
module MapString = Map. Make (String )
236
236
237
237
# 237 " myocamlbuild.ml"
238
238
module MyOCamlbuildFindlib = struct
239
- # 22 " /home/maurer/Sources/live/oasis/ src/plugins/ocamlbuild/MyOCamlbuildFindlib.ml"
239
+ (* # 22 "src/plugins/ocamlbuild/MyOCamlbuildFindlib.ml" *)
240
240
241
241
242
242
(* * OCamlbuild extension, copied from
@@ -249,9 +249,6 @@ module MyOCamlbuildFindlib = struct
249
249
*)
250
250
open Ocamlbuild_plugin
251
251
252
- type conf =
253
- { no_automatic_syntax : bool ;
254
- }
255
252
256
253
(* these functions are not really officially exported *)
257
254
let run_and_read =
@@ -341,7 +338,7 @@ module MyOCamlbuildFindlib = struct
341
338
]
342
339
343
340
344
- let dispatch conf =
341
+ let dispatch =
345
342
function
346
343
| After_options ->
347
344
(* By using Before_options one let command line options have an higher
@@ -360,39 +357,31 @@ module MyOCamlbuildFindlib = struct
360
357
* -linkpkg *)
361
358
flag [" ocaml" ; " link" ; " program" ] & A " -linkpkg" ;
362
359
363
- if not (conf.no_automatic_syntax) then begin
364
- (* For each ocamlfind package one inject the -package option when
365
- * compiling, computing dependencies, generating documentation and
366
- * linking. *)
367
- List. iter
368
- begin fun pkg ->
369
- let base_args = [A " -package" ; A pkg] in
370
- (* TODO: consider how to really choose camlp4o or camlp4r. *)
371
- let syn_args = [A " -syntax" ; A " camlp4o" ] in
372
- let (args, pargs) =
373
- (* Heuristic to identify syntax extensions: whether they end in
374
- ".syntax"; some might not.
375
- *)
376
- if Filename. check_suffix pkg " syntax" ||
377
- List. mem pkg well_known_syntax then
378
- (syn_args @ base_args, syn_args)
379
- else
380
- (base_args, [] )
381
- in
382
- flag [" ocaml" ; " compile" ; " pkg_" ^ pkg] & S args;
383
- flag [" ocaml" ; " ocamldep" ; " pkg_" ^ pkg] & S args;
384
- flag [" ocaml" ; " doc" ; " pkg_" ^ pkg] & S args;
385
- flag [" ocaml" ; " link" ; " pkg_" ^ pkg] & S base_args;
386
- flag [" ocaml" ; " infer_interface" ; " pkg_" ^ pkg] & S args;
387
-
388
- (* TODO: Check if this is allowed for OCaml < 3.12.1 *)
389
- flag [" ocaml" ; " compile" ; " package(" ^ pkg^ " )" ] & S pargs;
390
- flag [" ocaml" ; " ocamldep" ; " package(" ^ pkg^ " )" ] & S pargs;
391
- flag [" ocaml" ; " doc" ; " package(" ^ pkg^ " )" ] & S pargs;
392
- flag [" ocaml" ; " infer_interface" ; " package(" ^ pkg^ " )" ] & S pargs;
393
- end
394
- (find_packages () );
395
- end;
360
+ (* For each ocamlfind package one inject the -package option when
361
+ * compiling, computing dependencies, generating documentation and
362
+ * linking. *)
363
+ List. iter
364
+ begin fun pkg ->
365
+ let base_args = [A " -package" ; A pkg] in
366
+ (* TODO: consider how to really choose camlp4o or camlp4r. *)
367
+ let syn_args = [A " -syntax" ; A " camlp4o" ] in
368
+ let args =
369
+ (* Heuristic to identify syntax extensions: whether they end in
370
+ ".syntax"; some might not.
371
+ *)
372
+ if Filename. check_suffix pkg " syntax" ||
373
+ List. mem pkg well_known_syntax then
374
+ syn_args @ base_args
375
+ else
376
+ base_args
377
+ in
378
+ flag [" ocaml" ; " compile" ; " pkg_" ^ pkg] & S args;
379
+ flag [" ocaml" ; " ocamldep" ; " pkg_" ^ pkg] & S args;
380
+ flag [" ocaml" ; " doc" ; " pkg_" ^ pkg] & S args;
381
+ flag [" ocaml" ; " link" ; " pkg_" ^ pkg] & S base_args;
382
+ flag [" ocaml" ; " infer_interface" ; " pkg_" ^ pkg] & S args;
383
+ end
384
+ (find_packages () );
396
385
397
386
(* Like -package but for extensions syntax. Morover -syntax is useless
398
387
* when linking. *)
@@ -426,7 +415,7 @@ module MyOCamlbuildFindlib = struct
426
415
end
427
416
428
417
module MyOCamlbuildBase = struct
429
- # 22 " /home/maurer/Sources/live/oasis/ src/plugins/ocamlbuild/MyOCamlbuildBase.ml"
418
+ (* # 22 "src/plugins/ocamlbuild/MyOCamlbuildBase.ml" *)
430
419
431
420
432
421
(* * Base functions for writing myocamlbuild.ml
@@ -441,13 +430,13 @@ module MyOCamlbuildBase = struct
441
430
module OC = Ocamlbuild_pack. Ocaml_compiler
442
431
443
432
444
- type dir = string
445
- type file = string
446
- type name = string
447
- type tag = string
433
+ type dir = string
434
+ type file = string
435
+ type name = string
436
+ type tag = string
448
437
449
438
450
- # 62 "/home/maurer/Sources/live/oasis/ src/plugins/ocamlbuild/MyOCamlbuildBase.ml"
439
+ (* # 62 "src/plugins/ocamlbuild/MyOCamlbuildBase.ml" *)
451
440
452
441
453
442
type t =
@@ -459,7 +448,7 @@ module MyOCamlbuildBase = struct
459
448
* directory.
460
449
*)
461
450
includes : (dir * dir list ) list ;
462
- }
451
+ }
463
452
464
453
465
454
let env_filename =
@@ -557,12 +546,11 @@ module MyOCamlbuildBase = struct
557
546
558
547
(* When ocaml link something that use the C library, then one
559
548
need that file to be up to date.
560
- This holds both for programs and for libraries.
561
549
*)
562
- dep [" link" ; " ocaml" ; tag_libstubs lib]
550
+ dep [" link" ; " ocaml" ; " program " ; tag_libstubs lib]
563
551
[dir/ " lib" ^ (nm_libstubs lib)^ " ." ^ (! Options. ext_lib)];
564
552
565
- dep [" compile" ; " ocaml" ; tag_libstubs lib]
553
+ dep [" compile" ; " ocaml" ; " program " ; tag_libstubs lib]
566
554
[dir/ " lib" ^ (nm_libstubs lib)^ " ." ^ (! Options. ext_lib)];
567
555
568
556
(* TODO: be more specific about what depends on headers *)
@@ -592,18 +580,18 @@ module MyOCamlbuildBase = struct
592
580
()
593
581
594
582
595
- let dispatch_default conf t =
583
+ let dispatch_default t =
596
584
dispatch_combine
597
585
[
598
586
dispatch t;
599
- MyOCamlbuildFindlib. dispatch conf ;
587
+ MyOCamlbuildFindlib. dispatch;
600
588
]
601
589
602
590
603
591
end
604
592
605
593
606
- # 606 " myocamlbuild.ml"
594
+ # 594 " myocamlbuild.ml"
607
595
open Ocamlbuild_plugin ;;
608
596
let package_default =
609
597
{
@@ -614,11 +602,9 @@ let package_default =
614
602
}
615
603
;;
616
604
617
- let conf = {MyOCamlbuildFindlib. no_automatic_syntax = false }
618
-
619
- let dispatch_default = MyOCamlbuildBase. dispatch_default conf package_default;;
605
+ let dispatch_default = MyOCamlbuildBase. dispatch_default package_default;;
620
606
621
- # 622 " myocamlbuild.ml"
607
+ # 608 " myocamlbuild.ml"
622
608
(* OASIS_STOP *)
623
609
(*
624
610
let dispatch_local e =
0 commit comments