From bd0d4fd1d08502c09048db6dd4d1d46a53c568a1 Mon Sep 17 00:00:00 2001 From: Tim McGilchrist Date: Thu, 2 Dec 2021 15:06:17 +1100 Subject: [PATCH] Split benchmark into yojson-bench package. --- bench/dune | 2 ++ yojson-bench.opam | 25 +++++++++++++++++++++++++ yojson.opam | 2 -- 3 files changed, 27 insertions(+), 2 deletions(-) create mode 100644 yojson-bench.opam diff --git a/bench/dune b/bench/dune index 8c17e857..ec52f6da 100644 --- a/bench/dune +++ b/bench/dune @@ -1,5 +1,7 @@ (executable (name bench) + (package yojson-bench) + (public_name yojson-bench) (flags (-safe-string)) (libraries yojson core_bench core)) diff --git a/yojson-bench.opam b/yojson-bench.opam new file mode 100644 index 00000000..9cbd1d07 --- /dev/null +++ b/yojson-bench.opam @@ -0,0 +1,25 @@ +opam-version: "2.0" +maintainer: ["nathan@cryptosense.com" "marek@xivilization.net"] +authors: ["Martin Jambon"] +homepage: "https://github.com/ocaml-community/yojson" +bug-reports: "https://github.com/ocaml-community/yojson/issues" +dev-repo: "git+https://github.com/ocaml-community/yojson.git" +doc: "https://ocaml-community.github.io/yojson/" +license: "BSD-3-Clause" +build: [ + ["dune" "subst"] {pinned} + ["dune" "build" "-p" name "-j" jobs] +] +depends: [ + "ocaml" {>= "4.02.3"} + "yojson" {= version} + "dune" + "core_bench" +] +synopsis: + "Run Yojson benchmarks" +description: """ +Yojson benchmarks require `Core_bench` which is not a dependency of Yojson, +because it is not part of the regular installation/testing flow. This is solely +meant for developers that are worried about performance changes in Yojson. +""" diff --git a/yojson.opam b/yojson.opam index db2f956c..4b351a10 100644 --- a/yojson.opam +++ b/yojson.opam @@ -17,8 +17,6 @@ depends: [ "dune" "cppo" {build} "alcotest" {with-test & >= "0.8.5"} - "core_bench" {with-test} - "core" {with-test} "odoc" {with-doc} ] synopsis: