Comments (18)
저도 같은 에러를 경험했는데, 저의 경우 아래 방법을 통해 설치에 성공했습니다.
brew install zstd
CFLAGS="-I$(brew --prefix)/include" LDFLAGS="-L$(brew --prefix)/lib" pip install mysqlclient==2.0.1
from seminar-2021.
정말 감사합니다 해결됐습니다!
from seminar-2021.
찾아보니 mysql이 usr/local/bin에 있어야 하는 것 같은데 저는 opt/homebrew/bin에 설치가 되어 있는데 이 부분을 고쳐야 할 것 같은데 방법을 잘 모르겠습니다
Homebrew 버전의 차이입니다. x86_64버전의 경우 /usr/local/bin에, ARM버전의 경우 /opt/homebrew/bin에 설치됩니다. 설치 경로는 본 문제와 큰 연관이 없습니다.
from seminar-2021.
pip
대신 pip3
을 사용해도 같은 오류가 출력되었습니다.
from seminar-2021.
sudo apt-get install libmysqlclient-dev
치시면 해결 될거에요. mysql_config이 다른 패키지에 있어 발생하는 이슈입니다
from seminar-2021.
혹시 맥에서는 어떻게 해결해야 하나요?
from seminar-2021.
@jaylions 똑같은 에러인가요/? https://elfinlas.github.io/2019/01/23/pip-mysql-error/ 이거 참고해보시겠어요??
from seminar-2021.
감사합니다 확인해보겠습니다!
from seminar-2021.
말씀해주신 대로 sudo apt-get install libmysqlclient-dev
를 실행한 후 다시 mysqlclient 설치를 시도했는데 이번에는 이런 에러가 나왔습니다.
그래서 여기에 나와 있는 대로 python-dev 파일을 설치해보았는데도 여전히 같은 에러가 나옵니다.
from seminar-2021.
sudo apt-get install gcc
를 입력해 gcc를 설치했더니 해결되었습니다.
도움 주셔서 감사합니다!!
from seminar-2021.
넵 ㅎㅎ 에러 로그를 보면서 잘 쫓아가 주셨네요 :)
from seminar-2021.
보내주신 링크에 있는대로 했는데도 해결이 안됩니다 ㅠㅠ
from seminar-2021.
from seminar-2021.
mysql의 설치 위치가 문제인 것 같은데 해결이 잘 되지 않습니다
from seminar-2021.
전체 에러 로그를 올려주실 수 있나요?
from seminar-2021.
ERROR: Command errored out with exit status 1:
command: /Users/gubukson/waffle-rookies-19.5-backend-0/assignment0/venv/bin/python -u -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/private/var/folders/yh/hgff3rm12310wgk60ntsb0hw0000gn/T/pip-install-z10zosmx/mysqlclient_246670fdb7744a52a8999b06e7350f4c/setup.py'"'"'; file='"'"'/private/var/folders/yh/hgff3rm12310wgk60ntsb0hw0000gn/T/pip-install-z10zosmx/mysqlclient_246670fdb7744a52a8999b06e7350f4c/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(file) if os.path.exists(file) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' bdist_wheel -d /private/var/folders/yh/hgff3rm12310wgk60ntsb0hw0000gn/T/pip-wheel-iz8xzdr2
cwd: /private/var/folders/yh/hgff3rm12310wgk60ntsb0hw0000gn/T/pip-install-z10zosmx/mysqlclient_246670fdb7744a52a8999b06e7350f4c/
Complete output (29 lines):
running bdist_wheel
running build
running build_py
creating build
creating build/lib.macosx-11-universal2-3.8
creating build/lib.macosx-11-universal2-3.8/MySQLdb
copying MySQLdb/init.py -> build/lib.macosx-11-universal2-3.8/MySQLdb
copying MySQLdb/exceptions.py -> build/lib.macosx-11-universal2-3.8/MySQLdb
copying MySQLdb/connections.py -> build/lib.macosx-11-universal2-3.8/MySQLdb
copying MySQLdb/converters.py -> build/lib.macosx-11-universal2-3.8/MySQLdb
copying MySQLdb/cursors.py -> build/lib.macosx-11-universal2-3.8/MySQLdb
copying MySQLdb/release.py -> build/lib.macosx-11-universal2-3.8/MySQLdb
copying MySQLdb/times.py -> build/lib.macosx-11-universal2-3.8/MySQLdb
creating build/lib.macosx-11-universal2-3.8/MySQLdb/constants
copying MySQLdb/constants/init.py -> build/lib.macosx-11-universal2-3.8/MySQLdb/constants
copying MySQLdb/constants/CLIENT.py -> build/lib.macosx-11-universal2-3.8/MySQLdb/constants
copying MySQLdb/constants/CR.py -> build/lib.macosx-11-universal2-3.8/MySQLdb/constants
copying MySQLdb/constants/ER.py -> build/lib.macosx-11-universal2-3.8/MySQLdb/constants
copying MySQLdb/constants/FIELD_TYPE.py -> build/lib.macosx-11-universal2-3.8/MySQLdb/constants
copying MySQLdb/constants/FLAG.py -> build/lib.macosx-11-universal2-3.8/MySQLdb/constants
running build_ext
building 'MySQLdb.mysql' extension
creating build/temp.macosx-11-universal2-3.8
creating build/temp.macosx-11-universal2-3.8/MySQLdb
gcc -Wno-unused-result -Wsign-compare -Wunreachable-code -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -arch arm64 -arch x86_64 -g -Dversion_info=(2,0,1,'final',0) -D__version=2.0.1 -I/opt/homebrew/Cellar/mysql/8.0.26/include/mysql -I/Users/gubukson/waffle-rookies-19.5-backend-0/assignment0/venv/include -I/Library/Frameworks/Python.framework/Versions/3.8/include/python3.8 -c MySQLdb/_mysql.c -o build/temp.macosx-11-universal2-3.8/MySQLdb/_mysql.o
gcc -bundle -undefined dynamic_lookup -arch arm64 -arch x86_64 -g build/temp.macosx-11-universal2-3.8/MySQLdb/_mysql.o -L/opt/homebrew/Cellar/mysql/8.0.26/lib -lmysqlclient -lzstd -lresolv -o build/lib.macosx-11-universal2-3.8/MySQLdb/_mysql.cpython-38-darwin.so
ld: library not found for -lzstd
clang: error: linker command failed with exit code 1 (use -v to see invocation)
error: command 'gcc' failed with exit status 1
ERROR: Failed building wheel for mysqlclient
Running setup.py clean for mysqlclient
Failed to build mysqlclient
Installing collected packages: mysqlclient
Running setup.py install for mysqlclient ... error
ERROR: Command errored out with exit status 1:
command: /Users/gubukson/waffle-rookies-19.5-backend-0/assignment0/venv/bin/python -u -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/private/var/folders/yh/hgff3rm12310wgk60ntsb0hw0000gn/T/pip-install-z10zosmx/mysqlclient_246670fdb7744a52a8999b06e7350f4c/setup.py'"'"'; file='"'"'/private/var/folders/yh/hgff3rm12310wgk60ntsb0hw0000gn/T/pip-install-z10zosmx/mysqlclient_246670fdb7744a52a8999b06e7350f4c/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(file) if os.path.exists(file) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' install --record /private/var/folders/yh/hgff3rm12310wgk60ntsb0hw0000gn/T/pip-record-a5sv50xr/install-record.txt --single-version-externally-managed --compile --install-headers /Users/gubukson/waffle-rookies-19.5-backend-0/assignment0/venv/include/site/python3.8/mysqlclient
cwd: /private/var/folders/yh/hgff3rm12310wgk60ntsb0hw0000gn/T/pip-install-z10zosmx/mysqlclient_246670fdb7744a52a8999b06e7350f4c/
Complete output (29 lines):
running install
running build
running build_py
creating build
creating build/lib.macosx-11-universal2-3.8
creating build/lib.macosx-11-universal2-3.8/MySQLdb
copying MySQLdb/init.py -> build/lib.macosx-11-universal2-3.8/MySQLdb
copying MySQLdb/exceptions.py -> build/lib.macosx-11-universal2-3.8/MySQLdb
copying MySQLdb/connections.py -> build/lib.macosx-11-universal2-3.8/MySQLdb
copying MySQLdb/converters.py -> build/lib.macosx-11-universal2-3.8/MySQLdb
copying MySQLdb/cursors.py -> build/lib.macosx-11-universal2-3.8/MySQLdb
copying MySQLdb/release.py -> build/lib.macosx-11-universal2-3.8/MySQLdb
copying MySQLdb/times.py -> build/lib.macosx-11-universal2-3.8/MySQLdb
creating build/lib.macosx-11-universal2-3.8/MySQLdb/constants
copying MySQLdb/constants/init.py -> build/lib.macosx-11-universal2-3.8/MySQLdb/constants
copying MySQLdb/constants/CLIENT.py -> build/lib.macosx-11-universal2-3.8/MySQLdb/constants
copying MySQLdb/constants/CR.py -> build/lib.macosx-11-universal2-3.8/MySQLdb/constants
copying MySQLdb/constants/ER.py -> build/lib.macosx-11-universal2-3.8/MySQLdb/constants
copying MySQLdb/constants/FIELD_TYPE.py -> build/lib.macosx-11-universal2-3.8/MySQLdb/constants
copying MySQLdb/constants/FLAG.py -> build/lib.macosx-11-universal2-3.8/MySQLdb/constants
running build_ext
building 'MySQLdb.mysql' extension
creating build/temp.macosx-11-universal2-3.8
creating build/temp.macosx-11-universal2-3.8/MySQLdb
gcc -Wno-unused-result -Wsign-compare -Wunreachable-code -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -arch arm64 -arch x86_64 -g -Dversion_info=(2,0,1,'final',0) -D__version=2.0.1 -I/opt/homebrew/Cellar/mysql/8.0.26/include/mysql -I/Users/gubukson/waffle-rookies-19.5-backend-0/assignment0/venv/include -I/Library/Frameworks/Python.framework/Versions/3.8/include/python3.8 -c MySQLdb/_mysql.c -o build/temp.macosx-11-universal2-3.8/MySQLdb/_mysql.o
gcc -bundle -undefined dynamic_lookup -arch arm64 -arch x86_64 -g build/temp.macosx-11-universal2-3.8/MySQLdb/_mysql.o -L/opt/homebrew/Cellar/mysql/8.0.26/lib -lmysqlclient -lzstd -lresolv -o build/lib.macosx-11-universal2-3.8/MySQLdb/_mysql.cpython-38-darwin.so
ld: library not found for -lzstd
clang: error: linker command failed with exit code 1 (use -v to see invocation)
error: command 'gcc' failed with exit status 1
----------------------------------------
ERROR: Command errored out with exit status 1: /Users/gubukson/waffle-rookies-19.5-backend-0/assignment0/venv/bin/python -u -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/private/var/folders/yh/hgff3rm12310wgk60ntsb0hw0000gn/T/pip-install-z10zosmx/mysqlclient_246670fdb7744a52a8999b06e7350f4c/setup.py'"'"'; file='"'"'/private/var/folders/yh/hgff3rm12310wgk60ntsb0hw0000gn/T/pip-install-z10zosmx/mysqlclient_246670fdb7744a52a8999b06e7350f4c/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(file) if os.path.exists(file) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' install --record /private/var/folders/yh/hgff3rm12310wgk60ntsb0hw0000gn/T/pip-record-a5sv50xr/install-record.txt --single-version-externally-managed --compile --install-headers /Users/gubukson/waffle-rookies-19.5-backend-0/assignment0/venv/include/site/python3.8/mysqlclient Check the logs for full command output.
from seminar-2021.
찾아보니 mysql이 usr/local/bin에 있어야 하는 것 같은데 저는 opt/homebrew/bin에 설치가 되어 있는데 이 부분을 고쳐야 할 것 같은데 방법을 잘 모르겠습니다
from seminar-2021.
넵 위의 방법 시도해보시겠어요? ㅜ 저도 맥에서 비슷한 경험 한 적이 있긴 합니다
from seminar-2021.
Related Issues (20)
- Nginx 배포 완료 후 서버가 작동하지 않는 문제
- 장고 과제4 서버 실행시 static file not found 에러 질문드립니다. HOT 11
- 안드로이드 과제4 Dagger Hilt로 만든 okhttpclient에서 logcat 출력 설정 방법 HOT 2
- local에서 Authorization Error HOT 2
- 백엔드 서버가 보낼 수 있는 여러 에러 응답 처리 관련 HOT 2
- 안드로이드 과제4 스펙 관련 HOT 2
- Django 과제4 RDS 데이터베이스 생성 요금?? HOT 3
- 안드로이드 과제4 에러 메시지 관련 HOT 3
- 장고 과제4 migration 관련 에러 질문 HOT 5
- RDS 생성 후 DATA GRIP 연동 부분에서 connection이 계속 fail합니다. HOT 1
- 장고 OperationalError: (1045, "Access denied for user 'waffle-backend'@'172.31.44.17') HOT 3
- 장고 과제4 nginx stop 혹은 restart 시 오류 관련 HOT 5
- nginx 502 bad gateway 에러 HOT 1
- 장고 과제 5 exception_handler을 찾지 못하는 문제 관련 HOT 4
- 장고 과제 4 Migration 관련 질의 HOT 1
- 장고 과제 5(2) 문제 의도 및 추가적인 질문 HOT 5
- 장고 과제 5(3) notebook 실행 오류 질문 HOT 8
- EC2에서 애플리케이션이 꺼지는 현상
- 안드로이드 과제 리뷰 관련하여 질문드립니다. HOT 1
- Can I set more than one constant of P control when using PID control for line tracing made with Arduino?
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from seminar-2021.