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

Make [email protected] the main python #63346

Closed
wants to merge 3 commits into from

Conversation

fxcoudert
Copy link
Member

Here we go…

@BrewTestBot BrewTestBot added the automerge-skip `brew pr-automerge` will skip this pull request label Oct 23, 2020
@fxcoudert
Copy link
Member Author

Testing cannot proceed because:

[email protected]:
  * Versioned formulae in homebrew/core should use `keg_only :versioned_formula`

@fxcoudert
Copy link
Member Author

fxcoudert commented Oct 26, 2020

With this PR the output of python3-config --cflags --ldflags --embed (for [email protected]) on macOS 10.14 is:

-I/usr/local/Cellar/[email protected]/3.9.0_1/Frameworks/Python.framework/Versions/3.9/include/python3.9 -I/usr/local/Cellar/[email protected]/3.9.0_1/Frameworks/Python.framework/Versions/3.9/include/python3.9 -Wno-unused-result -Wsign-compare -Wunreachable-code -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk -I/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/Tk.framework/Versions/8.5/Headers -L/usr/local/opt/[email protected]/Frameworks/Python.framework/Versions/3.9/lib/python3.9/config-3.9-darwin -lpython3.9 -lintl -ldl -framework CoreFoundation

Without the PR, it is currently (also for [email protected]), on my local machine (macOS 10.15):

-I/usr/local/Cellar/[email protected]/3.9.0/Frameworks/Python.framework/Versions/3.9/include/python3.9 -I/usr/local/Cellar/[email protected]/3.9.0/Frameworks/Python.framework/Versions/3.9/include/python3.9 -Wno-unused-result -Wsign-compare -Wunreachable-code -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX10.15.sdk -I/Library/Developer/CommandLineTools/SDKs/MacOSX10.15.sdk/usr/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX10.15.sdk/System/Library/Frameworks/Tk.framework/Versions/8.5/Headers -L/usr/local/opt/[email protected]/Frameworks/Python.framework/Versions/3.9/lib/python3.9/config-3.9-darwin -lpython3.9 -ldl -framework CoreFoundation

I do not know where the extra -lintl flag comes from, but it is wrong. It triggers test failures for pybind11 and boost-python3. It may be a 10.14 vs. 10.15 issue, but I don't think that's likely (and we will know when the 10.15 testing is over).

@fxcoudert
Copy link
Member Author

fxcoudert commented Oct 26, 2020

Testing this locally on 10.15, I cannot reproduce the issue. During python 3.9.0 compilation, I get:

checking libintl.h usability... no
checking libintl.h presence... no
checking for libintl.h... no

and

checking for textdomain in -lintl... no

The resulting python installation does not have -lintl in the output of python3-config --cflags --ldflags --embed


As far as I can see, the presence of -lintl in LIBS (and therefore in python3-config) comes from the check for textdomain. If for some reason gettext was present on the CI nodes (perhaps from the testing of dependents of [email protected] before building [email protected]?) then it will be picked up (I can reproduce this locally when gettext is installed).

@fxcoudert
Copy link
Member Author

fxcoudert commented Oct 26, 2020

On 10.13, looking good:

brew test --retry --verbose freeling
brew install googletest
brew test --retry --verbose pcl
brew linkage --test urh

On 10.14, we have the same plus:

brew test --retry --verbose boost-python3
brew test --retry --verbose buku
brew test --retry --verbose glyr
brew test --retry --verbose pybind11
  • boost-python3 and pybind11 are related to libint/gettext, see my investigations above
  • glyr is a download error
  • buku has a [ERROR] No matching index or title immutable or empty DB, not sure why

On 10.15, we have in addition:

brew test --retry --verbose ngs
brew install --only-dependencies oclgrind
brew install oclgrind

where oclgrind is due to No space left on device (it couldn't install the llvm@9 bottle)

Copy link
Member

@MikeMcQuaid MikeMcQuaid left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Makes sense to me 👍🏻

@fxcoudert
Copy link
Member Author

fxcoudert commented Oct 26, 2020

There is not switch in Python's configure to allow it to disable libintl if found.
We could configure with ac_cv_lib_intl_textdomain=no, or split this into two pull requests (but that might introduce some audits failures, and the question of the switching of the symlinks is not clear).

Edit: I've chosen the ac_cv_lib_intl_textdomain=no approach. 2nd try…

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
automerge-skip `brew pr-automerge` will skip this pull request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants