make:***没有规则来制作'all'所需的目标`tools'。停止

时间:2011-11-09 11:24:12

标签: makefile embedded-linux

我正在尝试安装Flite1.4。安装是两个步骤

  1. ./configure
  2. make
  3. make给了我这个错误:

    make: *** No rule to make target `tools', needed by `all'.  Stop.
    

    请帮助解决此错误。

    [angus@bu flite-1.4-release]$ ls
    ACKNOWLEDGEMENTS  config.status  Exports.def      Makefile       src
    bin               config.sub     fliteDll.vcproj  missing        testsuite
    build             configure      flite.sln        mkinstalldirs  wince
    config            configure.in   include          palm
    config.guess      COPYING        install-sh       README
    config.log        doc            lang             sapi
    
    [angus@cebu flite-1.4-release]$ ./configure
    
    checking build system type... i686-pc-linux-gnu
    checking host system type... i686-pc-linux-gnu
    checking target system type... i686-pc-linux-gnu
    checking for gcc... gcc
    checking for C compiler default output file name... a.out
    checking whether the C compiler works... yes
    checking whether we are cross compiling... no
    checking for suffix of executables... 
    checking for suffix of object files... o
    checking whether we are using the GNU C compiler... yes
    checking whether gcc accepts -g... yes
    checking for gcc option to accept ISO C89... none needed
    checking for ranlib... ranlib
    checking for a BSD-compatible install... /usr/bin/install -c
    checking for ar... ar
    checking how to run the C preprocessor... gcc -E
    checking for grep that handles long lines and -e... /bin/grep
    checking for egrep... /bin/grep -E
    checking for ANSI C header files... yes
    checking for sys/types.h... yes
    checking for sys/stat.h... yes
    checking for stdlib.h... yes
    checking for string.h... yes
    checking for memory.h... yes
    checking for strings.h... yes
    checking for inttypes.h... yes
    checking for stdint.h... yes
    checking for unistd.h... yes
    checking whether byte ordering is bigendian... no
    checking for mmap... yes
    checking sys/soundcard.h usability... yes
    checking sys/soundcard.h presence... yes
    checking for sys/soundcard.h... yes
    checking machine/soundcard.h usability... no
    checking machine/soundcard.h presence... no
    checking for machine/soundcard.h... no
    checking sys/audioio.h usability... no
    checking sys/audioio.h presence... no
    checking for sys/audioio.h... no
    checking mmsystem.h usability... no
    checking mmsystem.h presence... no
    checking for mmsystem.h... no
    configure: creating ./config.status
    config.status: creating config/config
    config.status: creating config/system.mak
    
    
    [angus@bu flite-1.4-release]$ make
    
    make: *** No rule to make target `tools', needed by `all'.  Stop.
    

1 个答案:

答案 0 :(得分:1)

你的Makefile看起来很糟糕。其中的某个地方看起来像:

all: <some-other-targets> tools

其中表示目标all需要制作目标tools。但没有线 在Makefile中定义目标tools

对于已发布的代码,这似乎很奇怪。关于如何继续的一些想法:

  1. 确保目标tools拼写正确。案件很重要。
  2. 您可以尝试通过移除上述行上的工具来删除alltools的依赖关系,然后重新运行make。这并不能完整地构建你的包,但至少你知道是否还有其他问题需要解决。
  3. 运行configure --help并查看--enable-XXXXX之类的可用选项,以便与configure一起使用。使用configure选项可能会修改Makefile并避免构建tools目标。
  4. 请注意,每次调用configure时,都会重新生成Makefile:因此您的修改可能会丢失。