Ghcup cabal version error

Hi, when I try to set the cabal with ghcup it doesn’t appear, I think is a Path error but I don’t know what I have to do, any help is grateful

Check the bashrc file if u have the lines inside

export LD_LIBRARY_PATH="/usr/local/lib:$LD_LIBRARY_PATH"
export PKG_CONFIG_PATH="/usr/local/lib/pkgconfig:$PKG_CONFIG_PATH"

cabal error 2

keep giving me error

u are using cntools?

I think not, is necessary?

nope, just wanted to know what to provide you because there are more guides when u start building a node


STEP 2 - Make sure to have at least ghc 8.10.4 and cabal

ghcup upgrade
ghcup install ghc 8.10.4
ghcup set ghc 8.10.4
ghc --version
ghcup install cabal
ghcup set cabal
cabal --version
cabal update

I made all of that, I have ghc 8.10.4 and I installed cabal and set cabal but when I check the version still appears version

check this topic and also I will sugest to clean (keep only the right ones) the exports line from bashrc file (nano $HOME/.bashrc)

I have been trying everything, but version continues to appear, I have changed the paths as indicated but the same thing continues to appear, I am not understanding very well where the path should go, I have the cabal folder that I downloaded manually from The cabal page, on the other hand, there is what ghcup has downloaded, version, from what I see there are two paths, the library and the config, I suppose that both will represent the versions of cabal and the library, but to which directory or file should the path go? Is this the cabal path to select the versions, or is it ghcup?

cabal error 3

man let’s try something
cd /usr/local
ls -l

share the output

error cabal 4

ok, and now

cd ${HOME}/.cabal/
ls -l

error cabal 5

so, u have the old bin file on usr/local and it perhaps this is the reasson

try to cd /usr/local
mv bin bin_old

now check again cabal version

error cabal 6

When I cabal --version without sudo su still give me

try this command

. "${HOME}/.bashrc"

now check again cabal version

it’s not clear for me which guide did u followed to install the node…

type cd $CNODE_HOME

ls -l

error cabal 7

then go back to cd /usr/local and rename the bin_old back to bin
mv bin_old bin and I believe your issue is related with the export paths

error cabal 8

What paths should I change to fix it?