State #DF4 - pkg-config required by Ocaml package

I’m stuck on Stage #DF4 - Compression Headers.

To compress the content of the HTTP body, I installed the OCaml dependency ezgzip 0.2.3 (latest) · OCaml Package. According to the logs, this package requires pkg-config to be present on the build machine.

I’ve not found a suitable alternative package. I could try to execute a sub process to call gzip (assuming it would be present) to compress the string, but that feels like a workaround.

Thanks for you help.

Here are my logs:

] > <><> Processing actions <><><><><><><><><><><><><><><><><><><><><><><><><><><><>
[build] > 
[build] > #=== ERROR while compiling conf-pkg-config.4 ==================================#
[build] > "pkg-config": command not found.
[build] > 
[build] > 
[build] > <><> Error report <><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><>
[build] > +- The following actions failed
[build] > | - build cmdliner        2.1.0
[build] > | - build conf-pkg-config 4
[build] > +- 
[build] > - No changes have been performed
[build] > 
[build] > The packages you requested declare the following system dependencies. Please make sure they are installed before retrying:
[build] >     pkg-config
[build] > 
[build] > # Run eval $(opam env) to update the current shell environment
[build] Error: process "/bin/sh -c opam install . --yes" did not complete successfully: exit code: 31.
[build] > +- The following actions failed
[build] > | - build cmdliner        2.1.0
[build] > | - build conf-pkg-config 4
[build] > +- 
[build] > - No changes have been performed
[build] > 
[build] > The packages you requested declare the following system dependencies. Please make sure they are installed before retrying:
[build] >     pkg-config
[build] > 
[build] > # Run eval $(opam env) to update the current shell environment
[build] Build failed. Check the logs above for the reason.
[build] If you think this is a CodeCrafters error, please contact us at hello@codecrafters.io.

Hey @rubenbakker, looks like you’ve completed the HTTP server challenge without pkg-config. :tada:

Let me know if you’d still like pkg-config to be installed in the OCaml environment.

Hi @andy1li. I implemented a workaround by using gzip. If you’d be able to add pkg-config, I’d love to replace the workaround with a proper solution. Thanks!