Somewhat better attempt at a META file.
authorRichard W.M. Jones <rich@annexia.org>
Fri, 4 Jul 2008 13:40:07 +0000 (13:40 +0000)
committerRichard W.M. Jones <rich@annexia.org>
Fri, 4 Jul 2008 13:40:07 +0000 (13:40 +0000)
META.in
bitmatch.mli

diff --git a/META.in b/META.in
index fcd454d..97be0ff 100644 (file)
--- a/META.in
+++ b/META.in
@@ -1,14 +1,22 @@
-name="bitmatch"
-version="@PACKAGE_VERSION@"
-description="Bitstrings and bitstring matching"
-requires="unix"
-archive(byte)="bitmatch.cma"
-archive(native)="bitmatch.cmxa"
+name = "bitmatch"
+version = "@PACKAGE_VERSION@"
+description = "Bitstrings and bitstring matching"
+requires = "unix"
+archive(byte) = "bitmatch.cma"
+archive(native) = "bitmatch.cmxa"
+
+package "persistent" (
+  requires = "bitmatch"
+  version = "@PACKAGE_VERSION@"
+  description = "Persistent patterns for bitmatch (requires camlp4)"
+  archive(byte) = "bitmatch_persistent.cma"
+  archive(native) = "bitmatch_persistent.cmxa"
+)
 
 package "syntax" (
-  requires = "camlp4.quotations.o"
   version = "@PACKAGE_VERSION@"
   description = "Syntax extension: bitmatch operators"
-  archive(syntax,preprocessor) = "pa_bitmatch.cmo"
-  archive(syntax,toploop) = "pa_bitmatch.cmo"
+  archive(syntax,preprocessor) = "unix.cma bitmatch.cma bitmatch_persistent.cma pa_bitmatch.cmo"
+  archive(syntax,toploop) = "unix.cma bitmatch.cma bitmatch_persistent.cma pa_bitmatch.cmo"
+  preprocessor = "camlp4of"
 )
index 5628eb6..4aa221d 100644 (file)
@@ -455,14 +455,14 @@ bitmatch bits with
    ocamlc -I +bitmatch \
      -pp "camlp4o bitmatch.cma bitmatch_persistent.cma \
             `ocamlc -where`/bitmatch/pa_bitmatch.cmo" \
-     bitmatch.cma test.ml -o test
+     unix.cma bitmatch.cma test.ml -o test
    v}
 
    Simpler method using findlib:
 
    {v
    ocamlfind ocamlc \
-     -package bitmatch.syntax -syntax bitmatch.syntax \
+     -package bitmatch,bitmatch.syntax -syntax bitmatch.syntax \
      -linkpkg test.ml -o test
    v}