summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--CHANGES20
-rw-r--r--META2
-rw-r--r--Makefile6
-rw-r--r--README.md2
-rw-r--r--debian/changelog12
-rw-r--r--frontend.ml14
6 files changed, 42 insertions, 14 deletions
diff --git a/CHANGES b/CHANGES
index 7e598d4..62154c2 100644
--- a/CHANGES
+++ b/CHANGES
@@ -1,16 +1,26 @@
+not-ocamlfind 0.13
+------------------
-not-ocamlfind 0.10
----------------------
+* [3 May 2024] add "-impl", "-intf" to the "preprocess" command (pass
+ thru to camlp5). Also fix Freebsd build process.
-* [30 Aug 2023] swap "bash" to "sh"
+not-ocamlfind 0.12
+------------------
+
+* [22 Sep 2023] change bootstrap in Makefile to avoid freebsd build bug
not-ocamlfind 0.11
----------------------
+------------------
+
+* [30 Aug 2023] swap "bash" to "sh"
+
+not-ocamlfind 0.10
+------------------
* [30 Mar 2023] in "preprocess", ignore "-for-pack", "-linkall" arguments so we can just replace "ocamlc" with "preprocess"
not-ocamlfind 0.08
----------------------
+------------------
* [04 Aug 2021] add better support for syntax predicates.
diff --git a/META b/META
index dbe6aa7..6d8be6e 100644
--- a/META
+++ b/META
@@ -1,4 +1,4 @@
# stub META file for "not-ocamlfind" frontend to "ocamlfind"
requires = ""
-version = "0.10"
+version = "0.13"
description = "add-on commands for ocamlfind"
diff --git a/Makefile b/Makefile
index bcc1a5b..42ee82a 100644
--- a/Makefile
+++ b/Makefile
@@ -10,10 +10,10 @@ not-ocamlfind: fsmod.ml frontend.ml main.ml
(cd local-packages/ocamlfind/ && make)
ocamlfind ocamlc $(DEBUG) $(INC) -package $(PACKAGES) -linkall -linkpkg fsmod.ml frontend.ml main.ml -o not-ocamlfind
-fsmod.ml: fsmod.ORIG.ml
+bootstrap: fsmod.ORIG.ml
not-ocamlfind preprocess -package camlp5,pa_ppx.deriving_plugins.show,camlp5.pr_o \
- -syntax camlp5o $< > $@.NEW
- mv $@.NEW $@
+ -syntax camlp5o $< > fsmod.ml.NEW
+ mv fsmod.ml.NEW fsmod.ml
papr_official.exe: papr_official.ml
ocamlfind ocamlc $(DEBUG) $(INC) -package str,unix,compiler-libs.common \
diff --git a/README.md b/README.md
index 7df1248..6a869f7 100644
--- a/README.md
+++ b/README.md
@@ -45,7 +45,7 @@ can be coaxed to produce its preprocessed output by adding "-dsource". But this
```
ocamlfind ocamlc -package ounit2,ppx_deriving.show test_deriving_show.ml
```
-Note well that all the options destined only for the compiler, linker, etc, are removed (and henced rejected) for `preprocess`. Only options required for preprocessing are accepted (`-package`, `-syntax`, `-predicates`, `-ppopt`, `-ppxopt`).
+Note well that all the options destined only for the compiler, linker, etc, are removed (and henced rejected) for `preprocess`. Only options required for preprocessing are accepted (`-package`, `-syntax`, `-predicates`, `-ppopt`, `-ppxopt`, `-intf`, `-impl`).
This can work for camlp5 also, but that little bit of documentation is TBD.
diff --git a/debian/changelog b/debian/changelog
index 92398bc..d41f667 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,15 @@
+not-ocamlfind (0.13-1) unstable; urgency=medium
+
+ * New upstream release
+
+ -- Stéphane Glondu <glondu@debian.org> Mon, 03 Jun 2024 14:52:19 +0200
+
+not-ocamlfind (0.12-1) unstable; urgency=medium
+
+ * New upstream release
+
+ -- Stéphane Glondu <glondu@debian.org> Sat, 07 Oct 2023 07:06:48 +0200
+
not-ocamlfind (0.11+dfsg-1) unstable; urgency=medium
* New upstream release
diff --git a/frontend.ml b/frontend.ml
index b0a6dbc..9adbb64 100644
--- a/frontend.ml
+++ b/frontend.ml
@@ -750,8 +750,10 @@ let preprocess () =
syntax_preds := !syntax_preds @ (Fl_split.in_words s) ;
predicates := !predicates @ (List.map (Printf.sprintf "syntax_%s") (Fl_split.in_words s)) ;
end) in
+ let do_add_pp_opt s = pp_opts := !pp_opts @ [s] in
let add_pp_opt =
- Arg.String (fun s -> pp_opts := !pp_opts @ [s]) in
+ Arg.String do_add_pp_opt in
+ let do_add_pass_file s = pass_files := !pass_files @ [s] in
let ignore_error = ref false in
let arg_spec =
@@ -770,12 +772,16 @@ let preprocess () =
"<opt> Append option <opt> to preprocessor invocation";
"-ppxopt", Arg.String (fun s -> ppx_opts := !ppx_opts @ [s]),
"<pkg>,<opts> Append options <opts> to ppx invocation for package <pkg>";
+ "-impl", Arg.String (fun s -> do_add_pass_file (Impl s)),
+ "<file> Append \"impl <file>\" to preprocessor invocation";
+ "-intf", Arg.String (fun s -> do_add_pass_file (Intf s)),
+ "<file> Append \"intf <file>\" to preprocessor invocation";
"-ignore-error", Arg.Set ignore_error,
" Ignore the 'error' directive in META files";
"-only-show", Arg.Unit (fun () -> verbose := Only_show),
- " Only show the constructed command, but do not exec it\nSTANDARD OPTIONS:";
+ " Only show the constructed command, but do not exec it";
"-verbose", Arg.Unit (fun () -> verbose := Verbose),
- " Only show the constructed command, but do not exec it\nSTANDARD OPTIONS:";
+ " Show the constructed command and also exec it\nSTANDARD OPTIONS:";
] in
let (current,args) =
@@ -785,7 +791,7 @@ let preprocess () =
~current
~args
arg_spec
- (fun s -> pass_files := !pass_files @ [ Pass s])
+ (fun s -> do_add_pass_file (Pass s))
("usage: not-ocamlfind preprocess [options] file ...");
(* ---- Start requirements analysis ---- *)