From 234083a625f2f1c98ebafcf2076e5a1870c6eecc Mon Sep 17 00:00:00 2001 From: ION606 Date: Mon, 9 Sep 2024 19:03:30 -0400 Subject: [PATCH] fix to version 8.8.4 --- dockerfiles/haskell/3.0.0.0/Dockerfile | 23 +++++++++++++++++------ 1 file changed, 17 insertions(+), 6 deletions(-) diff --git a/dockerfiles/haskell/3.0.0.0/Dockerfile b/dockerfiles/haskell/3.0.0.0/Dockerfile index af83e51..87339c7 100644 --- a/dockerfiles/haskell/3.0.0.0/Dockerfile +++ b/dockerfiles/haskell/3.0.0.0/Dockerfile @@ -1,14 +1,25 @@ FROM ubuntu:22.04 -# Install necessary packages for GHC (compiler) +# Install necessary dependencies RUN apt-get update \ && apt-get install -y --no-install-recommends \ - ghc cabal-install \ + apt-utils curl build-essential libffi-dev libffi8 libgmp10 \ + libgmp-dev libncurses-dev libncurses5 libtinfo5 pkg-config \ + ca-certificates \ && rm -rf /var/lib/apt/lists/* - -# Maybe add Stack (another build tool for Haskell), up to Instructor? -# RUN curl -sSL https://get.haskellstack.org/ | sh + +# Install GHCup (Haskell toolchain manager) +RUN curl --proto '=https' --tlsv1.2 -sSf https://get-ghcup.haskell.org | bash -s -- -y + +# Add GHCup to the PATH +ENV PATH="/root/.ghcup/bin:${PATH}" + +# Install GHC 8.8.4 and Cabal using GHCup +RUN ghcup install ghc 8.8.4 \ + && ghcup set ghc 8.8.4 \ + && ghcup install cabal \ + && cabal update WORKDIR /usr/src/app -CMD ["/bin/bash"] \ No newline at end of file +CMD ["/bin/bash"]