biglybt: 3.5.0.0 -> 3.6.0.0
[NixPkgs.git] / pkgs / development / ocaml-modules / ocb-stubblr / pkg-config.patch
blobd86b3f8da9f1bf866f7367e1a66d3d897456e9c0
1 --- a/src/ocb_stubblr.ml 1970-01-01 00:00:01.000000000 +0000
2 +++ b/src/ocb_stubblr.ml 2016-12-04 11:10:10.000000000 +0000
3 @@ -31,20 +31,9 @@
5 (* XXX Would be nice to move pkg-config results to a build artefact. *)
7 - let opam_prefix =
8 - let cmd = "opam config var prefix" in
9 - lazy ( try run_and_read cmd with Failure _ ->
10 - error_msgf "error running opam")
12 - let var = "PKG_CONFIG_PATH"
14 - let path () =
15 - Lazy.force opam_prefix / "lib" / "pkgconfig" ::
16 - (try [Sys.getenv var] with Not_found -> []) |> String.concat ~sep:":"
18 let run ~flags package =
19 - let cmd = strf "%s=%s pkg-config %s %s 2>/dev/null"
20 - var (path ()) package (String.concat ~sep:" " flags) in
21 + let cmd = strf "pkg-config %s %s 2>/dev/null"
22 + package (String.concat ~sep:" " flags) in
23 try `Res (run_and_read cmd) with Failure _ -> `Nonexistent
24 end