Yashwanths-MacBook-Pro:~ yashwanthreddy$ opam install lwt
The following actions will be performed:
β install lwt 4.3.0
<><> Gathering sources ><><><><><><><><><><><><><><><><><><><><><><><><><><> π«
[lwt.4.3.0] found in cache
<><> Processing actions <><><><><><><><><><><><><><><><><><><><><><><><><><> π«
[ERROR] The compilation of lwt failed at "/Users/yashwanthreddy/.opam/opam-init/hooks/sandbox.sh build dune build -p lwt -j 7".
#=== ERROR while compiling lwt.4.3.0 ==========================================#
# context 2.0.5 | macos/x86_64 | ocaml-system.4.08.1 | https://opam.ocaml.org#852124c0
# path ~/.opam/default/.opam-switch/build/lwt.4.3.0
# command ~/.opam/opam-init/hooks/sandbox.sh build dune build -p lwt -j 7
# exit-code 1
# env-file ~/.opam/log/lwt-50424-ffb3fd.env
# output-file ~/.opam/log/lwt-50424-ffb3fd.out
### output ###
# [...]
# #include <stdlib.h>
# ^~~~~~~~~~
# 1 error generated.
# ocamlc src/unix/lwt_libev_stubs.o (exit 2)
# (cd _build/default/src/unix && /usr/local/bin/ocamlc.opt -g -I /Users/yashwanthreddy/.opam/default/lib/bytes -I /Users/yashwanthreddy/.opam/default/lib/mmap -I /Users/yashwanthreddy/.opam/default/lib/ocplib-endian -I /Users/yashwanthreddy/.opam/default/lib/result -I /Users/yashwanthreddy/.opam/default/lib/seq -I /usr/local/lib/ocaml/threads -I ../core -ccopt -I. -ccopt -g -o lwt_libev_stubs.o[...]
# In file included from lwt_libev_stubs.c:9:
# In file included from ./lwt_unix.h:11:
# In file included from /usr/local/lib/ocaml/caml/mlvalues.h:23:
# /usr/local/lib/ocaml/caml/misc.h:29:10: fatal error: 'stdlib.h' file not found
# #include <stdlib.h>
# ^~~~~~~~~~
# 1 error generated.
<><> Error report <><><><><><><><><><><><><><><><><><><><><><><><><><><><><> π«
ββ The following actions failed
β Ξ» build lwt 4.3.0
ββ
βΆβ No changes have been performed
<><> lwt.4.3.0 troubleshooting ><><><><><><><><><><><><><><><><><><><><><><> π«
=> Lwt 5.0.0 will make some breaking changes in November 2019. See
https://github.com/ocsigen/lwt/issues/584
Yashwanths-MacBook-Pro:~ yashwanthreddy$
Please let me know what is the issue.