Skip to content

gh-115119: Detect _decimal dependencies using pkg-config - #115406

Merged
erlend-aasland merged 8 commits into
python:mainfrom
erlend-aasland:ac/libmpdec
Apr 29, 2024
Merged

erlend-aasland merged 8 commits into
python:mainfrom
erlend-aasland:ac/libmpdec

Conversation

@erlend-aasland

@erlend-aasland erlend-aasland commented Feb 13, 2024 •

Copy link
Copy Markdown
Contributor

Only libmpdec 4.0.0 supports pkg-config.

Only libmpdec 4.0.0 supports pkg-config.
@bedevere-app bedevere-app Bot mentioned this pull request Feb 13, 2024
15 tasks done
@erlend-aasland

erlend-aasland commented Feb 13, 2024 •

Copy link
Copy Markdown
Contributor Author

Tested on macOS with the following scenarios:

$ ./configure && make                         # Uses CPython vendored mpdecimal
$ ./configure --with-system-libmpdec && make  # pkg-config detects Homebrew installed libmpdec 4.0.0
$ LIBMPDEC_CFLAGS="-I$HOME/install" \
  LIBMPDEC_LIBS="-L$HOME/install -lm -lmpdec" \
  ./configure --with-system-libmpdec && make  # Build with custom libmpdec 2.5.1

For some reason the latter fails, but I suspect it is an issue with my setup.

@erlend-aasland

Copy link
Copy Markdown
Contributor Author
@erlend-aasland
erlend-aasland marked this pull request as ready for review March 30, 2024 18:48
@erlend-aasland
erlend-aasland requested a review from zware March 30, 2024 18:48
Comment thread Modules/_decimal/_decimal.c Resolved
Comment thread Modules/_decimal/_decimal.c Resolved
@rhettinger
rhettinger removed their request for review March 30, 2024 19:21

@ned-deily ned-deily left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

LGTM, thanks! FWIW, I was able to successfully build and test with mpdecimal 2.5.1 as well as 4.0.0.

@erlend-aasland

Copy link
Copy Markdown
Contributor Author

Thanks, Ned! I had forgotten about this :)

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

Labels

None yet

2 participants