Skip to content

Commit 590b682

Browse files
committed
switching to auditool for linux
1 parent 667aabc commit 590b682

File tree

1 file changed

+19
-38
lines changed

1 file changed

+19
-38
lines changed

quaddtype/pyproject.toml

Lines changed: 19 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ build-backend = "mesonpy"
1212
name = "quaddtype"
1313
description = "Quad (128-bit) float dtype for numpy"
1414
version = "0.0.1"
15-
readme = "README.md"
15+
readme = 'README.md'
1616
authors = [{name = "Swayam Singh", email = "[email protected]"}]
1717
requires-python = ">=3.10.0"
1818
dependencies = [
@@ -26,55 +26,36 @@ test = [
2626

2727
[tool.cibuildwheel]
2828
archs = ["auto64"]
29-
skip = ["*-musllinux*", "pp*", "cp36-*", "cp37-*", "cp38-*", "cp39-*"]
30-
manylinux-x86_64-image = "manylinux2014"
29+
skip = ["*-musllinux*", "pp*", "cp36-*", "cp37-*", "cp38-*"]
3130
test-command = "pytest {project}/tests"
3231
test-extras = ["test"]
3332

3433
[tool.cibuildwheel.linux]
3534
before-all = """
36-
set -ex
37-
# Function to download with curl and fallback to Python if curl fails
38-
download_file() {
39-
if ! curl -L -o "$2" "$1"; then
40-
python -c "import urllib.request; urllib.request.urlretrieve('$1', '$2')"
41-
fi
42-
}
43-
44-
# Download and install a standalone GCC
45-
GCC_URL="https://github.com/Aetherinox/gcc-arm64/releases/download/12.3.1-2023.10/aarch64-linux-gnu-12.3.1-2023.10-x86_64-linux.tar.xz"
46-
download_file "$GCC_URL" "gcc.tar.xz"
47-
tar xf gcc.tar.xz -C /opt || echo "Failed to extract GCC"
48-
49-
# Install Miniconda and sleef
50-
MINICONDA_URL="https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh"
51-
download_file "$MINICONDA_URL" "miniconda.sh"
52-
bash miniconda.sh -b -p $HOME/miniconda || echo "Failed to install Miniconda"
53-
$HOME/miniconda/bin/conda install -y -c conda-forge sleef || echo "Failed to install sleef"
54-
55-
# Verify sleef installation
56-
ls -l $HOME/miniconda/include/sleef.h || echo "sleef.h not found"
57-
58-
# Print environment information for debugging
59-
echo "GCC version:"
60-
/opt/aarch64-linux-gnu/bin/gcc --version || echo "GCC not found"
61-
echo "Python version:"
62-
python --version
63-
echo "Conda version:"
64-
$HOME/miniconda/bin/conda --version
35+
yum install -y wget &&
36+
wget https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh -O miniconda.sh &&
37+
bash miniconda.sh -b -p $HOME/miniconda &&
38+
$HOME/miniconda/bin/conda install -y -c conda-forge sleef
39+
ls -l $HOME/miniconda/include/sleef.h
6540
"""
66-
environment = { LD_LIBRARY_PATH = "/opt/aarch64-linux-gnu/lib:$HOME/miniconda/lib:$LD_LIBRARY_PATH", LIBRARY_PATH = "$HOME/miniconda/lib:$LIBRARY_PATH", CFLAGS = "-I$HOME/miniconda/include -fPIC $CFLAGS", CXXFLAGS = "-I$HOME/miniconda/include -fPIC $CXXFLAGS", LDFLAGS = "-L$HOME/miniconda/lib $LDFLAGS", AUDITWHEEL_PLAT = "manylinux2014_x86_64", CC = "/opt/aarch64-linux-gnu/bin/gcc", CXX = "/opt/aarch64-linux-gnu/bin/g++" }
41+
environment = { LD_LIBRARY_PATH = "$HOME/miniconda/lib:$LD_LIBRARY_PATH", LIBRARY_PATH = "$HOME/miniconda/lib:$LIBRARY_PATH", CFLAGS = "-I$HOME/miniconda/include $CFLAGS", CXXFLAGS = "-I$HOME/miniconda/include $CXXFLAGS", LDFLAGS = "-L$HOME/miniconda/lib $LDFLAGS" }
6742
repair-wheel-command = "auditwheel repair -w {dest_dir} {wheel}"
6843

6944
[tool.cibuildwheel.macos]
7045
before-all = """
71-
curl -L https://repo.anaconda.com/miniconda/Miniconda3-latest-MacOSX-x86_64.sh -o miniconda.sh
72-
bash miniconda.sh -b -p $HOME/miniconda
46+
wget https://repo.anaconda.com/miniconda/Miniconda3-latest-MacOSX-x86_64.sh -O miniconda.sh &&
47+
bash miniconda.sh -b -p $HOME/miniconda &&
7348
$HOME/miniconda/bin/conda install -y -c conda-forge sleef
74-
ls -l $HOME/miniconda/include/sleef.h || echo "sleef.h not found"
49+
ls -l $HOME/miniconda/include/sleef.h
7550
"""
76-
environment = { DYLD_LIBRARY_PATH = "$HOME/miniconda/lib:$DYLD_LIBRARY_PATH", LIBRARY_PATH = "$HOME/miniconda/lib:$LIBRARY_PATH", CFLAGS = "-I$HOME/miniconda/include $CFLAGS", CXXFLAGS = "-I$HOME/miniconda/include $CXXFLAGS", LDFLAGS = "-L$HOME/miniconda/lib $LDFLAGS" }
51+
environment = {DYLD_LIBRARY_PATH = "$HOME/miniconda/lib:$DYLD_LIBRARY_PATH", LIBRARY_PATH = "$HOME/miniconda/lib:$LIBRARY_PATH", CFLAGS = "-I$HOME/miniconda/include $CFLAGS", CXXFLAGS = "-I$HOME/miniconda/include $CXXFLAGS", LDFLAGS = "-L$HOME/miniconda/lib $LDFLAGS"}
7752

7853
[tool.cibuildwheel.windows]
54+
before-all = """
55+
powershell -Command "Invoke-WebRequest -Uri https://repo.anaconda.com/miniconda/Miniconda3-latest-Windows-x86_64.exe -OutFile miniconda.exe" &&
56+
start /wait "" miniconda.exe /S /D=%UserProfile%\\Miniconda3 &&
57+
%UserProfile%\\Miniconda3\\Scripts\\conda install -y -c conda-forge sleef
58+
"""
7959
before-build = "pip install delvewheel"
80-
repair-wheel-command = "delvewheel repair -w {dest_dir} {wheel}"
60+
repair-wheel-command = "delvewheel repair -w {dest_dir} {wheel} --verbose || echo 'Repair failed, continuing anyway'"
61+
environment = { LIBRARY_PATH = "%UserProfile%\\Miniconda3\\Library\\lib;%LIBRARY_PATH%", INCLUDE = "%UserProfile%\\Miniconda3\\Library\\include;%INCLUDE%", LIB = "%UserProfile%\\Miniconda3\\Library\\lib;%LIB%" }

0 commit comments

Comments
 (0)