1

I want to create a fat library in mac. So I foll this. I copied the content of makefile into an edit text and renamed it to Makefile.mak. I opened the terminal in where the makefile is located and types "make" in the terminal and hit enter. I am getting an error that "Makefile is not found". What would be the reason for this? Where I made a mistake? Please help me. Thanks

4

2 回答 2

5

您的 makefile 名称不正确。您需要将 Makefile.mak 重命名为“makefile”;这就是 make 命令正在寻找的东西。

于 2019-11-13T23:22:52.320 回答
4

make查找名称为GNUmakefilemakefile的文件Makefile。如果您将文件名更改为其中之一,则可以毫无问题地运行它。如果您仍想使用该名称,则必须运行makewith-f标志。运行命令应该是这样的:

$make -f <file_name>

在你的情况下:

$make -f Makefile.mak

于 2019-11-14T08:18:24.667 回答