Closed Fifis closed 4 months ago
This is an R package, and R packages usually communicate this via the SystemRequirements
field in file DESCRIPTION
:
Thank you, I did not know this. Some popular packages handle configure
errors at the time of installation, which is why I thought that it would be a good idea. Another reason was, there is a similar answer on SO that does not list libprotoc-dev
for a different package that also relies on protobuf. Closing the issue.
Your point is entirely reasonable, but such declarations of dependencies is in fact a weak point of the R package system, see eg here https://mastodon.social/@jdblischak@rstats.me/112756888153973401 for a recent thread in which I participated.
And with all due respect (and the fact that I have been a Debian Developer for nearly 30 years) trying to detect where configure
runs and emiting appropriate errors is ... not a winning proposition. We have umpteen Linux distro, brew/homebrew, Conda, macports, ... It is impossible to follow (and likely why CRAN cannot declare dependencies 'universally') so failing when building is, I fear, the best we can do. I agree that here especially it is hard given the multiple dependencies but such is life.
Obviously RProtoBuf depends on Protobuf being available on the system. Usually, installing the corresponding
-dev
library on Debian-based system works. However, installinglibprotobuf-dev
andprotobuf-compiler
is not sufficient in this case. One has to check file lists for various packages to find that it islibprotoc-dev
that providesgoogle/protobuf/compiler/code_generator.h
.Suggestion: it is considered good user experience to list the dependencies as a suggestion if
configure
fails, e.g.:That should save time for the users who are wondring why doing
libprotobuf-dev
did not change anything.