Merge remote-tracking branch 'origin/ConYel/diffoscope' into staging

This commit is contained in:
Lance R. Vick 2024-08-24 17:40:04 -07:00
commit f1861cec72
No known key found for this signature in database
GPG key ID: 8E47A1EC35A1551D
5 changed files with 216 additions and 0 deletions

View file

@ -0,0 +1,46 @@
FROM scratch AS base
ENV VERSION=274
ENV SRC_HASH=c5398be0f26cb13344f4e27cf5a53df2b7a246a7b08944d114eee140989e5bb5
ENV SRC_FILE=${VERSION}.tar.gz
ENV SRC_SITE=https://salsa.debian.org/reproducible-builds/diffoscope/-/archive/${VERSION}/diffoscope-${SRC_FILE}
FROM base AS fetch
ADD --checksum=sha256:${SRC_HASH} ${SRC_SITE} .
FROM fetch AS build
COPY --from=stagex/busybox . /
COPY --from=stagex/musl . /
COPY --from=stagex/zlib . /
COPY --from=stagex/openssl . /
COPY --from=stagex/python . /
COPY --from=stagex/file . /
COPY --from=stagex/gcc . /
COPY --from=stagex/binutils . /
COPY --from=stagex/make . /
COPY --from=stagex/cmake . /
COPY --from=stagex/libffi . /
COPY --from=stagex/py-setuptools . /
COPY --from=stagex/py-installer . /
COPY --from=stagex/py-flit . /
COPY --from=stagex/py-gpep517 . /
COPY --from=stagex/py-wheel . /
COPY --from=stagex/py-distro . /
COPY --from=stagex/py-dateutil . /
COPY --from=stagex/py-urllib3 . /
COPY --from=stagex/py-cffi . /
COPY --from=stagex/py-magic . /
COPY --from=stagex/py-libarchive . /
RUN tar -xzf diffoscope-${SRC_FILE}
WORKDIR diffoscope-${VERSION}
RUN gpep517 build-wheel --wheel-dir .dist --output-fd 3 3>&1 >&2
#
FROM build AS install
RUN --network=none <<-EOF
set -eu
python -m installer -d /rootfs .dist/*.whl
find /rootfs | grep -E "(/__pycache__$|\.pyc$|\.pyo$)" | xargs rm -rf
EOF
FROM stagex/filesystem AS package
COPY --from=install /rootfs/. /

View file

@ -0,0 +1,43 @@
FROM scratch AS base
ENV VERSION=5.1
ENV SRC_HASH=b8198dd259684f75622112eb3172800780fbedda0a83652d22d36db0d4c0433c
ENV SRC_FILE=${VERSION}.tar.gz
ENV SRC_SITE=https://github.com/Changaco/python-libarchive-c/archive/${SRC_FILE}
FROM base AS fetch
ADD --checksum=sha256:${SRC_HASH} ${SRC_SITE} .
FROM fetch AS build
COPY --from=stagex/busybox . /
COPY --from=stagex/musl . /
COPY --from=stagex/python . /
COPY --from=stagex/binutils . /
COPY --from=stagex/make . /
COPY --from=stagex/libarchive . /
COPY --from=stagex/py-setuptools . /
COPY --from=stagex/py-installer . /
COPY --from=stagex/py-flit . /
COPY --from=stagex/py-gpep517 . /
COPY --from=stagex/py-wheel . /
COPY --from=stagex/py-distro . /
COPY --from=stagex/py-dateutil . /
COPY --from=stagex/py-urllib3 . /
COPY --from=stagex/py-cffi . /
COPY --from=stagex/zlib . /
COPY --from=stagex/openssl . /
COPY --from=stagex/libffi . /
COPY --from=stagex/cmake . /
COPY --from=stagex/gcc . /
RUN tar -xzf ${SRC_FILE}
WORKDIR python-libarchive-c-${VERSION}
RUN gpep517 build-wheel --wheel-dir .dist --output-fd 3 3>&1 >&2
FROM build AS install
RUN --network=none <<-EOF
set -eu
python -m installer -d /rootfs .dist/*.whl
find /rootfs | grep -E "(/__pycache__$|\.pyc$|\.pyo$)" | xargs rm -rf
EOF
FROM stagex/filesystem AS package
COPY --from=install /rootfs/. /

View file

@ -0,0 +1,43 @@
FROM scratch AS base
ENV VERSION=0.4.27
ENV SRC_HASH=3978a25d43d9a7b8a89ae9d726bd4962fc90dc4f69ae852e399f3c56d4b0bd63
ENV SRC_FILE=${VERSION}.tar.gz
ENV SRC_SITE=https://github.com/ahupp/python-magic/archive/${SRC_FILE}
FROM base AS fetch
ADD --checksum=sha256:${SRC_HASH} ${SRC_SITE} .
FROM fetch AS build
COPY --from=stagex/busybox . /
COPY --from=stagex/musl . /
COPY --from=stagex/zlib . /
COPY --from=stagex/openssl . /
COPY --from=stagex/python . /
COPY --from=stagex/gcc . /
COPY --from=stagex/binutils . /
COPY --from=stagex/make . /
COPY --from=stagex/cmake . /
COPY --from=stagex/libffi . /
COPY --from=stagex/py-setuptools . /
COPY --from=stagex/py-installer . /
COPY --from=stagex/py-flit . /
COPY --from=stagex/py-gpep517 . /
COPY --from=stagex/py-wheel . /
COPY --from=stagex/py-distro . /
COPY --from=stagex/py-dateutil . /
COPY --from=stagex/py-urllib3 . /
COPY --from=stagex/py-cffi . /
COPY --from=stagex/file . /
RUN tar -xzf ${SRC_FILE}
WORKDIR python-magic-${VERSION}
RUN gpep517 build-wheel --wheel-dir .dist --output-fd 3 3>&1 >&2
#
FROM build AS install
RUN --network=none <<-EOF
set -eu
python -m installer -d /rootfs .dist/*.whl
find /rootfs | grep -E "(/__pycache__$|\.pyc$|\.pyo$)" | xargs rm -rf
EOF
FROM stagex/filesystem AS package
COPY --from=install /rootfs/. /

View file

@ -16,6 +16,7 @@ COPY --from=stagex/musl . /
COPY --from=stagex/openssl . /
COPY --from=stagex/zlib . /
COPY --from=stagex/bzip2 . /
COPY --from=stagex/ncurses . /
COPY --from=stagex/sqlite3 . /
COPY --from=stagex/libffi . /
RUN tar -xf ${SRC_FILE}

View file

@ -465,6 +465,35 @@ out/cython/index.json: \
out/zlib/index.json
$(call build,cython)
.PHONY: diffoscope
diffoscope: out/diffoscope/index.json
out/diffoscope/index.json: \
packages/diffoscope/Containerfile \
out/binutils/index.json \
out/busybox/index.json \
out/cmake/index.json \
out/file/index.json \
out/filesystem/index.json \
out/gcc/index.json \
out/libffi/index.json \
out/make/index.json \
out/musl/index.json \
out/openssl/index.json \
out/py-cffi/index.json \
out/py-dateutil/index.json \
out/py-distro/index.json \
out/py-flit/index.json \
out/py-gpep517/index.json \
out/py-installer/index.json \
out/py-libarchive/index.json \
out/py-magic/index.json \
out/py-setuptools/index.json \
out/py-urllib3/index.json \
out/py-wheel/index.json \
out/python/index.json \
out/zlib/index.json
$(call build,diffoscope)
.PHONY: diffutils
diffutils: out/diffutils/index.json
out/diffutils/index.json: \
@ -2861,6 +2890,60 @@ out/py-jmespath/index.json: \
out/zlib/index.json
$(call build,py-jmespath)
.PHONY: py-libarchive
py-libarchive: out/py-libarchive/index.json
out/py-libarchive/index.json: \
packages/py-libarchive/Containerfile \
out/binutils/index.json \
out/busybox/index.json \
out/cmake/index.json \
out/filesystem/index.json \
out/gcc/index.json \
out/libarchive/index.json \
out/libffi/index.json \
out/make/index.json \
out/musl/index.json \
out/openssl/index.json \
out/py-cffi/index.json \
out/py-dateutil/index.json \
out/py-distro/index.json \
out/py-flit/index.json \
out/py-gpep517/index.json \
out/py-installer/index.json \
out/py-setuptools/index.json \
out/py-urllib3/index.json \
out/py-wheel/index.json \
out/python/index.json \
out/zlib/index.json
$(call build,py-libarchive)
.PHONY: py-magic
py-magic: out/py-magic/index.json
out/py-magic/index.json: \
packages/py-magic/Containerfile \
out/binutils/index.json \
out/busybox/index.json \
out/cmake/index.json \
out/file/index.json \
out/filesystem/index.json \
out/gcc/index.json \
out/libffi/index.json \
out/make/index.json \
out/musl/index.json \
out/openssl/index.json \
out/py-cffi/index.json \
out/py-dateutil/index.json \
out/py-distro/index.json \
out/py-flit/index.json \
out/py-gpep517/index.json \
out/py-installer/index.json \
out/py-setuptools/index.json \
out/py-urllib3/index.json \
out/py-wheel/index.json \
out/python/index.json \
out/zlib/index.json
$(call build,py-magic)
.PHONY: py-markupsafe
py-markupsafe: out/py-markupsafe/index.json
out/py-markupsafe/index.json: \