Re: How do I force prefix file to be precompiled w/C++ compiler?
Re: How do I force prefix file to be precompiled w/C++ compiler?
- Subject: Re: How do I force prefix file to be precompiled w/C++ compiler?
- From: Jim Wintermyre <email@hidden>
- Date: Wed, 13 Jul 2011 20:48:45 -0700
At 9:15 PM -0600 7/13/11, Scott Ribe wrote:
On Jul 13, 2011, at 5:18 PM, Jim Wintermyre wrote:
I have a project that uses a prefix header that is set to be
precompiled. If I set the "Compile Sources As" setting to "C++",
then this file gets precompiled with the C++ compiler (I verified
the "-x c++-header" in the build output). But... I can't use the
C++ setting for compile sources as for this project! So, if I have
to use "According to File Type" for that setting, how do I force
the prefix file to still get compiled with the C++ compiler? I
tried adding the prefix header to the project and manually changing
its file type to to sourcecode.cpp.h, but that didn't make a
difference (it's compiled with "-x c-header"). Any other way to do
this? In case it matters, the prefix file is named <filename>.pch.
Your prefix file will be precompiled potentially multiple times, as
needed to compile the types of files in your project.
Oh yeah. I think I knew that in a past life. :) Thanks for the
reminder. That won't work for me in this case... the pch needs the
C++ compiler to compile at all. So I guess I either need to figure
out how to get everything in the project to build when forced to C++,
or fix the pch so it can also compile with the straight C compiler.
Thanks,
Jim
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden