Libtool installation issue with make install

不问归期 提交于 2019-11-30 14:56:59

问题


I use the following autotool steps to install my pacakges:

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

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

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


回答1:


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.

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

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


来源:https://stackoverflow.com/questions/32766609/libtool-installation-issue-with-make-install

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!