feat: package sdtool

This commit is contained in:
Lance R. Vick 2024-08-18 16:36:31 -07:00
parent 42d06a89e8
commit a9270885f5
No known key found for this signature in database
GPG key ID: 8E47A1EC35A1551D
2 changed files with 38 additions and 0 deletions

View file

@ -0,0 +1,25 @@
FROM scratch AS base
ENV VERSION=ad4155c1d2988a17f4d5b13feaa6e4c1beb2cf4b
ENV SRC_HASH=82d289e47a6a379bc17df7fc9e5c665ef59edc4dd8a32998f244a6a7f22c24f7
ENV SRC_FILE=${VERSION}.tar.gz
ENV SRC_SITE=https://github.com/BertoldVdb/sdtool/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/gcc . /
COPY --from=stagex/binutils . /
COPY --from=stagex/linux-headers . /
COPY --from=stagex/make . /
COPY --from=stagex/musl . /
RUN tar -xf ${SRC_FILE}
WORKDIR sdtool-${VERSION}
RUN --network=none make all
FROM build AS install
RUN --network=none install -D -m644 sdtool /rootfs/usr/bin/sdtool
FROM stagex/filesystem AS package
COPY --from=install /rootfs/. /

View file

@ -3544,6 +3544,19 @@ out/scdoc/index.json: \
out/musl/index.json
$(call build,scdoc)
.PHONY: sdtool
sdtool: out/sdtool/index.json
out/sdtool/index.json: \
packages/sdtool/Containerfile \
out/binutils/index.json \
out/busybox/index.json \
out/filesystem/index.json \
out/gcc/index.json \
out/linux-headers/index.json \
out/make/index.json \
out/musl/index.json
$(call build,sdtool)
.PHONY: sed
sed: out/sed/index.json
out/sed/index.json: \