我该怎么做才能使用 ./configure 生成 makefile?

How can I do in order to generate the makefile with ./configure?

我正在尝试安装 EZTrace,这是一个旨在从 HPC 自动生成执行跟踪的工具。我从这里下载了安装文件夹,https://eztrace.gitlab.io/eztrace/index.html。解压后发现一个README文件:

Requirements
=============================================
In order to run EZTrace, you need the following software:

  * autoconf 2.63;

  * libelf or libbfd. Otherwise, only eztrace.old would be installed and the
    functionality would be limited, see the FAQ section.
    On Debian, libelf can be installed from command line by the following
    command: apt-get install libelf-dev

  * [Optional] Any MPI implementation.    

Building EZTrace
=============================================
At first, you need to configure EZTrace by invoking the configure script:

$ ./configure --prefix=<WHERE_YOU_INSTALL_EZTRACE>

Options to configure. You can pass several options to the configure script for
specifying where it should find the needed libraries:
--with-litl=$LITL_ROOT or ARG(=no): specify where LiTL is installed
--with-gtg=$GTG_ROOT: specify where GTG is installed.
--with-mpi=$MPI_ROOT: specify where MPI is installed. The mpi.h file must be
  located in the $MPI_ROOT/include/ directory.
--with-mpi-include=<PATH_TO_MPI.H>: specify the directory that contains the
  mpi.h file.
--with-papi=$PAPI_ROOT: specify where PAPI is installed. The papi.h file must be
  located in the $PAPI_ROOT/include directory and libpapi should be in 
  $PAPI_ROOT/lib

Once EZTrace is configured, just type:

$ make
$ make install

我检查了我是否已经安装了要求(完成)。当到达 ./configure 命令时,我遇到了一个问题,我通过键入 autoreconf -i.

解决了这个问题

问题是,在执行 ./configure 命令后和执行 make 命令时,出现此错误:

make: *** No targets specified and no makefile found.  Stop.

(这是因为命令 ./configure 没有按预期生成 makefile)。 我只有 Makefile.am & Makefile.in.

我尝试检查这个命令块:

aclocal
autoconf
autoheader
automake --add-missing

我得到了:

autoheader: error: AC_CONFIG_HEADERS not found in configure.ac
automake: warning: LINK was already defined in condition USE_CUDA, which is included in condition TRUE ...
src/modules/cuda/Makefile.am:15: ... 'LINK' previously defined here

我想提一下,我位于一个名为

的文件夹中
"/home/hakim/Téléchargements/eztrace-eztrace-1.1-9"

请提供生成 makefile 的任何帮助?

  • 不要 运行 autoheader - 项目未设置为使用它
  • automake 警告是 警告,不是错误。

通常,bootstrap 自动工具项目的最简单方法是 运行 宁 autoreconf -fiv。 这将创建一个 configure 脚本,您需要 运行 才能创建 Makefile。

autoreconf -fiv
./configure
make

编辑:EZtraze

原始答案(以上)是对一般问题(“我如何使用 ./configure 生成 makefile?”)的一般答案。

对于特定项目,例如 EZtrace,阅读 README 通常会有所帮助。 您已经引用了 README,但无论出于何种原因,您似乎遗漏了关键部分:

Getting EZTrace
=============================================
* You can get the latest stable release on EZTrace website:
  http://eztrace.gforge.inria.fr/

* Current development version is available via GIT
  git clone git://scm.gforge.inria.fr/eztrace/eztrace.git

After getting the latest development version (from GIT), you need to run
'./bootstrap' and only then build the tool.

(git 版本 您链接到的页面上可用的发布 tarball 包含此部分)。

它清楚地告诉你,你 必须先 运行 ./bootstrap

所以你的问题的答案是:请阅读文档。

(另请注意,特定软件包的构建过程通常在这里是题外话;请使用该软件包的支持论坛)