Part of my project requires the MySQL-python package. I'm running Linux Mint 20, kernel 5.11 I've had just about everything working fine up to this point. Just setup my virtual environment and all the packages install via poetry except MySQL-python. It fails with:
fatal error: my_config.h: No such file or directory
       44 | #include "my_config.h"
          |          ^~~~~~~~~~~~~
    compilation terminated.
    error: command 'x86_64-linux-gnu-gcc' failed with exit status 1
    ----------------------------------------
ERROR: Command errored out with exit status 1: /home/matt/git/proj/test/python/.venv/bin/python -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-f_UUOG/mysql-python/setup.py'"'"'; __file__='"'"'/tmp/pip-install-f_UUOG/mysql-python/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record /tmp/pip-record-XzgEIa/install-record.txt --single-version-externally-managed --compile --install-headers /home/matt/git/proj/test/python/.venv/include/site/python2.7/mysql-python Check the logs for full command output.
I tried adding a my_config_h folder to both /usr/local/mysql and /home/linuxbrew/.linuxbrew/Cellar/mysql/8.0.26 (where it is automatically setup). Not sure how to get past this.
I have export PATH=${PATH}:/usr/local/mysql/bin my bash config.
I tried linking/unlinking mysql with brew.
Did lots of googling and solutions that worked for others do not work for me.
Thanks in advance.
EDIT: after solving a bunch of minor errors, the issue is now is this
/home/linuxbrew/.linuxbrew/bin/ld: cannot find -lzstd
These are packages I believe inside both usr/bin and the above directory.
Here is more of the error output:
    /home/linuxbrew/.linuxbrew/bin/ld: cannot find -lzstd
    collect2: error: ld returned 1 exit status
    error: command 'x86_64-linux-gnu-gcc' failed with exit status 1```

mysqlclientpip package is a drop-in replacement.pip install mysqlclient/home/linuxbrew/.linuxbrew/bin/ld: cannot find -lzstd collect2: error: ld returned 1 exit status error: command 'x86_64-linux-gnu-gcc' failed with exit status 1