Bug 272189 - databases/py-mysqlclient fails to build after update to 2.2.0
Summary: databases/py-mysqlclient fails to build after update to 2.2.0
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Dima Panov
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-06-24 16:42 UTC by lysfjord.daniel
Modified: 2023-08-22 09:51 UTC (History)
4 users (show)

See Also:
bugzilla: maintainer-feedback? (fluffy)


Attachments
Poudriere build log (19.25 KB, text/plain)
2023-06-24 16:42 UTC, lysfjord.daniel
no flags Details
Add libmariadb to pkg-config search (401 bytes, patch)
2023-06-29 16:18 UTC, lysfjord.daniel
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description lysfjord.daniel 2023-06-24 16:42:02 UTC
Created attachment 242972 [details]
Poudriere build log

After update to version 2.2.0, py39-mysqlclient fails to build with the following error:

=======================<phase: build          >============================
===== env: NO_DEPENDS=yes USER=root UID=0 GID=0
===>  Building for py39-mysqlclient-2.2.0
* Getting build dependencies for wheel...
Trying pkg-config --exists mysqlclient
Command 'pkg-config --exists mysqlclient' returned non-zero exit status 1.
Trying pkg-config --exists mariadb
Command 'pkg-config --exists mariadb' returned non-zero exit status 1.
Traceback (most recent call last):
  File "/usr/local/lib/python3.9/site-packages/pyproject_hooks/_in_process/_in_process.py", line 353, in <module>
    main()
  File "/usr/local/lib/python3.9/site-packages/pyproject_hooks/_in_process/_in_process.py", line 335, in main
    json_out['return_val'] = hook(**hook_input['kwargs'])
  File "/usr/local/lib/python3.9/site-packages/pyproject_hooks/_in_process/_in_process.py", line 118, in get_requires_for_build_wheel
    return hook(config_settings)
  File "/usr/local/lib/python3.9/site-packages/setuptools/build_meta.py", line 177, in get_requires_for_build_wheel
    return self._get_build_requires(
  File "/usr/local/lib/python3.9/site-packages/setuptools/build_meta.py", line 159, in _get_build_requires
    self.run_setup()
  File "/usr/local/lib/python3.9/site-packages/setuptools/build_meta.py", line 174, in run_setup
    exec(compile(code, __file__, 'exec'), locals())
  File "setup.py", line 154, in <module>
    ext_options = get_config_posix(get_options())
  File "setup.py", line 48, in get_config_posix
    pkg_name = find_package_name()
  File "setup.py", line 27, in find_package_name
    raise Exception(
Exception: Can not find valid pkg-config name.
Specify MYSQLCLIENT_CFLAGS and MYSQLCLIENT_LDFLAGS env vars manually

ERROR Backend subprocess exited when trying to invoke get_requires_for_build_wheel
*** Error code 1
Comment 1 Ivan Rozhuk 2023-06-24 17:46:47 UTC
Same without Poudriere, mariadb used.
Comment 2 lysfjord.daniel 2023-06-28 22:05:17 UTC
Probably caused by the following commit: https://github.com/PyMySQL/mysqlclient/pull/586/commits/783370091f48911b5137231bbfea1b02005e1a22

For some reason, mariadb/mysqlclient doesn't show in the list in pkg-config.
Comment 3 lysfjord.daniel 2023-06-28 22:09:54 UTC
It does however find libmariadb
Comment 4 Eero Hänninen 2023-06-29 10:21:15 UTC
It has been fixed in upstream https://github.com/PyMySQL/mysqlclient/pull/631
Comment 5 lysfjord.daniel 2023-06-29 16:18:27 UTC
Created attachment 243076 [details]
Add libmariadb to pkg-config search
Comment 6 linus.sundqvist 2023-07-04 06:45:37 UTC
Getting the same error when trying to build 2023Q3 now. Is the upstream fix arriving soon, or is the current quarterly gonna be broken for a while?