Skip to content

[Bioc-devel] surfaltr build on Bioc 3.17 error advice

6 messages · Pooja Gangras, Hervé Pagès

#
Hi,

I got an email yesterday alerting me of the error in the build in the new
BioC release. Upon looking into the error further I found out that the
error is occurring because a dependency 'msa' package is not being built in
the new release likely due to some issues with the C++ compiler (just
guessing here).

Can you please advice on next steps? Is there anything I need to do here?

Thanks for your help,
Pooja
#
Hi Pooja,

Generally speaking there are 3 things you can do when a dep breaks your 
package:

1. Consider getting rid of that dep.

2. Contact the author/maintainers of the dep to let them know about the 
problem. If you can suggest a fix (e.g. by sending a PR on GitHub), 
that's even better, as I'm sure it will help get the issue resolved more 
quickly.

3. Do nothing and hope that the dep will get fixed in time for the 3.17 
release (scheduled for end of April, see our release schedule here 
https://bioconductor.org/developers/release-schedule/ for the details). 
But that's risky ;-)

In the case of msa's compilation error, it seems to be due to the R 
developers switching to the C++17 compiler by default for C++ package 
code in recent version of R devel (4.3 series). This is documented in 
the R devel NEWS file here: 
https://cran.r-project.org/doc/manuals/r-devel/NEWS.html

Note that BioC 3.16 is based on R 4.2 which uses the C++14 compiler by 
default for C++ package code. Therefore, in BioC 3.16, msa compiles fine 
on all platforms: 
https://bioconductor.org/checkResults/3.16/bioc-LATEST/msa/

So one option for the msa folks is to stick to the C++14 compiler by 
adding C++14 to they 'SystemRequirements' field. Although I don't know 
how that would play with Rcpp which gets compiled with the C++17 
compiler, and which they depend on. So maybe that's a little bit risky? 
Maybe something to check with the Rcpp experts.

Best,

H.
On 21/03/2023 09:18, Pooja Gangras wrote:

  
    
#
Hi Herve,

Thank you for the quick response.

So what surprises me is that msa was compiling and building just fine on
the devel branch until now. And hence so was surfaltr, without any errors.
There was a warning in surfaltr which one can see on the 3.16 release, I
had fixed it in the devel branch. For some reason I was not able to push
changes to the existing 3.16 release branch.

I will go ahead and contact the maintainer for msa but hoping that it will
fix itself before release because it was just fine until yesterday.

Thanks,
Pooja

On Tue, Mar 21, 2023, 2:43 PM Herv? Pag?s <hpages.on.github at gmail.com>
wrote:

  
  
#
On 21/03/2023 12:48, Pooja Gangras wrote:

            
As I said, the switch from C++14 to C++17 happened not too long ago in 
the devel version of R. And since we recently updated R on the BioC 3.17 
builders to the most recent R devel, that switch is now reflected on the 
3.17 builds.
That's a separate issue but if you provide more details about how you 
tried to do this and what happened, maybe someone on this list will be 
able to help.
Unfortunately it won't fix itself.

H.
2 days later
#
Hi Herv?,

I reached out to Ulrich who is the maintainer for msa package. He found
your suggestions very helpful and used the option 2 you suggested to fix
the error. Looks like the changes he made have fixed everything on windows
and Linux platforms but the macOS platform is still showing an error
message.

http://bioconductor.org/checkResults/devel/bioc-LATEST/msa/merida1-buildsrc.html

Any ideas on how to fix this?

Thank you so much for all your help!!

Pooja

On Tue, Mar 21, 2023, 4:50 PM Herv? Pag?s <hpages.on.github at gmail.com>
wrote:

  
  
#
Hi Pooja,

Looks like std::auto_ptr is no longer valid in C++17: 
https://stackoverflow.com/questions/69116001/how-do-i-re-enable-c17-removed-features-in-clang

Weird thing is that the compiler is invoked with -std=gnu++17 on all 
platforms but compilation of msa only fails on Mac.

It looks like using -D_LIBCPP_ENABLE_CXX17_REMOVED_FEATURES instead of 
-D_HAS_AUTO_PTR_ETC=1 in msa/src/ClustalW/msaMakefile solves the "no 
template named 'auto_ptr'" problem, but then compilation fails later with:

 ? fileInput/FileParser.cpp:56:5: error: ISO C++17 does not allow 'register'
 ? ?? ?? storage class specifier [-Wregister]
 ? ? ? register int i;
 ? ? ? ^~~~~~~~~

which is easy enough to fix by just removing the few occurrences of the 
'register' keyword in ClustalW source code.

With these small adjustments I manage to have the embedded ClustalW to 
compile on merida1. I don't know about the embedded ClustalOmega and 
Muscle though, they might need some similar adjustments too.

Best,

H.
On 24/03/2023 08:26, Pooja Gangras wrote: