-
Notifications
You must be signed in to change notification settings - Fork 158
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added initial functionality to build wheels
Signed-off-by: Alejandro Saucedo <[email protected]>
- Loading branch information
Showing
2 changed files
with
48 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
#!/bin/bash | ||
set -e -u -x | ||
|
||
function repair_wheel { | ||
wheel="$1" | ||
if ! auditwheel show "$wheel"; then | ||
echo "Skipping non-platform wheel $wheel" | ||
else | ||
auditwheel repair "$wheel" --plat "$PLAT" -w /io/dist/ | ||
fi | ||
} | ||
|
||
# System package required for library | ||
yum install -y vulkan | ||
yum install -y vulkan-devel | ||
|
||
# Create folder | ||
mkdir -p /io/dist_tmp/ | ||
mkdir -p /io/dist/ | ||
|
||
|
||
# Compile wheels | ||
for PYBIN in /opt/python/*/bin; do | ||
"${PYBIN}/pip" wheel --verbose /io/ --no-deps -w /io/dist_tmp/ | ||
done | ||
|
||
# Bundle external shared libraries into the wheels | ||
for whl in /io/dist_tmp/*.whl; do | ||
repair_wheel "$whl" && echo "Continuing" | ||
done | ||
|
||
# Install packages and test | ||
for PYBIN in /opt/python/*/bin/; do | ||
"${PYBIN}/pip" install -r /io/python/test/requirements-dev.txt | ||
"${PYBIN}/pip" install kp -f /io/dist | ||
make -C /io/ test_python PYTHON_BIN="${PYBIN}/python" | ||
done | ||
|