villano-lab / nrCascadeSim

calculating the NR spectrum resulting from neutron-capture cascades.
MIT License
0 stars 1 forks source link

Trouble installing on WSL #76

Closed nuclearGoblin closed 2 years ago

nuclearGoblin commented 2 years ago

I am submitting a documentation issue.

The files in question are: readthedocs pages

The problem is in the following category/categories: Undocumented Information

Description of the problem: Currently, the docs do not make it clear what setup is required for installation on WSL. This leads to issues with the installation that occur at the make step. Currently, these issues appear to be tied to how ROOT is installed.

Here is what I know so far:

Other possible issues/explanations:

Things that would be helpful to determine:

Tagging @altavir to continue our discussion from the review thread.

nuclearGoblin commented 2 years ago

Alternatively, resolving #71 will likely resolve this issue.

altavir commented 2 years ago

The error is the following: /usr/bin/ld: /nix/store/7g0k3gjnvswvllqjbcr02vsydzgpgzgm-xz-5.2.5/lib/liblzma.so.5: undefined reference to 'pthread_sigmask@GLIBC_2.32'. It seems like a glbc conflict inside root.

Removing Root dependency should indeed fix a lot of issues. You use it from python scipts anyway. It does not seem to be critical for the simulation iteslf.

villaa commented 2 years ago

@altavir it would be nice to remove the ROOT dependency but I don't think we want to at this stage. You are correct that the simulation itself (by design) doesn't depend on ROOT. However the output structure utilizes one important feature of ROOT output files--that each output element can essentially be jagged arrays.

Now, we could probably reproduce this in something like hdf5 but to remove the ROOT dependency totally would result in something that limits the use in our field severely (particle physics).

What I would ultimately suggest is to build up an hdf5 output and include ROOT as an option controlled by compiler directives. I think this may be work that we can schedule in the future but I hope it doesn't have to be done for this review (because it will take a long time).

What do you think?

altavir commented 2 years ago

@villaa It is up to you to decide. The issue #71 is not obligatory. I personally just hate ROOT (from software engeneering point of view) so I could be biased. In this particular case, it significantly complicates the build process and significantly limits application of the library. I think it should be still mentioned in the paper alongside with some reasoning because it is a significant complication.

People in accelerator physics community are obviously vendor-locked on ROOT, so it is not a problem for them, but luckily, people are stopping using it in non-accelerator physics (where I come from).

nuclearGoblin commented 2 years ago

I'm about to start a PR updating the docs with a note on the installation method for ROOT in WSL. @altavir whenever you next try installing, could you confirm whether the installation works on your system if you get ROOT via the conda package instead of nix-env?

altavir commented 2 years ago

The latest ROOT from conda seems to be working. It seems that the problem is ROOT from NIX is built on top of incompatible libc.