zoukankan      html  css  js  c++  java
  • 升级libtool带来的问题已经解决

    今天新装了个linux系统。因为版本比较低,所以对libtool, automake, autoconf,  m4,  pkg-config进行了升级。

    结果没有想到出了一个很是奇怪的错误。是在编译一个程序时,configure已经过了,在make的时候报的错误。

    libtool: unrecognized option `--tag=CC'
    Try `libtool --help' for more information.

    它说不认识--tag这个参数,查看了,可是是有的:

    [zhaowei@localhost src]$ libtool --help
    Usage: libtool [OPTION]... [MODE-ARG]...

    Provide generalized library-building support services.

    --config          show all configuration variables
    --debug           enable verbose shell tracing
    -n, --dry-run         display commands without modifying any files
    --features        display basic configuration information and exit
    --finish          same as `--mode=finish'
    --help            display this help message and exit
    --mode=MODE       use operation mode MODE [default=inferred from MODE-ARGS]
    --quiet           same as `--silent'
    --silent          don't print informational messages
    --tag=TAG         use configuration variables from tag TAG
    --version         print version information

    MODE must be one of the following:

    clean           remove files from the build directory
    compile         compile a source file into a libtool object
    execute         automatically set library path, then run a program
    finish          complete the installation of libtool libraries
    install         install libraries or executables
    link            create a library or an executable
    uninstall       remove libraries from an installed directory

    MODE-ARGS vary depending on the MODE.  Try `libtool --help --mode=MODE' for
    a more detailed description of MODE.

    Report bugs to <>.

    后来发现,在我编译的这个程序目录下的libtool没有这个--tag参数,这个东西是autogen.sh这个脚本产生configure文件时生成的。

    现在问题明朗了,libtool会使用ltmain.sh这个脚本,每次生成的时候,libtool会拷贝一个ltmain.sh到当前的程序目录中。那 就是这个ltmain.sh的版本不对了。我升级了libtool,但还保留了原来的,于是新的libtool居然使用了旧的ltmain.sh。新的 libtool我安装到/usr/local/下了,所以ltmain.sh在/usr/local/share/libtool下,老的在/usr /share/libtool下,我把老的libtool彻底删除就ok了。
  • 相关阅读:
    kendoui仪表盘和柱状图 示例
    log4net修改数据库连接字符串和写自定义信息
    为sharepoint的内部页面添加后台代码
    Qt中对QDomDocument和QDomnode的理解
    标准输出中stderr和stdout的区别
    设计一个算法移除字符串中的重复字符,并写出测试用例。
    字符串中单词的逆转,即将单词出现的顺序进行逆转。如将“Today is Friday!”逆转为“Friday! is Today”.
    输入两个很大的正数(用C字符串表示),输出他们的乘积,将设不考虑非法输入。
    微信公众平台的开发过程及其要点
    NR_OPEN 与 NR_FILE 的区别
  • 原文地址:https://www.cnblogs.com/danghuijian/p/4400373.html
Copyright © 2011-2022 走看看