如何在Mac中卸载OpenCV [英] How to uninstall OpenCV in mac

查看:1013
本文介绍了如何在Mac中卸载OpenCV的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我以这种方式安装了OpenCV

I installed OpenCV this way

#After downloading OpenCV-3.0, in the directory:
echo "#define GTEST_USE_OWN_TR1_TUPLE 1" | cat > temp1
cat modules/ts/include/opencv2/ts/ts_gtest.h > temp2
cat temp1 temp2 > modules/ts/include/opencv2/ts/ts_gtest.h
mkdir build
cd build
cmake .. -Wno-dev
make -j8 && sudo make install
#Update your bash_profile:
~$ echo "export PYTHONPATH=/usr/local/lib/python2.7/site-packages/:$PYTHONPATH" >>
~/.bash_profile
#Close and open the Terminal
#Open python console and try to import cv2 to test if everything works
~$ python import cv2

该版本不稳定,并且出错,我想卸载该版本以避免在使用brew安装opencv时出现问题,我应该删除文件夹吗?

The version is not stable and making errors I want to uninstall it to avoid problem when I install opencv using brew, should I just delete the folder ?

这就是我做完后得到的东西

THis what I get when i did

cd build
 make uninstall
-- Uninstalling "/usr/local/share/OpenCV/3rdparty/lib/libippicv.a"
CMake Error at cmake_uninstall.cmake:20 (MESSAGE):
  Problem when removing "/usr/local/share/OpenCV/3rdparty/lib/libippicv.a"


make[3]: *** [CMakeFiles/uninstall] Error 1
make[2]: *** [CMakeFiles/uninstall.dir/all] Error 2
make[1]: *** [CMakeFiles/uninstall.dir/rule] Error 2
make: *** [uninstall] Error 2

推荐答案

如果使用Homebrew进行安装,则可以使用此命令.

If you used Homebrew to install you can use this command.

brew uninstall opencv3

您将不必删除任何目录,例如/usr/local/Cellar/opencv3

You will not have to remove any directory such as /usr/local/Cellar/opencv3

这篇关于如何在Mac中卸载OpenCV的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆