File tree 3 files changed +11
-9
lines changed
3 files changed +11
-9
lines changed Original file line number Diff line number Diff line change 55
55
- name : Build macOS
56
56
if : runner.os == 'macOS'
57
57
run : ./build.libgit2.sh
58
- - name : Setup QEMU
59
- if : matrix.name == 'linux-musl-arm' || matrix.name == 'linux-musl-arm64'
60
- run : docker run --rm --privileged multiarch/qemu-user-static:register --reset
61
58
- name : Build Linux
62
59
if : runner.os == 'Linux'
63
60
run : ./dockerbuild.sh
Original file line number Diff line number Diff line change 1
- ARG ARCH='amd64'
2
- FROM multiarch/alpine:${ARCH}-v3.13
3
- RUN apk add --no-cache bash build-base cmake
1
+ FROM --platform=$BUILDPLATFORM tonistiigi/xx AS xx
2
+
3
+ FROM --platform=$BUILDPLATFORM alpine
4
+
5
+ RUN apk add cmake clang lld
4
6
5
7
WORKDIR /nativebinaries
6
8
COPY . /nativebinaries/
7
9
10
+ ARG TARGETPLATFORM
11
+ RUN xx-apk musl-dev gcc
12
+
8
13
CMD ["/bin/bash", "-c", "./build.libgit2.sh"]
Original file line number Diff line number Diff line change @@ -6,9 +6,9 @@ echo "building for $RID"
6
6
if [[ $RID =~ arm64 ]]; then
7
7
arch=" arm64"
8
8
elif [[ $RID =~ arm ]]; then
9
- arch=" armhf "
9
+ arch=" arm/v7 "
10
10
elif [[ $RID =~ ppc64le ]]; then
11
- arch=" powerpc64le "
11
+ arch=" ppc64le "
12
12
else
13
13
arch=" amd64"
14
14
fi
19
19
dockerfile=" Dockerfile.linux"
20
20
fi
21
21
22
- docker buildx build -t $RID -f $dockerfile --build-arg ARCH= $arch .
22
+ docker buildx build -t $RID -f $dockerfile --platform=linux/ $arch .
23
23
24
24
docker run -t -e RID=$RID --name=$RID $RID
25
25
You can’t perform that action at this time.
0 commit comments