首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >在python 3.7中安装Pyscard

在python 3.7中安装Pyscard
EN

Stack Overflow用户
提问于 2019-11-05 23:42:39
回答 2查看 2.5K关注 0票数 0

如何在Python3.7上安装pyscard

Python3.7中是否还有其他用于智能卡读卡器的模块?

下面的错误:

pip install pyscard

代码语言:javascript
复制
    ERROR: Command errored out with exit status 1:

     command: 'c:\allinone\portableapps\python374\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\E4B6~1\\AppData\\Local\\Temp\\pip-install-rgx51osl\\pyscard\\setup.py'"'"'; __file__='"'"'C:\\Users\\E4B6~1\\AppData\\Local\\Temp\\pip-install-rgx51osl\\pyscard\\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record 'C:\Users\E4B6~1\AppData\Local\Temp\pip-record-o8_63h_7\install-record.txt' --single-version-externally-managed --compile
         cwd: C:\Users\E4B6~1\AppData\Local\Temp\pip-install-rgx51osl\pyscard\
    Complete output (8 lines):
    running install
    running build
    running build_py
    running build_ext
    building 'smartcard.scard._scard' extension
    swigging smartcard/scard/scard.i to smartcard/scard/scard_wrap.c
    swig.exe -python -outdir smartcard/scard -DWIN32 -o smartcard/scard/scard_wrap.c smartcard/scard/scard.i
    error: command 'swig.exe' failed: No such file or directory


ERROR: Command errored out with exit status 1: 'c:\allinone\portableapps\python374\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\E4B6~1\\AppData\\Local\\Temp\\pip-install-rgx51osl\\pyscard\\setup.py'"'"'; __file__='"'"'C:\\Users\\E4B6~1\\AppData\\Local\\Temp\\pip-install-rgx51osl\\pyscard\\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record 'C:\Users\E4B6~1\AppData\Local\Temp\pip-record-o8_63h_7\install-record.txt' --single-version-externally-managed --compile Check the logs for full command output.
EN

回答 2

Stack Overflow用户

发布于 2021-03-14 01:11:10

下载swig,最新版本。将其解压到C:\python\Swig这样的文件夹中,并将该文件夹添加到PATH中。如果您还没有,请从Microsoft下载并安装VCPP express。然后尝试:

代码语言:javascript
复制
pip install pyscard
票数 1
EN

Stack Overflow用户

发布于 2020-07-20 15:55:42

只需下载http://www.swig.org/download.html

SWIG是一个接口编译器,它将用C和C++编写的程序与脚本语言连接起来

票数 -1
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/58714774

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档