今天在编译crosstool的时候,执行./configure时出现错误,提示找不到libtool
checking whether /usr/bin/make sets $(MAKE)… yes
checking for make 3.81… no
checking for GNU libtool >= 1.5.26… no
configure: error: could not find GNU libtool >= 1.5.26
但是使用apt-get 安装libtool的时候提示已经安装
$ sudo apt-get install libtool
Reading package lists... Done
Building dependency tree
Reading state information... Done
libtool is already the newest version (2.4.6-0.1).
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
没办法,只能查看configure文件,发现是因为没有找到libtool导致的,使用whereis命令查看libtool路径
$ whereis libtool
libtool: /usr/share/libtool
但是在configure的时候,是使用PATH来查找文件的,所以解决问题就简单了,configure支持–with-libtool来指定libtool的路径
$ ./configure --with-libtool=/usr/share/libtool