Skip to content

Commit db8697b

Browse files
committed
Start on trying to get an s390x git in the s390x cross container
Currently this fails with: Some packages could not be installed. This may mean that you have requested an impossible situation or if you are using the unstable distribution that some required packages have not yet been created or been moved out of Incoming. The following information may help to resolve the situation: The following packages have unmet dependencies: git:s390x : Depends: perl:s390x but it is not going to be installed Depends: liberror-perl:s390x but it is not installable Or, in some variations, the (same) error is expressed as: E: Package 'liberror-perl:s390x' has no installation candidate
1 parent c40ead9 commit db8697b

File tree

1 file changed

+14
-5
lines changed

1 file changed

+14
-5
lines changed

etc/docker/Dockerfile.test-cross

Lines changed: 14 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,17 +2,26 @@ ARG TARGET
22

33
FROM ghcr.io/cross-rs/${TARGET}:latest
44

5-
RUN apt-get update && \
5+
ARG TARGET
6+
7+
RUN set -uC && \
8+
apt_suffix= && \
9+
if target_arch="$(dpkg-architecture --host-type "$TARGET" --query DEB_HOST_ARCH)"; then \
10+
dpkg --add-architecture "$target_arch" && \
11+
apt_suffix=":$target_arch"; \
12+
fi && \
13+
apt-get update && \
614
apt-get install --no-install-recommends -y apt-transport-https gnupg && \
715
release="$(sed -n 's/^VERSION_CODENAME=//p' /etc/os-release)" && \
816
echo "deb https://ppa.launchpadcontent.net/git-core/ppa/ubuntu $release main" \
917
>/etc/apt/sources.list.d/git-core-ubuntu-ppa.list && \
1018
apt-key adv --keyserver keyserver.ubuntu.com \
1119
--recv-keys F911AB184317630C59970973E363C90F8F1B6217 && \
1220
apt-get update && \
13-
apt-get install --no-install-recommends -y git jq patch && \
21+
apt-get install --no-install-recommends -y "git$apt_suffix" jq patch && \
1422
rm -rf /var/lib/apt/lists/* && \
15-
to_patch=/android-runner && \
16-
patcher='s/^export LD_PRELOAD=/test "${NO_PRELOAD_CXX:-0}" != 0 || &/' && \
17-
if test -f "$to_patch"; then sed -i.orig "$patcher" -- "$to_patch"; fi && \
23+
if test -f /android-runner; then \
24+
sed -i.orig 's/^export LD_PRELOAD=/test "${NO_PRELOAD_CXX:-0}" != 0 || &/' \
25+
/android-runner; \
26+
fi && \
1827
git config --system gitoxide.imaginary.arbitraryVariable arbitraryValue

0 commit comments

Comments
 (0)