Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Work around various opam and dune issues on non-linux systems #475

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ bench:
dune exec -- ./bench/bench_stream.exe
dune exec -- ./bench/bench_semaphore.exe
dune exec -- ./bench/bench_cancel.exe
dune exec -- ./lib_eio_linux/tests/bench_noop.exe
if ocamlc -config | grep -q '^system: linux'; then dune exec -- ./lib_eio_linux/tests/bench_noop.exe; fi

test_luv:
EIO_BACKEND=luv dune runtest
Expand Down
1 change: 1 addition & 0 deletions dune-project
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@
(name eio_linux)
(synopsis "Eio implementation for Linux using io-uring")
(description "An Eio implementation for Linux using io-uring.")
(allow_empty) ; Work-around for dune bug #6938
(depends
(alcotest (and (>= 1.4.0) :with-test))
(eio (= :version))
Expand Down
8 changes: 8 additions & 0 deletions lib_eio_linux/tests/dune
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
(* -*- tuareg -*- *)

let linux = List.mem ("system", "linux") Jbuild_plugin.V1.ocamlc_config

let () = Jbuild_plugin.V1.send @@ if not linux then "" else {|

(library
(name eurcp_lib)
(enabled_if (= %{system} "linux"))
Expand Down Expand Up @@ -33,3 +39,5 @@
(package eio_linux)
(enabled_if (= %{system} "linux"))
(deps (package eio_linux)))

|}