ocamlnet 4.1.2 compile with safe string fails in cppo-0.9.4

Gerd Stolpmann
2017-10-07T09:44:17Z

Compiler 4.04.0+safe-string, opam package ocamlnet.4.1.2, fails with type byte string problem.

The problem occurs in ocamlnet.4.1.2/tools/cppo-0.9.4. An "install cppo 1.4.1" succeeds. So evidently an old version of cppo is shipped with ocamlnet and this causes this problem.

For completeness I am pasting the relevant part of the compile error:

`### stdout ###

[...]

make[1]: Entering directory '/data/lvmvol/opt/opam/4.04.0+safe-string/build/ocamlnet.4.1.2/tools/cppo-0.9.4'

echo 'let cppo_version = "0.9.4"' > cppo_version.ml

ocamlyacc cppo_parser.mly

ocamllex cppo_lexer.mll

352 states, 13139 transitions, table size 54668 bytes

3450 additional bytes used for bindings

ocamlc -o cppo -dtypes unix.cma cppo_version.ml cppo_types.ml cppo_parser.mli cppo_parser.ml cppo_lexer.ml cppo_command.ml cppo_eval.ml cppo_main.ml

Makefile:60: recipe for target 'all' failed

make[1]: Leaving directory '/data/lvmvol/opt/opam/4.04.0+safe-string/build/ocamlnet.4.1.2/tools/cppo-0.9.4'

Makefile:51: recipe for target 'tools' failed

stderr

File "cppo_lexer.mll", line 24, characters 7-8:

Error: This expression has type bytes but an expression was expected of type

string

make[1]: *** [all] Error 2

`