使用make install的Libtool安装问题 [英] Libtool installation issue with make install

查看:2685
本文介绍了使用make install的Libtool安装问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用以下自动工具步骤来安装我的pacakges:

I use the following autotool steps to install my pacakges:

./configure
make
make install prefix=/my/path

但是我得到了以下libtool警告" libtool:警告:记得运行'libtool --finish/usr/local/lib '和" libtool:警告:'lib/my使用自动工具安装软件包时,.la'尚未安装在'/usr/local/lib'中.如果更改为以下命令,问题将消失:

However I got the following libtool warning "libtool: warning: remember to run 'libtool --finish /usr/local/lib' and "libtool: warning: 'lib/my.la' has not been installed in '/usr/local/lib'" when using the autotool to install my software package. If I change to the following command, the problem disappear:

./configure
make prefix=/my/path
make install prefix=/my/path

第一个方法似乎没有正确地将prefix替换为libtool.我该如何避免这个问题?

It looks like the first method doesn't substitute the prefix correctly to libtool. How can I avoid this problem?

推荐答案

libtool存档记录的有关它们描述的库的信息中,预期的安装位置是.创建库时将记录该信息.然后,您可以安装到其他位置,但是libtool会抱怨.通常,libtool的警告是无害的.

Among the information that libtool archives record about the libraries they describe is the expected installation location. That information is recorded when the library is created. You can then install to a different location, but libtool will complain. Often, libtool's warning is harmless.

为了避免此类警告,您需要在构建时告诉libtool与安装时相同的安装位置.您提出了在问题中执行此操作的一种方法,但是,如果使用的是标准Autotools构建系统,则最好将安装前缀指定为configure:

In order to avoid such a warning, you need to tell libtool the same installation location at build time that you do at install time. You present one way to do that in the question, but if you're using a standard Autotools build system then it is better to specify the installation prefix to configure:

./configure --prefix=/my/path
make
make install

或者,如果要安装到临时区域(例如,用于构建RPM),则在安装时使用DESTDIR. libtool仍会发出警告,但您将避免弄乱其他任何东西:

Alternatively, if you're installing into a staging area, such as for building an RPM, then use DESTDIR at install time. libtool will still warn, but you'll avoid messing up anything else:

./configure
make
make install DESTDIR=/staging/area

这篇关于使用make install的Libtool安装问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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