I'd like to make the pre-requisites for PICRUSt2 available on conda to make the installation more straight-forward. EPA-NG (GitHub - pierrebarbera/epa-ng: Massively parallel phylogenetic placement of genetic sequences) is one of the pre-requisities that I'm having trouble writing a conda recipe for. This tool has a number of build requirements including cmake and autotools-dev (which isn't available through conda and may be related to this problem).
I'm getting this error in the circle CI report:
Running cmake
CMake Warning (dev) at CMakeLists.txt:119:
Syntax Warning in cmake code at column 71
Argument not separated from preceding token by whitespace.
This warning is for project developers. Use -Wno-dev to suppress it.
CMake Error at /opt/conda/conda-bld/epa-ng_1539368794807/_build_env/share/cmake-3.12/Modules/CMakeDetermineCXXCompiler.cmake:47 (message):
Could not find compiler set in environment variable CXX:
Are you building this locally or in the context of something like conda-forge or bioconda (I'll assume locally).
I think if you change the compiler:
To 'cxx' instead we'll get some slightly different errors, as it looks like EPA-NG uses CMake and C++. I'm not sure how CMake factors into this (if at all), but it's probably not surprising that conda isn't setting a env-var for a C++ compiler.
We can also use conda render which will template out everything in the recipe to what it is going to use. This should show us the recipe conda is actually using, which should be helpful information.
CMake Error at /opt/conda/conda-bld/epa-ng_1539608768649/_build_env/share/cmake-3.12/Modules/CMakeDetermineCXXCompiler.cmake:47 (message):
Could not find compiler set in environment variable CXX:
Since you are using bioconda, that makes things a bit harder, we’ve noticed their compiler toolchain doesn’t quite work like we expect, so it’s something we’re trying to learn as well.
I’ll spend a few hours reading up on it and see what I can do.
Do you have a repo with this recipe inside (or a pull request to bioconda)? I couldn’t find anything specifically.
If you have the time that would be great @ebolyen, thanks!
I do have a pull-request here: https://github.com/bioconda/bioconda-recipes/pull/10902. I have mainly been testing it locally, but that was my first attempt at pushing the tool as a test. Two major problems could be that (1) EPA-NG hasn’t been released for Mac yet and (2) the requirement autotools-dev isn’t available through conda. I don’t think these issues explain this particular error message though!
I was able to reproduce the problem on Circle CI. Basically, we need gcc7 during the build step because epa-ng uses C++14. conda-forge is in the middle of a complete overhaul to make this possible:
However I don't know how to enable similar compilers on bioconda yet:
I guess the best answer I have is stay tuned? Either this is possible with some kind of machinery that we don’t know about just yet, or it will soon be possible (ideally by default).
Until then, I don’t think there’s anything we can do about this particular recipe.
Great news! I was able to get the new compilers, and after some tweaking (and trying to figure out what exit code 141 means to bison) I was able to get a local build working in docker!