如何在msys2中修复./configure?
我正在尝试构建 libxc-4.3.4 在Windows 10 。 已经安装了构建工具
pacman -S --needed base-devel mingw-w64-x86_64-toolchain autoconf
我已经在Linux机器上安装了数十个时间, 。第一步是,
./configure --prefix /somewhere
但是在MSYS2中,我得到了
$ ./configure --prefix $PWD/../libxc
bash: ./configure: No such file or directory
如何使这项工作?
I'm trying to build libxc-4.3.4 in an MSYS2 shell on Windows 10. I've installed the latest version of MSYS2 (msys2-x86_64-20220319.exe) and followed the installation instructions. I've installed build tools using
pacman -S --needed base-devel mingw-w64-x86_64-toolchain autoconf
I've installed libxc dozens of time on Linux machines. The first step is
./configure --prefix /somewhere
But in MSYS2 I get
$ ./configure --prefix $PWD/../libxc
bash: ./configure: No such file or directory
How can I make this work?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
MSYS2先决条件
首先确保MSYS2具有所有需要的程序。
在MSYS2 SHELL中首先更新软件包管理器信息:
然后安装所需的软件包。我至少建议至少这些:
接下来的项目来源
您应该确保所处的文件夹实际上具有配置脚本:
如今许多项目正在切换到更有效的构建系统,例如CMAKE或MESON。
我通常在项目源文件夹中使用以下命令来检查几个构建系统:
构建libxc
libxc项目 ,我看到有一个
cmakelists.txt
文件,还有configure.ac < /代码>文件。
因此,要么您应该考虑使用cmake或与以下方式生成
配置
文件:我刚刚尝试使用CMAKE和NINJA在MSYS2中构建LiBXC,而且这有效:
MSYS2 prerequisites
First of all make sure MSYS2 has all programs that are needed.
In the MSYS2 shell first update the package manager information:
Then install the packages you need. I would recommend at least these:
Project sources
Next you should make sure the folder you are in actually has a configure script:
A lot of projects these days are switching to more efficient build systems like CMake or Meson.
I usually use the following command in the projects source folder to check for several build systems:
building libxc
For the libxc project I see there is a
CMakeLists.txt
file and also aconfigure.ac
file.So either you should look into using CMake or generate the
configure
file with:I have just tried to build libxc in MSYS2 with CMake and Ninja and this worked: