@daemonspudguy
I also got the error. I found that ocaml-curl installs its files in /usr/lib/curl/. However, ocamlfind only searches for packages in /usr/lib/ocaml/ by default.
There are two relatively straightforward methods to resolve this issue.
The first method involves modifying the build() function in gapi-ocaml's PKGBUILD as follows:
build() {
cd "${srcdir}/${pkgname}-${pkgver}"
export OCAMLPATH="/usr/lib:/usr/lib/ocaml"
dune build -p "$pkgname"
sed -i '/doc:\s\[/,$d' _build/default/gapi-ocaml.install
}
However, this requires manually modifying the build() section after every gapi-ocaml update until the packager fixes the PKGBUILD.
The second method is to manually create symbolic links so ocamlfind can find what it needs:
sudo ln -s /usr/lib/curl /usr/lib/ocaml/curl
sudo ln -s /usr/lib/ocurl /usr/lib/ocaml/ocurl
sudo ln -s /usr/lib/curl_lwt /usr/lib/ocaml/curl_lwt
This is the safest approach, preventing ocamlfind from scanning the entire /usr/lib directory.
Pinned Comments
nerflad commented on 2019-09-10 10:13 (UTC)
@caseyjp1 It's not a problem with the build. Read the error message. You have updated ocaml since the last time you compiled this package so you need to recompile all the dependencies. Use "pacman -Qo [.cmi filename]" to find which packages to rebuild. Or if you're brave, pacman -Rsc gapi-ocaml && pacman -Sc and start from scratch.