FAQ: document additional tools required for C/C++ development
PR Checklist:
- [x] note any issues closed by this PR with closing keywords
- [x] if you are adding a new page under
docs/orcommunity/, you have added it to the sidebar in the corresponding_sidebar.jsonfile - [x] put any other relevant information below
Whenever I suggest users to use conda-forge for C/C++ development, I almost always suggest them to install the packages:
compilers cmake pkg-config make ninja meson
while this list is quite an arbitrary choice (for example, most Windows users do not actually need make, and typically only one of cmake or meson is used) I found it useful to have a simple list of packages that users need to install, without having to think too much about it, so I thought it would be useful to have it in the main conda-forge docs.
I think this is particularly useful as sometimes the reason of why you need all this packages are really far from intuitive or obvious. Some examples:
compilersinstead ofcxx-compiler: A user wants to develop a C++ library with CMake, so intuitively it just installscxx-compilerandcmakepackages. If it does that, CMake may fail complaining that a C compiler is not found, as CMake always look for a C compiler unlessLANGUAGES CXXis not explicitly passed to theprojectcommand invocation. And even if a user setsLANGUAGES CXXin its root CMakeLists.txt, C language support could still be used in aFind<pkg>script or in a dependency included (even transitively) viaFetchContent, so it is difficult to anticipate whenc-compileris also require, and when not.cmake pkg-configinstead ofcmake: manyFind<pkg>.cmakescripts, either provided by CMake or in third party projects, rely on pkg-config being available for finding projects that install.pcfiles. Not havingpkg-configmay result in enigmaticfind_package(...)failures, especially for not experienced users.
I sometimes wonder if it could make sense to a build-essential meta-package similar to the similar package available in Debian, but I guess that would be a longer discussion, as a first step just adding some details in the docs seemed the easiest thing to do.
I opened this PR just encountered users on Twitter confused by how to do C/C++ dev with conda-forge (see https://x.com/sitraversaro/status/1858085950078746697), and I realized it could be convenient to have this info in conda-forge docs.