Skip to content

Commit

Permalink
Generate opam file from dune-project (#78)
Browse files Browse the repository at this point in the history
Generate opam file from dune-project

Co-authored-by: Jérémie Dimino <jeremie@dimino.org>
  • Loading branch information
rgrinberg and jeremiedimino authored Aug 6, 2019
2 parents 6fcb10c + 8b1b5db commit 481fc2d
Show file tree
Hide file tree
Showing 7 changed files with 69 additions and 15 deletions.
13 changes: 13 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,16 @@
unreleased
----------

- Use dune's include_subdirs (#72)

- Fix parallel build (#75)

- Add `(mode fallback)` to installConfig.ml (#76)

- Fix iana executable (#77)

- Generate opam files from dune. (#78)

1.0.1
-----

Expand Down
2 changes: 1 addition & 1 deletion Camomile/mappings/dune
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

(executable
(name gen_mappings)
(libraries toolslib))
(libraries toolslib camomile.library))

(install
(section share)
Expand Down
4 changes: 2 additions & 2 deletions Camomile/tools/dune
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
camomilestringprep)
(flags -I Camomile :standard)
(modules :standard \ camomilelocaledef camomilelocaledef_lexer iana)
(libraries toolslib))
(libraries toolslib camomile camomile.library))

(executable
(name iana)
Expand All @@ -21,6 +21,6 @@

(executable
(name camomilelocaledef)
(libraries toolslib)
(libraries toolslib camomile.library)
(flags -I Camomile :standard)
(modules camomilelocaledef camomilelocaledef_lexer))
2 changes: 1 addition & 1 deletion Camomile/toolslib/dune
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
(name toolslib)
(wrapped false)
(flags -I Camomile :standard)
(libraries camomile bigarray str))
(libraries camomile camomile.library bigarray str))

(ocamllex colLexer)
(ocamlyacc colParser)
32 changes: 22 additions & 10 deletions camomile.opam
Original file line number Diff line number Diff line change
@@ -1,16 +1,28 @@
opam-version: "1.2"
maintainer: "yoriyuki.y@gmail.com"
# This file is generated by dune, edit dune-project instead
opam-version: "2.0"
synopsis: "A Unicode library"
description: """
Camomile is a Unicode library for OCaml. Camomile provides Unicode character
type, UTF-8, UTF-16, UTF-32 strings, conversion to/from about 200 encodings,
collation and locale-sensitive case mappings, and more. The library is currently
designed for Unicode Standard 3.2."""
maintainer: ["yoriyuki.y@gmail.com"]
authors: ["Yoriyuki Yamagata"]
homepage: "https://github.com/yoriyuki/Camomile/"
bug-reports: "https://github.com/yoriyuki/Camomile/issues"
license: "LGPL-2+ with OCaml linking exception"
dev-repo: "https://github.com/yoriyuki/Camomile.git"
homepage: "https://github.com/yoriyuki/Camomile"
doc: "https:/yoriyuki.github.io/Camomile/"
bug-reports: "https://github.com/yoriyuki/Camomile/issues"
depends: [
"dune" {>= "1.11"}
"ocaml" {>= "4.02.3"}
]
dev-repo: "git+https://github.com/yoriyuki/Camomile.git"
build: [
["ocaml" "configure.ml" "--share" "%{share}%/camomile"]
["dune" "subst"] {pinned}
["dune" "build" "-p" name "-j" jobs]
]
depends: [
"dune" {build & >= "1.1.0"}
["dune" "build" "-p" name "-j" jobs
"@install"
"@runtest" {with-test}
"@doc" {with-doc}
]
]
available: [ocaml-version >= "4.02.3"]
9 changes: 9 additions & 0 deletions camomile.opam.template
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
build: [
["ocaml" "configure.ml" "--share" "%{share}%/camomile"]
["dune" "subst"] {pinned}
["dune" "build" "-p" name "-j" jobs
"@install"
"@runtest" {with-test}
"@doc" {with-doc}
]
]
22 changes: 21 additions & 1 deletion dune-project
Original file line number Diff line number Diff line change
@@ -1,2 +1,22 @@
(lang dune 1.1)
(lang dune 1.11)
(name camomile)

(generate_opam_files true)
(license "LGPL-2+ with OCaml linking exception")
(maintainers "yoriyuki.y@gmail.com")
(authors "Yoriyuki Yamagata")
(implicit_transitive_deps false)
(source (github yoriyuki/Camomile))
(documentation "https:/yoriyuki.github.io/Camomile/")

(package
(name camomile)
(synopsis "A Unicode library")
(description "\
Camomile is a Unicode library for OCaml. Camomile provides Unicode character
type, UTF-8, UTF-16, UTF-32 strings, conversion to/from about 200 encodings,
collation and locale-sensitive case mappings, and more. The library is currently
designed for Unicode Standard 3.2.")
(depends
(dune (>= 1.11))
(ocaml (>= "4.02.3"))))

0 comments on commit 481fc2d

Please sign in to comment.