localhost:~ jerry$ Processing /var/www/git/python/tesserocr

-bash: Processing: command not found

localhost:~ jerry$ pip3 install tesserocr

Collecting tesserocr

Using cached https://files.pythonhosted.org/packages/f8/6d/4e81e041f33a4419e59edcb1dbdf3c56e9393f60f5ef531381bd67a1339b/tesserocr-2.3.1.tar.gz

Building wheels for collected packages: tesserocr

Running setup.py bdist_wheel for tesserocr ... error

Complete output from command /anaconda3/bin/python -u -c "import setuptools, tokenize;__file__='/private/var/folders/b_/dgk5x9dx6bx69rhw7v6dhgtw0000gn/T/pip-install-v4ek5yfd/tesserocr/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" bdist_wheel -d /private/var/folders/b_/dgk5x9dx6bx69rhw7v6dhgtw0000gn/T/pip-wheel-u4i9uj2o --python-tag cp37:

/private/var/folders/b_/dgk5x9dx6bx69rhw7v6dhgtw0000gn/T/pip-install-v4ek5yfd/tesserocr/setup.py:132: DeprecationWarning: The 'warn' method is deprecated, use 'warning' instead

_LOGGER.warn('pkg-config failed to find tesseract/lept libraries: {}'.format(e))

pkg-config failed to find tesseract/lept libraries: b"Package tesseract was not found in the pkg-config search path.\nPerhaps you should add the directory containing `tesseract.pc'\nto the PKG_CONFIG_PATH environment variable\nNo package 'tesseract' found\n"

Supporting tesseract v4.0.0

Building with configs: {'libraries': ['tesseract', 'lept'], 'cython_compile_time_env': {'TESSERACT_VERSION': 262144}}

running bdist_wheel

running build

running build_ext

building 'tesserocr' extension

creating build

creating build/temp.macosx-10.7-x86_64-3.7

gcc -Wno-unused-result -Wsign-compare -Wunreachable-code -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -I/anaconda3/include -arch x86_64 -I/anaconda3/include -arch x86_64 -I/anaconda3/include/python3.7m -c tesserocr.cpp -o build/temp.macosx-10.7-x86_64-3.7/tesserocr.o -std=c++11 -DUSE_STD_NAMESPACE

warning: include path for stdlibc++ headers not found; pass '-std=libc++' on the command line to use the libc++ standard library instead [-Wstdlibcxx-not-found]

In file included from tesserocr.cpp:603:

/usr/local/include/tesseract/unichar.h:24:10: fatal error: 'cstring' file not found

#include <cstring>

^~~~~~~~~

1 warning and 1 error generated.

error: command 'gcc' failed with exit status 1

----------------------------------------

Failed building wheel for tesserocr

Running setup.py clean for tesserocr

Failed to build tesserocr

Installing collected packages: tesserocr

Running setup.py install for tesserocr ... error

Complete output from command /anaconda3/bin/python -u -c "import setuptools, tokenize;__file__='/private/var/folders/b_/dgk5x9dx6bx69rhw7v6dhgtw0000gn/T/pip-install-v4ek5yfd/tesserocr/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /private/var/folders/b_/dgk5x9dx6bx69rhw7v6dhgtw0000gn/T/pip-record-1cw_w_lk/install-record.txt --single-version-externally-managed --compile:

/private/var/folders/b_/dgk5x9dx6bx69rhw7v6dhgtw0000gn/T/pip-install-v4ek5yfd/tesserocr/setup.py:132: DeprecationWarning: The 'warn' method is deprecated, use 'warning' instead

_LOGGER.warn('pkg-config failed to find tesseract/lept libraries: {}'.format(e))

pkg-config failed to find tesseract/lept libraries: b"Package tesseract was not found in the pkg-config search path.\nPerhaps you should add the directory containing `tesseract.pc'\nto the PKG_CONFIG_PATH environment variable\nNo package 'tesseract' found\n"

Supporting tesseract v4.0.0

Building with configs: {'libraries': ['tesseract', 'lept'], 'cython_compile_time_env': {'TESSERACT_VERSION': 262144}}

running install

running build

running build_ext

building 'tesserocr' extension

creating build

creating build/temp.macosx-10.7-x86_64-3.7

gcc -Wno-unused-result -Wsign-compare -Wunreachable-code -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -I/anaconda3/include -arch x86_64 -I/anaconda3/include -arch x86_64 -I/anaconda3/include/python3.7m -c tesserocr.cpp -o build/temp.macosx-10.7-x86_64-3.7/tesserocr.o -std=c++11 -DUSE_STD_NAMESPACE

warning: include path for stdlibc++ headers not found; pass '-std=libc++' on the command line to use the libc++ standard library instead [-Wstdlibcxx-not-found]

In file included from tesserocr.cpp:603:

/usr/local/include/tesseract/unichar.h:24:10: fatal error: 'cstring' file not found

#include <cstring>

^~~~~~~~~

1 warning and 1 error generated.

error: command 'gcc' failed with exit status 1

----------------------------------------

Command "/anaconda3/bin/python -u -c "import setuptools, tokenize;__file__='/private/var/folders/b_/dgk5x9dx6bx69rhw7v6dhgtw0000gn/T/pip-install-v4ek5yfd/tesserocr/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /private/var/folders/b_/dgk5x9dx6bx69rhw7v6dhgtw0000gn/T/pip-record-1cw_w_lk/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /private/var/folders/b_/dgk5x9dx6bx69rhw7v6dhgtw0000gn/T/pip-install-v4ek5yfd/tesserocr/

看了下网上的搜索结果,发现原来是我安装了Anaconda的原因。同时,也找到了解决方法

conda install -c simonflueckiger tesserocr

查了下conda install 发现conda是针对于python的。可以安装minconda或anaconda进行安装。所以在安装了Anaconda的条件下,我们可以通过conda install安装tesserocr

参考链接地址:http://mkd.pub/chl434723646/415732_22875257.html

解决Mac安装tesserocr报错问题 Failed building wheel for的更多相关文章

  1. Mac安装MySQL-python报错解决

    Mac安装MySQL-pyhton报错 今天在Mac上安装MySQL-python报错,搜遍网络都说什么mysql config路径问题,但是都不行. 解决方案 一开始遇到的问题是: Complete ...

  2. 解决vue安装less报错Failed to compile with 1 errors的问题

    1.创建vue项目后安装less,执行 npm install less less-loader --save-dev 下载版本为:less-loader@6.1.0 , less@3.11.3,重启 ...

  3. 解决mac安装homebrew后报错-bash: brew: command not found

    解决mac安装homebrew后报错-bash: brew: command not found     参照官网上很简单的一句安装命令, /usr/bin/ruby -e "$(curl ...

  4. Mac安装MAT报错问题

    安装mat报错,提示在/.eclipse/1528649425_macosx_cocoa_x86_64/configuration/1539332382530.log路径下查看错误日志, 原因是/pr ...

  5. Python安装scrapy过程中出现“Failed building wheel for xxx”

    https://www.lfd.uci.edu/~gohlke/pythonlibs/#lxml Python安装scrapy库过程中出现“ Failed building wheel for xxx ...

  6. mac 安装homobrew 报错解决

    按照官网(https://brew.sh/index_zh-cn.html)给的命令:     /usr/bin/ruby -e "$(curl -fsSL https://raw.gith ...

  7. 关于mac安装rails报错clang: error: unknown argument

    文章都是从我的个人博客上转载过来的,大家可以点击我的个人博客. www.iwangzheng.com mac上安装rails的时候报错, 安装rails的在终端执行了一句命令: $sudo gem i ...

  8. Linux下安装vim-plug报错:Failed to connect to raw.githubusercontent.com port 443: Connection refused

    安装vim-plug时,输入以下命令: curl -fLo ~/.vim/autoload/plug.vim --create-dirs https://raw.githubusercontent.c ...

  9. 【Django】Mac 安装pip3-install-mysqlclient 报错

    1.首先在pip3-install-mysqlclient时报错 mysql_config not found 2.逛了一些博客 让安装mysql或者mysql-connector-c 我安装了后者还 ...

随机推荐

  1. 2019CSP初赛基础知识整理

    一.硬件 计算机发展:   年代 元件 第一代 1946~1958 电子管 第二代 1959~1964 晶体管 第三代 1965~1970 集成电路 第四代 1971~? 大规模集成电路 世界上第一台 ...

  2. Vue 前端uni-app多环境配置部署服务器的问题

    目录 前端Vue 针对问题 package.json描述 多环境部署 查看源码获取解决方案 转载请标明出处: http://dujinyang.blog.csdn.net/ 本文出自:[奥特曼超人的博 ...

  3. ThreadPoolTaskExecutor介绍

    ThreadPoolTaskExecutor是一个spring的线程池技术,其实,它的实现方式完全是使用ThreadPoolExecutor进行实现.对于ThreadPoolExecutor,有一些重 ...

  4. NOIP2006 1.明明的随机数

    题目:明明想在学校中请一些同学一起做一项问卷调查,为了实验的客观性,他先用计算机生成了N个1到1000之间的随机整数(N≤100),对于其中重复的数字,只保留一个,把其余相同的数去掉,不同的数对应着不 ...

  5. maven的使用解说

    maven周期及项目中的应用: 周期如下: 1.default生命周期,部署项目(jar包的依赖管理) 2.clear生命周期,项目清理工作 3.site生命周期,处理项目中产生的文档信息 应用: 1 ...

  6. opencv中IplImage* src = cvLoadImage,错误

    在调试这段代码时 IplImage* src = cvLoadImage("D:\\图像\\已处理 - 11.26\\1.jpg", 1); 提示一下错误 引发了异常: 读取访问权 ...

  7. java、八大经典书籍,你看过几本?

    java.八大经典书籍,你看过几本? 转载  一.Java从入门到精通 <Java从入门到精通(第3版)>从初学者角度出发,通过通俗易懂的语言.丰富多彩的实例,详细介绍了使用Java语言进 ...

  8. Jackson 序列化和反序列化

    博客地址:https://www.moonxy.com 一.前言 Jackson 功能很强大,既能满足简单的序列化和反序列化操作,也能实现复杂的.个性化的序列化和反序列化操作.到目前为止,Jackso ...

  9. [VB.NET Tips]VB.NET专有的字符串处理函数

    .NET Framework类库中含有专门为Visual Basic.NET程序员设计的函数和过程. 这些方法虽然是为VB.NET程序员设计的,但是也可以被.NET Framework上支持的任何语言 ...

  10. Mybatis源码解析,一步一步从浅入深(五):mapper节点的解析

    在上一篇文章Mybatis源码解析,一步一步从浅入深(四):将configuration.xml的解析到Configuration对象实例中我们谈到了properties,settings,envir ...