1 |
commit: a5cc44195933bd43f9b584dfc988113ef94c509a |
2 |
Author: Alexis Ballier <aballier <AT> gentoo <DOT> org> |
3 |
AuthorDate: Sun May 1 15:16:29 2016 +0000 |
4 |
Commit: Alexis Ballier <aballier <AT> gentoo <DOT> org> |
5 |
CommitDate: Tue May 3 09:13:52 2016 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=a5cc4419 |
7 |
|
8 |
dev-ml/deriving: fix build with ocaml 4.03 |
9 |
|
10 |
Package-Manager: portage-2.2.28 |
11 |
Signed-off-by: Alexis Ballier <aballier <AT> gentoo.org> |
12 |
|
13 |
dev-ml/deriving/deriving-0.7.ebuild | 1 + |
14 |
dev-ml/deriving/files/oc43.patch | 24 ++++++++++++++++++++++++ |
15 |
2 files changed, 25 insertions(+) |
16 |
|
17 |
diff --git a/dev-ml/deriving/deriving-0.7.ebuild b/dev-ml/deriving/deriving-0.7.ebuild |
18 |
index 9ce4458..a37c6ee 100644 |
19 |
--- a/dev-ml/deriving/deriving-0.7.ebuild |
20 |
+++ b/dev-ml/deriving/deriving-0.7.ebuild |
21 |
@@ -29,6 +29,7 @@ DEPEND="${RDEPEND} |
22 |
DOCS=( CHANGES README.md ) |
23 |
oasis_configure_opts="--enable-tc" |
24 |
OASIS_SETUP_COMMAND="./setup.exe" |
25 |
+PATCHES=( "${FILESDIR}/oc43.patch" ) |
26 |
|
27 |
src_configure() { |
28 |
emake setup.exe |
29 |
|
30 |
diff --git a/dev-ml/deriving/files/oc43.patch b/dev-ml/deriving/files/oc43.patch |
31 |
new file mode 100644 |
32 |
index 0000000..0369343 |
33 |
--- /dev/null |
34 |
+++ b/dev-ml/deriving/files/oc43.patch |
35 |
@@ -0,0 +1,24 @@ |
36 |
+commit 926305bb6fc95494064e75ceafc6443b62d3773b |
37 |
+Author: Vasilis Papavasileiou <git@×××××××××××××××.net> |
38 |
+Date: Tue Mar 29 15:42:38 2016 +0200 |
39 |
+ |
40 |
+ Fix DELETE_RULE for 4.03 (nonrec flag) |
41 |
+ |
42 |
+diff --git a/syntax/std/pa_deriving_std.ml b/syntax/std/pa_deriving_std.ml |
43 |
+index 1ec000c..dde8d9e 100644 |
44 |
+--- a/syntax/std/pa_deriving_std.ml |
45 |
++++ b/syntax/std/pa_deriving_std.ml |
46 |
+@@ -18,8 +18,13 @@ struct |
47 |
+ open Camlp4.PreCast |
48 |
+ include Syntax |
49 |
+ |
50 |
++#if ocaml_version >= (4, 03) |
51 |
++ DELETE_RULE Gram str_item: "type"; opt_nonrec; type_declaration END |
52 |
++ DELETE_RULE Gram sig_item: "type"; opt_nonrec; type_declaration END |
53 |
++#else |
54 |
+ DELETE_RULE Gram str_item: "type"; type_declaration END |
55 |
+ DELETE_RULE Gram sig_item: "type"; type_declaration END |
56 |
++#endif |
57 |
+ |
58 |
+ open Ast |
59 |
+ |