Skip to content

Commit

Permalink
fix: install pkg-config dependency for mysqlclient>=2.2.0
Browse files Browse the repository at this point in the history
Repositiories that depend on mysqlclient>=2.2.0 will need to install the package pkg-config in their Dockerfile: PyMySQL/mysqlclient#620. This commit installs the pkg-config package in the Dockerfile.

If this is missing, then pip install of mysqlclient fails with an error that includes the following:

Exception: Can not find valid pkg-config name.
Specify MYSQLCLIENT_CFLAGS and MYSQLCLIENT_LDFLAGS env vars manually

See edx/edx-arch-experiments#349.
  • Loading branch information
MichaelRoytman committed Jul 6, 2023
1 parent 171fc3a commit 96b05f0
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@ MAINTAINER [email protected]
# libmysqlclient-dev; to install header files needed to use native C implementation for
# MySQL-python for performance gains.

# pkg-config; mysqlclient>=2.2.0 requires pkg-config (https://github.com/PyMySQL/mysqlclient/issues/620)

# libssl-dev; # mysqlclient wont install without this.

# python3-dev; to install header files for python extensions; much wheel-building depends on this
Expand All @@ -27,6 +29,7 @@ RUN apt-get update && apt-get -qy install --no-install-recommends \
python3.8 \
python3-pip \
libmysqlclient-dev \
pkg-config \
libssl-dev \
python3-dev \
build-essential \
Expand Down

0 comments on commit 96b05f0

Please sign in to comment.