Failure to build with Python 3.9.0 on macOS
See original GitHub issueWhile rebuilding packages with Python 3.9.0 on macOS Homebrew (https://github.com/Homebrew/homebrew-core/pull/62560), we are seeing a failure to build scipy 1.5.2.
Reproducing code example:
/usr/local/opt/python@3.9/bin/python3 setup.py build --fcompiler=gnu95
Error message:
scipy/sparse/linalg/dsolve/SuperLU/SRC/clacon2.c:175:5: error: implicit declaration of function 'ccopy_' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
scipy/sparse/linalg/dsolve/SuperLU/SRC/dmach.c:62:9: error: implicitly declaring library function 'strncmp' with type 'int (const char *, const char *, unsigned long)' [-Werror,-Wimplicit-function-declaration]
scipy/sparse/linalg/dsolve/SuperLU/SRC/ilu_cdrop_row.c:196:3: error: implicit declaration of function 'scopy_' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
scipy/sparse/linalg/dsolve/SuperLU/SRC/ilu_zdrop_row.c:196:3: error: implicit declaration of function 'dcopy_' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
scipy/sparse/linalg/dsolve/SuperLU/SRC/smach.c:62:9: error: implicitly declaring library function 'strncmp' with type 'int (const char *, const char *, unsigned long)' [-Werror,-Wimplicit-function-declaration]
scipy/sparse/linalg/dsolve/SuperLU/SRC/zlacon2.c:175:5: error: implicit declaration of function 'zcopy_' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
scipy/sparse/linalg/dsolve/SuperLU/SRC/slacon2.c:160:16: error: implicit declaration of function 'idamax_' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
Issue Analytics
- State:
 - Created 3 years ago
 - Reactions:3
 - Comments:17 (11 by maintainers)
 
Top Results From Across the Web
python@3.9 fails to build from source on macOS Big Sur #9329
If you change MACOSX_DEPLOYMENT_TARGET in the formula (line 124) manually to 11.0, it builds fine with no issues. If it's set to just...
Read more >Failure to build with MACOSX_DEPLOYMENT_TARGET=11 ...
Therefore, MACOSX_DEPLOYMENT_TARGET=11 has become a valid setting. It is accepted by system tools: $ MACOSX_DEPLOYMENT_TARGET=11 clang a.c && ...
Read more >PyEnv BUILD FAILED installing Python on MacOS
While trying to install Python 3.6.6 (for Airflow ) using PyEnv on MacOS , I am encountering build failure with following stack-trace
Read more >Not Able to Build Some Versions of Python on M1 at 12.3.1
I trying to build older version of python such as 3.6, 3.7, 3.8 using pyenv and having build failures. I am on apple...
Read more >m1 pyenv build failed | The Search Engine You Control
Mac M1 pyenv installing Python reported an error "BUILD FAILED (OS X 12.3.1 ... python-build: use readline from homebrew Downloading Python-3.9.0.tar.xz.
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

This worked for me:
However it’s better to have a proper solution such as an inclusion of proper headers without this requirement of this hack