• ubuntu lua安装


    #解压
    tar -xzvf  lua5.2.2.tar.gz
    
    #进入lua5.2.2文件夹
    cd lua5.2.2
    
    #执行make
    sudo make linux
    
    #提示如下错误:
    #lua.c:67:31: 致命错误: readline/readline.h:没有那个文件或目录编译中断。
    
    #到网上下载,大小2.2M
    sudo wget  http://www.sfr-fresh.com/unix/misc/readline-6.1.tar.gz
    
    #执行下列操作
    tar -zxvf readline-6.1.tar.gz,cd ~~ ./configure && make && make install 
    sudo ldconfig
    
    #下载ncurses安装
    wget http://ftp.gnu.org/pub/gnu/ncurses/ncurses-5.7.tar.gz
    #执行下列操作
    tar -xvf ncurses-5.7.tar.gz
    cd ncurses-5.7
    ./configure
    make
    make install
    
    #运行make linux,提示
    /usr/local/lib/libreadline.so: undefined reference to `PC'
    /usr/local/lib/libreadline.so: undefined reference to `tgetflag'
    /usr/local/lib/libreadline.so: undefined reference to `tgetent'
    /usr/local/lib/libreadline.so: undefined reference to `UP'
    /usr/local/lib/libreadline.so: undefined reference to `tputs'
    /usr/local/lib/libreadline.so: undefined reference to `tgoto'
    /usr/local/lib/libreadline.so: undefined reference to `tgetnum'
    /usr/local/lib/libreadline.so: undefined reference to `BC'
    /usr/local/lib/libreadline.so: undefined reference to `tgetstr'
    
    #google了一下,解决方案都没好用,后来请教同学,告诉我直接从命令行安装下列包,果真好用了不报错了
    sudo apt-get install libreadline6-dev
    sudo apt-get install libreadline6-dbg
    
    #最后执行make linux,make install
    sudo make linux
    sudo make install
    

      以上内容转载自http://www.w3hacker.com/?p=500

    #####################################################################

    安装完成后输入lua报错:lua: symbol lookup error: /usr/local/lib/libreadline.so.6: undefined symbol: PC"

    解决办法:

      cd /usr/local/lib

        mkdir temp
        mv libreadline* temp/
        ldconfig
  • 相关阅读:
    Linux服务器因为Nginx日志access.log文件过大项目无法访问的问题
    【译】StackExchange.Redis 中文文档(二)配置
    【译】StackExchange.Redis 中文文档(一)基础
    Redis应用(一)实时在线用户
    [.NET]Thread与Task的区别
    并查集(UnionFind)技巧总结
    [LeetCode题解]377. 组合总和 Ⅳ
    [LeetCode题解]216. 组合总和 III
    [LeetCode题解]39. 组合总和
    [LeetCode题解]40. 组合总和 II
  • 原文地址:https://www.cnblogs.com/baiyideng/p/3791662.html
Copyright © 2020-2023  润新知