This repo provides Github releases for Alpine Linux glibc
packages, for both amd64 and arm64 CPU architectures.
Although the artifacts (and intermediate tarballs) are store in Git LFS, please do not pull these unless you are a maintainer of this repo, as Github's LFS bandwidth limitation of 10GB per month would soon be exhausted. There is no such limit for downloading artifacts from releases.
Full credit to @sgerrand for the original work; all that's really done here is wrapping
the build process up in Github workflows that provide a hassle-free way to deliver new releases when new glibc
versions become available.
Specifically, this repo is derived from a combination of:
- https://github.com/sgerrand/alpine-pkg-glibc - for amd64, up to glibc 2.35 inclusive, we just used releases from this repo, but new ones stopped being added, and Github Issues were disabled here.
- https://github.com/sgerrand/docker-glibc-builder and https://github.com/sgerrand/docker-alpine-abuild - which we
continue to make use of in our Github workflows for compiling
glibcand packaging the resulting binaries into Alpineapkfiles.
Maintainers:
Here is an excerpt from a multi-architecture Dockerfile, showing how you might consume the binary artifacts in
our releases.
The derivation of this, in turn, came from a long-since-removed AdoptOpenJDK Dockerfile definition for building an OpenJ9 Alpine Linux Java base image.
ENV GLIBC_VERSION='2.42'
RUN echo 'Installing glibc-based standard C libraries' && \
curl -LfsS https://github.com/dalet-oss/alpine-glibc/releases/download/${GLIBC_VERSION}-${TARGETARCH}/glibc-${GLIBC_VERSION}.apk -o /tmp/glibc-${GLIBC_VERSION}.apk && \
curl -LfsS https://github.com/dalet-oss/alpine-glibc/releases/download/${GLIBC_VERSION}-${TARGETARCH}/glibc-bin-${GLIBC_VERSION}.apk -o /tmp/glibc-bin-${GLIBC_VERSION}.apk && \
curl -LfsS https://github.com/dalet-oss/alpine-glibc/releases/download/${GLIBC_VERSION}-${TARGETARCH}/glibc-i18n-${GLIBC_VERSION}.apk -o /tmp/glibc-i18n-${GLIBC_VERSION}.apk && \
curl -LfsS https://raw.githubusercontent.com/dalet-oss/alpine-glibc/refs/heads/master/alpine-packaging-rsa.pub -o /etc/apk/keys/alpine-packaging-rsa.pub && \
apk add --force-overwrite --no-cache /tmp/glibc-${GLIBC_VERSION}.apk && \
apk add --no-cache /tmp/glibc-bin-${GLIBC_VERSION}.apk && \
apk add --no-cache /tmp/glibc-i18n-${GLIBC_VERSION}.apk && \
rm -rf /tmp/*.apk
# N.B. If you want to use this glibc installation to run a glibc-based JVM, you'll want to install `libgcc`,
# `libstdc++`, and `zlib` also. Arch Linux is a good source for these binaries, which at the time of writing seem
# to work just fine when unpacked to the /usr/glibc-compat/lib directory.Release tags are normally ${GLIBC_VERSION}-${TARGETARCH}, exactly as used above.
Version 2.44 is an exception: its tags are 2.44-amd64-r1 and 2.44-arm64-r1. Empty releases were briefly
published for 2.44-amd64 and 2.44-arm64 in error and were subsequently deleted; because this repository has
immutable releases
enabled, a tag name used by an immutable release is permanently reserved and cannot be recreated even once the
release and tag have been deleted. A -r1 suffix is therefore used for 2.44.
Only the tag name is affected; the asset filenames are unchanged. So for 2.44 the download URL is:
https://github.com/dalet-oss/alpine-glibc/releases/download/2.44-${TARGETARCH}-r1/glibc-2.44.apk
- Edit glibc-versions.yml to add an entry for the new glibc version, with dummy checksums. Anyone can raise a PR for this!
- Push this change (e.g. merge the PR) to
master. - Github Actions will launch the
compile-glibcworkflow to compile the new glibc version foramd64, and raise a PR delivering it and updating the corresponding checksum in glibc-versions.yml. - When the autogenerated PR is ready, you should review it, and merge if appropriate.
- Repeat steps (3) and (4) for the
arm64variant. - Github Actions will then launch both of:
- the
compile-glibcworkflow again (validating checksums); and - the
package-apksworkflow to package glibc into appropriate, signed APKs, raising separate PRs for each of theamd64andarm64variants.
- the
- When the autogenerated PRs are ready, you should review them, and merge if appropriate. They may be merged in
either order; the
publish-releasesworkflow watches both architectures' APK directories, and publishes each architecture's release as soon as that architecture's four APKs have landed onmaster. - Github Actions will then launch the
publish-releasesworkflow to publish the new APK sets to our Github releases page. - 💃 🪩 🕺