Can anyone explain the difference between these two cabal
invocations? I don’t understand it.
% cabal install --with-ghc ghc-9.6 pandoc
The path to the compiler program (or programs used by the
compiler) cannot be specified on a per-package basis in the
cabal.project file (i.e. setting the 'ghc-location' for package 'pandoc').
All packages have to use the same compiler, so specify the path in a
global 'program-locations' section.
% cabal install --with-compiler ghc-9.6 pandoc
Resolving dependencies...
<proceeds to compile as expected>