Skip to content

Remove unused *_ROOT globals from setup.py#9767

Open
hugovk wants to merge 1 commit into
python-pillow:mainfrom
hugovk:simplify-build_extensions
Open

Remove unused *_ROOT globals from setup.py#9767
hugovk wants to merge 1 commit into
python-pillow:mainfrom
hugovk:simplify-build_extensions

Conversation

@hugovk

@hugovk hugovk commented Jul 4, 2026

Copy link
Copy Markdown
Member

And simplify library root detection in build_extensions().

@hugovk hugovk added Cleanup Packaging Any mention of setup.py; some overlap with Install label labels Jul 4, 2026
@radarhere

Copy link
Copy Markdown
Member

In PIL, theses looked like

# --------------------------------------------------------------------
# Library pointers.
#
# Use None to look for the libraries in well-known library locations.
# Use a string to specify a single directory, for both the library and
# the include files.  Use a tuple to specify separate directories:
# (libpath, includepath).  Examples:
#
# JPEG_ROOT = "/home/libraries/jpeg-6b"
# TIFF_ROOT = "/opt/tiff/lib", "/opt/tiff/include"
#
# If you have "lib" and "include" directories under a common parent,
# you can use the "libinclude" helper:
#
# TIFF_ROOT = libinclude("/opt/tiff")

TCL_ROOT = None
JPEG_ROOT = None
ZLIB_ROOT = None
TIFF_ROOT = None
FREETYPE_ROOT = None
LCMS_ROOT = None

I think the expectation was for people building from source to patch these. https://github.com/conda-forge/pillow-feedstock/blob/main/recipe/patches/0003-add-XCB_ROOT.patch sort of does this.

You are asserting though that we have better mechanisms now, like ddb01ac, yes?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Cleanup Packaging Any mention of setup.py; some overlap with Install label

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants