Skip to content

Commit

Permalink
fixing wheel build
Browse files Browse the repository at this point in the history
  • Loading branch information
angeloprobst committed Oct 24, 2024
1 parent d0a7150 commit a477740
Show file tree
Hide file tree
Showing 7 changed files with 14 additions and 8 deletions.
6 changes: 4 additions & 2 deletions hyperon_das_atomdb_cpp/scripts/_build_glibc_wheel.sh
Original file line number Diff line number Diff line change
@@ -1,13 +1,15 @@
#!/bin/bash

source $(dirname $0)/common.sh

# This script is used to build a wheel for the current package.

TMP_DEST_DIR="tmp_dist"
DEST_DIR="dist"

# Remove existing/old wheel files
rm -rf ${TMP_DEST_DIR}
rm -f ${DEST_DIR}/*manylinux*.whl
rm -f ${DEST_DIR}/${GLIBC_WHEEL_NAME_PATTERN}

# Create dirs
mkdir -p ${TMP_DEST_DIR} ${DEST_DIR}
Expand All @@ -18,7 +20,7 @@ ${PYTHON_EXECUTABLE} -m pip wheel . --wheel-dir ${TMP_DEST_DIR}
[ $? -ne 0 ] && exit 1

# Repair wheel - tag as manylinux
find ${TMP_DEST_DIR} -type f -name "*.whl" \
find ${TMP_DEST_DIR} -type f -name "*abi3-linux_x86_64.whl" \
-exec ${PYTHON_EXECUTABLE} -m auditwheel repair {} -w ${DEST_DIR} \;
[ $? -ne 0 ] && exit 1

Expand Down
6 changes: 4 additions & 2 deletions hyperon_das_atomdb_cpp/scripts/_build_musl_wheel.sh
Original file line number Diff line number Diff line change
@@ -1,13 +1,15 @@
#!/bin/bash

source $(dirname $0)/common.sh

# This script is used to build a wheel for the current package.

TMP_DEST_DIR="tmp_dist"
DEST_DIR="dist"

# Remove existing/old wheel files
rm -rf ${TMP_DEST_DIR}
rm -f ${DEST_DIR}/*musllinux*.whl
rm -f ${DEST_DIR}/${MUSL_WHEEL_NAME_PATTERN}

# Create dirs
mkdir -p ${TMP_DEST_DIR} ${DEST_DIR}
Expand All @@ -18,7 +20,7 @@ ${PYTHON_EXECUTABLE} -m pip wheel . --wheel-dir ${TMP_DEST_DIR}
[ $? -ne 0 ] && exit 1

# Repair wheel - tag as manylinux
find ${TMP_DEST_DIR} -type f -name "*.whl" \
find ${TMP_DEST_DIR} -type f -name "*abi3-linux_x86_64.whl" \
-exec ${PYTHON_EXECUTABLE} -m auditwheel repair {} -w ${DEST_DIR} \;
[ $? -ne 0 ] && exit 1

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/bash

source ${PWD}/scripts/common.sh
source $(dirname $0)/common.sh

docker buildx build -t ${WHEELER_GLIBC_CONTAINER_NAME} \
--load -f ${WHEELER_GLIBC_DOCKER_FILE} .
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/bash

source ${PWD}/scripts/common.sh
source $(dirname $0)/common.sh

docker buildx build -t ${WHEELER_MUSL_CONTAINER_NAME} \
--load -f ${WHEELER_MUSL_DOCKER_FILE} .
Expand Down
2 changes: 2 additions & 0 deletions hyperon_das_atomdb_cpp/scripts/common.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
# AlmaLinux variables
WHEELER_GLIBC_CONTAINER_NAME="das-atomdb-cpp-glibc-wheeler"
WHEELER_GLIBC_DOCKER_FILE="docker/Dockerfile.glibc.wheeler"
GLIBC_WHEEL_NAME_PATTERN="*manylinux_2_28_x86_64*.whl"

# Alpine variables
WHEELER_MUSL_CONTAINER_NAME="das-atomdb-cpp-musl-wheeler"
WHEELER_MUSL_DOCKER_FILE="docker/Dockerfile.musl.wheeler"
MUSL_WHEEL_NAME_PATTERN="*musllinux_1_2_x86_64*.whl"
2 changes: 1 addition & 1 deletion hyperon_das_atomdb_cpp/scripts/run_glibc_wheeler.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/bash

source ${PWD}/scripts/common.sh
source $(dirname $0)/common.sh

# Build the wheel for GLIBC
docker run --rm \
Expand Down
2 changes: 1 addition & 1 deletion hyperon_das_atomdb_cpp/scripts/run_musl_wheeler.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/bash

source ${PWD}/scripts/common.sh
source $(dirname $0)/common.sh

# Build the wheel for MUSL
docker run --rm \
Expand Down

0 comments on commit a477740

Please sign in to comment.