问题1:

补充,升级gcc,g++ 到4.7以上的版本才能安装成功

github 官网

github https://github.com/Valloric/YouCompleteMe#ubuntu-linux-x64

问题2:

./install.py --clang-completer

Using Clang archive: /root/.vim/bundle/YouCompleteMe/third_party/ycmd/cpp/../clang_archives/clang+llvm-3.9.0-x86_64-opensuse13.2.tar.xz
tar (child): xz: Cannot exec: No such file or directory

tar (child): Error is not recoverable: exiting now
tar: Child returned status 2
tar: Error is not recoverable: exiting now
CMake Error at ycm/CMakeLists.txt:164 (message):
You have not specified which libclang to use. You have several options:

1. Set PATH_TO_LLVM_ROOT to a path to the root of a LLVM+Clang binary distribution. You can download such a binary distro from llvm.org. This is the recommended approach.
2. Set USE_SYSTEM_LIBCLANG to ON; this makes YCM search for the system version of libclang.
3. Set EXTERNAL_LIBCLANG_PATH to a path to whatever libclang.[so|dylib|dll] you wish to use.

You HAVE to pick one option. See the docs for more information.

这个错误是现在下来的/root/.vim/bundle/YouCompleteMe/third_party/ycmd/clang_archives/clang+llvm-3.9.0-x86_64-opensuse13.2.tar.xz 的clang_archives目录要放入/root/.vim/bundle/YouCompleteMe/third_party/ycmd/cpp/llvm 目录下,也可以做一个软连接

vim /root/.vim/bundle/YouCompleteMe/third_party/ycmd/cpp/ycm/CMakeLists.txt

新开第一行:

set (PATH_TO_LLVM_ROOT "/root/.vim/bundle/YouCompleteMe/third_party/ycmd/cpp/llvm")

这个方法解决后发现自动补全受到影响,又重新编译了,即./install.py 没用加任何参数,我不需要cfailmy

下面这个方法试了没用 https://github.com/Valloric/YouCompleteMe/issues/1237

I've tried to add the following lines to the top of .vim/bundle/YouCompleteMe/third_party/ycmd/cpp/CMakeLists.txt

set(CMAKE_C_COMPILER "gcc")
set(CMAKE_CXX_COMPILER "g++")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fPIC" )
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC" )

But it ends the same.

vim YouCompleteMe 遇到的问题及解决的更多相关文章

  1. vim黏贴代码格式混乱的解决方法

    from:http://blog.csdn.net/commshare/article/details/6215088 感谢牛人的文章.解决了我在vim使用中,很头疼的问题. 在vim新建文件的时候, ...

  2. vim(5)vim下wimrc的配置,解决中文乱码问题

    解决linux下vim乱码的情况:(修改vimrc的内容) 全局的情况下:即所有用户都能用这个配置 文件地址:/etc/vimrc 在文件中添加: ,ucs-bom,gb18030,gbk,gb231 ...

  3. Ubuntu Vim YouCompleteMe 安装

    0. 必要工具安装 sudo apt-get install build-essential cmake 1. 安装 vundle mkdir ~/.vim/bundle git clone http ...

  4. win使用telnet到ubuntu下vim显示中文为乱码的解决方法~

    1.几个路径: ubuntu: /etc/default/locale  相当于 centos:/etc/sysconfig/i18n vimrc的路径:① ~/.vimrc    ② /etc/vi ...

  5. SecureCRT使用Vim出现中文乱码问题的解决

    1. 首先保证securecrt本身显示中文是ok的.如果不是,就先解决这一个问题. 2. vi ~/.vimrc 添加set encoding=utf-8 fileencodings=ucs-bom ...

  6. ubuntu 14.04 vim YoucompleteMe 代码自动补全工具安装

    安装步骤如下: sudo apt-get install vim ; sudo apt-get install vim-youcompleteme ; sudo apt-get install vim ...

  7. [转帖] linux下面 vim 数字键无法插入的解决办法

    感谢原作者: https://blog.csdn.net/guoyuqi0554/article/details/11477597 这个问题困扰自己好久了.. 刚才解决了 rlwrap的问题 这会儿 ...

  8. vim学习笔记(12):在vim中修改文件编码,解决vim 打开乱码

    在linux 中查看文件编码可以通过以下几种方式: 一.查看文件编码 1.查看文件编码file命令 :file ip.txt ip.txt: UTF-8 Unicode text, with esca ...

  9. Vim打开文件中文乱码如何解决?

    今天想找一下之前的随机数组demo复习,在源文件src里用vim打开.java文件,中文出现乱码 vim也是,选项里没有直接选择设置utf-8之类的 查了下网上,http://easwy.com/bl ...

随机推荐

  1. sql注入2

    一.查询数据库的版本号 http://10.1.2.5:10631/sqli/Less-2/?id=-1 union select 1,2,version() 二.查询数据库中所有的库名 http:/ ...

  2. 按此格式写你的distributionUrl,可以直接用本地的gradle包

    distributionUrl=file\:/C:/Users/shenliuyong/.gradle/wrapper/dists/gradle-2.10-all/a4w5fzrkeut1ox71xs ...

  3. 【Python】随机数random模块randint、shuffle、random、sample、choice、uniform、

    1 ).random() 返回0<=n<1之间的随机实数n:2 ).choice(seq) 从序列seq中返回随机的元素:3 ).getrandbits(n) 以长整型形式返回n个随机位: ...

  4. ubuntu apt 安装 mpv

    安装 curl -s https://non-gnu.uvt.nl/debian/uvt_key.gpg | sudo apt-key add - sudo add-apt-repository &q ...

  5. QT | 聊聊QT与直播流播放——从QMediaPlayer到Qt-AV

    [原创文章,转载请注明来源,方便查看本文更新] 这段时间需要用QT开发一个播放直播流的功能,能够播放各种格式的直播流,并且CPU占用率不要太高(可以占用GPU),这些是我们的目标. 直播流推流的技术进 ...

  6. 无空格字符串的break-all的性能问题

  7. Python全栈之路----常用模块----subprocess模块

    我们经常需要通过Python去执行一条系统命令或脚本,系统的shell命令是独立于你的python进程之外的,每执行一条命令,就是发起一个新进程,通过python调用系统命令或脚本的模块在python ...

  8. Go小爬虫测试

    package main import ( "fmt" "io/ioutil" "log" "net/http" ) t ...

  9. 不应该使用String.valueOf的场景

    今天在接口中接收参数转换String时遇到一个巨大的坑,也是自己疏忽大意所致---- 事情是这样的,项目中接口的公共入参对象为Map<String,Object>,而sql中需要的参数为S ...

  10. Keuskal算法模板

    int cmp(const int i, const int j) { return w[i]<w[j]; }///间接比较函数,w[i]表示边i权值 int find_set(int x) { ...