【问题标题】:"No rule to make target `install`" error when using make install使用 make install 时出现“No rule to make target `install`”错误
【发布时间】:2016-06-07 22:49:40
【问题描述】:

我正在尝试安装 sia-hsd 报警系统, github link

到 ./configure 输出为

Setting top to                           : /home/siahsd-master
Setting out to                           : /home/siahsd-master/build
Checking for program gcc,cc              : gcc
Checking for program ar                  : /usr/bin/ar
Checking for program pkg-config          : /usr/bin/pkg-config
Checking for 'glib-2.0'                  : yes
Checking for 'talloc'                    : yes
Checking for 'tevent'                    : yes
Checking for 'samba-util'                : yes
Checking for 'ndr'                       : yes
Checking for header stdio.h              : yes
Checking for header stdlib.h             : yes
Checking for header stdint.h             : yes
Checking for header stdbool.h            : yes
Checking for header sys/time.h           : yes
Checking for header sys/types.h          : yes
Checking for header sys/stat.h           : yes
Checking for header netinet/in.h         : yes
Checking for header arpa/inet.h          : yes
Checking for header unistd.h             : yes
Checking for header string.h             : yes
Checking for header fcntl.h              : yes
Checking for header errno.h              : yes
Checking for header talloc.h             : yes
Checking for header glib.h               : yes
Checking for header glibconfig.h         : yes
Checking for header dbi/dbi.h            : yes
Checking for header util/data_blob.h     : yes
Checking for header core/ntstatus.h      : yes
Checking for header charset.h            : yes
Checking for library dbi                 : yes
Checking for library talloc              : yes
Checking for library ndr                 : yes
Checking for library gmp                 : yes
Checking for library hogweed             : yes
Checking for library nettle              : yes
'configure' finished successfully (2.057s)

make "CPP=gcc -E -ffreestanding" 命令的输出如下

[21/27] cstlib: build/jsonbot.c.7.o -> build/libjsonbot.a
[22/27] cstlib: build/siahs.c.6.o -> build/libsiahs.a
[23/27] cstlib: build/sia.c.5.o -> build/libsia.a
[24/27] cstlib: build/config.c.4.o -> build/libconfig.a
[25/27] cprogram: build/chirond.c.10.o build/ndr_chiron.c.10.o -> build/chirond
[26/27] cprogram: build/siahsd.c.8.o -> build/siahsd
[27/27] cprogram: build/secipd.c.9.o build/crc16.c.9.o build/ndr_secip.c.9.o -> build/secipd
Waf: Leaving directory `/home/siahsd-master/build'
'build' finished successfully (3.389s)

当我使用 make install 命令时,我得到了这个错误:

make: *** No rule to make target `install'.  Stop.

关于如何解决它的任何想法?

非常感谢

【问题讨论】:

  • CC++ 是不同的。请不要同时标记问题。
  • Makefile 中是否有名为 install 的目标?
  • 这不是一个编程问题。这也不是一个包含足够信息来给出有意义答案的问题(例如,您甚至要安装什么?什么是“sia-hsd”?什么是 full 错误输出等) .

标签: c gcc debian


【解决方案1】:

如上所述,Makefile 不包含“install”目标,因此 make 不知道如何制作它。查看 waf 构建文件,它没有提供有关如何实现安装目标的任何线索。显然构建软件后不需要安装,只需运行它即可。

您可以在 Makefile 中实现“dist”目标以查看它实际打包的内容。也许这提供了关于应该安装什么的提示。

dist:
    @bin/waf dist

【讨论】:

  • 谢谢会检查它,你能告诉我如何运行它。我的意思是我必须运行哪个文件。
  • 如果您将上述行添加到“Makefile”中,您应该能够像运行其他 make 命令一样运行“make dist”。请确保使用“制表符”字符进行缩进,在添加的行之后也有一个空行。
猜你喜欢
  • 2021-01-01
  • 2019-09-15
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 2013-02-02
  • 2016-11-19
  • 2015-06-23
  • 2021-11-22
相关资源
最近更新 更多