cabal-install bootstrap script respects PREFIX inconsistently, fails
The bootstrap.sh script that comes with cabal-install is documented as respecting a PREFIX environment variable, but if you pass one it will ignore it during the installation of the executable:
./Setup configure --user "--prefix=${HOME}/.cabal" \
--with-compiler=${GHC} --with-hc-pkg=${GHC_PKG} \
${EXTRA_CONFIGURE_OPTS} ${VERBOSE} \
|| die "Configuring the ${PKG} package failed"
But then respect it during the post-install self-test:
CABAL_BIN="$PREFIX/bin"
if [ -x "$CABAL_BIN/cabal" ]
then
- ..
else
echo "Sorry, something went wrong."
fi
Which means that it always emits the "Sorry, something went wrong." message and not the success message when PREFIX was specified. Also that it installed into the wrong directory.
Trac metadata
Trac field | Value |
---|---|
Version | 6.10.4 |
Type | Bug |
TypeOfFailure | OtherFailure |
Priority | normal |
Resolution | Unresolved |
Component | Compiler |
Test case | |
Differential revisions | |
BlockedBy | |
Related | |
Blocking | |
CC | |
Operating system | |
Architecture |