Commit 1e3f889f authored by Eric Timmons's avatar Eric Timmons
Browse files

Support multiple architectures

Grab some code from my SBCL repo to handle this.
parent c270b7e7
#!/bin/bash
declare -A CONTEXTS
declare -A ARCH_MAP
ARCH_MAP[amd64]=linux/amd64
ARCH_MAP[arm32v7]=linux/arm/v7
ARCH_MAP[windows-amd64]=windows/amd64
CCL_VERSION=1.11.5
REPO=daewok/ccl
LATEST_DEBIAN=buster
LATEST_UBUNTU=eoan
#+TITLE: CCL Docker Images
#+AUTHOR: Eric Timmons
This repo contains Dockerfiles for Clozure Common Lisp (CCL) on a variety of
base images.
* Supported Tags
The CCL versions built are:
+ =1.11.5-debian-buster=, =1.11.5-debian=, =debian-buster=, =debian=
+ =1.11.5-debian-stretch=, =debian-stretch=
+ =1.11.5-ubuntu-eoan=, =1.11.5-ubuntu=, =ubuntu-eoan=, =ubuntu=
+ =1.11.5-ubuntu-bionic=, =ubuntu-bionic=
+ 1.11.5
* Quick Reference
The OSes and versions CCL is built on are:
+ CCL Home Page :: [[https://ccl.clozure.com/][https://ccl.clozure.com/]]
+ Where to file Docker image related issues :: [[https://github.com/daewok/docker-ccl/][https://github.com/daewok/docker-ccl/]]
+ Where to file issues for CCL itself :: [[https://github.com/Clozure/ccl/issues][https://github.com/Clozure/ccl/issues]]
+ Maintained by :: [[https://github.com/daewok/docker-ccl/][Eric Timmons]] (i.e., this is not an official CCL image)
+ Supported architectures :: =linux/arm64=, =linux/arm/v7=
+ debian
+ stretch
+ ubuntu
+ cosmic
+ bionic
* What is CCL?
* Building
From [[https://ccl.clozure.com][CCL's Home Page]]:
To build all images, just run:
#+begin_quote
Clozure CL (often called CCL for short) is a free Common Lisp implementation
with a long history. Some distinguishing features of the implementation
include fast compilation speed, native threads, a precise, generational,
compacting garbage collector, and a convenient foreign-function interface.
#+end_quote
#+begin_src shell
make
#+end_src
* What's in the image?
This image contains CCL binaries built from the latest binary releases from
the CCL devs for a variety of OSes and architectures.
The general policy for OS support is that images will be built for two
versions of supported OSes: either the two most recent versions or the latest
LTS and most recent version, as applicable.
* License
CCL is licensed under the [[https://www.apache.org/licenses/LICENSE-2.0][Apache v2.0]].
The Dockerfiles used to build the images are licensed under BSD-2-Clause.
As with all Docker images, these likely also contain other software which may
be under other licenses (such as Bash, etc from the base distribution, along
with any direct or indirect dependencies of the primary software being
contained).
As for any pre-built image usage, it is the image user's responsibility to
ensure that any use of this image complies with any relevant licenses for all
software contained within.
FROM ubuntu:cosmic
FROM debian:buster
LABEL maintainer="etimmons@mit.edu"
......
FROM debian:buster
LABEL maintainer="etimmons@mit.edu"
ENV CCL_VERSION=1.11.5
WORKDIR /usr/local/src/
ENV OPENMCL_KERNEL=armcl
# hadolint ignore=DL3003,DL3008
RUN set -x \
&& apt-get update \
&& apt-get install -y --no-install-recommends wget ca-certificates \
&& wget https://github.com/Clozure/ccl/releases/download/v${CCL_VERSION}/ccl-${CCL_VERSION}-linuxarm.tar.gz \
&& gunzip ccl-${CCL_VERSION}-linuxarm.tar.gz \
&& tar xf ccl-${CCL_VERSION}-linuxarm.tar \
&& (cd ccl && rm -rf .git && cp scripts/ccl /usr/local/bin/ccl ) \
&& rm ccl-${CCL_VERSION}-linuxarm.tar \
&& apt-get remove -y wget ca-certificates \
&& apt-get autoremove -y \
&& rm -rf /var/lib/apt/lists/*
WORKDIR /
ENTRYPOINT ["ccl"]
FROM debian:stretch
LABEL maintainer="etimmons@mit.edu"
ENV CCL_VERSION=1.11.5
WORKDIR /usr/local/src/
ENV OPENMCL_KERNEL=armcl
# hadolint ignore=DL3003,DL3008
RUN set -x \
&& apt-get update \
&& apt-get install -y --no-install-recommends wget ca-certificates \
&& wget https://github.com/Clozure/ccl/releases/download/v${CCL_VERSION}/ccl-${CCL_VERSION}-linuxarm.tar.gz \
&& gunzip ccl-${CCL_VERSION}-linuxarm.tar.gz \
&& tar xf ccl-${CCL_VERSION}-linuxarm.tar \
&& (cd ccl && rm -rf .git && cp scripts/ccl /usr/local/bin/ccl ) \
&& rm ccl-${CCL_VERSION}-linuxarm.tar \
&& apt-get remove -y wget ca-certificates \
&& apt-get autoremove -y \
&& rm -rf /var/lib/apt/lists/*
WORKDIR /
ENTRYPOINT ["ccl"]
FROM ubuntu:bionic
LABEL maintainer="etimmons@mit.edu"
ENV CCL_VERSION=1.11.5
WORKDIR /usr/local/src/
ENV OPENMCL_KERNEL=armcl
# hadolint ignore=DL3003,DL3008
RUN set -x \
&& apt-get update \
&& apt-get install -y --no-install-recommends wget ca-certificates \
&& wget https://github.com/Clozure/ccl/releases/download/v${CCL_VERSION}/ccl-${CCL_VERSION}-linuxarm.tar.gz \
&& gunzip ccl-${CCL_VERSION}-linuxarm.tar.gz \
&& tar xf ccl-${CCL_VERSION}-linuxarm.tar \
&& (cd ccl && rm -rf .git && cp scripts/ccl /usr/local/bin/ccl ) \
&& rm ccl-${CCL_VERSION}-linuxarm.tar \
&& apt-get remove -y wget ca-certificates \
&& apt-get autoremove -y \
&& rm -rf /var/lib/apt/lists/*
WORKDIR /
ENTRYPOINT ["ccl"]
FROM ubuntu:eoan
LABEL maintainer="etimmons@mit.edu"
ENV CCL_VERSION=1.11.5
WORKDIR /usr/local/src/
# hadolint ignore=DL3003,DL3008
RUN set -x \
&& apt-get update \
&& apt-get install -y --no-install-recommends wget ca-certificates \
&& wget https://github.com/Clozure/ccl/releases/download/v${CCL_VERSION}/ccl-${CCL_VERSION}-linuxx86.tar.gz \
&& gunzip ccl-${CCL_VERSION}-linuxx86.tar.gz \
&& tar xf ccl-${CCL_VERSION}-linuxx86.tar \
&& (cd ccl && rm -rf .git && cp scripts/ccl64 /usr/local/bin/ccl ) \
&& rm ccl-${CCL_VERSION}-linuxx86.tar \
&& apt-get remove -y wget ca-certificates \
&& apt-get autoremove -y \
&& rm -rf /var/lib/apt/lists/*
WORKDIR /
ENTRYPOINT ["ccl"]
FROM ubuntu:eoan
LABEL maintainer="etimmons@mit.edu"
ENV CCL_VERSION=1.11.5
WORKDIR /usr/local/src/
ENV OPENMCL_KERNEL=armcl
# hadolint ignore=DL3003,DL3008
RUN set -x \
&& apt-get update \
&& apt-get install -y --no-install-recommends wget ca-certificates \
&& wget https://github.com/Clozure/ccl/releases/download/v${CCL_VERSION}/ccl-${CCL_VERSION}-linuxarm.tar.gz \
&& gunzip ccl-${CCL_VERSION}-linuxarm.tar.gz \
&& tar xf ccl-${CCL_VERSION}-linuxarm.tar \
&& (cd ccl && rm -rf .git && cp scripts/ccl /usr/local/bin/ccl ) \
&& rm ccl-${CCL_VERSION}-linuxarm.tar \
&& apt-get remove -y wget ca-certificates \
&& apt-get autoremove -y \
&& rm -rf /var/lib/apt/lists/*
WORKDIR /
ENTRYPOINT ["ccl"]
image: daewok/ccl:debian-buster
manifests:
- image: $DEBIAN_BUSTER_AMD64_NONBUILD_DIGEST
platform:
architecture: amd64
os: linux
- image: $DEBIAN_BUSTER_ARM32V7_NONBUILD_DIGEST
platform:
architecture: arm
variant: v7
os: linux
image: daewok/ccl:debian-stretch
manifests:
- image: $DEBIAN_STRETCH_AMD64_NONBUILD_DIGEST
platform:
architecture: amd64
os: linux
- image: $DEBIAN_STRETCH_ARM32V7_NONBUILD_DIGEST
platform:
architecture: arm
variant: v7
os: linux
image: daewok/ccl:debian
manifests:
- image: $DEBIAN_BUSTER_AMD64_NONBUILD_DIGEST
platform:
architecture: amd64
os: linux
- image: $DEBIAN_BUSTER_ARM32V7_NONBUILD_DIGEST
platform:
architecture: arm
variant: v7
os: linux
image: daewok/ccl:ubuntu-bionic
manifests:
- image: $UBUNTU_BIONIC_AMD64_NONBUILD_DIGEST
platform:
architecture: amd64
os: linux
- image: $UBUNTU_BIONIC_ARM32V7_NONBUILD_DIGEST
platform:
architecture: arm
variant: v7
os: linux
image: daewok/ccl:ubuntu-eoan
manifests:
- image: $UBUNTU_EOAN_AMD64_NONBUILD_DIGEST
platform:
architecture: amd64
os: linux
- image: $UBUNTU_EOAN_ARM32V7_NONBUILD_DIGEST
platform:
architecture: arm
variant: v7
os: linux
image: daewok/ccl:ubuntu
manifests:
- image: $UBUNTU_EOAN_AMD64_NONBUILD_DIGEST
platform:
architecture: amd64
os: linux
- image: $UBUNTU_EOAN_ARM32V7_NONBUILD_DIGEST
platform:
architecture: arm
variant: v7
os: linux
image: daewok/ccl:$CCL_VERSION-debian-buster
manifests:
- image: $DEBIAN_BUSTER_AMD64_NONBUILD_DIGEST
platform:
architecture: amd64
os: linux
- image: $DEBIAN_BUSTER_ARM32V7_NONBUILD_DIGEST
platform:
architecture: arm
variant: v7
os: linux
image: daewok/ccl:$CCL_VERSION-debian-stretch
manifests:
- image: $DEBIAN_STRETCH_AMD64_NONBUILD_DIGEST
platform:
architecture: amd64
os: linux
- image: $DEBIAN_STRETCH_ARM32V7_NONBUILD_DIGEST
platform:
architecture: arm
variant: v7
os: linux
image: daewok/ccl:$CCL_VERSION-debian
manifests:
- image: $DEBIAN_BUSTER_AMD64_NONBUILD_DIGEST
platform:
architecture: amd64
os: linux
- image: $DEBIAN_BUSTER_ARM32V7_NONBUILD_DIGEST
platform:
architecture: arm
variant: v7
os: linux
image: daewok/ccl:$CCL_VERSION-ubuntu-bionic
manifests:
- image: $UBUNTU_BIONIC_AMD64_NONBUILD_DIGEST
platform:
architecture: amd64
os: linux
- image: $UBUNTU_BIONIC_ARM32V7_NONBUILD_DIGEST
platform:
architecture: arm
variant: v7
os: linux
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment