问题描述:
从win10下的github desktop git clone protobuf,然后把文件夹穿到linux平台的服务器再运行.sh文件产生如下错误
libtoolize: putting auxiliary files in AC_CONFIG_AUX_DIR, 'build-aux'.
libtoolize: copying file 'build-aux/ltmain.sh'
.ibtoolize: error: AC_CONFIG_MACRO_DIRS([m4]) conflicts with ACLOCAL_AMFLAGS=-I m4
autoreconf: libtoolize failed with exit status: 1
解决方法:
参考
https://stackoverflow.com/questions/47582762/ac-config-macro-dirsbuild-aux-m4-conflicts-with-aclocal-amflags-i-build-aux
在终端中运行以下命令
sudo find . -name \*.sh|xargs dos2unix
sudo find . -name \*.m4|xargs dos2unix
sudo find . -name \*.ac|xargs dos2unix
sudo find . -name \*.am|xargs dos2unix
以上方法指标不治本,由于文件夹是在windows下下载的,