Gentoo Prefix on CVMFS

I tried your “Gentoo Prefix on CVMFS” on a Ubuntu 18.04 LTS / x86_64 machine:

[...]:~$ /cvmfs/sft.cern.ch/lcg/contrib/gentoo/linux/x86_64/startprefix
Entering Gentoo Prefix /cvmfs/sft.cern.ch/lcg/contrib/gentoo/linux/x86_64
bash: eval: line 31: syntax error near unexpected token `newline'
bash: eval: line 31: `Usage: lesspipe <file>'

Your bashrc seems to be interfering with it. Can you try with a clean shell setup? In particular, you should not prepend things to $PATH, for example, as that would probably put things from your Ubuntu installation before things from the prefix, and you want prefix stuff coming first.

diff /etc/skel/.bashrc ${HOME}/.bashrc” returns nothing

So, your “Gentoo Prefix on CVMFS” happily injects a “lesspipe” utility which is incompatible with the one provided by Ubuntu systems.
A brutal fix:

[...]:~$ diff /etc/skel/.bashrc ${HOME}/.bashrc
31c31
< [ -x /usr/bin/lesspipe ] && eval "$(SHELL=/bin/sh lesspipe)"
---
> [ -x /usr/bin/lesspipe ] && eval "$(SHELL=/bin/sh /usr/bin/lesspipe)"

Well, that’s the whole point of using Gentoo prefix, it “happily injects” all the tools from Gentoo for you to use, and some tools may not be the same as from your own distro. Gentoo prefix depends only on the kernel of the host system (and that’s why it works on all distros), everything else is in CVMFS and is used once you enter the environment. You can actually bind mount /cvmfs into a busybox docker container and use it. But indeed, you may need minor adjustments like the above to your own .bashrc when you use the prefix environment. Gentoo’s less utility doesn’t need eval $(lesspipe) in .bashrc to work. You should just export LESSCOLOR=always in your bashrc (run lesspipe --help on Gentoo prefix if you want to look further into this). This problem has actually come up in some other places as well. Cheers,

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.