amauryt / cr-cmark-gfm

Crystal C bindings for cmark-gfm to work with Commonmark and Github Flavored Markdown
BSD 2-Clause "Simplified" License
20 stars 4 forks source link

Possible to skip building man pages during install? #4

Closed jwoertink closed 4 years ago

jwoertink commented 4 years ago

I've added this shard which needs to build on github actions CI, but it currently fails with python: not found. I don't need python for anything else, so I'd rather not add it in just to install this, so I was wondering if there was a way to skip that during the make?

  Binaries can be found in build/src
  python man/make_man_page.py src/cmark-gfm.h > man/man3/cmark-gfm.3
  /bin/sh: 1: python: not found
  Makefile:105: recipe for target 'man/man3/cmark-gfm.3' failed
  make[1]: Leaving directory '/__w/website/website/lib/cmark/ext/cmark-gfm'
  make[1]: *** [man/man3/cmark-gfm.3] Error 127
  Makefile:7: recipe for target 'libcmark-gfm.a' failed
  make: *** [libcmark-gfm.a] Error 2
##[error]Process completed with exit code 1.
amauryt commented 4 years ago

Hey @jwoertink, it should be possible to skip the man page generation by modifying L7 on the Makefile of this shard ext folder, by adding the target cmake_build, that is:

cd $(CMARK) && INSTALL_PREFIX=.. make cmake_build

This is because the all target on the Makefile of the cmark-gfm C library has only two targets: cmake_build and the man page generation.

However, I'm not sure if this should be an option or the default in which we completely forgo man page generation.

What are your thoughts on this?

jwoertink commented 4 years ago

Yeah, I guess I could fork the shard and make the update, then point over to my fork, but then I would have to maintain that unless you made the change.

Personally, I don't think man page docs are necessary here since no one would be using the cmark directly. The idea being that if we needed to understand something, we'd look for your shard docs instead. Removing it completely might also help make shard postinstall quicker since it would skip that.

amauryt commented 4 years ago

I agree. I have made and published the change to forgo man page generation. Given that the build passes on Travis, please update your shard dependency and let me know if that fixes it for you. Thanks!

jwoertink commented 4 years ago

Sweet! That let the CI build pass! Thanks so much for the quick update. I think this is resolved now.