Skip to content

Commit 7a085c9

Browse files
committed
reduce size of arch specific OCI packages
1 parent 41feac6 commit 7a085c9

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

.gitlab/prepare-oci-package.sh

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,16 @@ BUILD_DIR=sources
2525

2626
echo -n "$PYTHON_PACKAGE_VERSION" > sources/version
2727

28+
echo "Cleaning up binaries for ${ARCH}"
29+
if [ "${ARCH}" == "arm64" ]; then
30+
echo "Removing x86_64 binaries"
31+
find ../pywheels-dep/ -type f -name '*x86_64*' -exec rm -f {} \;
32+
elif [ "${ARCH}" == "amd64" ]; then
33+
echo "Removing aarch64 binaries"
34+
find ../pywheels-dep/ -type f -name '*aarch64*' -exec rm -f {} \;
35+
else
36+
echo "No ARCH set, not removing any binaries"
37+
fi
2838
cp -r ../pywheels-dep/site-packages* sources/ddtrace_pkgs
2939

3040
cp ../lib-injection/sources/* sources/

0 commit comments

Comments
 (0)