使用 GNUStep 编译应用程序包装器

发布于 2024-12-26 11:08:54 字数 1039 浏览 1 评论 0原文

我逐字遵循 GNUStep 网站上的指示。这是我的制作文件。

include $(GNUSTEP_MAKEFILES)/common.make

APP_NAME = FirstApp

FirstApp_OBJC_FILES = main.m \
MyController.m

FirstApp_MAIN_MODEL_FILE = FirstApp.gorm

FirstApp_RESOURCE_FILES = FirstApp.gorm

include $(GNUSTEP_MAKEFILES)/application.make

以下是该目录的内容(请注意,在教程中没有提到创建 main.m 文件。我认为这是自动生成的。如果这是教程作者部分的遗漏,请告诉我。另外应该做什么main.m 文件包含。

FirstApp.gorm  GNUmakefile  MyController.h  MyController.m  MyController.m~

我通过切换到目录并运行 make 进行编译,这是我收到的输出。

This is gnustep-make 2.6.1. Type 'make print-gnustep-make-help' for help.
Making all for app FirstApp...
 Creating FirstApp.app/....
make[3]: *** No rule to make target `obj/FirstApp.obj/main.m.o', needed by `FirstApp.app/./FirstApp'.  Stop.
make[2]: *** [internal-app-run-compile-submake] Error 2
make[1]: *** [FirstApp.all.app.variables] Error 2
make: *** [internal-all] Error 2

现在我可以看到这与 main.m 文件有关,但从输出中我不确定在哪里。任何帮助将不胜感激。因为我是 GNUstep 的新手,我在使用 gorm 时是否错误地删除了它的创建?

I am following the directions verbatim as on the GNUStep website. Here's my make file.

include $(GNUSTEP_MAKEFILES)/common.make

APP_NAME = FirstApp

FirstApp_OBJC_FILES = main.m \
MyController.m

FirstApp_MAIN_MODEL_FILE = FirstApp.gorm

FirstApp_RESOURCE_FILES = FirstApp.gorm

include $(GNUSTEP_MAKEFILES)/application.make

Here are the contents of the directory (noted that in the tutorial there is no mention of creating a main.m file. I assumed this was autogenerated somehow. If this is an omission on the tutorial writers part please let me know. Also what should the main.m file contain.

FirstApp.gorm  GNUmakefile  MyController.h  MyController.m  MyController.m~

I compiled by switching to the directory and running make and this is the output I recieved.

This is gnustep-make 2.6.1. Type 'make print-gnustep-make-help' for help.
Making all for app FirstApp...
 Creating FirstApp.app/....
make[3]: *** No rule to make target `obj/FirstApp.obj/main.m.o', needed by `FirstApp.app/./FirstApp'.  Stop.
make[2]: *** [internal-app-run-compile-submake] Error 2
make[1]: *** [FirstApp.all.app.variables] Error 2
make: *** [internal-all] Error 2

Now I can see that this has to do with the main.m file, but from the output I am not sure where to go from here. Any help would be greatly appreciated as I am new to GNUstep. Could I have mistakenly deleted the creation of it when working with gorm?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

云柯 2025-01-02 11:08:54

几个小时后我在这里找到了一个很棒的教程。这是链接。主文件基本上应该如下所示:

#include <AppKit/NSApplication.h>

int main(int argc, const char *argv[]) 
{
   return NSApplicationMain (argc, argv);
}

这是链接

http://gnustep .made-it.com/GSPT/xml/Tutorial_en.html#AEN412

I found an aweomse tutorial here a few hours later. Here is the link. The Main file should basically look like this:

#include <AppKit/NSApplication.h>

int main(int argc, const char *argv[]) 
{
   return NSApplicationMain (argc, argv);
}

here's the link

http://gnustep.made-it.com/GSPT/xml/Tutorial_en.html#AEN412

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文