Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

configure finds zlib but pillow does not #30103

Open
mkoeppe opened this issue Jul 10, 2020 · 17 comments
Open

configure finds zlib but pillow does not #30103

mkoeppe opened this issue Jul 10, 2020 · 17 comments

Comments

@mkoeppe
Copy link
Contributor

mkoeppe commented Jul 10, 2020

https://groups.google.com/d/msg/sage-support/vS2CZd_kEHA/f1VaXUQhAQAJ

In complete analogy to
#29448 (configure finds libpng but matplotlib does not)

See also:

Depends on #30185

CC: @dimpase @orlitzky @jhpalmieri

Component: build: configure

Issue created by migration from https://trac.sagemath.org/ticket/30103

@mkoeppe mkoeppe added this to the sage-9.2 milestone Jul 10, 2020
@dimpase
Copy link
Member

dimpase commented Jul 11, 2020

comment:2

I don't see how this is in analogy to #29448

With zlib we don't use pkg-config - so something really goes bad in pillow.

@orlitzky
Copy link
Contributor

comment:3

Pillow's build system is a half-baked reimplementation of autotools in python. It tries and fails to guess the system library location, whereas AC_CHECK_LIB actually compiles and links something, so it doesn't need to guess.

The first thing we should do is upgrade to the latest version of pillow so that we aren't completely wasting our time. Then the best solution would be for them to adopt a real build system reimplement AC_CHECK_LIB in their python script. Trying to fix the list of guessed locations isn't a good long term solution because it's guaranteed to find the wrong libraries if you check e.g. /usr/lib before /usr/lib64 on a multilib system. All you really want to know is if you can compile something with -lz, so autotools has the right idea.

@mkoeppe
Copy link
Contributor Author

mkoeppe commented Jul 11, 2020

comment:4

+1 on upgrading pillow first.

@mkoeppe
Copy link
Contributor Author

mkoeppe commented Jul 11, 2020

comment:5

Replying to @dimpase:

I don't see how this is in analogy to #29448

With zlib we don't use pkg-config - so something really goes bad in pillow.

Well, pillow uses pkg-config to find zlib, as you can see in the bug report:

[pillow-5.3.0.p0] Looking for `zlib` using pkg-config.
[pillow-5.3.0.p0] Looking for zlib

@mkoeppe
Copy link
Contributor Author

mkoeppe commented Jul 11, 2020

@mkoeppe

This comment has been minimized.

@mkoeppe
Copy link
Contributor Author

mkoeppe commented Jul 11, 2020

Commit: 8eb7aa9

@mkoeppe
Copy link
Contributor Author

mkoeppe commented Jul 11, 2020

New commits:

8eb7aa9build/pkgs/pillow: Update to 7.2.0

@mkoeppe
Copy link
Contributor Author

mkoeppe commented Jul 11, 2020

comment:8

7.2.0 still uses the same approach for finding its libraries.

Since it checks each library using pkgconfig first, Dima's approach of generating fake pkgconfig files (from the abandoned ticket #28906) could be a solution that would not require patching pillow.

@orlitzky
Copy link
Contributor

comment:9

I wonder why pillow's pkg-config isn't finding zlib in this case. I think the reporter is using Gentoo, and we install zlib.pc. In fact everyone should be installing zlib.pc since 2012 or so.

@dimpase
Copy link
Member

dimpase commented Jul 12, 2020

comment:10

probably his PKG_path - whatever it is called, ismiconfigured.

@mkoeppe

This comment has been minimized.

@mkoeppe
Copy link
Contributor Author

mkoeppe commented Jul 21, 2020

comment:11

Moved the pillow upgrade to #30185

@mkoeppe
Copy link
Contributor Author

mkoeppe commented Jul 21, 2020

Dependencies: #30185

@mkoeppe
Copy link
Contributor Author

mkoeppe commented Jul 21, 2020

Changed branch from u/mkoeppe/configure_finds_zlib_but_pillow_does_not to none

@mkoeppe
Copy link
Contributor Author

mkoeppe commented Jul 21, 2020

Changed commit from 8eb7aa9 to none

@mkoeppe mkoeppe modified the milestones: sage-9.2, sage-9.3 Oct 24, 2020
@mkoeppe
Copy link
Contributor Author

mkoeppe commented May 10, 2021

comment:15

Moving to 9.4, as 9.3 has been released.

@mkoeppe mkoeppe modified the milestones: sage-9.3, sage-9.4 May 10, 2021
@mkoeppe mkoeppe modified the milestones: sage-9.4, sage-9.5 Aug 22, 2021
@mkoeppe mkoeppe removed this from the sage-9.5 milestone Dec 18, 2021
@mkoeppe mkoeppe added this to the sage-9.6 milestone Dec 18, 2021
@mkoeppe mkoeppe modified the milestones: sage-9.6, sage-9.7 May 3, 2022
@mkoeppe mkoeppe modified the milestones: sage-9.7, sage-9.8 Sep 19, 2022
@mkoeppe mkoeppe removed this from the sage-9.8 milestone Jan 29, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants