opam-version: "2.0"
maintainer: "Christophe.Troestler@umons.ac.be"
authors: [
  "Christophe Troestler <Christophe.Troestler@umons.ac.be>"
  "Pierre Hauweele <antegallya@gmail.com>"
]
homepage: "http://forge.ocamlcore.org/projects/cairo/"
dev-repo: "git+https://github.com/Chris00/ocaml-cairo.git"
bug-reports: "https://forge.ocamlcore.org/tracker/?atid=1104&group_id=246&func=browse"
license: "LGPL-3.0-only with OCaml-LGPL-linking-exception"
build: [
  [
    "ocaml"
    "setup.ml"
    "-configure"
    "--prefix"
    prefix
    "--%{lablgtk:enable}%-lablgtk2"
  ]
  ["ocaml" "setup.ml" "-build"]
  ["ocaml" "setup.ml" "-doc"] {with-doc}
]
install: [["ocaml" "setup.ml" "-install"]]
remove: [["ocamlfind" "remove" "cairo2"]]
depends: [
  "ocaml" {< "4.06.0"}
  "ocamlfind" {build}
  "ocamlbuild" {build}
  "conf-cairo" {build}
  "conf-autoconf" {build}
]
depopts: ["lablgtk"]
conflicts: [ "cairo2" ]

# The package does not build without Graphics,
# which is not available by default on OS X.
# Use cairo2 >= 0.5.
available: os != "macos"
synopsis: "Binding to Cairo, a 2D Vector Graphics Library."
description: """
This is a binding to Cairo, a 2D graphics library with support for
multiple output devices. Currently supported output targets include
the X Window System, Quartz, Win32, image buffers, PostScript, PDF,
and SVG file output."""
flags: light-uninstall
url {
  src: "https://download.ocamlcore.org/cairo/cairo/0.4.2/cairo-0.4.2.tar.gz"
  checksum: "md5=cbd64bfe6a3eb120ae98deb5ce6980ae"
}
