Closed villaa closed 2 years ago
Coming here from https://github.com/villano-lab/nrCascadeSim/issues/48#issuecomment-993035515, I guess this was already know to you given:
As nrCascadeSim
can currently only be compiled (I think, so let me know if you have a c++17
version I should be using) against ROOT releases that were also compiled against c++14
can you recommend an CVMFS LCG view that you've used to test this that has c++14
ROOT so I can keep testing now while c++17
support is considered?
The LCG view that I'm most used to setting up is LCG view 98python3
with x86_64-centos7-gcc8-opt
but that gives me a c++17
ROOT:
$ . /cvmfs/sft.cern.ch/lcg/views/LCG_98python3/x86_64-centos7-gcc8-opt/setup.sh
$ command -v root
/cvmfs/sft.cern.ch/lcg/views/LCG_98python3/x86_64-centos7-gcc8-opt/bin/root
$ root --version
ROOT Version: 6.22/00
Built for linuxx8664gcc on Jun 14 2020, 15:54:05
From tags/v6-22-00@v6-22-00
$ root-config --cflags
-pthread -std=c++17 -m64 -I/cvmfs/sft.cern.ch/lcg/releases/ROOT/v6.22.00-be0a0/x86_64-centos7-gcc8-opt/include
I think because of the merging of #54 we should be OK with C++14 or C++17, but should now explicitly test C++17 in the CI. After upgrading that will consider this issue closed.
Closed with PR #57 where we work in all compilers ranging from c++11 to c++17 into Travis-CI
See the second-submission's pre-review thread.
[ ] Installation: Does installation proceed as outlined in the documentation?
No. The Makefile has hardcoded assumptions on the C++ standard that will be used, while they should instead rely on the information provided by root-config --cflags. Here the Makefile has hardcoded c++14. If this software wants to make the decision to enforce an uppper bound on the C++ standards they support that's not fundamentally wrong, but it needs to be made explicitly clear to the user in advance.
Reproducible example of failing with ROOT compiled against c++17:
If the hardcoded C++ flags are changed to reflect the version of C++ used to compile ROOT then things will pass (this is why the project CI passes, as only c++14 is tested).
...
This should not be the responsibility of the user, but should be discoverable and covered in tests.
The install Make target also hardcodes the install target directory to /usr/local/bin. Install locations can have defaults, but should allow for user input. Similarly, advocating directly for the use of sudo for installation of local software should be avoided.