Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
G
GHC musl
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Glasgow Haskell Compiler
GHC musl
Commits
08e8eddc
Verified
Commit
08e8eddc
authored
1 year ago
by
Olivier Benz
Browse files
Options
Downloads
Plain Diff
Merge branch 'freeze-version'
parents
905a3747
18129a13
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
.gitlab-ci.yml
+2
-2
2 additions, 2 deletions
.gitlab-ci.yml
CODE_OF_CONDUCT.md
+2
-2
2 additions, 2 deletions
CODE_OF_CONDUCT.md
prior/9.8.1.Dockerfile
+175
-0
175 additions, 0 deletions
prior/9.8.1.Dockerfile
with
179 additions
and
4 deletions
.gitlab-ci.yml
+
2
−
2
View file @
08e8eddc
...
@@ -5,8 +5,8 @@
...
@@ -5,8 +5,8 @@
STACK_VERSION
:
"
2.15.1"
STACK_VERSION
:
"
2.15.1"
HLS_VERSION
:
"
2.6.0.0"
HLS_VERSION
:
"
2.6.0.0"
BUILD_GHC
:
"
true"
BUILD_GHC
:
"
true"
BUILD_HLS
:
"
tru
e"
BUILD_HLS
:
"
fals
e"
TAG_VERSION_MAJ_MIN
:
"
tru
e"
TAG_VERSION_MAJ_MIN
:
"
fals
e"
TAG_VERSION_MAJ
:
"
false"
TAG_VERSION_MAJ
:
"
false"
.before-script-build
:
&before-script-build
.before-script-build
:
&before-script-build
...
...
This diff is collapsed.
Click to expand it.
CODE_OF_CONDUCT.md
+
2
−
2
View file @
08e8eddc
...
@@ -45,14 +45,14 @@ or harmful.
...
@@ -45,14 +45,14 @@ or harmful.
Community leaders have the right and responsibility to remove, edit, or reject
Community leaders have the right and responsibility to remove, edit, or reject
comments, commits, code, wiki edits, issues, and other contributions that are
comments, commits, code, wiki edits, issues, and other contributions that are
not aligned to this Code of Conduct, and will communicate reasons formoderation
not aligned to this Code of Conduct, and will communicate reasons for
moderation
decisions when appropriate.
decisions when appropriate.
## Scope
## Scope
This Code of Conduct applies within all community spaces, and also applies when
This Code of Conduct applies within all community spaces, and also applies when
an individual is officially representing the community in public spaces.
an individual is officially representing the community in public spaces.
Examples of representing our community include using an official e
-
mail address,
Examples of representing our community include using an official email address,
posting via an official social media account, or acting as an appointed
posting via an official social media account, or acting as an appointed
representative at an online or offline event.
representative at an online or offline event.
...
...
This diff is collapsed.
Click to expand it.
prior/9.8.1.Dockerfile
0 → 100644
+
175
−
0
View file @
08e8eddc
ARG
GHC_VERSION=9.8.1
ARG
CABAL_VERSION=3.10.2.1
ARG
STACK_VERSION=2.15.1
ARG
GHC_VERSION_BUILD=${GHC_VERSION}
ARG
CABAL_VERSION_BUILD=${CABAL_VERSION}
FROM
glcr.b-data.ch/ghc/ghc-musl:9.6.4
as
bootstrap
RUN
apk upgrade
--no-cache
\
&&
apk add
--no-cache
\
autoconf
\
automake
\
binutils-gold
\
build-base
\
coreutils
\
cpio
\
curl
\
gnupg
\
linux-headers
\
libffi-dev
\
llvm14
\
ncurses-dev
\
perl
\
python3
\
xz
\
zlib-dev
FROM
bootstrap
as
bootstrap-ghc
ARG
GHC_VERSION_BUILD
ENV
GHC_VERSION=${GHC_VERSION_BUILD}
RUN
cd
/tmp
\
&&
curl
-sSLO
https://downloads.haskell.org/~ghc/
"
$GHC_VERSION
"
/ghc-
"
$GHC_VERSION
"
-src
.tar.xz
\
&&
curl
-sSLO
https://downloads.haskell.org/~ghc/
"
$GHC_VERSION
"
/ghc-
"
$GHC_VERSION
"
-src
.tar.xz.sig
\
&&
gpg
--keyserver
hkps://keyserver.ubuntu.com:443
\
--receive-keys
FFEB7CE81E16A36B3E2DED6F2DE04D4E97DB64AD
||
\
gpg
--keyserver
hkp://keyserver.ubuntu.com:80
\
--receive-keys
FFEB7CE81E16A36B3E2DED6F2DE04D4E97DB64AD
\
&&
gpg
--verify
"ghc-
$GHC_VERSION
-src.tar.xz.sig"
"ghc-
$GHC_VERSION
-src.tar.xz"
\
&&
tar
-xJf
"ghc-
$GHC_VERSION
-src.tar.xz"
\
&&
cd
"ghc-
$GHC_VERSION
"
\
&&
./boot.source
\
&&
./configure
--disable-ld-override
LD
=
ld.gold
\
## Use the LLVM backend
## Switch llvm-targets from unknown-linux-gnueabihf->alpine-linux
## so we can match the llvm vendor string alpine uses
&& sed -i -e 's/unknown-linux-gnueabihf/alpine-linux/g' llvm-targets \
&& sed -i -e 's/unknown-linux-gnueabi/alpine-linux/g' llvm-targets \
&& sed -i -e 's/unknown-linux-gnu/alpine-linux/g' llvm-targets \
&& cabal update \
## See https://unix.stackexchange.com/questions/519092/what-is-the-logic-of-using-nproc-1-in-make-command
&& hadrian/build binary-dist -j"$(($(nproc)+1))" \
--flavour=perf+llvm+split_sections \
--docs=none
FROM
bootstrap
as
bootstrap-cabal
ARG
CABAL_VERSION_BUILD
ENV
CABAL_VERSION=${CABAL_VERSION_BUILD}
## Build Cabal (the tool) with the GHC bootstrap version
RUN
cabal update
\
## See https://gitlab.haskell.org/ghc/ghc/-/wikis/commentary/libraries/version-history
&& cabal install "cabal-install-$CABAL_VERSION"
FROM
alpine:3.19
as
ghc-base
LABEL
org.opencontainers.image.licenses="MIT" \
org.opencontainers.image.source="https://gitlab.b-data.ch/ghc/ghc-musl" \
org.opencontainers.image.vendor="Olivier Benz" \
org.opencontainers.image.authors="Olivier Benz <olivier.benz@b-data.ch>"
ARG
GHC_VERSION_BUILD
ARG
CABAL_VERSION_BUILD
ARG
STACK_VERSION
ENV
GHC_VERSION=${GHC_VERSION_BUILD} \
CABAL_VERSION=${CABAL_VERSION_BUILD} \
STACK_VERSION=${STACK_VERSION}
RUN
apk add
--no-cache
\
bash
\
build-base
\
bzip2
\
bzip2-dev
\
bzip2-static
\
curl
\
curl-static
\
dpkg
\
fakeroot
\
git
\
gmp-dev
\
libcurl
\
libffi
\
libffi-dev
\
llvm14
\
ncurses-dev
\
ncurses-static
\
openssl-dev
\
openssl-libs-static
\
pcre
\
pcre-dev
\
pcre2
\
pcre2-dev
\
perl
\
## Install shadow for `stack --docker`
shadow \
wget \
xz \
xz-dev \
zlib \
zlib-dev \
zlib-static
FROM
ghc-base
as
ghc-stage1
COPY
--from=bootstrap-ghc /tmp/ghc-"$GHC_VERSION"/_build/bindist/ghc-"$GHC_VERSION"-*-alpine-linux.tar.xz /tmp/
RUN
cd
/tmp
\
## Install GHC
&& tar -xJf ghc-"$GHC_VERSION"-*-alpine-linux.tar.xz \
&& cd ghc-"$GHC_VERSION"-*-alpine-linux \
&& ./configure --disable-ld-override \
&& make install \
## Install Stack
&& cd /tmp \
&& curl -sSLO https://github.com/commercialhaskell/stack/releases/download/v"$STACK_VERSION"/stack-"$STACK_VERSION"-linux-"$(uname -m)".tar.gz \
&& curl -sSLO https://github.com/commercialhaskell/stack/releases/download/v"$STACK_VERSION"/stack-"$STACK_VERSION"-linux-"$(uname -m)".tar.gz.sha256 \
&& sha256sum -cs stack-"$STACK_VERSION"-linux-"$(uname -m)".tar.gz.sha256 \
&& tar -xzf stack-"$STACK_VERSION"-linux-"$(uname -m)".tar.gz \
&& mv stack-"$STACK_VERSION"-linux-"$(uname -m)"/stack /usr/local/bin/stack \
## Clean up
&& rm -rf /tmp/*
FROM
ghc-stage1
as
ghc-stage2
## Install Cabal (the tool) built with the GHC bootstrap version
COPY
--from=bootstrap-cabal /root/.local/bin/cabal /usr/local/bin/cabal
## Rebuild Cabal (the tool) with the GHC target version
RUN
cabal update
\
&&
cabal
install
"cabal-install-
$CABAL_VERSION
"
FROM
ghc-stage1
as
test
WORKDIR
/usr/local/src
## Install Cabal (the tool) built with the GHC target version
COPY
--from=ghc-stage2 /root/.local/bin/cabal /usr/local/bin/cabal
COPY
Main.hs Main.hs
RUN
ghc
-static
-optl-pthread
-optl-static
Main.hs
\
&&
file Main
\
&&
./Main
\
## Test cabal workflow
&& mkdir cabal-test \
&& cd cabal-test \
&& cabal update \
&& cabal init -n --is-executable -p tester -l MIT \
&& cabal run
FROM
ghc-base
## Install GHC and Stack
COPY
--from=ghc-stage1 /usr/local /usr/local
## Install Cabal (the tool) built with the GHC target version
COPY
--from=ghc-stage2 /root/.local/bin/cabal /usr/local/bin/cabal
CMD
["ghci"]
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment