summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorWojciech Meyer <wojciech.meyer@gmail.com>2012-12-28 18:19:27 +0000
committerWojciech Meyer <wojciech.meyer@gmail.com>2012-12-28 18:19:27 +0000
commit655cf17e4edfe46e94a62f24f6b7b0ed4e98ae42 (patch)
treeb83cc09a25f45f38cf1129c74b89f2f4f461960b
parent5ac5c519144dc896774409435c984fbcbf539725 (diff)
Revert "PR#5652: Try to use camlp4.opt if it's possible"
camlp4.opt works only with native plugins therefore the fix will break bytecode camlp4 plugins. git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@13167 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
-rw-r--r--ocamlbuild/ocaml_specific.ml14
1 files changed, 4 insertions, 10 deletions
diff --git a/ocamlbuild/ocaml_specific.ml b/ocamlbuild/ocaml_specific.ml
index bf5bff17e..51215f076 100644
--- a/ocamlbuild/ocaml_specific.ml
+++ b/ocamlbuild/ocaml_specific.ml
@@ -478,26 +478,20 @@ let () =
pflag ["ocaml";"compile";] "warn"
(fun param -> S [A "-w"; A param])
-let try_opt name =
- let cmd = Command.string_of_command_spec (A name)in
- try ignore(Command.search_in_path cmd); name ^ ".opt"
- with Not_found -> name
-
let camlp4_flags camlp4s =
List.iter begin fun camlp4 ->
- flag ["ocaml"; "pp"; camlp4] (A (try_opt camlp4))
+ flag ["ocaml"; "pp"; camlp4] (A camlp4)
end camlp4s;;
camlp4_flags ["camlp4o"; "camlp4r"; "camlp4of"; "camlp4rf"; "camlp4orf"; "camlp4oof"];;
let camlp4_flags' camlp4s =
- List.iter begin fun (camlp4, cmd, flags) ->
- let flags = S (A (try_opt cmd) :: flags) in
+ List.iter begin fun (camlp4, flags) ->
flag ["ocaml"; "pp"; camlp4] flags
end camlp4s;;
-camlp4_flags' ["camlp4orr", "camlp4of", [A"-parser"; A"reloaded"];
- "camlp4rrr", "camlp4rf", [A"-parser"; A"reloaded"]];;
+camlp4_flags' ["camlp4orr", S[A"camlp4of"; A"-parser"; A"reloaded"];
+ "camlp4rrr", S[A"camlp4rf"; A"-parser"; A"reloaded"]];;
flag ["ocaml"; "pp"; "camlp4:no_quot"] (A"-no_quot");;