google / google/or-tools

Distributing or-tools with a cpython whl

Open
#5,287 4 comments 0 reactions 1 assignee Claimed by @Mizux View on GitHub
Bug Build: CMake Lang: Python
Dominant language
C++
Stars
14.1k
Forks
2.5k
Avg merge
8h 39m
Merged PRs (30d)
72

Description

**What language and solver does this apply to?**
All, Python, C++

**Describe the problem you are trying to solve.**
Distributing PyPi whl files for https://github.com/NatLabRockies/pysam/ based on https://github.com/NatLabRockies/ssc with ortools dependencies for Windows x86_64, macOS arm64 and x86_64 and Linux aarch64 and x86_64.

Currently, the Windows whl files have all dll depenendencies without issue.

The macOS and Linux whl files require many libraries with non-standard name. e.g. libortools.so.9.14.6206

The build process uses pyproject.toml (https://github.com/NatLabRockies/pysam/blob/nlr_pysam-8.0.0/pyproject.toml) and setup.py (https://github.com/NatLabRockies/pysam/blob/nlr_pysam-8.0.0/setup.py) for cpython extensions. Also, necessary libraries are copied over in prepare_build.py (https://github.com/NatLabRockies/pysam/blob/nlr_pysam-8.0.0/prepare_build.py)

The entire manylinux build process is contained in https://github.com/NatLabRockies/pysam/blob/nlr_pysam-8.0.0/build_manylinux.sh

The issue is that auditwheel repair fails for several of the non-standard libraries, e.g.

Image

**Describe the solution you'd like**

Would like a small subset of lib files (.so and .dylib) to allow for whl file distributing with all dependencies covered.

**Describe alternatives you've considered**

Including all lib files from binary distributions of or-tools in whl file and repairing links (rpath) with auditwheel repair

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.