I am building a new node. all goes well until i run this command and get a ghc error.
cabal build cardano-cli cardano-node
[root@ADA-host cardano-node]# cabal build cardano-cli cardano-node
cabal: Cannot find the program ‘ghc’. User-specified path ‘ghc-8.10.2’ does
not refer to an executable and the program is not on the system path.
any ideas why it would not be able to find the program up to this point?
Did you download ghc and install/unpack it? Looks like you didn’t do install ghc/lib or the path is incorrect.
You can reference the coincash guide but swap out the commands to be centos vs ubuntu as each os is slightly different…
Thank you! looks like i ran the command from an old article and used cabal configure --with-compiler=ghc-8.10.2 instead of cabal configure --with-compiler=ghc-8.10.4
now i am getting
, these were the
goals I’ve had most trouble fulfilling: cardano-crypto-class
cabal build cardano-cli cardano-node
Warning: Requested index-state 2021-03-15T00:00:00Z is newer than
‘hackage.haskell.org’! Falling back to older state (2021-03-14T23:47:09Z).
Resolving dependencies…
cabal: Could not resolve dependencies:
[__0] next goal: cardano-crypto-class (user goal)
[__0] rejecting: cardano-crypto-class-2.0.0 (conflict: pkg-config package
libsodium-any, not found in the pkg-config database)
[__0] fail (backjumping, conflict set: cardano-crypto-class)
After searching the rest of the dependency tree exhaustively, these were the
goals I’ve had most trouble fulfilling: cardano-crypto-class
Failed to build Win32-network-0.1.0.0.
Build log (
/root/.cabal/logs/ghc-8.10.4/Win32-network-0.1.0.0-ea777a1112c9a903f5a922e05d3ca5b37daa02b493554559e7d31acd8a4ddd0d.log
):
Configuring library for Win32-network-0.1.0.0…
Preprocessing library for Win32-network-0.1.0.0…
Building library for Win32-network-0.1.0.0…
[1 of 1] Compiling System.IOManager ( src/System/IOManager.hs, dist/build/System/IOManager.o, dist/build/System/IOManager.dyn_o )
/bin/ld.gold: error: cannot find -lgmp
collect2: error: ld returned 1 exit status gcc' failed in phase Linker’. (Exit code: 1)
cabal: Failed to build Diff-0.4.0 (which is required by
test:cardano-cli-golden from cardano-cli-1.27.0). See the build log above for
details.
Failed to build StateVar-1.2.1 (which is required by test:cardano-node-test
from cardano-node-1.27.0, exe:cardano-node from cardano-node-1.27.0 and
others). See the build log above for details.
Failed to build Win32-network-0.1.0.0 (which is required by
test:cardano-node-test from cardano-node-1.27.0, exe:cardano-node from
cardano-node-1.27.0 and others). See the build log above for details.
you can “close” the topic by mark one of the answer as solution - also the title of the topic can be improved by adding the error message itself. like - stake pool server help - “cannot find the ghc”