开发者

GNUStep make with a precompiled (and prefixed) .pch header from Xcode project?

I'm trying to build an Xcode project with GNUStep-make. Right now the project is very small (3 classes) however it will grow to hundreds of classes over the coming weeks so I'm trying to get everything figured out and well-organised now.

Xcode creates a ProjectName_Prefix.pch file which is a header that: a) get precompiled and b) is prefixed to every file in my project; at least if I understand correctly.

Now, how do I tell GNUStep-make what to do with this file when it builds? I've added it to the XXX_PRECOMPILED_HEADERS variable.

Cioccolata_OBJC_PRECOMPILED_HEADERS = Cioccolata_Prefix.pch

With this in place the build fails with the error:

Making all for framework Cioccolata...
make[1]: *** No rule to make target `/Users/chris/Projects/Mac/Cio开发者_开发知识库ccolata/build/GNUStep/obj/PrecompiledHeaders/ObjC/Cioccolata_Prefix.pch', needed by `internal-precompile-headers'.  Stop.
make: *** [Cioccolata.all.framework.variables] Error 2

I've also got the following in my makefile:

ADDITIONAL_OBJC_FLAGS += -include Cioccolata_Prefix.pch -Winvalid-pch

I'm not sure what I've done wrong here. I basically have tried to follow the GNUStep documentation for precompiled headers.

None of my project's source files expressly include the Foundation framework since this header does that.


Thanks for pointing our attention to this problem and for your patch! :-)

This is now fixed on gnustep-make trunk, and so will be fixed in gnustep-make 2.4.0 once released.

Nicola Pero (gnustep-make)

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜