opam-version: "2.0"
maintainer: "sheets@alum.mit.edu"
authors: [
  "David Sheets <sheets@alum.mit.edu>"
  "Peter Zotov <whitequark@whitequark.org>"
]
homepage: "https://github.com/dsheets/ocaml-sodium/"
bug-reports: "https://github.com/dsheets/ocaml-sodium/issues/"
tags: "org:mirage"
dev-repo: "git+https://github.com/dsheets/ocaml-sodium.git"
build: [
  [make] {os != "freebsd"}
  [make "CFLAGS=-I/usr/local/include -L/usr/local/lib"] {os = "freebsd"}
  [make "test"] {with-test & os != "freebsd"}
  [make "CFLAGS=-I/usr/local/include -L/usr/local/lib" "test"]
    {with-test & os = "freebsd"}
]
install: [make "PREFIX=%{prefix}%" "install"]
remove: ["ocamlfind" "remove" "sodium"]
depends: [
  "ocaml" {>= "4.01.0"}
  "base-bigarray"
  "base-bytes"
  "ocamlfind"
  "conf-libsodium"
  "ctypes" {>= "0.4.0" & < "0.6.0"}
  "ocamlbuild" {build}
]
post-messages: [
  "This package requires installation of libsodium-dev (>= 0.7.0)"
    {failure & os = "debian"}
  "This package requires installation of libsodium-dev (>= 0.7.0)"
    {failure & os = "ubuntu"}
  "This package requires installation of libsodium-dev (>= 0.7.0)"
    {failure & os = "alpine"}
  "This package requires installation of security/libsodium (>= 0.7.0)"
    {failure & os = "freebsd"}
  "This package requires installation of libsodium (>= 0.7.0)"
    {failure & os = "macos"}
]
synopsis: "Binding to libsodium UNAUDITED"
description: """
Binding to libsodium 0.7.0+, a shared library wrapper for djb's NaCl.

Binding uses ctypes' stub generation system. GNU/Linux, FreeBSD, and OS
X are supported.

UNAUDITED"""
flags: light-uninstall
url {
  src: "https://github.com/dsheets/ocaml-sodium/archive/0.5.0.tar.gz"
  checksum: "md5=07c585883270fe5d1eee84d94f26864a"
}
