Skip to content

Commit 649ac2b

Browse files
committed
Only patch /android-runner if it exists
So the `cross` Dockerfile can continue to be used for both Android and non-Android targets.
1 parent f4210ee commit 649ac2b

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

etc/docker/Dockerfile.test-cross

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,5 +12,7 @@ RUN apt-get update && \
1212
apt-get update && \
1313
apt-get install --no-install-recommends -y git jq && \
1414
rm -rf /var/lib/apt/lists/* && \
15-
sed -i.orig 's/^export LD_PRELOAD=/test "${NO_PRELOAD_CXX:-0}" != 0 || &/' /android-runner && \
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 && \
1618
git config --system gitoxide.imaginary.arbitraryVariable arbitraryValue

0 commit comments

Comments
 (0)